difftreelog
Merge branch 'develop' into feature/multi-assets-redone
in: master
108 files changed
.docker/Dockerfile-chain-dev-unitdiffbeforeafterboth--- a/.docker/Dockerfile-chain-dev-unit
+++ b/.docker/Dockerfile-chain-dev-unit
@@ -23,4 +23,4 @@
WORKDIR /dev_chain
-RUN cargo test --features=limit-testing
+CMD cargo test --features=limit-testing
.docker/Dockerfile-parachain-node-onlydiffbeforeafterboth--- /dev/null
+++ b/.docker/Dockerfile-parachain-node-only
@@ -0,0 +1,103 @@
+# ===== Rust builder =====
+FROM ubuntu:20.04 as rust-builder
+LABEL maintainer="Unique.Network"
+
+ARG RUST_TOOLCHAIN=
+
+ENV RUST_TOOLCHAIN $RUST_TOOLCHAIN
+ENV CARGO_HOME="/cargo-home"
+ENV PATH="/cargo-home/bin:$PATH"
+ENV TZ=UTC
+RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
+
+RUN apt-get update && \
+ apt-get install -y curl cmake pkg-config libssl-dev git clang && \
+ apt-get clean && \
+ rm -r /var/lib/apt/lists/*
+
+RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain none
+
+RUN rustup toolchain uninstall $(rustup toolchain list) && \
+ rustup toolchain install $RUST_TOOLCHAIN && \
+ rustup default $RUST_TOOLCHAIN && \
+ rustup target list --installed && \
+ rustup show
+RUN rustup target add wasm32-unknown-unknown --toolchain $RUST_TOOLCHAIN
+
+RUN mkdir /unique_parachain
+WORKDIR /unique_parachain
+
+
+# ===== BUILD current version ======
+FROM rust-builder as builder-unique-current
+
+ARG PROFILE=release
+ARG FEATURE=
+ARG MAINNET_BRANCH=
+ARG REPO_URL=
+
+WORKDIR /unique_parachain
+
+RUN git clone $REPO_URL -b $MAINNET_BRANCH . && \
+ cargo build --features=$FEATURE --$PROFILE
+
+# ===== BUILD target version ======
+FROM rust-builder as builder-unique-target
+
+ARG PROFILE=release
+ARG FEATURE=
+
+COPY . /unique_parachain
+WORKDIR /unique_parachain
+
+RUN cargo build --features=$FEATURE --$PROFILE
+
+# ===== BUILD POLKADOT =====
+FROM rust-builder as builder-polkadot
+
+ARG POLKADOT_BUILD_BRANCH=
+ENV POLKADOT_BUILD_BRANCH $POLKADOT_BUILD_BRANCH
+
+
+WORKDIR /unique_parachain
+
+RUN git clone -b $POLKADOT_BUILD_BRANCH --depth 1 https://github.com/paritytech/polkadot.git && \
+ cd polkadot && \
+ cargo build --release
+
+# ===== RUN ======
+
+FROM ubuntu:20.04
+
+ARG RUNTIME=
+ENV RUNTIME $RUNTIME
+
+RUN apt-get -y update && \
+ apt-get -y install curl git && \
+ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash && \
+ export NVM_DIR="$HOME/.nvm" && \
+ [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
+ nvm install v16.16.0 && \
+ nvm use v16.16.0
+
+RUN git clone https://github.com/uniquenetwork/polkadot-launch -b feature/runtime-upgrade-testing
+
+RUN export NVM_DIR="$HOME/.nvm" && \
+ [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
+ cd /polkadot-launch && \
+ npm install --global yarn && \
+ yarn install
+
+RUN echo "$RUNTIME"
+
+COPY --from=builder-unique-current /unique_parachain/target/release/unique-collator /unique-chain/current/release/
+COPY --from=builder-unique-target /unique_parachain/target/release/unique-collator /unique-chain/target/release/
+COPY --from=builder-unique-target /unique_parachain/target/release/wbuild/"$RUNTIME"-runtime/"$RUNTIME"_runtime.compact.compressed.wasm /unique-chain/target/release/wbuild/"$RUNTIME"-runtime/"$RUNTIME"_runtime.compact.compressed.wasm
+
+COPY --from=builder-polkadot /unique_parachain/polkadot/target/release/polkadot /polkadot/target/release/
+COPY --from=builder-polkadot /unique_parachain/polkadot/target/release/wbuild/westend-runtime/westend_runtime.compact.compressed.wasm /polkadot/target/release/wbuild/westend-runtime/westend_runtime.compact.compressed.wasm
+
+CMD export NVM_DIR="$HOME/.nvm" && \
+ [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" && \
+ cd /polkadot-launch && \
+ yarn start launch-config.json --test-upgrade-parachains -w -n
.docker/docker-compose.tmp-node.j2diffbeforeafterboth--- /dev/null
+++ b/.docker/docker-compose.tmp-node.j2
@@ -0,0 +1,33 @@
+version: "3.5"
+
+services:
+ node-parachain:
+ build:
+ args:
+ - "RUST_TOOLCHAIN={{ RUST_TOOLCHAIN }}"
+ - "BRANCH={{ BRANCH }}"
+ - "REPO_URL={{ REPO_URL }}"
+ - "FEATURE={{ FEATURE }}"
+ - "RUNTIME={{ RUNTIME }}"
+ - "POLKADOT_BUILD_BRANCH={{ POLKADOT_BUILD_BRANCH }}"
+ - "MAINNET_TAG={{ MAINNET_TAG }}"
+ - "MAINNET_BRANCH={{ MAINNET_BRANCH }}"
+ context: ../
+ dockerfile: .docker/Dockerfile-parachain-node-only
+ image: node-parachain
+ container_name: node-parachain
+ volumes:
+ - type: bind
+ source: ./launch-config-forkless-nodata.json
+ target: /polkadot-launch/launch-config.json
+ read_only: true
+ expose:
+ - 9944
+ - 9933
+ ports:
+ - 127.0.0.1:9944:9944
+ - 127.0.0.1:9933:9933
+ logging:
+ options:
+ max-size: "1m"
+ max-file: "3"
.docker/forkless-config/launch-config-forkless-data.j2diffbeforeafterboth--- a/.docker/forkless-config/launch-config-forkless-data.j2
+++ b/.docker/forkless-config/launch-config-forkless-data.j2
@@ -86,7 +86,7 @@
},
"parachains": [
{
- "bin": "/unique-chain/target/release/unique-collator",
+ "bin": "/unique-chain/current/release/unique-collator",
"upgradeBin": "/unique-chain/target/release/unique-collator",
"upgradeWasm": "/unique-chain/target/release/wbuild/{{ FEATURE }}/{{ RUNTIME }}_runtime.compact.compressed.wasm",
"id": "1000",
.docker/forkless-config/launch-config-forkless-nodata.j2diffbeforeafterboth--- a/.docker/forkless-config/launch-config-forkless-nodata.j2
+++ b/.docker/forkless-config/launch-config-forkless-nodata.j2
@@ -101,7 +101,8 @@
"--rpc-cors=all",
"--unsafe-rpc-external",
"--unsafe-ws-external",
- "-lxcm=trace"
+ "-lxcm=trace",
+ "--ws-max-connections=1000"
]
},
{
@@ -113,7 +114,8 @@
"--rpc-cors=all",
"--unsafe-rpc-external",
"--unsafe-ws-external",
- "-lxcm=trace"
+ "-lxcm=trace",
+ "--ws-max-connections=1000"
]
}
]
.github/workflows/build-test-master.ymldiffbeforeafterboth--- a/.github/workflows/build-test-master.yml
+++ /dev/null
@@ -1,127 +0,0 @@
-name: yarn test para
-
-# Controls when the action will run.
-on:
- # Triggers the workflow on push or pull request events but only for the master branch
- pull_request:
- branches:
- - master
- types:
- - opened
- - reopened
- - synchronize #commit(s) pushed to the pull request
- - ready_for_review
-
- # Allows you to run this workflow manually from the Actions tab
- workflow_dispatch:
-
-#Define Workflow variables
-env:
- REPO_URL: ${{ github.server_url }}/${{ github.repository }}
-
-concurrency:
- group: ${{ github.workflow }}-${{ github.ref }}
- cancel-in-progress: true
-
-# A workflow run is made up of one or more jobs that can run sequentially or in parallel
-jobs:
-
- master-build-and-test:
- # The type of runner that the job will run on
- runs-on: [self-hosted-ci,large]
- timeout-minutes: 1380
-
- name: ${{ matrix.network }}
-
- continue-on-error: true #Do not stop testing of matrix runs failed.
-
- strategy:
- matrix:
- include:
- - network: "opal"
- features: "opal-runtime"
- - network: "quartz"
- features: "quartz-runtime"
- - network: "unique"
- features: "unique-runtime"
-
- steps:
- - name: Skip if pull request is in Draft
- # `if: github.event.pull_request.draft == true` should be kept here, at
- # the step level, rather than at the job level. The latter is not
- # recommended because when the PR is moved from "Draft" to "Ready to
- # review" the workflow will immediately be passing (since it was skipped),
- # even though it hasn't actually ran, since it takes a few seconds for
- # the workflow to start. This is also disclosed in:
- # https://github.community/t/dont-run-actions-on-draft-pull-requests/16817/17
- # That scenario would open an opportunity for the check to be bypassed:
- # 1. Get your PR approved
- # 2. Move it to Draft
- # 3. Push whatever commits you want
- # 4. Move it to "Ready for review"; now the workflow is passing (it was
- # skipped) and "Check reviews" is also passing (it won't be updated
- # until the workflow is finished)
- if: github.event.pull_request.draft == true
- run: exit 1
-
- - name: Clean Workspace
- uses: AutoModality/action-clean@v1.1.0
-
- # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- - uses: actions/checkout@v3
- with:
- ref: ${{ github.head_ref }}
-
- - name: Read .env file
- uses: xom9ikk/dotenv@v1.0.2
-
- - name: Generate ENV related extend file for docker-compose
- uses: cuchi/jinja2-action@v1.2.0
- with:
- template: .docker/docker-compose.tmp-master.j2
- output_file: .docker/docker-compose.${{ matrix.network }}.yml
- variables: |
- REPO_URL=${{ github.server_url }}/${{ github.repository }}.git
- RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}
- POLKADOT_BUILD_BRANCH=${{ env.POLKADOT_BUILD_BRANCH }}
- FEATURE=${{ matrix.features }}
- BRANCH=${{ github.head_ref }}
-
- - name: Show build configuration
- run: cat .docker/docker-compose.${{ matrix.network }}.yml
-
- - name: Build the stack
- run: docker-compose -f ".docker/docker-compose-master.yml" -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build
-
- - uses: actions/setup-node@v3
- with:
- node-version: 16
-
- - name: Run tests
- run: |
- cd tests
- yarn install
- yarn add mochawesome
- echo "Ready to start tests"
- node scripts/readyness.js
- NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}
- env:
- RPC_URL: http://127.0.0.1:9933/
-
- - name: Test Report
- uses: phoenix-actions/test-reporting@v8
- id: test-report
- if: success() || failure() # run this step even if previous step failed
- with:
- name: Tests ${{ matrix.network }} # Name of the check run which will be created
- path: tests/mochawesome-report/test-*.json # Path to test results
- reporter: mochawesome-json
- fail-on-error: 'false'
-
- - name: Read output variables
- run: |
- echo "url is ${{ steps.test-report.outputs.runHtmlUrl }}"
-
- - name: Stop running containers
- if: always() # run this step always
- run: docker-compose -f ".docker/docker-compose-master.yml" -f ".docker/docker-compose.${{ matrix.network }}.yml" down
.github/workflows/codestyle.ymldiffbeforeafterboth--- a/.github/workflows/codestyle.yml
+++ b/.github/workflows/codestyle.yml
@@ -49,7 +49,7 @@
run: cargo fmt -- --check # In that mode it returns only exit code.
- name: Cargo fmt state
if: success()
- run: echo "Nothing to do. Cargo fmt returned exit code 0."
+ run: echo "Nothing to do. Command 'cargo fmt -- --check' returned exit code 0."
clippy:
.github/workflows/dev-build-tests.ymldiffbeforeafterboth--- a/.github/workflows/dev-build-tests.yml
+++ b/.github/workflows/dev-build-tests.yml
@@ -123,66 +123,3 @@
- name: Stop running containers
if: always() # run this step always
run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.${{ matrix.network }}.yml" down
-
-
- dev_build_unit_test:
- # The type of runner that the job will run on
- runs-on: [self-hosted-ci,medium]
- timeout-minutes: 1380
-
- name: unit tests
-
-
- continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.
-
-
- steps:
- - name: Skip if pull request is in Draft
- # `if: github.event.pull_request.draft == true` should be kept here, at
- # the step level, rather than at the job level. The latter is not
- # recommended because when the PR is moved from "Draft" to "Ready to
- # review" the workflow will immediately be passing (since it was skipped),
- # even though it hasn't actually ran, since it takes a few seconds for
- # the workflow to start. This is also disclosed in:
- # https://github.community/t/dont-run-actions-on-draft-pull-requests/16817/17
- # That scenario would open an opportunity for the check to be bypassed:
- # 1. Get your PR approved
- # 2. Move it to Draft
- # 3. Push whatever commits you want
- # 4. Move it to "Ready for review"; now the workflow is passing (it was
- # skipped) and "Check reviews" is also passing (it won't be updated
- # until the workflow is finished)
- if: github.event.pull_request.draft == true
- run: exit 1
-
- - name: Clean Workspace
- uses: AutoModality/action-clean@v1.1.0
-
- # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- - uses: actions/checkout@v3
- with:
- ref: ${{ github.head_ref }} #Checking out head commit
-
- - name: Read .env file
- uses: xom9ikk/dotenv@v1.0.2
-
- - name: Generate ENV related extend file for docker-compose
- uses: cuchi/jinja2-action@v1.2.0
- with:
- template: .docker/docker-compose.tmp-unit.j2
- output_file: .docker/docker-compose.unit.yml
- variables: |
- RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}
- FEATURE=${{ matrix.features }}
-
-
- - name: Show build configuration
- run: cat .docker/docker-compose.unit.yml
-
- - name: Build the stack
- run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.unit.yml" up -d --build --remove-orphans
-
-
- - name: Stop running containers
- if: always() # run this step always
- run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.unit.yml" down
.github/workflows/nodes-only-update.ymldiffbeforeafterboth--- /dev/null
+++ b/.github/workflows/nodes-only-update.yml
@@ -0,0 +1,301 @@
+name: nodes-only update
+
+# Controls when the action will run.
+on:
+ # Triggers the workflow on push or pull request events but only for the master branch
+ pull_request:
+ branches:
+ - master
+ types:
+ - opened
+ - reopened
+ - synchronize #commit(s) pushed to the pull request
+ - ready_for_review
+
+ # Allows you to run this workflow manually from the Actions tab
+ workflow_dispatch:
+
+#Define Workflow variables
+env:
+ REPO_URL: ${{ github.server_url }}/${{ github.repository }}
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+# A workflow run is made up of one or more jobs that can run sequentially or in parallel
+jobs:
+
+ prepare-execution-marix:
+
+ name: Prepare execution matrix
+
+ runs-on: self-hosted-ci
+ outputs:
+ matrix: ${{ steps.create_matrix.outputs.matrix }}
+
+ steps:
+
+ - name: Clean Workspace
+ uses: AutoModality/action-clean@v1.1.0
+
+ # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
+ - uses: actions/checkout@v3
+ with:
+ ref: ${{ github.head_ref }} #Checking out head commit
+
+ - name: Read .env file
+ uses: xom9ikk/dotenv@v1.0.2
+
+ - name: Create Execution matrix
+ uses: fabiocaccamo/create-matrix-action@v2
+ id: create_matrix
+ with:
+ matrix: |
+ network {opal}, runtime {opal}, features {opal-runtime}, mainnet_branch {${{ env.QUARTZ_MAINNET_TAG }}}
+ network {quartz}, runtime {quartz}, features {quartz-runtime}, mainnet_branch {${{ env.QUARTZ_MAINNET_TAG }}}
+ network {unique}, runtime {unique}, features {unique-runtime}, mainnet_branch {${{ env.UNIQUE_MAINNET_TAG }}}
+
+
+
+ forkless-update-nodata:
+ needs: prepare-execution-marix
+ # The type of runner that the job will run on
+ runs-on: [self-hosted-ci,large]
+
+
+
+ timeout-minutes: 1380
+
+ name: ${{ matrix.network }}
+
+ continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.
+
+ strategy:
+ matrix:
+ include: ${{fromJson(needs.prepare-execution-marix.outputs.matrix)}}
+
+
+ steps:
+ - name: Skip if pull request is in Draft
+ # `if: github.event.pull_request.draft == true` should be kept here, at
+ # the step level, rather than at the job level. The latter is not
+ # recommended because when the PR is moved from "Draft" to "Ready to
+ # review" the workflow will immediately be passing (since it was skipped),
+ # even though it hasn't actually ran, since it takes a few seconds for
+ # the workflow to start. This is also disclosed in:
+ # https://github.community/t/dont-run-actions-on-draft-pull-requests/16817/17
+ # That scenario would open an opportunity for the check to be bypassed:
+ # 1. Get your PR approved
+ # 2. Move it to Draft
+ # 3. Push whatever commits you want
+ # 4. Move it to "Ready for review"; now the workflow is passing (it was
+ # skipped) and "Check reviews" is also passing (it won't be updated
+ # until the workflow is finished)
+ if: github.event.pull_request.draft == true
+ run: exit 1
+
+ - name: Clean Workspace
+ uses: AutoModality/action-clean@v1.1.0
+
+ # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
+ - uses: actions/checkout@v3
+ with:
+ ref: ${{ github.head_ref }} #Checking out head commit
+
+ - name: Read .env file
+ uses: xom9ikk/dotenv@v1.0.2
+
+ - name: Generate ENV related extend file for docker-compose
+ uses: cuchi/jinja2-action@v1.2.0
+ with:
+ template: .docker/docker-compose.tmp-node.j2
+ output_file: .docker/docker-compose.node.${{ matrix.network }}.yml
+ variables: |
+ REPO_URL=${{ github.server_url }}/${{ github.repository }}.git
+ RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}
+ POLKADOT_BUILD_BRANCH=${{ env.POLKADOT_BUILD_BRANCH }}
+ POLKADOT_MAINNET_BRANCH=${{ env.POLKADOT_MAINNET_BRANCH }}
+ MAINNET_TAG=${{ matrix.mainnet_tag }}
+ MAINNET_BRANCH=${{ matrix.mainnet_branch }}
+ FEATURE=${{ matrix.features }}
+ RUNTIME=${{ matrix.runtime }}
+ BRANCH=${{ github.head_ref }}
+
+ - name: Show build configuration
+ run: cat .docker/docker-compose.node.${{ matrix.network }}.yml
+
+ - name: Generate launch-config-forkless-nodata.json
+ uses: cuchi/jinja2-action@v1.2.0
+ with:
+ template: .docker/forkless-config/launch-config-forkless-nodata.j2
+ output_file: .docker/launch-config-forkless-nodata.json
+ variables: |
+ FEATURE=${{ matrix.features }}
+ RUNTIME=${{ matrix.runtime }}
+
+ - name: Show launch-config-forkless configuration
+ run: cat .docker/launch-config-forkless-nodata.json
+
+ - uses: actions/setup-node@v3
+ with:
+ node-version: 16
+
+ - name: Build the stack
+ run: docker-compose -f ".docker/docker-compose-forkless.yml" -f ".docker/docker-compose.node.${{ matrix.network }}.yml" up -d --build --remove-orphans --force-recreate --timeout 300
+
+ # π POLKADOT LAUNCH COMPLETE π
+ - name: Check if docker logs consist messages related to testing of Node Parachain Upgrade.
+ if: success()
+ run: |
+ counter=160
+ function check_container_status {
+ docker inspect -f {{.State.Running}} node-parachain
+ }
+ function do_docker_logs {
+ docker logs --details node-parachain 2>&1
+ }
+ function is_started {
+ if [ "$(check_container_status)" == "true" ]; then
+ echo "Container: node-parachain RUNNING";
+ echo "Check Docker logs"
+ DOCKER_LOGS=$(do_docker_logs)
+ if [[ ${DOCKER_LOGS} = *"POLKADOT LAUNCH COMPLETE"* ]];then
+ echo "π POLKADOT LAUNCH COMPLETE π"
+ return 0
+ else
+ echo "Message not found in logs output, repeating..."
+ return 1
+ fi
+ else
+ echo "Container node-parachain NOT RUNNING"
+ echo "Halting all future checks"
+ exit 1
+ fi
+ echo "something goes wrong"
+ exit 1
+ }
+ while ! is_started; do
+ echo "Waiting for special message in log files "
+ sleep 30s
+ counter=$(( $counter - 1 ))
+ echo "Counter: $counter"
+ if [ "$counter" -gt "0" ]; then
+ continue
+ else
+ break
+ fi
+ done
+ echo "Halting script"
+ exit 0
+ shell: bash
+
+ - name: Run tests before Node Parachain upgrade
+ working-directory: tests
+ run: |
+ yarn install
+ yarn add mochawesome
+ echo "Ready to start tests"
+ NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}
+ env:
+ RPC_URL: http://127.0.0.1:9933/
+
+ - name: Test Report Before Node upgrade
+ uses: phoenix-actions/test-reporting@v8
+ id: test-report-before
+ if: success() || failure() # run this step even if previous step failed
+ with:
+ name: Tests before node upgrade ${{ matrix.network }} # Name of the check run which will be created
+ path: tests/mochawesome-report/test-*.json # Path to test results
+ reporter: mochawesome-json
+ fail-on-error: 'false'
+
+ - name: Send SIGUSR1 to polkadotlaunch process
+ if: success() || failure()
+ run: |
+ #Get PID of polkadot-launch
+ PID=$(docker exec node-parachain pidof 'polkadot-launch')
+ echo "Polkadot-launch PID: $PID"
+ #Send SIGUSR1 signal to $PID
+ docker exec node-parachain kill -SIGUSR1 ${PID}
+
+ # π All parachain collators restarted with the new binaries.
+ - name: Check if docker logs consist messages related to testing of Node Parachain Upgrade.
+ if: success()
+ run: |
+ counter=160
+ function check_container_status {
+ docker inspect -f {{.State.Running}} node-parachain
+ }
+ function do_docker_logs {
+ docker logs --details node-parachain 2>&1
+ }
+ function is_started {
+ if [ "$(check_container_status)" == "true" ]; then
+ echo "Container: node-parachain RUNNING";
+ echo "Check Docker logs"
+ DOCKER_LOGS=$(do_docker_logs)
+ if [[ ${DOCKER_LOGS} = *"All parachain collators restarted with the new binaries."* ]];then
+ echo "π All parachain collators restarted with the new binaries."
+ return 0
+ else
+ echo "Message not found in logs output, repeating..."
+ return 1
+ fi
+ else
+ echo "Container node-parachain NOT RUNNING"
+ echo "Halting all future checks"
+ exit 1
+ fi
+ echo "something goes wrong"
+ exit 1
+ }
+ while ! is_started; do
+ echo "Waiting for special message in log files "
+ sleep 30s
+ counter=$(( $counter - 1 ))
+ echo "Counter: $counter"
+ if [ "$counter" -gt "0" ]; then
+ continue
+ else
+ break
+ fi
+ done
+ echo "Halting script"
+ exit 0
+ shell: bash
+
+ - name: Run tests after Node Parachain upgrade
+ working-directory: tests
+ run: |
+ yarn install
+ yarn add mochawesome
+ echo "Ready to start tests"
+ NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}
+ env:
+ RPC_URL: http://127.0.0.1:9933/
+
+ - name: Test Report After Node upgrade
+ uses: phoenix-actions/test-reporting@v8
+ id: test-report-after
+ if: success() || failure() # run this step even if previous step failed
+ with:
+ name: Tests after node upgrade ${{ matrix.network }} # Name of the check run which will be created
+ path: tests/mochawesome-report/test-*.json # Path to test results
+ reporter: mochawesome-json
+ fail-on-error: 'false'
+
+
+ - name: Stop running containers
+ if: always() # run this step always
+ run: docker-compose -f ".docker/docker-compose-forkless.yml" -f ".docker/docker-compose.node.${{ matrix.network }}.yml" down --volumes
+
+ - name: Remove builder cache
+ if: always() # run this step always
+ run: |
+ docker builder prune -f
+ docker system prune -f
+
+ - name: Clean Workspace
+ if: always()
+ uses: AutoModality/action-clean@v1.1.0
.github/workflows/unit-test.ymldiffbeforeafterboth--- /dev/null
+++ b/.github/workflows/unit-test.yml
@@ -0,0 +1,84 @@
+name: unit tests
+
+# Controls when the action will run.
+on:
+ # Triggers the workflow on push or pull request events but only for the master branch
+ pull_request:
+ branches:
+ - develop
+ - master
+ types:
+ - opened
+ - reopened
+ - synchronize #commit(s) pushed to the pull request
+ - ready_for_review
+
+ # Allows you to run this workflow manually from the Actions tab
+ workflow_dispatch:
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+# A workflow run is made up of one or more jobs that can run sequentially or in parallel
+jobs:
+
+ unit_tests:
+ # The type of runner that the job will run on
+ runs-on: [self-hosted-ci,medium]
+ timeout-minutes: 1380
+
+ name: ${{ github.base_ref }}
+
+ continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.
+
+
+ steps:
+ - name: Skip if pull request is in Draft
+ # `if: github.event.pull_request.draft == true` should be kept here, at
+ # the step level, rather than at the job level. The latter is not
+ # recommended because when the PR is moved from "Draft" to "Ready to
+ # review" the workflow will immediately be passing (since it was skipped),
+ # even though it hasn't actually ran, since it takes a few seconds for
+ # the workflow to start. This is also disclosed in:
+ # https://github.community/t/dont-run-actions-on-draft-pull-requests/16817/17
+ # That scenario would open an opportunity for the check to be bypassed:
+ # 1. Get your PR approved
+ # 2. Move it to Draft
+ # 3. Push whatever commits you want
+ # 4. Move it to "Ready for review"; now the workflow is passing (it was
+ # skipped) and "Check reviews" is also passing (it won't be updated
+ # until the workflow is finished)
+ if: github.event.pull_request.draft == true
+ run: exit 1
+
+ - name: Clean Workspace
+ uses: AutoModality/action-clean@v1.1.0
+
+ # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
+ - uses: actions/checkout@v3
+ with:
+ ref: ${{ github.head_ref }} #Checking out head commit
+
+ - name: Read .env file
+ uses: xom9ikk/dotenv@v1.0.2
+
+ - name: Generate ENV related extend file for docker-compose
+ uses: cuchi/jinja2-action@v1.2.0
+ with:
+ template: .docker/docker-compose.tmp-unit.j2
+ output_file: .docker/docker-compose.unit.yml
+ variables: |
+ RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}
+ FEATURE=${{ matrix.features }}
+
+
+ - name: Show build configuration
+ run: cat .docker/docker-compose.unit.yml
+
+ - name: Build the stack
+ run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.unit.yml" up --build --force-recreate --timeout 300 --remove-orphans --exit-code-from node-dev
+
+ - name: Stop running containers
+ if: always() # run this step always
+ run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.unit.yml" down
.maintain/frame-weight-template.hbsdiffbeforeafterboth--- a/.maintain/frame-weight-template.hbs
+++ b/.maintain/frame-weight-template.hbs
@@ -14,6 +14,7 @@
#![cfg_attr(rustfmt, rustfmt_skip)]
#![allow(unused_parens)]
#![allow(unused_imports)]
+#![allow(missing_docs)]
#![allow(clippy::unnecessary_cast)]
use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
Cargo.lockdiffbeforeafterboth977 packageslockfile v3
Might be heavy and slow!
addr2line
0.17.0crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb9ecd88a8c8378ca913a680cd98f0f13ac67383d35993f86c90a70e3f137816bdepends onadler
1.0.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35feused byaead
0.4.3crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0b613b8e1e3cf911a086f53f03bf286f52fd7a7258e4fa606f0ef220d39d8877depends onaes
0.7.5crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8used byaes-gcm
0.9.4crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumdf5f85a83a7d8b0442b6aa7b504b8212c1733da07b98aae43d4bc21b2cb3cdf6used byahash
0.7.6crates.ioβ 3β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47aho-corasick
0.7.18crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1e37cfd5e7657ada45f742d6e99ca5788580b5c529dc78faf11ece6dc702656fdepends onused byalways-assert
0.1.2crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfbf688625d06217d5b1bb0ea9d9c44a1635fd0ee3534466388d18203174f4d11android_system_properties
0.1.4crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd7ed72e1635e121ca3e79420540282af22da58be50de153d36f81ddc6b83aa9edepends onused byansi_term
0.12.1crates.ioβ 1β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd52a9bb7ec0cf484c551830a7ce27bd20d67eac647e1befb56b0be4ee39a55d2depends onanyhow
1.0.61crates.ioβ 0β 14sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum508b352bb5c066aac251f6daf6b36eccd03e8a88e8081cd44959ea277a3af9a8approx
0.5.1crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcab112f0a86d568ea0e627cc1d6be74a1e9cd55214684db5561995f6dad897c6depends onarrayref
0.3.6crates.ioβ 0β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma4c527152e37cf757a3f78aae5a06fbeefdb07ccc535c980a3208ee3060dd544arrayvec
0.4.12crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcd9fd44efafa8690358b7408d253adf110036b88f55672a933f01d616ad9b1b9depends onarrayvec
0.5.2crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum23b62fc65de8e4e7f52534fb52b0f3ed04746ae267519eef2a83941e8085068barrayvec
0.7.2crates.ioβ 0β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6asn1_der
0.7.5crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume22d1f4b888c298a027c99dc9048015fac177587de20fc30232a057dfbe24a21used byassert_matches
1.5.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9b34d609dfbaf33d6889b2b7106d3ca345eacad44200913df5ba02bfd31d2ba9async-attributes
1.1.2crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma3203e79f4dd9bdda415ed03cf14dae5a2bf775c683a00f94e9cd1faf0f596e5depends onused byasync-channel
1.7.1crates.ioβ 3β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume14485364214912d3b19cc3435dde4df66065127f05fa0d75c712f36f12c2f28async-executor
1.4.1crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum871f9bb5e0a22eeb7e8cf16641feb87c9dc67032ccf8ff49e772eb9941d3a965depends onused byasync-global-executor
2.2.0crates.ioβ 8β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5262ed948da60dd8956c6c5aca4d4163593dddb7b32d73267c93dab7b2e98940depends onasync-io
1.7.0crates.ioβ 11β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume5e18f61464ae81cde0a23e713ae8fd299580c54d697a35820cfd0625b8b0e07depends onasync-lock
2.5.0crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume97a171d191782fba31bb902b14ad94e24a68145032b7eedf871ab0bc0d077b6depends onasync-process
1.4.0crates.ioβ 9β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcf2c06e30a24e8c78a3987d07f0930edf76ef35e027e7bdb063fccafdad1f60cdepends onasync-std
1.12.0crates.ioβ 20β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum62565bb4402e926b29953c785397c6dc0391b7b446e45008b0049eb43cec6f5ddepends on- async-attributes
1.1.2 - async-channel
1.7.1 - async-global-executor
2.2.0 - async-io
1.7.0 - async-lock
2.5.0 - async-process
1.4.0 - crossbeam-utils
0.8.11 - futures-channel
0.3.23 - futures-core
0.3.23 - futures-io
0.3.23 - futures-lite
1.12.0 - gloo-timers
0.2.4 - kv-log-macro
1.0.7 - log
0.4.17 - memchr
2.5.0 - once_cell
1.13.0 - pin-project-lite
0.2.9 - pin-utils
0.1.0 - slab
0.4.7 - wasm-bindgen-futures
0.4.32
- async-attributes
async-std-resolver
0.21.2crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0f2f8a4a203be3325981310ab243a28e6e4ea55b6519bffce05d41ab60e09ad8depends onused byasync-task
4.3.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7a40729d2133846d9ed0ea60a8b9541bccddab49cd30f0715a1da672fe9a2524async-trait
0.1.57crates.ioβ 3β 41sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum76464446b8bc32758d7e88ee1a804d9914cd9b1cb264c029899680b0be29826fdepends onused by- async-std-resolver
0.21.2 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-consensus
2.0.0-dev - jsonrpsee-core
0.14.0 - libp2p-autonat
0.5.0 - libp2p-request-response
0.19.0 - orchestra
0.0.1 - polkadot-network-bridge
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-service
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-service
0.10.0-dev - sp-authorship
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-inherents
4.0.0-dev - sp-keystore
0.12.0 - sp-timestamp
4.0.0-dev - sp-transaction-storage-proof
4.0.0-dev - substrate-test-client
2.0.1 - trust-dns-proto
0.21.2
- async-std-resolver
asynchronous-codec
0.6.0crates.ioβ 5β 10sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf0de5164e5edbf51c45fb8c2d9664ae1c095cce1b265ecf7569093c0d66ef690atomic-waker
1.0.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum065374052e7df7ee4047b1160cca5e1467a12351a40b3da123c870ba0b8eda2aused byatty
0.2.14crates.ioβ 3β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8depends onauto_impl
0.5.0crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7862e21c893d65a1650125d157eaeec691439379a1cee17ee49031b79236ada4used byautocfg
1.1.0crates.ioβ 0β 12sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fabackoff
0.4.0crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb62ddb9cb1ec0a098ad4bbf9344d0713fa193ae1a80af55febcff2627b6a00c1backtrace
0.3.66crates.ioβ 7β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcab84319d616cfb654d03394f38ab7e6f0919e181b1b57e1fd15e7fb4077d9a7depends onbase-x
0.2.11crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4cbbc9d0964165b47557570cce6c952866c2678457aca742aafc9fb771d30270used bybase16ct
0.1.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum349a06037c7bf932dd7e7d1f653678b2038b9ad46a74102f1fc7bd7872678cceused bybase58
0.2.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6107fe1be6682a68940da878d9e9f5e90ca5745b3dec9fd1bb393c8777d4f581used bybase64
0.13.0crates.ioβ 0β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fdbeef
0.5.2crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3a8241f3ebb85c056b509d4327ad0358fbbba6ffb340bf388f26350aeda225b1depends onbeefy-gadget
4.0.0-devgithub.com/paritytech/substrateβ 27β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- beefy-primitives
4.0.0-dev - fnv
1.0.7 - futures
0.3.23 - futures-timer
3.0.2 - hex
0.4.3 - log
0.4.17 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - sc-chain-spec
4.0.0-dev - sc-client-api
4.0.0-dev - sc-finality-grandpa
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-utils
4.0.0-dev - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-arithmetic
5.0.0 - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-keystore
0.12.0 - sp-mmr-primitives
4.0.0-dev - sp-runtime
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32 - wasm-timer
0.2.5
- beefy-primitives
beefy-gadget-rpc
4.0.0-devgithub.com/paritytech/substrateβ 13β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bybeefy-merkle-tree
4.0.0-devgithub.com/paritytech/substrateβ 2β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onbeefy-primitives
4.0.0-devgithub.com/paritytech/substrateβ 7β 13sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - beefy-merkle-tree
4.0.0-dev - kusama-runtime
0.9.27 - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - polkadot-client
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - rococo-runtime
0.9.27 - westend-runtime
0.9.27
- beefy-gadget
bimap
0.6.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbc0455254eb5c6964c4545d8bac815e1a1be4f3afe0ae695ea539c12d728d44bused bybincode
1.3.3crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb1f45e9417d87227c7a56d22e471c6206462cba514c7590c09aff4cf6d1ddcaddepends onbindgen
0.59.2crates.ioβ 11β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2bd2a9a458e8f4304c52c43ebb0cfbd520289f8379a52e329a38afda99bf8eb8depends onused bybitflags
1.3.2crates.ioβ 0β 15sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718abitvec
0.20.4crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7774144344a4faa177370406a7ff5f1da24303817368584c6206c8303eb07848depends onused bybitvec
1.0.1crates.ioβ 4β 13sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9cdepends onused by- kusama-runtime
0.9.27 - parity-scale-codec
3.1.5 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - scale-info
2.1.2 - westend-runtime
0.9.27
- kusama-runtime
blake2
0.10.4crates.ioβ 1β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb9cf849ee05b2ee5fba5e36f97ff8ec2533916700fc0758d40d92136a42f3388depends onblake2-rfc
0.2.18crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5d6d530bdd2d52966a6d03b7a964add7ae1a288d25214066fd4b600f0f796400depends onused byblake2b_simd
1.0.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum72936ee4afc7f8f736d1c38383b56480b5497b4617b4a77bdbf1d2ababc76127used byblake2s_simd
1.0.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumdb539cc2b5f6003621f1cd9ef92d7ded8ea5232c7de0f9faa2de251cd98730d4used byblake3
1.3.1crates.ioβ 6β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma08e53fc5a564bb15bfe6fae56bd71522205f1f91893f9c0116edad6496c183fused byblock-buffer
0.7.3crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc0940dc441f31689269e10ac70eb1002a3a1d3ad1390e030043662eb7fe4688bused byblock-buffer
0.9.0crates.ioβ 2β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4depends onused byblock-buffer
0.10.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0bf7fe51849ea569fd452f37822f606a5cabb684dc918707a0193fd4664ff324depends onused byblock-padding
0.1.5crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfa79dedbb091f449f1f39e53edf88d5dbe95f895dae6135a8d7b881fb5af73f5depends onused byblock-padding
0.2.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8d696c370c750c948ada61c69a0ee2cbbb9c50b1019ddb86d9317157a99c2caeused byblocking
1.2.0crates.ioβ 6β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc6ccb65d468978a086b69884437ded69a90faab3bbe6e67f242173ea728accccdepends onbounded-vec
0.6.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3372be4090bf9d4da36bd8ba7ce6ca1669503d0cf6e667236c6df7f053153eb6depends onbs58
0.4.0crates.ioβ 0β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum771fe0050b883fcc3ea2359b1a96bcfbc090b7116eae7c3c512c7a083fdf23d3bstr
0.2.17crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumba3569f383e8f1598449f1a423e72e99569137b47740b1da11ef19af3d5c3223depends onused bybuild-helper
0.1.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbdce191bf3fa4995ce948c8c83b4640a1745457a149e73c6db75b4ffe36aad5fdepends onbumpalo
3.10.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum37ccbd214614c6783386c1af30caf03192f17891059cecc394b4fb119e363de3used bybyte-slice-cast
1.2.1crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum87c5fdd0166095e1d463fc6cc01aa8ce547ad77a4e84d42eb6762b084e28067ebyte-tools
0.3.1crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7byteorder
1.4.3crates.ioβ 0β 19sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610used by- block-buffer
0.7.3 - cuckoofilter
0.5.0 - curve25519-dalek
2.1.3 - curve25519-dalek
3.2.0 - curve25519-dalek
4.0.0-pre.1 - dns-parser
0.8.0 - fixed-hash
0.7.0 - fxhash
0.2.1 - libp2p-gossipsub
0.39.0 - merlin
2.0.1 - multiaddr
0.14.0 - netlink-packet-core
0.4.2 - netlink-packet-route
0.12.0 - netlink-packet-utils
0.5.1 - parity-wasm
0.32.0 - sp-core
6.0.0 - sp-core-hashing
4.0.0 - thrift
0.15.0 - uint
0.9.3
- block-buffer
bytes
1.2.1crates.ioβ 0β 29sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumec8a7b6a70fde80372154c65702f00a0f56f3e1c36abbc6c440484be248856dbused by- asynchronous-codec
0.6.0 - ethereum
0.12.0 - h2
0.3.13 - http
0.2.8 - http-body
0.4.5 - hyper
0.14.20 - libp2p
0.46.1 - libp2p-gossipsub
0.39.0 - libp2p-kad
0.38.0 - libp2p-mplex
0.34.0 - libp2p-noise
0.37.0 - libp2p-plaintext
0.34.0 - libp2p-relay
0.10.0 - libp2p-request-response
0.19.0 - multistream-select
0.11.0 - netlink-proto
0.10.0 - netlink-sys
0.8.3 - polkadot-network-bridge
0.9.27 - prost
0.10.4 - prost-build
0.10.4 - prost-codec
0.1.0 - prost-types
0.10.1 - rlp
0.5.1 - sc-network
0.10.0-dev - sc-offchain
4.0.0-dev - soketto
0.7.1 - tokio
1.20.1 - tokio-util
0.7.3 - unsigned-varint
0.7.1
- asynchronous-codec
bzip2-sys
0.1.11+1.0.8crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum736a955f3fa7875102d57c82b8cac37ec45224a07fd32d58f9f7a186b6cd4cdcdepends onused bycache-padded
1.2.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc1db59621ec70f09c5e9b597b220c7a2b43611f4710dc03ceb8748637775692cused bycamino
1.1.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum88ad0e1e3e88dd237a156ab9f571021b8a158caa0ae44b1968a241efb5144c1edepends onused bycargo_metadata
0.14.2crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4acbb09d9ee8e23699b9634375c72795d095bf268439da88562cf9b501f181facargo-platform
0.1.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcbdb825da8a5df079a43676dbe042702f1707b1109f713a01420fbb4cc71fa27depends onused bycc
1.0.73crates.ioβ 1β 16sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11depends oncexpr
0.6.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6fac387a98bb7c37292057cffc56d62ecb629900026402633ae9160df93a8766depends onused bycfg_aliases
0.1.1crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfd16c4719339c4530435d38e511904438d07cce7950afa3718a84ac36c10e89ecfg-if
0.1.10crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822cfg-if
1.0.0crates.ioβ 0β 44sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbaf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fdused by- aes
0.7.5 - async-process
1.4.0 - backtrace
0.3.66 - blake3
1.3.1 - chacha20
0.8.2 - cpp_demangle
0.3.5 - crc32fast
1.3.2 - crossbeam-channel
0.5.6 - crossbeam-deque
0.8.2 - crossbeam-epoch
0.9.10 - crossbeam-queue
0.3.6 - crossbeam-utils
0.8.11 - directories-next
2.0.0 - filetime
0.2.17 - frame-metadata
15.0.0 - getrandom
0.1.16 - getrandom
0.2.7 - instant
0.1.12 - k256
0.10.4 - libloading
0.7.3 - log
0.4.17 - nix
0.24.2 - parity-util-mem
0.11.0 - parking_lot_core
0.8.5 - parking_lot_core
0.9.3 - polling
2.2.0 - polyval
0.5.3 - prometheus
0.13.1 - prost-build
0.10.4 - sc-executor-wasmtime
0.10.0-dev - scale-info
2.1.2 - sha-1
0.9.8 - sha-1
0.10.0 - sha2
0.9.9 - sha2
0.10.2 - tempfile
3.3.0 - tracing
0.1.36 - trust-dns-proto
0.21.2 - trust-dns-resolver
0.21.2 - wasm-bindgen
0.2.82 - wasm-bindgen-futures
0.4.32 - wasmtime
0.38.3 - wasmtime-jit
0.38.3 - wasmtime-runtime
0.38.3
- aes
chacha20
0.8.2crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5c80e5460aa66fe3b91d40bcbdab953a597b60053e34d684ac6903f863b680a6used bychacha20poly1305
0.9.1crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma18446b09be63d457bbec447509e85f662f32952b035ce892290396bc0b0cff5used bychrono
0.4.22crates.ioβ 7β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbfd4d1b31faaa3a89d7934dbded3111da0d2ef28e3ebccdb4f0179f5929d1ef1depends oncid
0.8.6crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf6ed9c8b2d17acb8110c46f1da5bf4a696d745e1474a16db0cd2b49cd0249bf2used bycipher
0.3.0crates.ioβ 1β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7depends onckb-merkle-mountain-range
0.3.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4f061f97d64fd1822664bdfb722f7ae5469a97b77567390f7442be5b5dc82a5bdepends onused byclang-sys
1.3.3crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5a050e2153c5be08febd6734e29298e844fdb0fa21aeddd63b4eb7baa106c69bdepends onused byclap
3.2.17crates.ioβ 9β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum29e724a68d9319343bb3328c9cc2dfde263f4b3142ee1059a9980580171c954bdepends onclap_derive
3.2.17crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum13547f7012c01ab4a0e8f8967730ada8f9fdf419e8b6c792788f39cf4e46eefaused byclap_lex
0.2.4crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2850f2f5a82cbf437dd5af4d49848fbdfc27c157c3d010345776f952765261c5depends onused bycmake
0.1.48crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume8ad8cef104ac57b68b89df3208164d228503abbdce70f6880ffa3d970e7443adepends onused bycoarsetime
0.1.22crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum454038500439e141804c655b4cd1bc6a70bcb95cd2bc9463af5661b6956f0e46comfy-table
6.0.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum121d8a5b0346092c18a4b2fd6f620d7a06f0eb7ac0a45860939a0884bc579c56concurrent-queue
1.2.4crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumaf4780a44ab5696ea9e28294517f1fffb421a83a25af521333c838635509db9cdepends onconstant_time_eq
0.1.5crates.ioβ 0β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum245097e9a4535ee1e3e3931fcfcd55a796a44c643e8596ff6566d68f09b87bbcconvert_case
0.4.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0eused bycore-foundation
0.9.3crates.ioβ 2β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146depends oncore-foundation-sys
0.8.3crates.ioβ 0β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dccore2
0.4.0crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb49ba7ef1ad6107f8824dbe97de947cbaac53c44e7f9756a1fba0d37c1eec505depends onused bycpp_demangle
0.3.5crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumeeaa953eaad386a53111e47172c2fedba671e5684c8dd601a5f474f4f118710fdepends onused bycpufeatures
0.2.2crates.ioβ 1β 8sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum59a6001667ab124aebae2a495118e11d30984c3a653e99d86d58971708cf5e4bdepends oncranelift-bforest
0.85.3crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum749d0d6022c9038dccf480bdde2a38d435937335bf2bb0f14e815d94517cdce8depends onused bycranelift-codegen
0.85.3crates.ioβ 10β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume94370cc7b37bf652ccd8bb8f09bd900997f7ccf97520edfc75554bb5c4abbeadepends oncranelift-codegen-meta
0.85.3crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume0a3cea8fdab90e44018c5b9a1dfd460d8ee265ac354337150222a354628bdb6depends onused bycranelift-entity
0.85.3crates.ioβ 1β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum09eaeacfcd2356fe0e66b295e8f9d59fdd1ac3ace53ba50de14d628ec902f72ddepends oncranelift-frontend
0.85.3crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumdba69c9980d5ffd62c18a2bde927855fcd7c8dc92f29feaf8636052662cbd99ccranelift-isle
0.85.3crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd2920dc1e05cac40304456ed3301fde2c09bd6a9b0210bcfa2f101398d628d5bused bycranelift-native
0.85.3crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf04dfa45f9b2a6f587c564d6b63388e00cd6589d2df6ea2758cf79e1a13285e6used bycranelift-wasm
0.85.3crates.ioβ 8β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum31a46513ae6f26f3f267d8d75b5373d555fbbd1e68681f348d99df43f747ec54depends onused bycrc32fast
1.3.2crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880ddepends oncrossbeam-channel
0.5.6crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc2dd04ddaf88237dc3b8d8f9a3c1004b506b54b3313403944054d23c0870c521depends onused bycrossbeam-deque
0.8.2crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum715e8152b692bba2d374b53d4875445368fdf21a94751410af607a5ac677d1fcused bycrossbeam-epoch
0.9.10crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum045ebe27666471bb549370b4b0b3e51b07f56325befa4284db65fc89c02511b1used bycrossbeam-queue
0.3.6crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1cd42583b04998a5363558e5f9291ee5a5ff6b49944332103f251e7479a82aa7depends oncrossbeam-utils
0.8.11crates.ioβ 2β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum51887d4adc7b564537b15adcfb307936f8075dfcd5f00dde9a9f1d29383682bcdepends oncrunchy
0.2.2crates.ioβ 0β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7crypto-bigint
0.3.2crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum03c6a1d5fa1de37e071642dfa44ec552ca5b299adb128fab16138e24b548fd21crypto-common
0.1.6crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3depends onused bycrypto-mac
0.8.0crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeabdepends onused bycrypto-mac
0.11.1crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb1d1a86f49236c215f271d40892d5fc950490551400b02ef360692c29815c714depends onused byctor
0.1.23crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcdffe87e1d521a10f9696f833fe502293ea446d7f256c06128293a4119bdf4cbdepends onused byctr
0.8.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761eadepends onused bycuckoofilter
0.5.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb810a8449931679f64cd7eef1bbd0fa315801b6d5d9cdc1ace2804d6529eee18depends onused bycumulus-client-cli
0.1.0github.com/paritytech/cumulusβ 8β 2sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncumulus-client-collator
0.1.0github.com/paritytech/cumulusβ 17β 2sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-relay-chain-interface
0.1.0 - futures
0.3.23 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-overseer
0.9.27 - polkadot-primitives
0.9.27 - sc-client-api
4.0.0-dev - sp-api
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0 - tracing
0.1.36
- cumulus-client-consensus-common
cumulus-client-consensus-aura
0.1.0github.com/paritytech/cumulusβ 22β 1sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- async-trait
0.1.57 - cumulus-client-consensus-common
0.1.0 - cumulus-primitives-core
0.1.0 - futures
0.3.23 - parity-scale-codec
3.1.5 - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-telemetry
4.0.0-dev - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-keystore
0.12.0 - sp-runtime
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev - tracing
0.1.36
used by- async-trait
cumulus-client-consensus-common
0.1.0github.com/paritytech/cumulusβ 14β 4sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncumulus-client-network
0.1.0github.com/paritytech/cumulusβ 18β 2sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- async-trait
0.1.57 - cumulus-relay-chain-interface
0.1.0 - derive_more
0.99.17 - futures
0.3.23 - futures-timer
3.0.2 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - polkadot-node-primitives
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - sc-client-api
4.0.0-dev - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - tracing
0.1.36
- async-trait
cumulus-client-pov-recovery
0.1.0github.com/paritytech/cumulusβ 17β 1sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- cumulus-primitives-core
0.1.0 - cumulus-relay-chain-interface
0.1.0 - futures
0.3.23 - futures-timer
3.0.2 - parity-scale-codec
3.1.5 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-overseer
0.9.27 - polkadot-primitives
0.9.27 - rand
0.8.5 - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sp-api
4.0.0-dev - sp-consensus
0.10.0-dev - sp-maybe-compressed-blob
4.1.0-dev - sp-runtime
6.0.0 - tracing
0.1.36
used by- cumulus-primitives-core
cumulus-client-service
0.1.0github.com/paritytech/cumulusβ 21β 1sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- cumulus-client-cli
0.1.0 - cumulus-client-collator
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-relay-chain-interface
0.1.0 - parking_lot
0.12.1 - polkadot-overseer
0.9.27 - polkadot-primitives
0.9.27 - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-service
0.10.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0 - tracing
0.1.36
used by- cumulus-client-cli
cumulus-pallet-aura-ext
0.1.0github.com/paritytech/cumulusβ 11β 3sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncumulus-pallet-dmp-queue
0.1.0github.com/paritytech/cumulusβ 11β 3sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncumulus-pallet-parachain-system
0.1.0github.com/paritytech/cumulusβ 23β 3sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- cumulus-pallet-parachain-system-proc-macro
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - environmental
1.1.3 - frame-support
4.0.0-dev - frame-system
4.0.0-dev - impl-trait-for-tuples
0.2.2 - log
0.4.17 - pallet-balances
4.0.0-dev - parity-scale-codec
3.1.5 - polkadot-parachain
0.9.27 - scale-info
2.1.2 - serde
1.0.143 - sp-core
6.0.0 - sp-externalities
0.12.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - sp-std
4.0.0 - sp-trie
6.0.0 - sp-version
5.0.0 - xcm
0.9.27
- cumulus-pallet-parachain-system-proc-macro
cumulus-pallet-parachain-system-proc-macro
0.1.0github.com/paritytech/cumulusβ 4β 1sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbcumulus-pallet-xcm
0.1.0github.com/paritytech/cumulusβ 10β 3sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncumulus-pallet-xcmp-queue
0.1.0github.com/paritytech/cumulusβ 11β 3sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncumulus-primitives-core
0.1.0github.com/paritytech/cumulusβ 9β 21sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends onused by- cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-primitives-timestamp
0.1.0 - cumulus-primitives-utility
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - cumulus-test-relay-sproof-builder
0.1.0 - opal-runtime
0.9.27 - orml-xtokens
0.4.1-dev - parachain-info
0.1.0 - quartz-runtime
0.9.27 - unique-node
0.9.27 - unique-runtime
0.9.27
- cumulus-client-collator
cumulus-primitives-parachain-inherent
0.1.0github.com/paritytech/cumulusβ 16β 2sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- async-trait
0.1.57 - cumulus-primitives-core
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-test-relay-sproof-builder
0.1.0 - parity-scale-codec
3.1.5 - sc-client-api
4.0.0-dev - scale-info
2.1.2 - sp-api
4.0.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - sp-std
4.0.0 - sp-storage
6.0.0 - sp-trie
6.0.0 - tracing
0.1.36
- async-trait
cumulus-primitives-timestamp
0.1.0github.com/paritytech/cumulusβ 6β 3sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncumulus-primitives-utility
0.1.0github.com/paritytech/cumulusβ 12β 3sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncumulus-relay-chain-inprocess-interface
0.1.0github.com/paritytech/cumulusβ 23β 1sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- async-trait
0.1.57 - cumulus-primitives-core
0.1.0 - cumulus-relay-chain-interface
0.1.0 - futures
0.3.23 - futures-timer
3.0.2 - parking_lot
0.12.1 - polkadot-cli
0.9.27 - polkadot-client
0.9.27 - polkadot-service
0.9.27 - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus-babe
0.10.0-dev - sc-network
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - tracing
0.1.36
used by- async-trait
cumulus-relay-chain-interface
0.1.0github.com/paritytech/cumulusβ 16β 9sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- async-trait
0.1.57 - cumulus-primitives-core
0.1.0 - derive_more
0.99.17 - futures
0.3.23 - jsonrpsee-core
0.14.0 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - polkadot-overseer
0.9.27 - polkadot-service
0.9.27 - sc-client-api
4.0.0-dev - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - thiserror
1.0.32
- async-trait
cumulus-relay-chain-rpc-interface
0.1.0github.com/paritytech/cumulusβ 20β 1sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends on- async-trait
0.1.57 - backoff
0.4.0 - cumulus-primitives-core
0.1.0 - cumulus-relay-chain-interface
0.1.0 - futures
0.3.23 - futures-timer
3.0.2 - jsonrpsee
0.14.0 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - polkadot-service
0.9.27 - sc-client-api
4.0.0-dev - sc-rpc-api
0.10.0-dev - sp-api
4.0.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - sp-storage
6.0.0 - tokio
1.20.1 - tracing
0.1.36 - url
2.2.2
used by- async-trait
cumulus-test-relay-sproof-builder
0.1.0github.com/paritytech/cumulusβ 6β 1sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends oncurve25519-dalek
2.1.3crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4a9b85542f99a2dfa2a1b8e192662741c9859a846b296bef1c92ef9b58b5a216used bycurve25519-dalek
3.2.0crates.ioβ 5β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61curve25519-dalek
4.0.0-pre.1crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4033478fbf70d6acf2655ac70da91ee65852d69daf7a67bf7a2f518fb47aafcfused bydarling
0.13.4crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453cdepends onused bydarling_core
0.13.4crates.ioβ 6β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610darling_macro
0.13.4crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835depends onused bydata-encoding
2.3.2crates.ioβ 0β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3ee2393c4a91429dffb4bedf19f4d6abf27d8a732c8ce4980305d782e5426d57data-encoding-macro
0.1.12crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum86927b7cd2fe88fa698b87404b287ab98d1a0063a34071d92e575b72d3029acaused bydata-encoding-macro-internal
0.1.10crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma5bbed42daaa95e780b60a50546aa345b8413a1e46f9a40a12907d3598f038dbdepends onused byder
0.5.1crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6919815d73839e7ad218de758883aae3a257ba6759ce7a9992501efbb53d705cdepends onderivative
2.2.0crates.ioβ 3β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770bdepends onderive_more
0.99.17crates.ioβ 5β 13sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321used by- cumulus-client-network
0.1.0 - cumulus-relay-chain-interface
0.1.0 - polkadot-availability-distribution
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-parachain
0.9.27 - polkadot-runtime-parachains
0.9.27 - prioritized-metered-channel
0.2.0 - reed-solomon-novelpoly
1.0.0 - scale-info
2.1.2
- cumulus-client-network
digest
0.8.1crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf3d0c8c8752312f9713efd397ff63acb9f85585afbf179282e720e7704954dd5depends ondigest
0.9.0crates.ioβ 1β 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066depends ondigest
0.10.3crates.ioβ 3β 8sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf2fb860ca6fafa5552fb6d0e816a69c8e49f0908bf524e30a90d97c85892d506directories
4.0.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf51c5d4ddabd36886dd3e1438cb358cdcb0d7c499cb99cb4ac2e38e18b5cb210depends onused bydirectories-next
2.0.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum339ee130d97a610ea5a5872d2bbb130fdf68884ff09d3028b81bec8a1ac23bbcdepends onused bydirs-sys
0.3.7crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6depends onused bydirs-sys-next
0.1.2crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4ddepends onused bydns-parser
0.8.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc4d33be9473d06f75f58220f71f7a9317aca647dc061dbd3c361b0bef505fbeadepends onused bydowncast-rs
1.2.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9ea835d29036a4087793836fa931b08837ad5e957da9e23886b29586fb9b6650used bydtoa
1.0.3crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc6053ff46b5639ceb91756a85a4c8914668393a03170efd79c8884a529d80656used bydyn-clonable
0.9.0crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4e9232f0e607a262ceb9bd5141a3dfb3e4db6994b31989bbfd845878cba59fd4depends onused bydyn-clonable-impl
0.9.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum558e40ea573c374cf53507fd240b7ee2f5477df7cfebdb97323ec61c719399c5depends onused bydyn-clone
1.0.9crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4f94fa09c2aeea5b8839e414b7b841bf429fd25b9c522116ac97ee87856d88b2ecdsa
0.13.4crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd0d69ae62e0ce582d56380743515fefaf1a8c70cec685d9677636d7e30ae9dc9used byed25519
1.5.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1e9c280362032ea4203659fc489832d0204ef09f247a0506f170dafcac08c369depends onused byed25519-dalek
1.0.1crates.ioβ 6β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9deither
1.7.0crates.ioβ 0β 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3f107b87b6afc2a64fd13cac55fe06d6c8859f12d4b14cbcdd2c67d0976781beelliptic-curve
0.11.12crates.ioβ 10β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum25b477563c2bfed38a3b7a60964c49e058b2510ad3f12ba3483fd8f62c2306d6depends onused byenum-as-inner
0.4.0crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum21cdad81446a7f7dc43f6a77409efeb9733d2fa65553efef6018ef257c959b73used byenumflags2
0.7.5crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume75d4cd21b95383444831539909fbb14b9dc3fdceb2a6f5d36577329a1f55ccbdepends onused byenumflags2_derive
0.7.4crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf58dc3c5e468259f19f2d46304a6b28f1c3d034442e14b322d2b850e36f6d5aedepends onused byenumn
0.1.5crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum038b1afa59052df211f9efd58f8b1d84c242935ede1c3dbaed26b018a9e06ae2depends onused byenv_logger
0.9.0crates.ioβ 5β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0b2cf0344971ee6c64c31be0d530793fba457d322dfec2810c453d0ef228f9c3environmental
1.1.3crates.ioβ 0β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum68b91989ae21441195d7d9b9993a2f9295c7e1a8c96255d8b729accddc124797errno
0.2.8crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf639046355ee4f37944e44f60642c6f3a7efa3cf6b78c78a0d989a8ce6c396a1used byerrno-dragonfly
0.1.2crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumaa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bfdepends onused byethbloom
0.12.1crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum11da94e443c60508eb62cf256243a64da87304c2802ac2528847f79d750007efdepends onused byethereum
0.12.0crates.ioβ 11β 14sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum23750149fe8834c0e24bb9adcbacbe06c45b9861f15df53e09f26cb7c4ab91efdepends onethereum-types
0.13.1crates.ioβ 8β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb2827b94c556145446fcce834ca86b7abf0c39a805883fe20e72c5bfdb5a0dc6depends onevent-listener
2.5.3crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0evm
0.35.0github.com/uniquenetwork/evmβ 13β 4sourcegit+https://github.com/uniquenetwork/evm?branch=unique-polkadot-v0.9.27#e9252ed42dc26fc85b6703b1ba50660a08209e55depends onevm-coder
0.1.1workspaceβ 7β 11depends onevm-coder-macros
0.1.0workspaceβ 7β 1evm-core
0.35.0github.com/uniquenetwork/evmβ 4β 4sourcegit+https://github.com/uniquenetwork/evm?branch=unique-polkadot-v0.9.27#e9252ed42dc26fc85b6703b1ba50660a08209e55evm-gasometer
0.35.0github.com/uniquenetwork/evmβ 4β 1sourcegit+https://github.com/uniquenetwork/evm?branch=unique-polkadot-v0.9.27#e9252ed42dc26fc85b6703b1ba50660a08209e55used byevm-runtime
0.35.0github.com/uniquenetwork/evmβ 5β 2sourcegit+https://github.com/uniquenetwork/evm?branch=unique-polkadot-v0.9.27#e9252ed42dc26fc85b6703b1ba50660a08209e55used byexit-future
0.2.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume43f2f1833d64e33f15592464d6fdd70f349dda7b1a53088eb83cd94014008c5depends onused byexpander
0.0.4crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma718c0675c555c5f976fff4ea9e2c150fa06cefa201cadef87cfbf9324075881used byexpander
0.0.6crates.ioβ 5β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3774182a5df13c3d1690311ad32fbe913feef26baba609fa2dd5f72042bd2ab6fallible-iterator
0.2.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4443176a9f2c162692bd3d352d745ef9413eec5782a80d8fd6f8a1ac692a07f7used byfastrand
1.8.0crates.ioβ 1β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma7a407cfaa3385c4ae6b23e84623d48c2798d06e3e6a1878f7f59f17b3f86499depends onfatality
0.0.6crates.ioβ 2β 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2ad875162843b0d046276327afe0136e9ed3a23d5a754210fb6f1f33610d39abdepends onused by- polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-statement-distribution
0.9.27
- polkadot-availability-distribution
fatality-proc-macro
0.0.6crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf5aa1e3ae159e592ad222dc90c5acbad632b527779ba88486abe92782ab268bddepends onused byfc-consensus
2.0.0-devgithub.com/uniquenetwork/frontierβ 12β 1sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onused byfc-db
2.0.0-devgithub.com/uniquenetwork/frontierβ 9β 5sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onfc-mapping-sync
2.0.0-devgithub.com/uniquenetwork/frontierβ 10β 2sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onfc-rpc
2.0.0-devgithub.com/uniquenetwork/frontierβ 33β 2sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends on- ethereum
0.12.0 - ethereum-types
0.13.1 - evm
0.35.0 - fc-db
2.0.0-dev - fc-rpc-core
1.1.0-dev - fp-rpc
3.0.0-dev - fp-storage
2.0.0 - futures
0.3.23 - hex
0.4.3 - jsonrpsee
0.14.0 - libsecp256k1
0.7.1 - log
0.4.17 - lru
0.7.8 - parity-scale-codec
3.1.5 - prometheus
0.13.1 - rand
0.8.5 - rlp
0.5.1 - rustc-hex
2.1.0 - sc-client-api
4.0.0-dev - sc-network
0.10.0-dev - sc-rpc
4.0.0-dev - sc-service
0.10.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - sp-api
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-storage
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev - tokio
1.20.1
- ethereum
fc-rpc-core
1.1.0-devgithub.com/uniquenetwork/frontierβ 7β 3sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onfdlimit
0.2.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2c4c9e43643f5a3be4ca5b67d26b98031ff9db6806c3440ae32e02e3ceac3f1bdepends onused byff
0.11.1crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum131655483be284720a17d74ff97592b8e76576dc25563148601df2d7c9080924depends onfile-per-thread-logger
0.1.5crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum21e16290574b39ee41c71aeb90ae960c504ebaf1e2a1c87bd52aa56ed6e1a02fdepends onused byfiletime
0.2.17crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume94a7bbaa59354bc20dd75b67f23e2797b4490e9d6928203fb105c79e448c86cfinality-grandpa
0.16.0crates.ioβ 8β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb22349c6a11563a202d95772a68e0fcf56119e74ea8a2a19cf2301460fcd0df5depends onfixed-hash
0.7.0crates.ioβ 4β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcfcf0ed7fe52a17a03854ec54a9f76d6d84508d1c0e66bc1793301c73fc8493cfixedbitset
0.4.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80used byflate2
1.0.24crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf82b0f4c27ad9f8bfd1f3208d882da2b09c301bc1c828fd3a00d0216d2fbbff6flexi_logger
0.22.6crates.ioβ 9β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0c76a80dd14a27fc3d8bc696502132cb52b3f227256fd8601166c3a35e45f409depends onused byfnv
1.0.7crates.ioβ 0β 16sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1fork-tree
3.0.0github.com/paritytech/substrateβ 1β 5sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onform_urlencoded
1.0.1crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5fc25a87fa4fd2094bffb06925852034d90a17f0d1e05197d4956d3555752191depends onused byfp-consensus
2.0.0-devgithub.com/uniquenetwork/frontierβ 5β 3sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21fp-evm
3.0.0-devgithub.com/uniquenetwork/frontierβ 7β 7sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onfp-evm-mapping
0.1.0github.com/uniquenetwork/frontierβ 2β 9sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onfp-rpc
3.0.0-devgithub.com/uniquenetwork/frontierβ 10β 10sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onfp-self-contained
1.0.0-devgithub.com/uniquenetwork/frontierβ 9β 4sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onfp-storage
2.0.0github.com/uniquenetwork/frontierβ 1β 4sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onframe-benchmarking
4.0.0-devgithub.com/paritytech/substrateβ 15β 61sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- frame-benchmarking-cli
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-common
0.1.5 - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-election-provider-support-benchmarking
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-migration
0.1.1 - pallet-fungible
0.1.3 - pallet-gilt
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nonfungible
0.1.4 - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-scheduler
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-structure
0.1.2 - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm-benchmarks
0.9.27 - polkadot-client
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - unique-node
0.9.27 - unique-runtime
0.9.27 - westend-runtime
0.9.27 - xcm-executor
0.9.27
- frame-benchmarking-cli
frame-benchmarking-cli
4.0.0-devgithub.com/paritytech/substrateβ 44β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- Inflector
0.11.4 - chrono
0.4.22 - clap
3.2.17 - comfy-table
6.0.0 - frame-benchmarking
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - gethostname
0.2.3 - handlebars
4.3.3 - hash-db
0.15.2 - hex
0.4.3 - itertools
0.10.3 - kvdb
0.11.0 - lazy_static
1.4.0 - linked-hash-map
0.5.6 - log
0.4.17 - memory-db
0.29.0 - parity-scale-codec
3.1.5 - rand
0.8.5 - rand_pcg
0.3.1 - sc-block-builder
0.10.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-executor
0.10.0-dev - sc-service
0.10.0-dev - sc-sysinfo
6.0.0-dev - serde
1.0.143 - serde_json
1.0.83 - serde_nanos
0.1.2 - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-database
4.0.0-dev - sp-externalities
0.12.0 - sp-inherents
4.0.0-dev - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - sp-storage
6.0.0 - sp-trie
6.0.0 - tempfile
3.3.0 - thiserror
1.0.32 - thousands
0.2.0
- Inflector
frame-election-provider-solution-type
4.0.0-devgithub.com/paritytech/substrateβ 4β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05frame-election-provider-support
4.0.0-devgithub.com/paritytech/substrateβ 9β 11sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- kusama-runtime
0.9.27 - pallet-bags-list
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-election-provider-support-benchmarking
4.0.0-dev - pallet-nomination-pools-benchmarking
1.0.0 - pallet-offences-benchmarking
4.0.0-dev - pallet-staking
4.0.0-dev - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-test-runtime
0.9.27 - westend-runtime
0.9.27
- kusama-runtime
frame-executive
4.0.0-devgithub.com/paritytech/substrateβ 9β 9sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onframe-metadata
15.0.0crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumdf6bb8542ef006ef0de09a5c4420787d79823c0ed7924225822362fd2bf2ff2dused byframe-support
4.0.0-devgithub.com/paritytech/substrateβ 23β 109sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- bitflags
1.3.2 - frame-metadata
15.0.0 - frame-support-procedural
4.0.0-dev - impl-trait-for-tuples
0.2.2 - k256
0.10.4 - log
0.4.17 - once_cell
1.13.0 - parity-scale-codec
3.1.5 - paste
1.0.8 - scale-info
2.1.2 - serde
1.0.143 - smallvec
1.9.0 - sp-arithmetic
5.0.0 - sp-core
6.0.0 - sp-core-hashing-proc-macro
5.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-staking
4.0.0-dev - sp-state-machine
0.12.0 - sp-std
4.0.0 - sp-tracing
5.0.0 - tt-call
1.0.8
used by- cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-utility
0.1.0 - fp-evm
3.0.0-dev - fp-evm-mapping
0.1.0 - fp-self-contained
1.0.0-dev - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-try-runtime
0.10.0-dev - kusama-runtime
0.9.27 - kusama-runtime-constants
0.9.27 - opal-runtime
0.9.27 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-utilities
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xcm-support
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-gilt
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nonfungible
0.1.4 - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-randomness-collective-flip
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-society
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-structure
0.1.2 - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - parachain-info
0.1.0 - polkadot-parachain
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-constants
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - rococo-runtime-constants
0.9.27 - test-runtime-constants
0.9.27 - tests
0.1.1 - unique-runtime
0.9.27 - up-common
0.9.27 - up-data-structs
0.2.2 - westend-runtime
0.9.27 - westend-runtime-constants
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- bitflags
frame-support-procedural
4.0.0-devgithub.com/paritytech/substrateβ 5β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused byframe-support-procedural-tools
4.0.0-devgithub.com/paritytech/substrateβ 5β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onframe-support-procedural-tools-derive
3.0.0github.com/paritytech/substrateβ 3β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onframe-system
4.0.0-devgithub.com/paritytech/substrateβ 10β 95sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - orml-tokens
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-election-provider-support-benchmarking
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-gilt
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nonfungible
0.1.4 - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-randomness-collective-flip
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-society
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-structure
0.1.2 - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - parachain-info
0.1.0 - polkadot-client
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - tests
0.1.1 - unique-runtime
0.9.27 - up-data-structs
0.2.2 - westend-runtime
0.9.27 - xcm-builder
0.9.27
- cumulus-pallet-aura-ext
frame-system-benchmarking
4.0.0-devgithub.com/paritytech/substrateβ 8β 7sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onframe-system-rpc-runtime-api
4.0.0-devgithub.com/paritytech/substrateβ 2β 11sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onframe-try-runtime
0.10.0-devgithub.com/paritytech/substrateβ 4β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05fs_extra
1.2.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2022715d62ab30faffd124d40b76f4134a550a87792276512b18d63272333394fs-err
2.7.0crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5bd79fa345a495d3ae89fb7165fec01c0e72f41821d642dda363a1e97975652efs-swap
0.2.6crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum03d47dad3685eceed8488986cad3d5027165ea5edb164331770e2059555f10a5used byfs2
0.4.3crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9564fc758e15025b46aa6643b1b77d047d1a56a1aea6e01002ac0c7026876213depends onused byfunty
1.1.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfed34cd105917e91daa4da6b3728c47b068749d6a62c59811f06ed2ac71d9da7used byfunty
2.0.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9cused byfutures
0.1.31crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3a471a38ef8ed83cd6e40aa59c1ffe17db6855c18e3604d9c4ed8c08ebc28678used byfutures
0.3.23crates.ioβ 7β 122sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumab30e97ab6aacfe635fad58f22c2bb06c8b685f7421eb1e064a729e2a5f481fadepends onused by- beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-primitives-timestamp
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - exit-future
0.2.0 - fc-mapping-sync
2.0.0-dev - fc-rpc
2.0.0-dev - finality-grandpa
0.16.0 - if-watch
1.1.1 - libp2p
0.46.1 - libp2p-autonat
0.5.0 - libp2p-core
0.34.0 - libp2p-deflate
0.34.0 - libp2p-dns
0.34.0 - libp2p-floodsub
0.37.0 - libp2p-gossipsub
0.39.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-mdns
0.38.0 - libp2p-mplex
0.34.0 - libp2p-noise
0.37.0 - libp2p-ping
0.37.0 - libp2p-plaintext
0.34.0 - libp2p-pnet
0.22.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - libp2p-request-response
0.19.0 - libp2p-swarm
0.37.0 - libp2p-tcp
0.34.0 - libp2p-uds
0.33.0 - libp2p-wasm-ext
0.34.0 - libp2p-websocket
0.36.0 - libp2p-yamux
0.38.0 - mick-jaeger
0.1.8 - multistream-select
0.11.0 - netlink-proto
0.10.0 - netlink-sys
0.8.3 - orchestra
0.0.1 - polkadot-approval-distribution
0.9.27 - polkadot-availability-bitfield-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-cli
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-bitfield-signing
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-chain-api
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-core-runtime-api
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27 - polkadot-test-service
0.9.27 - prioritized-metered-channel
0.2.0 - rtnetlink
0.10.1 - rw-stream-sink
0.3.0 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-informant
0.10.0-dev - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-offchain
4.0.0-dev - sc-peerset
4.0.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-rpc-server
4.0.0-dev - sc-service
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - sc-utils
4.0.0-dev - soketto
0.7.1 - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-io
6.0.0 - sp-keystore
0.12.0 - substrate-frame-rpc-system
4.0.0-dev - substrate-test-client
2.0.1 - substrate-test-utils
4.0.0-dev - unique-node
0.9.27 - unique-rpc
0.1.1 - wasm-timer
0.2.5 - yamux
0.10.2
- beefy-gadget
futures-channel
0.3.23crates.ioβ 2β 9sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2bfc52cbddcfd745bf1740338492bb0bd83d76c67b445f91c5fb29fae29ecaa1depends onfutures-core
0.3.23crates.ioβ 0β 14sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd2acedae88d38235936c3922476b10fced7b2b68136f5e3c03c2d5be348a1115futures-executor
0.3.23crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1d11aa21b5b587a64682c0094c2bdd4df0076c5324961a40cc3abd7f37930528used byfutures-io
0.3.23crates.ioβ 0β 9sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum93a66fc6d035a26a3ae255a6d2bca35eda63ae4c5512bef54449113f7a1228e5futures-lite
1.12.0crates.ioβ 7β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7694489acd39452c77daa48516b894c153f192c3578d5a839b62c58099fcbf48depends onfutures-macro
0.3.23crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0db9cce532b0eae2ccf2766ab246f114b56b9cf6d445e00c2549fbc100ca045ddepends onused byfutures-rustls
0.22.2crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd2411eed028cdf8c8034eaf21f9915f956b6c3abec4d4c7949ee67f0721127bddepends onused byfutures-sink
0.3.23crates.ioβ 0β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumca0bae1fe9752cf7fd9b0064c674ae63f97b37bc714d745cbde0afb7ec4e6765futures-task
0.3.23crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum842fc63b931f4056a24d59de13fb1272134ce261816e063e634ad0c15cdc5306futures-timer
3.0.2crates.ioβ 0β 44sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume64b03909df88034c26dc1547e8970b91f98bdb65165d6a4e9110d94263dbb2cused by- beefy-gadget
4.0.0-dev - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-mapping-sync
2.0.0-dev - finality-grandpa
0.16.0 - jsonrpsee-core
0.14.0 - libp2p
0.46.1 - libp2p-autonat
0.5.0 - libp2p-core
0.34.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-ping
0.37.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - libp2p-swarm
0.37.0 - libp2p-tcp
0.34.0 - orchestra
0.0.1 - polkadot-collator-protocol
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-overseer
0.9.27 - prioritized-metered-channel
0.2.0 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-informant
0.10.0-dev - sc-network
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-offchain
4.0.0-dev - sc-service
0.10.0-dev - sc-transaction-pool
4.0.0-dev - sc-utils
4.0.0-dev - sp-consensus
0.10.0-dev - sp-timestamp
4.0.0-dev
- beefy-gadget
futures-util
0.3.23crates.ioβ 11β 14sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf0828a5471e340229c11c77ca80017937ce3c58cb788a17e5f1c2d5c485a9577depends onused by- async-std-resolver
0.21.2 - asynchronous-codec
0.6.0 - futures
0.3.23 - futures-executor
0.3.23 - h2
0.3.13 - hyper
0.14.20 - jsonrpsee-client-transport
0.14.0 - jsonrpsee-core
0.14.0 - jsonrpsee-http-server
0.14.0 - jsonrpsee-ws-server
0.14.0 - substrate-prometheus-endpoint
0.10.0-dev - trust-dns-proto
0.21.2 - trust-dns-resolver
0.21.2 - unsigned-varint
0.7.1
- async-std-resolver
fxhash
0.2.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50cdepends onused bygeneric-array
0.12.4crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumffdf9f34f1447443d37393cc6c2b8313aebddcd96906caf34e54c68d8e57d7bddepends onused bygeneric-array
0.14.6crates.ioβ 2β 13sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbff49e947297f3312447abdca79f45f4738097cc82b06e72054d2223f601f1b9depends ongethostname
0.2.3crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc1ebd34e35c46e00bb73e81363248d627782724609fe1b6396f553f68fe3862edepends ongetrandom
0.1.16crates.ioβ 5β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fcegetrandom
0.2.7crates.ioβ 3β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4eb1a864a501629691edf6c15a593b7a51eebaa1e8468e9ddc623de7c9b58ec6ghash
0.4.4crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1583cc1656d7839fd3732b80cf4f38850336cdb9b8ded1cd399ca62958de3c99depends onused bygimli
0.26.2crates.ioβ 3β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum22030e2c5a68ec659fde1e949a745124b48e6fa8b045b7ed5bd1fe4ccc5c4e5dglob
0.3.0crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9b919933a397b79c37e33b77bb2aa3dc8eb6e165ad809e58ff75bc7db2e34574globset
0.4.9crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0a1e17342619edbc21a964c2afbeb6c820c6a2560032872f397bb97ea127bd0aused bygloo-timers
0.2.4crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5fb7d06c1c8cc2a29bee7ec961009a0b2caa0793ee4900c2ffb348734ba1c8f9used bygroup
0.11.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbc5ac374b108929de78460075f3dc439fa66df9d8fc77e8f12caa5165fcf0c89depends onused byh2
0.3.13crates.ioβ 11β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum37a82c6d637fc9515a4694bbf1cb2457b79d81ce52b3108bdeea58b07dd34a57depends onused byhandlebars
4.3.3crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum360d9740069b2f6cbb63ce2dbaa71a20d3185350cbb990d7bebeb9318415eb17hash-db
0.15.2crates.ioβ 0β 15sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd23bd4e7b5eda0d0f3a307e8b381fdc8ba9000f26fbe912250c0a4cc3956364ahash256-std-hasher
0.15.2crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum92c171d55b98633f4ed3860808f004099b36c1cc29c42cfc53aa8591b21efcf2depends onhashbrown
0.11.2crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumab5ef0d4909ef3724cc8cce6ccc8572c5c817592e9285f5464f8e86f8bd3726edepends onused byhashbrown
0.12.3crates.ioβ 1β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888depends onheck
0.4.0crates.ioβ 0β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2540771e65fc8cb83cd6e8a237f70c319bd5c29f78ed1084ba5d50eeac86f7f9hermit-abi
0.1.19crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33depends onused byhex
0.4.3crates.ioβ 0β 18sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70used by- beefy-gadget
4.0.0-dev - evm-coder
0.1.1 - evm-coder-macros
0.1.0 - fc-rpc
2.0.0-dev - frame-benchmarking-cli
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-foreing-assets
0.1.0 - parity-db
0.3.16 - polkadot-test-service
0.9.27 - sc-cli
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-offchain
4.0.0-dev - sp-core
6.0.0 - substrate-test-client
2.0.1 - uint
0.9.3
- beefy-gadget
hex_fmt
0.3.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb07f60793ff0a4d9cef0f18e63b5357e06209987153a64648c972c1e5aff336fused byhex-literal
0.3.4crates.ioβ 0β 10sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7ebdb29d2ea9ed0083cd8cece49bbd968021bd99b0849edb4a9a7ee0fdf6a4e0hmac
0.8.1crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum126888268dcc288495a26bf004b38c5fdbb31682f992c84ceb046a1f0fe38840depends onhmac
0.11.0crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69bdepends onhmac-drbg
0.3.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum17ea0a1394df5b6574da6e0c1ade9e78868c9fb0a4e5ef4428e32da4676b85b1depends onused byhostname
0.3.1crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3c731c3e10504cc8ed35cfe2f1db4c9274c3d35fa486e3b31df46f068ef3e867depends onused byhttp
0.2.8crates.ioβ 3β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum75f43d41e26995c17e71ee126451dd3941010b0514a81a9d11f3b341debc2399depends onhttp-body
0.4.5crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1depends onused byhttparse
1.7.1crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum496ce29bb5a52785b44e0f7ca2847ae0bb839c9bd28f69acac9b99d461c0c04cused byhttpdate
1.0.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421used byhumantime
2.1.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4used byhyper
0.14.20crates.ioβ 16β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum02c929dc5c39e335a03c405292728118860721b10190d98c2a0f0efd5baafbacdepends onhyper-rustls
0.23.0crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd87c48c02e0dc5e3b849a2041db3029fd066650f8f717c07bf8ed78ccb895cacdepends onused byiana-time-zone
0.1.45crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumef5528d9c2817db4e10cc78f8d4c8228906e5854f389ff6b076cee3572a09d35depends onused byident_case
1.0.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39used byidna
0.2.3crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum418a0a6fab821475f634efe3ccc45c013f742efe03d853e8d3355d5cb850ecf8if-addrs
0.7.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcbc0fa01ffc752e9dbc72818cdb072cd028b86be5e09dd04c5a643704fe101a9depends onused byif-watch
1.1.1crates.ioβ 10β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum015a7df1eb6dda30df37f34b63ada9b7b352984b0e84de2a20ed526345000791depends onimpl-codec
0.6.0crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumba6a270039626615617f3f36d15fc827041df3b78c439da2cadfa47455a77f2fdepends onimpl-rlp
0.3.0crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf28220f89297a075ddc7245cd538076ee98b01f2a9c23a53a4f1105d5a322808depends onimpl-serde
0.3.2crates.ioβ 1β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4551f042f3438e64dbd6226b20527fc84a6e1fe65688b58746a2f53623f25f5cdepends onimpl-trait-for-tuples
0.2.2crates.ioβ 3β 21sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395ebdepends onused by- cumulus-pallet-parachain-system
0.1.0 - evm-coder
0.1.1 - fp-evm
3.0.0-dev - frame-support
4.0.0-dev - orml-traits
0.4.1-dev - pallet-authorship
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-session
4.0.0-dev - pallet-treasury
4.0.0-dev - parity-scale-codec
2.3.1 - parity-scale-codec
3.1.5 - parity-util-mem
0.11.0 - polkadot-runtime-common
0.9.27 - sc-chain-spec
4.0.0-dev - sp-inherents
4.0.0-dev - sp-runtime
6.0.0 - sp-runtime-interface
6.0.0 - sp-wasm-interface
6.0.0 - up-sponsorship
0.1.0 - xcm
0.9.27 - xcm-executor
0.9.27
- cumulus-pallet-parachain-system
indexmap
1.9.1crates.ioβ 3β 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum10a35a97730320ffe8e2d410b5d3b69279b98d2c14bdb8b70ea89ecf7888d41edepends onInflector
0.11.4crates.ioβ 2β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3depends oninstant
0.1.12crates.ioβ 1β 14sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2cdepends oninteger-encoding
3.0.4crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8bb03732005da905c88227371639bf1ad885cc712789c011c31c5fb3ab3ccf02used byinteger-sqrt
0.1.5crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum276ec31bcb4a9ee45f58bec6f9ec700ae4cf4f4f8f2fa7e06cb406bd5ffdd770depends onused byio-lifetimes
0.5.3crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumec58677acfea8a15352d42fc87d11d63596ade9239e0a7c9352914417515dbe6used byio-lifetimes
0.7.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum24c3f4eff5495aee4c0399d7b6a0dc2b6e81be84242ffbfcf253ebacccc1d0cbused byip_network
0.4.1crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumaa2f047c0a98b2f299aa5d6d7088443570faae494e9ae1305e48be000c9e0eb1ipconfig
0.3.0crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum723519edce41262b05d4143ceb95050e4c614f483e78e9fd9e39a8275a84ad98used byipnet
2.5.0crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum879d54834c8c76457ef4293a689b2a8c59b076067ad77b15efafbb05f92a592bitertools
0.10.3crates.ioβ 1β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma9a9d19fa1e79b6215ff29b9d6880b706147f16e9b1dbb1e4e5947b5b02bc5e3depends onitoa
0.4.8crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4used byitoa
1.0.3crates.ioβ 0β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6c8af84674fe1f223a982c933a0ee1086ac4d4052aa0fb8060c12c6ad838e754jobserver
0.1.24crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumaf25a77299a7f711a01975c35a6a424eb6862092cc2d6c72c4ed6cbc56dfc1fadepends onused byjs-sys
0.3.59crates.ioβ 1β 8sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum258451ab10b34f8af53416d1fdab72c22e805f0c92a1136d59470ec0b11138b2depends onjsonrpsee
0.14.0github.com/uniquenetwork/jsonrpseeβ 7β 22sourcegit+https://github.com/uniquenetwork/jsonrpsee?branch=unique-v0.14.0-fix-unknown-fields#01bb8a7ec51880c79206bdcac4f09d54e58b2da8depends onused by- beefy-gadget-rpc
4.0.0-dev - cumulus-relay-chain-rpc-interface
0.1.0 - fc-rpc
2.0.0-dev - fc-rpc-core
1.1.0-dev - pallet-mmr-rpc
3.0.0 - pallet-transaction-payment-rpc
4.0.0-dev - polkadot-rpc
0.9.27 - remote-externalities
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-rpc-server
4.0.0-dev - sc-service
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - substrate-frame-rpc-system
4.0.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev - try-runtime-cli
0.10.0-dev - uc-rpc
0.1.3 - unique-node
0.9.27 - unique-rpc
0.1.1
- beefy-gadget-rpc
jsonrpsee-client-transport
0.14.0github.com/uniquenetwork/jsonrpseeβ 13β 1sourcegit+https://github.com/uniquenetwork/jsonrpsee?branch=unique-v0.14.0-fix-unknown-fields#01bb8a7ec51880c79206bdcac4f09d54e58b2da8depends onused byjsonrpsee-core
0.14.0github.com/uniquenetwork/jsonrpseeβ 22β 6sourcegit+https://github.com/uniquenetwork/jsonrpsee?branch=unique-v0.14.0-fix-unknown-fields#01bb8a7ec51880c79206bdcac4f09d54e58b2da8depends on- anyhow
1.0.61 - arrayvec
0.7.2 - async-lock
2.5.0 - async-trait
0.1.57 - beef
0.5.2 - futures-channel
0.3.23 - futures-timer
3.0.2 - futures-util
0.3.23 - globset
0.4.9 - hyper
0.14.20 - jsonrpsee-types
0.14.0 - lazy_static
1.4.0 - parking_lot
0.12.1 - rand
0.8.5 - rustc-hash
1.1.0 - serde
1.0.143 - serde_json
1.0.83 - soketto
0.7.1 - thiserror
1.0.32 - tokio
1.20.1 - tracing
0.1.36 - unicase
2.6.0
- anyhow
jsonrpsee-http-server
0.14.0github.com/uniquenetwork/jsonrpseeβ 9β 1sourcegit+https://github.com/uniquenetwork/jsonrpsee?branch=unique-v0.14.0-fix-unknown-fields#01bb8a7ec51880c79206bdcac4f09d54e58b2da8depends onused byjsonrpsee-proc-macros
0.14.0github.com/uniquenetwork/jsonrpseeβ 4β 1sourcegit+https://github.com/uniquenetwork/jsonrpsee?branch=unique-v0.14.0-fix-unknown-fields#01bb8a7ec51880c79206bdcac4f09d54e58b2da8used byjsonrpsee-types
0.14.0github.com/uniquenetwork/jsonrpseeβ 6β 6sourcegit+https://github.com/uniquenetwork/jsonrpsee?branch=unique-v0.14.0-fix-unknown-fields#01bb8a7ec51880c79206bdcac4f09d54e58b2da8jsonrpsee-ws-client
0.14.0github.com/uniquenetwork/jsonrpseeβ 3β 1sourcegit+https://github.com/uniquenetwork/jsonrpsee?branch=unique-v0.14.0-fix-unknown-fields#01bb8a7ec51880c79206bdcac4f09d54e58b2da8used byjsonrpsee-ws-server
0.14.0github.com/uniquenetwork/jsonrpseeβ 10β 1sourcegit+https://github.com/uniquenetwork/jsonrpsee?branch=unique-v0.14.0-fix-unknown-fields#01bb8a7ec51880c79206bdcac4f09d54e58b2da8depends onused byk256
0.10.4crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum19c3a5e0a0b8450278feda242592512e09f61c72e018b8cd5c859482802daf2dused bykeccak
0.1.2crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf9b7d56ba4a8344d6be9729995e6b06f928af29998cdf79fe390cbf6b1fee838kusama-runtime
0.9.27github.com/paritytech/polkadotβ 86β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- beefy-primitives
4.0.0-dev - bitvec
1.0.1 - frame-benchmarking
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - frame-try-runtime
0.10.0-dev - hex-literal
0.3.4 - kusama-runtime-constants
0.9.27 - log
0.4.17 - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-election-provider-support-benchmarking
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-gilt
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-membership
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nomination-pools-runtime-api
1.0.0-dev - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-society
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-staking-reward-fn
4.0.0-dev - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - parity-scale-codec
3.1.5 - polkadot-primitives
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - rustc-hex
2.1.0 - scale-info
2.1.2 - serde
1.0.143 - serde_derive
1.0.143 - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-arithmetic
5.0.0 - sp-authority-discovery
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-consensus-babe
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0 - sp-transaction-pool
4.0.0-dev - sp-version
5.0.0 - static_assertions
1.1.0 - substrate-wasm-builder
5.0.0-dev - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- beefy-primitives
kusama-runtime-constants
0.9.27github.com/paritytech/polkadotβ 5β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bykv-log-macro
1.0.7crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0de8b303297635ad57c9f5059fd9cee7a47f8e8daa09df0fcd07dd39fb22977fdepends onused bykvdb
0.11.0crates.ioβ 2β 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma301d8ecb7989d4a6e2c57a49baca77d353bdbf879909debe3f375fe25d61f86depends onused by- frame-benchmarking-cli
4.0.0-dev - kvdb-memorydb
0.11.0 - kvdb-rocksdb
0.15.2 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-service
0.9.27 - sc-client-db
0.10.0-dev - sp-database
4.0.0-dev
- frame-benchmarking-cli
kvdb-memorydb
0.11.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumece7e668abd21387aeb6628130a6f4c802787f014fa46bc83221448322250357used bykvdb-rocksdb
0.15.2crates.ioβ 10β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumca7fbdfd71cd663dceb0faf3367a99f8cf724514933e9867cec4995b6027cbc1depends onlazy_static
1.4.0crates.ioβ 0β 29sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646used by- Inflector
0.11.4 - bindgen
0.59.2 - flexi_logger
0.22.6 - frame-benchmarking-cli
4.0.0-dev - fs-swap
0.2.6 - jsonrpsee-core
0.14.0 - libp2p
0.46.1 - libp2p-core
0.34.0 - libp2p-mdns
0.38.0 - libp2p-noise
0.37.0 - polkadot-node-jaeger
0.9.27 - prometheus
0.13.1 - prost-build
0.10.4 - sc-executor
0.10.0-dev - sc-tracing
4.0.0-dev - sc-utils
4.0.0-dev - schannel
0.1.20 - sharded-slab
0.1.4 - sp-core
6.0.0 - sp-keyring
6.0.0 - sp-panic-handler
4.0.0 - statrs
0.15.0 - tracing-log
0.1.3 - tracing-subscriber
0.2.25 - trust-dns-proto
0.21.2 - trust-dns-resolver
0.21.2 - wasmtime
0.38.3 - wasmtime-jit-debug
0.38.3 - which
4.2.5
- Inflector
lazycell
1.3.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55used bylibc
0.2.131crates.ioβ 0β 74sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum04c3b4822ccebfa39c02fc03d1534441b22ead323fa0f48bb7ddd8e6ba076a40used by- android_system_properties
0.1.4 - async-io
1.7.0 - async-process
1.4.0 - atty
0.2.14 - backtrace
0.3.66 - bzip2-sys
0.1.11+1.0.8 - clang-sys
1.3.3 - coarsetime
0.1.22 - core-foundation
0.9.3 - cpufeatures
0.2.2 - cranelift-native
0.85.3 - dirs-sys
0.3.7 - dirs-sys-next
0.1.2 - errno
0.2.8 - errno-dragonfly
0.1.2 - fdlimit
0.2.1 - filetime
0.2.17 - fs-swap
0.2.6 - fs2
0.4.3 - gethostname
0.2.3 - getrandom
0.1.16 - getrandom
0.2.7 - hermit-abi
0.1.19 - hostname
0.3.1 - if-addrs
0.7.0 - jobserver
0.1.24 - libp2p-tcp
0.34.0 - librocksdb-sys
0.6.1+6.28.2 - lz4
1.23.3 - lz4-sys
1.9.3 - mach
0.3.2 - memfd
0.4.1 - memmap2
0.2.3 - memmap2
0.5.7 - mio
0.8.4 - netlink-packet-core
0.4.2 - netlink-packet-route
0.12.0 - netlink-sys
0.8.3 - nix
0.24.2 - num_cpus
1.13.1 - num_threads
0.1.6 - parity-db
0.3.16 - parking_lot_core
0.8.5 - parking_lot_core
0.9.3 - polling
2.2.0 - rand
0.7.3 - rand
0.8.5 - region
2.2.0 - ring
0.16.20 - rocksdb
0.18.0 - rpassword
5.0.1 - rustix
0.33.7 - rustix
0.35.7 - sc-executor-wasmtime
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-tracing
4.0.0-dev - security-framework
2.6.1 - security-framework-sys
2.6.1 - signal-hook
0.3.14 - signal-hook-registry
1.4.0 - socket2
0.4.4 - static_init
0.5.2 - system-configuration-sys
0.5.0 - tempfile
3.3.0 - tikv-jemalloc-sys
0.4.3+5.2.1-patched.2 - time
0.1.44 - time
0.3.9 - tokio
1.20.1 - wasmi
0.9.1 - wasmtime
0.38.3 - wasmtime-runtime
0.38.3 - which
4.2.5 - zstd-safe
5.0.2+zstd.1.5.2 - zstd-sys
2.0.1+zstd.1.5.2
- android_system_properties
libloading
0.5.2crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf2b111a074963af1d37a139918ac6d49ad1d0d5e47f72fd55388619691a7d753depends onused bylibloading
0.7.3crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumefbc0f03f9a775e9f6aed295c6a1ba2253c5757a9e03d55c6caa46a681abcddddepends onused bylibm
0.2.5crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum292a948cd991e376cf75541fe5b97a1081d713c618b4f1b9500f8844e49eb565used bylibp2p
0.46.1crates.ioβ 36β 10sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum81327106887e42d004fbdab1fef93675be2e2e07c1b95fce45e2cc813485611ddepends on- bytes
1.2.1 - futures
0.3.23 - futures-timer
3.0.2 - getrandom
0.2.7 - instant
0.1.12 - lazy_static
1.4.0 - libp2p-autonat
0.5.0 - libp2p-core
0.34.0 - libp2p-deflate
0.34.0 - libp2p-dns
0.34.0 - libp2p-floodsub
0.37.0 - libp2p-gossipsub
0.39.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-mdns
0.38.0 - libp2p-metrics
0.7.0 - libp2p-mplex
0.34.0 - libp2p-noise
0.37.0 - libp2p-ping
0.37.0 - libp2p-plaintext
0.34.0 - libp2p-pnet
0.22.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - libp2p-request-response
0.19.0 - libp2p-swarm
0.37.0 - libp2p-swarm-derive
0.28.0 - libp2p-tcp
0.34.0 - libp2p-uds
0.33.0 - libp2p-wasm-ext
0.34.0 - libp2p-websocket
0.36.0 - libp2p-yamux
0.38.0 - multiaddr
0.14.0 - parking_lot
0.12.1 - pin-project
1.0.12 - rand
0.7.3 - smallvec
1.9.0
- bytes
libp2p-autonat
0.5.0crates.ioβ 11β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4decc51f3573653a9f4ecacb31b1b922dd20c25a6322bb15318ec04287ec46f9depends onused bylibp2p-core
0.34.0crates.ioβ 27β 23sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfbf9b94cefab7599b2d3dff2f93bee218c6621d68590b23ede4485813cbcece6depends on- asn1_der
0.7.5 - bs58
0.4.0 - ed25519-dalek
1.0.1 - either
1.7.0 - fnv
1.0.7 - futures
0.3.23 - futures-timer
3.0.2 - instant
0.1.12 - lazy_static
1.4.0 - libsecp256k1
0.7.1 - log
0.4.17 - multiaddr
0.14.0 - multihash
0.16.3 - multistream-select
0.11.0 - parking_lot
0.12.1 - pin-project
1.0.12 - prost
0.10.4 - prost-build
0.10.4 - rand
0.8.5 - ring
0.16.20 - rw-stream-sink
0.3.0 - sha2
0.10.2 - smallvec
1.9.0 - thiserror
1.0.32 - unsigned-varint
0.7.1 - void
1.0.2 - zeroize
1.5.7
used by- libp2p
0.46.1 - libp2p-autonat
0.5.0 - libp2p-deflate
0.34.0 - libp2p-dns
0.34.0 - libp2p-floodsub
0.37.0 - libp2p-gossipsub
0.39.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-mdns
0.38.0 - libp2p-metrics
0.7.0 - libp2p-mplex
0.34.0 - libp2p-noise
0.37.0 - libp2p-ping
0.37.0 - libp2p-plaintext
0.34.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - libp2p-request-response
0.19.0 - libp2p-swarm
0.37.0 - libp2p-tcp
0.34.0 - libp2p-uds
0.33.0 - libp2p-wasm-ext
0.34.0 - libp2p-websocket
0.36.0 - libp2p-yamux
0.38.0
- asn1_der
libp2p-deflate
0.34.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd0183dc2a3da1fbbf85e5b6cf51217f55b14f5daea0c455a9536eef646bfec71used bylibp2p-dns
0.34.0crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6cbf54723250fa5d521383be789bf60efdabe6bacfb443f87da261019a49b4b5depends onused bylibp2p-floodsub
0.37.0crates.ioβ 10β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum98a4b6ffd53e355775d24b76f583fdda54b3284806f678499b57913adb94f231depends onused bylibp2p-gossipsub
0.39.0crates.ioβ 20β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum74b4b888cfbeb1f5551acd3aa1366e01bf88ede26cc3c4645d0d2d004d5ca7b0depends onlibp2p-identify
0.37.0crates.ioβ 13β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc50b585518f8efd06f93ac2f976bd672e17cdac794644b3117edd078e96bda06depends onlibp2p-kad
0.38.0crates.ioβ 20β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum740862893bb5f06ac24acc9d49bdeadc3a5e52e51818a30a25c1f3519da2c851depends onlibp2p-mdns
0.38.0crates.ioβ 13β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum66e5e5919509603281033fd16306c61df7a4428ce274b67af5e14b07de5cdcb2depends onused bylibp2p-metrics
0.7.0crates.ioβ 8β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumef8aff4a1abef42328fbb30b17c853fff9be986dc39af17ee39f9c5f755c5e0cdepends onused bylibp2p-mplex
0.34.0crates.ioβ 10β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum61fd1b20638ec209c5075dfb2e8ce6a7ea4ec3cd3ad7b77f7a477c06d53322e2depends onused bylibp2p-noise
0.37.0crates.ioβ 14β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum762408cb5d84b49a600422d7f9a42c18012d8da6ebcd570f9a4a4290ba41fb6fdepends onused bylibp2p-ping
0.37.0crates.ioβ 8β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum100a6934ae1dbf8a693a4e7dd1d730fd60b774dafc45688ed63b554497c6c925depends onlibp2p-plaintext
0.34.0crates.ioβ 9β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbe27bf0820a6238a4e06365b096d428271cce85a129cf16f2fe9eb1610c4df86depends onused bylibp2p-pnet
0.22.0crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0f1a458bbda880107b5b36fcb9b5a1ef0c329685da0e203ed692a8ebe64cc92cused bylibp2p-relay
0.10.0crates.ioβ 18β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4931547ee0cce03971ccc1733ff05bb0c4349fd89120a39e9861e2bbe18843c3depends onlibp2p-rendezvous
0.7.0crates.ioβ 15β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9511c9672ba33284838e349623319c8cad2d18cfad243ae46c6b7e8a2982ea4edepends onused bylibp2p-request-response
0.19.0crates.ioβ 10β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum508a189e2795d892c8f5c1fa1e9e0b1845d32d7b0b249dbf7b05b18811361843depends onlibp2p-swarm
0.37.0crates.ioβ 12β 12sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum95ac5be6c2de2d1ff3f7693fda6faf8a827b1f3e808202277783fea9f527d114depends onlibp2p-swarm-derive
0.28.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9f54a64b6957249e0ce782f8abf41d97f69330d02bf229f0672d864f0650cc76depends onused bylibp2p-tcp
0.34.0crates.ioβ 9β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8a6771dc19aa3c65d6af9a8c65222bfc8fcd446630ddca487acd161fa6096f3bdepends onused bylibp2p-uds
0.33.0crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd125e3e5f0d58f3c6ac21815b20cf4b6a88b8db9dc26368ea821838f4161fd4dused bylibp2p-wasm-ext
0.34.0crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumec894790eec3c1608f8d1a8a0bdf0dbeb79ed4de2dce964222011c2896dfa05adepends onused bylibp2p-websocket
0.36.0crates.ioβ 11β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9808e57e81be76ff841c106b4c5974fb4d41a233a7bdd2afbf1687ac6def3818depends onused bylibp2p-yamux
0.38.0crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc6dea686217a06072033dc025631932810e2f6ad784e4fafa42e27d311c7a81cused bylibrocksdb-sys
0.6.1+6.28.2crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum81bc587013734dadb7cf23468e531aa120788b87243648be42e2d3a072186291depends onused bylibsecp256k1
0.7.1crates.ioβ 11β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum95b09eff1b35ed3b33b877ced3a691fc7a481919c7e29c53c906226fcf55e2a1depends onlibsecp256k1-core
0.3.0crates.ioβ 3β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5be9b9bb642d8522a44d533eab56c16c738301965504753b03ad1de3425d5451depends onlibsecp256k1-gen-ecmult
0.3.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3038c808c55c87e8a172643a7d87187fc6c4174468159cb3090659d55bcb4809depends onused bylibsecp256k1-gen-genmult
0.3.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3db8d6ba2cec9eacc40e6e8ccc98931840301f1006e95647ceb2dd5c3aa06f7cdepends onused bylibz-sys
1.1.8crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9702761c3935f8cc2f101793272e202c72b99da8f4224a19ddcf1279a6450bbfdepends onlinked_hash_set
0.1.4crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum47186c6da4d81ca383c7c47c1bfc80f4b95f4720514d860a5407aaf4233f9588depends onused bylinked-hash-map
0.5.6crates.ioβ 0β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0717cef1bc8b636c6e1c1bbdefc09e6322da8a9321966e8928ef80d20f7f770flinregress
0.4.4crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd6c601a85f5ecd1aba625247bca0031585fb1c446461b142878a16f8245ddeb8depends onused bylinux-raw-sys
0.0.42crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5284f00d480e1c39af34e72f8ad60b94f47007e3481cd3b731c1d67190ddc7b7used bylinux-raw-sys
0.0.46crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd4d2456c373231a208ad294c33dc5bff30051eafd954cd4caae83a712b12854dused bylock_api
0.4.7crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum327fa5b6a6940e4699ec49a9beae1ea4845c6bab9314e4f84ac68742139d8c53depends onlog
0.4.17crates.ioβ 2β 171sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumabb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382edepends onused by- async-io
1.7.0 - async-std
1.12.0 - beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - cranelift-codegen
0.85.3 - cranelift-frontend
0.85.3 - cranelift-wasm
0.85.3 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - env_logger
0.9.0 - evm
0.35.0 - fc-mapping-sync
2.0.0-dev - fc-rpc
2.0.0-dev - file-per-thread-logger
0.1.5 - finality-grandpa
0.16.0 - flexi_logger
0.22.6 - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - globset
0.4.9 - handlebars
4.3.3 - hyper-rustls
0.23.0 - if-watch
1.1.1 - kusama-runtime
0.9.27 - kv-log-macro
1.0.7 - kvdb-rocksdb
0.15.2 - libp2p-autonat
0.5.0 - libp2p-core
0.34.0 - libp2p-dns
0.34.0 - libp2p-floodsub
0.37.0 - libp2p-gossipsub
0.39.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-mdns
0.38.0 - libp2p-mplex
0.34.0 - libp2p-noise
0.37.0 - libp2p-ping
0.37.0 - libp2p-plaintext
0.34.0 - libp2p-pnet
0.22.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - libp2p-request-response
0.19.0 - libp2p-swarm
0.37.0 - libp2p-tcp
0.34.0 - libp2p-uds
0.33.0 - libp2p-websocket
0.36.0 - mio
0.8.4 - multistream-select
0.11.0 - netlink-proto
0.10.0 - netlink-sys
0.8.3 - opal-runtime
0.9.27 - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-contract-helpers
0.1.2 - pallet-foreing-assets
0.1.0 - pallet-grandpa
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-membership
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-offences
4.0.0-dev - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-staking-reward-fn
4.0.0-dev - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-unique-scheduler
0.1.1 - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - parity-db
0.3.16 - polkadot-cli
0.9.27 - polkadot-node-jaeger
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-performance-test
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - polling
2.2.0 - prost-build
0.10.4 - quartz-runtime
0.9.27 - regalloc2
0.2.3 - remote-externalities
0.10.0-dev - rococo-runtime
0.9.27 - rtnetlink
0.10.1 - rustls
0.20.6 - sc-allocator
4.1.0-dev - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-executor-wasmi
0.10.0-dev - sc-executor-wasmtime
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-informant
0.10.0-dev - sc-network
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-peerset
4.0.0-dev - sc-proposer-metrics
0.10.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-rpc-server
4.0.0-dev - sc-service
0.10.0-dev - sc-state-db
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - sc-utils
4.0.0-dev - soketto
0.7.1 - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-io
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-runtime
6.0.0 - sp-sandbox
0.10.0-dev - sp-state-machine
0.12.0 - sp-tasks
4.0.0-dev - sp-timestamp
4.0.0-dev - sp-transaction-storage-proof
4.0.0-dev - sp-wasm-interface
6.0.0 - substrate-frame-rpc-system
4.0.0-dev - substrate-prometheus-endpoint
0.10.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev - thrift
0.15.0 - tracing-log
0.1.3 - trie-db
0.23.1 - trust-dns-proto
0.21.2 - trust-dns-resolver
0.21.2 - try-runtime-cli
0.10.0-dev - unique-node
0.9.27 - unique-runtime
0.9.27 - want
0.3.0 - wasm-bindgen-backend
0.2.82 - wasm-gc-api
0.1.11 - wasmtime
0.38.3 - wasmtime-cache
0.38.3 - wasmtime-cranelift
0.38.3 - wasmtime-environ
0.38.3 - wasmtime-jit
0.38.3 - wasmtime-runtime
0.38.3 - westend-runtime
0.9.27 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27 - yamux
0.10.2
- async-io
lru
0.6.6crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7ea2d928b485416e8908cff2d97d621db22b27f7b3b6729e438bcf42c671ba91depends onused bylru
0.7.8crates.ioβ 1β 16sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume999beba7b6e8345721bd280141ed958096a2e4abdf74f67ff4ce49b4b54e47adepends onused by- fc-rpc
2.0.0-dev - libp2p-identify
0.37.0 - parity-util-mem
0.11.0 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-service
0.9.27 - sc-executor
0.10.0-dev - sc-network
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-network-sync
0.10.0-dev - sp-blockchain
4.0.0-dev
- fc-rpc
lru-cache
0.1.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum31e24f1ad8321ca0e8a1e0ac13f23cb668e6f5466c2c57319f6a5cf1cc8e3b1cdepends onused bylz4
1.23.3crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4edcb94251b1c375c459e5abe9fb0168c1c826c3370172684844f8f3f8d1a885depends onused bylz4-sys
1.9.3crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd7be8908e2ed6f31c02db8a9fa962f03e36c53fbfde437363eae3306b85d7e17depends onused bymach
0.3.2crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb823e83b2affd8f40a9ee8c29dbc56404c1e34cd2710921f2801e2cf29527afadepends onmatch_cfg
0.1.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumffbee8634e0d45d258acb448e7eaab3fce7a0a467395d4d9f228e3c1f01fb2e4used bymatchers
0.0.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf099785f7595cc4b4553a174ce30dd7589ef93391ff414dbb67f62392b9e0ce1depends onused bymatches
0.1.9crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma3e378b66a060d48947b590737b30a1be76706c8dd7b8ba0f2fe3989c68a853fmatrixmultiply
0.3.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumadd85d4dd35074e6fedc608f8c8f513a3548619a9024b751949ef0e8e45a4d84depends onused bymemchr
2.5.0crates.ioβ 0β 14sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566dmemfd
0.4.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf6627dc657574b49d6ad27105ed671822be56e0d2547d413bfbf3e8d8fa92e7adepends onused bymemmap2
0.2.3crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum723e3ebdcdc5c023db1df315364573789f8857c11b631a2fdfad7c00f5c046b4depends onused bymemmap2
0.5.7crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum95af15f345b17af2efc8ead6080fb8bc376f8cec1b35277b935637595fe77498depends onused bymemoffset
0.6.5crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79cedepends onmemory_units
0.3.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum71d96e3f3c0b6325d8ccd83c33b28acb183edcb6c67938ba104ec546854b0882used bymemory-db
0.29.0crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6566c70c1016f525ced45d7b7f97730a2bafb037c788211d0c186ef5b2189f0amemory-lru
0.1.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbeeb98b3d1ed2c0054bd81b5ba949a0243c3ccad751d45ea898fa8059fa2860adepends onmerlin
2.0.1crates.ioβ 4β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4e261cf0f8b3c42ded9f7d2bb59dea03aa52bc8a1cbc7482f9fc3fd1229d3b42mick-jaeger
0.1.8crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum69672161530e8aeca1d1400fbf3f1a1747ff60ea604265a4e906c2442df20532depends onused byminimal-lexical
0.2.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79aused byminiz_oxide
0.5.3crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6f5c75688da582b8ffc1f1799e9db273f32133c49e048f614d22ec3256773cccdepends onused bymio
0.8.4crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum57ee1c23c7c63b0c9250c339ffdc69255f110b298b901b9f6c82547b7b87caafused bymore-asserts
0.2.2crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7843ec2de400bcbc6a6328c958dc38e5359da6e93e72e37bc5246bf1ae776389multiaddr
0.14.0crates.ioβ 10β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3c580bfdd8803cce319b047d239559a22f809094aaea4ac13902a1fdcfcd4261depends onmultibase
0.9.1crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9b3539ec3c1f04ac9748a260728e855f261b4977f5c3406612c884564f329404used bymultihash
0.16.3crates.ioβ 9β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1c346cf9999c631f002d8f977c4eaeaa0e6386f16007202308d0b3757522c2ccdepends onmultihash-derive
0.8.0crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfc076939022111618a5026d3be019fd8b366e76314538ff9a1b59ffbcbf98bcddepends onused bymultimap
0.8.3crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume5ce46fe64a9d73be07dcbe690a38ce1b293be448fd8ce1e6c1b8062c9f72c6aused bymultistream-select
0.11.0crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum363a84be6453a70e63513660f4894ef815daf88e3356bffcda9ca27d810ce83bused bynalgebra
0.27.1crates.ioβ 10β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum462fffe4002f4f2e1f6a9dcf12cc1a6fc0e15989014efc02a941d3e0f5dc2120depends onused bynalgebra-macros
0.1.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum01fcc0b8149b4632adc89ac3b7b31a12fb6099a0317a4eb2ebff574ef7de7218depends onused bynames
0.13.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume7d66043b25d4a6cccb23619d10c19c25304b355a7dccd4a8e11423dd2382146depends onused bynanorand
0.7.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6a51313c5820b0b02bd422f4b44776fbf47961755c74ce64afc73bfad10226c3netlink-packet-core
0.4.2crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum345b8ab5bd4e71a2986663e88c56856699d060e78e152e6e9d7966fcd5491297netlink-packet-route
0.12.0crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd9ea4302b9759a7a88242299225ea3688e63c85ea136371bb6cf94fd674efaabdepends onused bynetlink-packet-utils
0.5.1crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum25af9cf0dc55498b7bd94a1508af7a78706aa0ab715a73c5169273e03c84845enetlink-proto
0.10.0crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum65b4b14489ab424703c092062176d52ba55485a89c076b4f9db05092b7223aa6depends onused bynetlink-sys
0.8.3crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum92b654097027250401127914afb37cb1f311df6610a9891ff07a757e94199027used bynix
0.24.2crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum195cdbc1741b8134346d515b3a56a1c94b0912758009cfd53f99ea0f57b065fcdepends onused bynodrop
0.1.14crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bbused bynohash-hasher
0.2.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2bf50223579dc7cdcfb3bfcacf7069ff68243f8c363f62ffa99cf000a6b9c451nom
7.1.1crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma8903e5a29a317527874d0402f867152a3d21c908bb0b933e416c65e301d4c36depends onused bynum_cpus
1.13.1crates.ioβ 2β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum19e64526ebdee182341572e50e9ad03965aa510cd94427a4549448f285e957a1depends onnum_threads
0.1.6crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2819ce041d2ee131036f4fc9d6ae7ae125a3a40e97ba64d04fe799ad9dabbb44depends onused bynum-bigint
0.2.6crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum090c7f9998ee0ff65aa5b723e4009f7b217707f1fb5ea551329cc4d6231fb304num-complex
0.4.2crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7ae39348c8bc5fbd7f40c727a9925f03517afd2ab27d46702108b6a7e5414c19depends onused bynum-format
0.4.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbafe4179722c2894288ee77a9f044f02811c86af699344c498b0840c698a2465depends onused bynum-integer
0.1.45crates.ioβ 2β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9depends onnum-rational
0.2.4crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5c000134b5dbf44adc5cb772486d335293351644b801551abe8f75c84cfa4aefnum-rational
0.4.1crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0used bynum-traits
0.2.15crates.ioβ 2β 20sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcddepends onused by- approx
0.5.1 - chrono
0.4.22 - finality-grandpa
0.16.0 - integer-sqrt
0.1.5 - nalgebra
0.27.1 - num-bigint
0.2.6 - num-complex
0.4.2 - num-integer
0.1.45 - num-rational
0.2.4 - num-rational
0.4.1 - ordered-float
1.1.1 - orml-traits
0.4.1-dev - rand_distr
0.4.3 - sc-consensus-babe
0.10.0-dev - simba
0.5.1 - sp-arithmetic
5.0.0 - sp-core
6.0.0 - sp-state-machine
0.12.0 - statrs
0.15.0 - wasmi
0.9.1
- approx
object
0.28.4crates.ioβ 4β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume42c982f2d955fac81dd7e1d0e1426a7d702acd9c98d19ab01083a6a0328c424object
0.29.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum21158b2c33aa6d4561f1c0a6ea283ca92bc54802a93b263e910746d679a7eb53depends onused byonce_cell
1.13.0crates.ioβ 0β 24sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum18a6dbe30758c9f83eb00cbea4ac95966305f5a7772f3f42ebfc7fc7eddbd8e1used by- ahash
0.7.6 - async-executor
1.4.1 - async-global-executor
2.2.0 - async-io
1.7.0 - async-process
1.4.0 - async-std
1.12.0 - blocking
1.2.0 - clap
3.2.17 - coarsetime
0.1.22 - crossbeam-epoch
0.9.10 - crossbeam-utils
0.8.11 - frame-support
4.0.0-dev - pest_meta
2.2.1 - proc-macro-crate
1.2.1 - ring
0.16.20 - sc-executor-wasmtime
0.10.0-dev - sc-offchain
4.0.0-dev - sc-tracing
4.0.0-dev - thread_local
1.1.4 - tiny-bip39
0.8.2 - tokio
1.20.1 - tracing-core
0.1.29 - wasm-bindgen-backend
0.2.82 - wasmtime
0.38.3
- ahash
opal-runtime
0.9.27workspaceβ 83β 1depends on- cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-timestamp
0.1.0 - cumulus-primitives-utility
0.1.0 - derivative
2.2.0 - evm-coder
0.1.1 - fp-evm-mapping
0.1.0 - fp-rpc
3.0.0-dev - fp-self-contained
1.0.0-dev - frame-benchmarking
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - frame-try-runtime
0.10.0-dev - hex-literal
0.3.4 - log
0.4.17 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-inflation
0.1.1 - pallet-nonfungible
0.1.4 - pallet-randomness-collective-flip
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-structure
0.1.2 - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-xcm
0.9.27 - parachain-info
0.1.0 - parity-scale-codec
3.1.5 - polkadot-parachain
0.9.27 - rmrk-rpc
0.0.2 - scale-info
2.1.2 - serde
1.0.143 - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-arithmetic
5.0.0 - sp-block-builder
4.0.0-dev - sp-consensus-aura
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-std
4.0.0 - sp-transaction-pool
4.0.0-dev - sp-version
5.0.0 - substrate-wasm-builder
5.0.0-dev - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3 - up-sponsorship
0.1.0 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
used by- cumulus-pallet-aura-ext
opaque-debug
0.2.3crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2839e79665f131bdb5782e51f2c6c9599c133c6098982a54c794358bf432529cused byopaque-debug
0.3.0crates.ioβ 0β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5openssl-probe
0.1.5crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cfused byorchestra
0.0.1github.com/paritytech/polkadotβ 9β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onorchestra-proc-macro
0.0.1github.com/paritytech/polkadotβ 7β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused byordered-float
1.1.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3305af35278dd29f46fcdd139e0b1fbfae2153f0e5928b39b035542dd31e37b7depends onused byorml-tokens
0.4.1-devgithub.com/open-web3-stack/open-runtime-module-libraryβ 8β 4sourcegit+https://github.com/open-web3-stack/open-runtime-module-library?branch=polkadot-v0.9.27#377213f750755cc48e80a3131eaae63b5eda8362depends onorml-traits
0.4.1-devgithub.com/open-web3-stack/open-runtime-module-libraryβ 11β 6sourcegit+https://github.com/open-web3-stack/open-runtime-module-library?branch=polkadot-v0.9.27#377213f750755cc48e80a3131eaae63b5eda8362depends onorml-utilities
0.4.1-devgithub.com/open-web3-stack/open-runtime-module-libraryβ 7β 1sourcegit+https://github.com/open-web3-stack/open-runtime-module-library?branch=polkadot-v0.9.27#377213f750755cc48e80a3131eaae63b5eda8362depends onused byorml-vesting
0.4.1-devgithub.com/open-web3-stack/open-runtime-module-libraryβ 8β 3sourcegit+https://github.com/open-web3-stack/open-runtime-module-library?branch=polkadot-v0.9.27#377213f750755cc48e80a3131eaae63b5eda8362depends onorml-xcm-support
0.4.1-devgithub.com/open-web3-stack/open-runtime-module-libraryβ 7β 1sourcegit+https://github.com/open-web3-stack/open-runtime-module-library?branch=polkadot-v0.9.27#377213f750755cc48e80a3131eaae63b5eda8362depends onused byorml-xtokens
0.4.1-devgithub.com/open-web3-stack/open-runtime-module-libraryβ 14β 3sourcegit+https://github.com/open-web3-stack/open-runtime-module-library?branch=polkadot-v0.9.27#377213f750755cc48e80a3131eaae63b5eda8362depends onos_str_bytes
6.3.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9ff7415e9ae3fff1225851df9e0d9e4e5479f947619774677a63572e55e80effused byowning_ref
0.4.1crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6ff55baddef9e4ad00f88b6c743a2a8062d4c6ade126c2a528644b8e444d52cedepends onpallet-aura
4.0.0-devgithub.com/paritytech/substrateβ 9β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-authority-discovery
4.0.0-devgithub.com/paritytech/substrateβ 9β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-authorship
4.0.0-devgithub.com/paritytech/substrateβ 8β 11sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-babe
4.0.0-devgithub.com/paritytech/substrateβ 17β 9sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- frame-benchmarking
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - log
0.4.17 - pallet-authorship
4.0.0-dev - pallet-session
4.0.0-dev - pallet-timestamp
4.0.0-dev - parity-scale-codec
3.1.5 - scale-info
2.1.2 - sp-application-crypto
6.0.0 - sp-consensus-babe
0.10.0-dev - sp-consensus-vrf
0.10.0-dev - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0
- frame-benchmarking
pallet-bags-list
4.0.0-devgithub.com/paritytech/substrateβ 13β 5sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-balances
4.0.0-devgithub.com/paritytech/substrateβ 8β 20sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-pallet-parachain-system
0.1.0 - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-bags-list
4.0.0-dev - pallet-foreing-assets
0.1.0 - pallet-inflation
0.1.1 - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-treasury
4.0.0-dev - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - tests
0.1.1 - unique-runtime
0.9.27 - westend-runtime
0.9.27
- cumulus-pallet-parachain-system
pallet-base-fee
1.0.0github.com/uniquenetwork/frontierβ 8β 3sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends onpallet-beefy
4.0.0-devgithub.com/paritytech/substrateβ 9β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-beefy-mmr
4.0.0-devgithub.com/paritytech/substrateβ 16β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-bounties
4.0.0-devgithub.com/paritytech/substrateβ 11β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-child-bounties
4.0.0-devgithub.com/paritytech/substrateβ 12β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-collective
4.0.0-devgithub.com/paritytech/substrateβ 10β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-common
0.1.5workspaceβ 15β 16depends onused by- opal-runtime
0.9.27 - pallet-evm-contract-helpers
0.1.2 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-nonfungible
0.1.4 - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-structure
0.1.2 - pallet-unique
0.1.3 - quartz-runtime
0.9.27 - tests
0.1.1 - uc-rpc
0.1.3 - unique-rpc
0.1.1 - unique-runtime
0.9.27 - up-rpc
0.1.3
- opal-runtime
pallet-configuration
0.1.1workspaceβ 10β 3pallet-democracy
4.0.0-devgithub.com/paritytech/substrateβ 9β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-election-provider-multi-phase
4.0.0-devgithub.com/paritytech/substrateβ 16β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-election-provider-support-benchmarking
4.0.0-devgithub.com/paritytech/substrateβ 6β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-elections-phragmen
5.0.0-devgithub.com/paritytech/substrateβ 11β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-ethereum
4.0.0-devgithub.com/uniquenetwork/frontierβ 22β 8sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends on- ethereum
0.12.0 - ethereum-types
0.13.1 - evm
0.35.0 - fp-consensus
2.0.0-dev - fp-evm
3.0.0-dev - fp-evm-mapping
0.1.0 - fp-rpc
3.0.0-dev - fp-self-contained
1.0.0-dev - fp-storage
2.0.0 - frame-support
4.0.0-dev - frame-system
4.0.0-dev - log
0.4.17 - pallet-evm
6.0.0-dev - pallet-timestamp
4.0.0-dev - parity-scale-codec
3.1.5 - rlp
0.5.1 - scale-info
2.1.2 - serde
1.0.143 - sha3
0.10.2 - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-std
4.0.0
- ethereum
pallet-evm
6.0.0-devgithub.com/uniquenetwork/frontierβ 20β 21sourcegit+https://github.com/uniquenetwork/frontier?branch=unique-polkadot-v0.9.27#64915c0986fcf2bbe942794b838c0cf359c93c21depends on- evm
0.35.0 - fp-evm
3.0.0-dev - fp-evm-mapping
0.1.0 - frame-benchmarking
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - hex
0.4.3 - impl-trait-for-tuples
0.2.2 - log
0.4.17 - pallet-timestamp
4.0.0-dev - parity-scale-codec
3.1.5 - primitive-types
0.11.1 - rlp
0.5.1 - scale-info
2.1.2 - serde
1.0.143 - sha3
0.10.2 - sp-core
6.0.0 - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-std
4.0.0
used by- opal-runtime
0.9.27 - pallet-common
0.1.5 - pallet-ethereum
4.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-fungible
0.1.3 - pallet-nonfungible
0.1.4 - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-structure
0.1.2 - pallet-unique
0.1.3 - quartz-runtime
0.9.27 - tests
0.1.1 - uc-rpc
0.1.3 - unique-runtime
0.9.27 - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3
- evm
pallet-evm-coder-substrate
0.1.3workspaceβ 12β 10depends onpallet-evm-contract-helpers
0.1.2workspaceβ 15β 3depends onpallet-evm-migration
0.1.1workspaceβ 11β 3pallet-evm-transaction-payment
0.1.1workspaceβ 13β 3depends onpallet-foreing-assets
0.1.0workspaceβ 21β 3depends on- frame-support
4.0.0-dev - frame-system
4.0.0-dev - hex
0.4.3 - log
0.4.17 - orml-tokens
0.4.1-dev - pallet-balances
4.0.0-dev - pallet-common
0.1.5 - pallet-fungible
0.1.3 - pallet-timestamp
4.0.0-dev - parity-scale-codec
3.1.5 - scale-info
2.1.2 - serde
1.0.143 - serde_json
1.0.83 - sp-core
6.0.0 - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-std
4.0.0 - up-data-structs
0.2.2 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- frame-support
pallet-fungible
0.1.3workspaceβ 15β 5depends onpallet-gilt
4.0.0-devgithub.com/paritytech/substrateβ 8β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bypallet-grandpa
4.0.0-devgithub.com/paritytech/substrateβ 16β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- frame-benchmarking
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - log
0.4.17 - pallet-authorship
4.0.0-dev - pallet-session
4.0.0-dev - parity-scale-codec
3.1.5 - scale-info
2.1.2 - sp-application-crypto
6.0.0 - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0
- frame-benchmarking
pallet-identity
4.0.0-devgithub.com/paritytech/substrateβ 9β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-im-online
4.0.0-devgithub.com/paritytech/substrateβ 13β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-indices
4.0.0-devgithub.com/paritytech/substrateβ 10β 5sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-inflation
0.1.1workspaceβ 13β 3depends onpallet-membership
4.0.0-devgithub.com/paritytech/substrateβ 10β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-mmr
4.0.0-devgithub.com/paritytech/substrateβ 11β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-mmr-rpc
3.0.0github.com/paritytech/substrateβ 8β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bypallet-multisig
4.0.0-devgithub.com/paritytech/substrateβ 8β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-nomination-pools
1.0.0github.com/paritytech/substrateβ 10β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-nomination-pools-benchmarking
1.0.0github.com/paritytech/substrateβ 12β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-nomination-pools-runtime-api
1.0.0-devgithub.com/paritytech/substrateβ 3β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05pallet-nonfungible
0.1.4workspaceβ 16β 7depends on- ethereum
0.12.0 - evm-coder
0.1.1 - frame-benchmarking
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - pallet-common
0.1.5 - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-structure
0.1.2 - parity-scale-codec
3.1.5 - scale-info
2.1.2 - sp-core
6.0.0 - sp-runtime
6.0.0 - sp-std
4.0.0 - struct-versioning
0.1.0 - up-data-structs
0.2.2
- ethereum
pallet-offences
4.0.0-devgithub.com/paritytech/substrateβ 10β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-offences-benchmarking
4.0.0-devgithub.com/paritytech/substrateβ 16β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- frame-benchmarking
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-offences
4.0.0-dev - pallet-session
4.0.0-dev - pallet-staking
4.0.0-dev - parity-scale-codec
3.1.5 - scale-info
2.1.2 - sp-runtime
6.0.0 - sp-staking
4.0.0-dev - sp-std
4.0.0
- frame-benchmarking
pallet-preimage
4.0.0-devgithub.com/paritytech/substrateβ 9β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-proxy
4.0.0-devgithub.com/paritytech/substrateβ 8β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-randomness-collective-flip
4.0.0-devgithub.com/paritytech/substrateβ 7β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-recovery
4.0.0-devgithub.com/paritytech/substrateβ 8β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-refungible
0.2.3workspaceβ 17β 5depends on- derivative
2.2.0 - ethereum
0.12.0 - evm-coder
0.1.1 - frame-benchmarking
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - pallet-common
0.1.5 - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-structure
0.1.2 - parity-scale-codec
3.1.5 - scale-info
2.1.2 - sp-core
6.0.0 - sp-runtime
6.0.0 - sp-std
4.0.0 - struct-versioning
0.1.0 - up-data-structs
0.2.2
- derivative
pallet-rmrk-core
0.1.2workspaceβ 15β 4depends onpallet-rmrk-equip
0.1.2workspaceβ 14β 3depends onpallet-scheduler
4.0.0-devgithub.com/paritytech/substrateβ 9β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-session
4.0.0-devgithub.com/paritytech/substrateβ 14β 15sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- kusama-runtime
0.9.27 - pallet-authority-discovery
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-staking
4.0.0-dev - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - rococo-runtime
0.9.27 - westend-runtime
0.9.27
- kusama-runtime
pallet-session-benchmarking
4.0.0-devgithub.com/paritytech/substrateβ 9β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-society
4.0.0-devgithub.com/paritytech/substrateβ 7β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-staking
4.0.0-devgithub.com/paritytech/substrateβ 16β 12sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- frame-benchmarking
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - log
0.4.17 - pallet-authorship
4.0.0-dev - pallet-session
4.0.0-dev - parity-scale-codec
3.1.5 - rand_chacha
0.2.2 - scale-info
2.1.2 - serde
1.0.143 - sp-application-crypto
6.0.0 - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-staking
4.0.0-dev - sp-std
4.0.0
used by- kusama-runtime
0.9.27 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-offences-benchmarking
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - rococo-runtime
0.9.27 - westend-runtime
0.9.27
- frame-benchmarking
pallet-staking-reward-curve
4.0.0-devgithub.com/paritytech/substrateβ 4β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05pallet-staking-reward-fn
4.0.0-devgithub.com/paritytech/substrateβ 2β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bypallet-structure
0.1.2workspaceβ 9β 8depends onpallet-sudo
4.0.0-devgithub.com/paritytech/substrateβ 7β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-template-transaction-payment
3.0.0github.com/uniquenetwork/pallet-sponsoringβ 13β 3sourcegit+https://github.com/uniquenetwork/pallet-sponsoring?branch=polkadot-v0.9.27#853766d6033ceb68a2bef196790b962dd0663a04depends onpallet-timestamp
4.0.0-devgithub.com/paritytech/substrateβ 11β 18sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-aura
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-foreing-assets
0.1.0 - pallet-inflation
0.1.1 - pallet-session
4.0.0-dev - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - tests
0.1.1 - unique-runtime
0.9.27 - westend-runtime
0.9.27
- kusama-runtime
pallet-tips
4.0.0-devgithub.com/paritytech/substrateβ 12β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-transaction-payment
4.0.0-devgithub.com/paritytech/substrateβ 9β 15sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-template-transaction-payment
3.0.0 - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - polkadot-client
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - tests
0.1.1 - unique-runtime
0.9.27 - westend-runtime
0.9.27 - xcm-builder
0.9.27
- kusama-runtime
pallet-transaction-payment-rpc
4.0.0-devgithub.com/paritytech/substrateβ 8β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-transaction-payment-rpc-runtime-api
4.0.0-devgithub.com/paritytech/substrateβ 4β 13sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05pallet-treasury
4.0.0-devgithub.com/paritytech/substrateβ 10β 10sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-unique
0.1.3workspaceβ 18β 5depends on- ethereum
0.12.0 - evm-coder
0.1.1 - frame-benchmarking
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - pallet-common
0.1.5 - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-nonfungible
0.1.4 - pallet-refungible
0.2.3 - parity-scale-codec
3.1.5 - scale-info
2.1.2 - serde
1.0.143 - sp-core
6.0.0 - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-std
4.0.0 - up-data-structs
0.2.2
- ethereum
pallet-unique-scheduler
0.1.1workspaceβ 13β 3depends onpallet-utility
4.0.0-devgithub.com/paritytech/substrateβ 9β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-vesting
4.0.0-devgithub.com/paritytech/substrateβ 8β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onpallet-xcm
0.9.27github.com/paritytech/polkadotβ 11β 9sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onpallet-xcm-benchmarks
0.9.27github.com/paritytech/polkadotβ 10β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onparachain-info
0.1.0github.com/paritytech/cumulusβ 6β 3sourcegit+https://github.com/paritytech/cumulus?branch=polkadot-v0.9.27#66b684f88eba6c755651b8c47dccad2c2d9ac3dbdepends onparity-db
0.3.16crates.ioβ 11β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2bb474d0ed0836e185cb998a6b140ed1073d1fbf27d690ecf9ede8030289382cdepends onparity-scale-codec
2.3.1crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum373b1a4c1338d9cd3d1fa53b3a11bdab5ab6bd80a20f7f7becd76953ae2be909depends onused byparity-scale-codec
3.1.5crates.ioβ 6β 230sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9182e4a71cae089267ab03e67c99368db7cd877baf50f931e5d6d4b71e195ac0depends onused by- beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - beefy-primitives
4.0.0-dev - cumulus-client-cli
0.1.0 - cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-primitives-timestamp
0.1.0 - cumulus-primitives-utility
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - cumulus-test-relay-sproof-builder
0.1.0 - ethereum
0.12.0 - evm
0.35.0 - evm-core
0.35.0 - fc-db
2.0.0-dev - fc-rpc
2.0.0-dev - finality-grandpa
0.16.0 - fork-tree
3.0.0 - fp-consensus
2.0.0-dev - fp-evm
3.0.0-dev - fp-rpc
3.0.0-dev - fp-self-contained
1.0.0-dev - fp-storage
2.0.0 - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-metadata
15.0.0 - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - impl-codec
0.6.0 - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-utilities
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xcm-support
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-election-provider-support-benchmarking
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-gilt
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-mmr-rpc
3.0.0 - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nomination-pools-runtime-api
1.0.0-dev - pallet-nonfungible
0.1.4 - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-randomness-collective-flip
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-society
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-structure
0.1.2 - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - parachain-info
0.1.0 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-core-primitives
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-erasure-coding
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-jaeger
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-metrics
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-statement-distribution
0.9.27 - polkadot-statement-table
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - remote-externalities
0.10.0-dev - rmrk-traits
0.1.0 - rococo-runtime
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-block-builder
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-executor
0.10.0-dev - sc-executor-common
0.10.0-dev - sc-executor-wasmi
0.10.0-dev - sc-executor-wasmtime
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-offchain
4.0.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sc-state-db
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-transaction-pool
4.0.0-dev - scale-info
2.1.2 - slot-range-helper
0.9.27 - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-arithmetic
5.0.0 - sp-authority-discovery
4.0.0-dev - sp-authorship
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-consensus-vrf
0.10.0-dev - sp-core
6.0.0 - sp-externalities
0.12.0 - sp-finality-grandpa
4.0.0-dev - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-keystore
0.12.0 - sp-mmr-primitives
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-runtime
6.0.0 - sp-runtime-interface
6.0.0 - sp-sandbox
0.10.0-dev - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-state-machine
0.12.0 - sp-storage
6.0.0 - sp-timestamp
4.0.0-dev - sp-tracing
5.0.0 - sp-transaction-storage-proof
4.0.0-dev - sp-trie
6.0.0 - sp-version
5.0.0 - sp-version-proc-macro
4.0.0-dev - sp-wasm-interface
6.0.0 - substrate-frame-rpc-system
4.0.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev - substrate-test-client
2.0.1 - tests
0.1.1 - try-runtime-cli
0.10.0-dev - uc-rpc
0.1.3 - unique-node
0.9.27 - unique-runtime
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3 - westend-runtime
0.9.27 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- beefy-gadget
parity-scale-codec-derive
2.3.1crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1557010476e0595c9b568d16dcfb81b93cdeb157612726f5170d31aa707bed27used byparity-scale-codec-derive
3.1.3crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9299338969a3d2f491d65f140b00ddec470858402f888af98e8642fb5e8965cdused byparity-send-wrapper
0.1.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumaa9777aa91b8ad9dd5aaa04a9b6bcb02c7f1deb952fca5a66034d5e63afc5c6fused byparity-util-mem
0.11.0crates.ioβ 10β 17sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc32561d248d352148124f036cac253a644685a21dc9fea383eb4907d7bd35a8fdepends onused by- fp-self-contained
1.0.0-dev - kvdb
0.11.0 - kvdb-memorydb
0.11.0 - kvdb-rocksdb
0.15.2 - memory-db
0.29.0 - polkadot-core-primitives
0.9.27 - polkadot-node-core-runtime-api
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - sc-informant
0.10.0-dev - sc-service
0.10.0-dev - sc-state-db
0.10.0-dev - sc-transaction-pool
4.0.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0
- fp-self-contained
parity-util-mem-derive
0.1.0crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf557c32c6d268a07c921471619c0295f5efad3a0e76d4f97a05c091a51d110b2parity-wasm
0.32.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum16ad52817c4d343339b3bc2e26861bd21478eda0b7509acf83505727000512acdepends onused byparity-wasm
0.42.2crates.ioβ 0β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbe5e13c266502aadf83426d87d81a0f5d1ef45b8027f5a471c360abfe4bfae92parking
2.0.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum427c3892f9e783d91cc128285287e70a59e206ca452770ece88a76f7a3eddd72parking_lot
0.11.2crates.ioβ 3β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7d17b78036a60663b797adeaee46f5c9dfebb86948d1255007a1d6be0271ff99parking_lot
0.12.1crates.ioβ 2β 51sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228fdepends onused by- beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - cumulus-client-collator
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-service
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-db
2.0.0-dev - finality-grandpa
0.16.0 - jsonrpsee-core
0.14.0 - kvdb-memorydb
0.11.0 - kvdb-rocksdb
0.15.2 - libp2p
0.46.1 - libp2p-core
0.34.0 - libp2p-dns
0.34.0 - libp2p-mplex
0.34.0 - libp2p-websocket
0.36.0 - libp2p-yamux
0.38.0 - parity-util-mem
0.11.0 - polkadot-network-bridge
0.9.27 - polkadot-node-jaeger
0.9.27 - polkadot-overseer
0.9.27 - prometheus
0.13.1 - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-executor
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-offchain
4.0.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sc-state-db
0.10.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sc-utils
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-database
4.0.0-dev - sp-io
6.0.0 - sp-keystore
0.12.0 - sp-state-machine
0.12.0 - tokio
1.20.1 - trust-dns-resolver
0.21.2 - unique-node
0.9.27 - yamux
0.10.2
- beefy-gadget
parking_lot_core
0.8.5crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd76e8e1493bcac0d2766c42737f34458f1c8c50c0d23bcb24ea953affb273216used byparking_lot_core
0.9.3crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum09a279cbf25cb0757810394fbc1e359949b59e348145c643a939a525692e6929used bypaste
1.0.8crates.ioβ 0β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9423e2b32f7a043629287a536f21951e8c6a82482d0acb1eeebfc90bc2225b22pbkdf2
0.4.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum216eaa586a190f0a738f2f918511eecfa90f13295abec0e457cdebcceda80cbddepends onused bypbkdf2
0.8.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd95f5254224e617595d2cc3cc73ff0a5eaf2637519e25f03388154e9378b6ffadepends onused bypeeking_take_while
0.1.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099used bypercent-encoding
2.1.0crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd4fd5641d01c8f18a23da7b6fe29298ff4b55afcccdf78973b24cf3175fee32epest
2.2.1crates.ioβ 2β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum69486e2b8c2d2aeb9762db7b4e00b0331156393555cff467f4163ff06821eef8depends onpest_derive
2.2.1crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb13570633aff33c6d22ce47dd566b10a3b9122c2fe9d8e7501895905be532b91depends onused bypest_generator
2.2.1crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb3c567e5702efdc79fb18859ea74c3eb36e14c43da7b8c1f098a4ed6514ec7a0used bypest_meta
2.2.1crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5eb32be5ee3bbdafa8c7a18b0a8a8d962b66cfa2ceee4037f49267a50ee821fedepends onused bypetgraph
0.6.2crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume6d5014253a1331579ce62aa67443b4a658c5e7dd03d4bc6d302b94474888143depends onpin-project
1.0.12crates.ioβ 1β 15sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumad29a609b6bcd67fee905812e544992d216af9d755757c05ed2d0e15a74c6eccdepends onused by- jsonrpsee-client-transport
0.14.0 - libp2p
0.46.1 - libp2p-core
0.34.0 - libp2p-pnet
0.22.0 - libp2p-relay
0.10.0 - libp2p-swarm
0.37.0 - multistream-select
0.11.0 - orchestra
0.0.1 - polkadot-node-core-pvf
0.9.27 - polkadot-node-subsystem-util
0.9.27 - rw-stream-sink
0.3.0 - sc-network
0.10.0-dev - sc-service
0.10.0-dev - sc-telemetry
4.0.0-dev - tracing-futures
0.2.5
- jsonrpsee-client-transport
pin-project-internal
1.0.12crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum069bdb1e05adc7a8990dce9cc75370895fbe4e3d58b9b73bf1aee56359344a55depends onused bypin-project-lite
0.1.12crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum257b64915a082f7811703966789728173279bdebb956b143dbcd23f6f970a777used bypin-project-lite
0.2.9crates.ioβ 0β 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116pin-utils
0.1.0crates.ioβ 0β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184pkg-config
0.3.25crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1df8c4ec4b0627e53bdf214615ad287367e482558cf84b109250b37464dc03aeplatforms
2.0.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume8d0eef3571242013a0d5dc84861c3ae4a652e56e12adf8bdc26ff5f8cb34c94polkadot-approval-distribution
0.9.27github.com/paritytech/polkadotβ 8β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-availability-bitfield-distribution
0.9.27github.com/paritytech/polkadotβ 7β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-availability-distribution
0.9.27github.com/paritytech/polkadotβ 16β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- derive_more
0.99.17 - fatality
0.0.6 - futures
0.3.23 - lru
0.7.8 - parity-scale-codec
3.1.5 - polkadot-erasure-coding
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-primitives
0.9.27 - rand
0.8.5 - sp-core
6.0.0 - sp-keystore
0.12.0 - thiserror
1.0.32 - tracing-gum
0.9.27
used by- derive_more
polkadot-availability-recovery
0.9.27github.com/paritytech/polkadotβ 14β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- fatality
0.0.6 - futures
0.3.23 - lru
0.7.8 - parity-scale-codec
3.1.5 - polkadot-erasure-coding
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-primitives
0.9.27 - rand
0.8.5 - sc-network
0.10.0-dev - thiserror
1.0.32 - tracing-gum
0.9.27
used by- fatality
polkadot-cli
0.9.27github.com/paritytech/polkadotβ 19β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- clap
3.2.17 - frame-benchmarking-cli
4.0.0-dev - futures
0.3.23 - log
0.4.17 - polkadot-client
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-performance-test
0.9.27 - polkadot-service
0.9.27 - sc-cli
0.10.0-dev - sc-service
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-tracing
4.0.0-dev - sp-core
6.0.0 - sp-keyring
6.0.0 - sp-trie
6.0.0 - substrate-build-script-utils
3.0.0 - thiserror
1.0.32 - try-runtime-cli
0.10.0-dev
- clap
polkadot-client
0.9.27github.com/paritytech/polkadotβ 33β 3sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- beefy-primitives
4.0.0-dev - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-system
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - polkadot-core-primitives
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-executor
0.10.0-dev - sc-service
0.10.0-dev - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-inherents
4.0.0-dev - sp-keyring
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-storage
6.0.0 - sp-timestamp
4.0.0-dev - sp-transaction-pool
4.0.0-dev
- beefy-primitives
polkadot-collator-protocol
0.9.27github.com/paritytech/polkadotβ 14β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-core-primitives
0.9.27github.com/paritytech/polkadotβ 6β 6sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onpolkadot-dispute-distribution
0.9.27github.com/paritytech/polkadotβ 16β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- derive_more
0.99.17 - fatality
0.0.6 - futures
0.3.23 - lru
0.7.8 - parity-scale-codec
3.1.5 - polkadot-erasure-coding
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-primitives
0.9.27 - sc-network
0.10.0-dev - sp-application-crypto
6.0.0 - sp-keystore
0.12.0 - thiserror
1.0.32 - tracing-gum
0.9.27
used by- derive_more
polkadot-erasure-coding
0.9.27github.com/paritytech/polkadotβ 7β 7sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onpolkadot-gossip-support
0.9.27github.com/paritytech/polkadotβ 13β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-network-bridge
0.9.27github.com/paritytech/polkadotβ 16β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- always-assert
0.1.2 - async-trait
0.1.57 - bytes
1.2.1 - fatality
0.0.6 - futures
0.3.23 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - polkadot-node-network-protocol
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-primitives
0.9.27 - sc-network
0.10.0-dev - sp-consensus
0.10.0-dev - thiserror
1.0.32 - tracing-gum
0.9.27
used by- always-assert
polkadot-node-collation-generation
0.9.27github.com/paritytech/polkadotβ 11β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-approval-voting
0.9.27github.com/paritytech/polkadotβ 22β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- bitvec
1.0.1 - derive_more
0.99.17 - futures
0.3.23 - futures-timer
3.0.2 - kvdb
0.11.0 - lru
0.7.8 - merlin
2.0.1 - parity-scale-codec
3.1.5 - polkadot-node-jaeger
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-primitives
0.9.27 - sc-keystore
4.0.0-dev - schnorrkel
0.9.1 - sp-application-crypto
6.0.0 - sp-consensus
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-runtime
6.0.0 - thiserror
1.0.32 - tracing-gum
0.9.27
used by- bitvec
polkadot-node-core-av-store
0.9.27github.com/paritytech/polkadotβ 13β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-backing
0.9.27github.com/paritytech/polkadotβ 12β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-bitfield-signing
0.9.27github.com/paritytech/polkadotβ 8β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-candidate-validation
0.9.27github.com/paritytech/polkadotβ 11β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-chain-api
0.9.27github.com/paritytech/polkadotβ 8β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-chain-selection
0.9.27github.com/paritytech/polkadotβ 10β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-dispute-coordinator
0.9.27github.com/paritytech/polkadotβ 12β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-parachains-inherent
0.9.27github.com/paritytech/polkadotβ 10β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onpolkadot-node-core-provisioner
0.9.27github.com/paritytech/polkadotβ 11β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-pvf
0.9.27github.com/paritytech/polkadotβ 25β 3sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- always-assert
0.1.2 - assert_matches
1.5.0 - async-process
1.4.0 - async-std
1.12.0 - futures
0.3.23 - futures-timer
3.0.2 - parity-scale-codec
3.1.5 - pin-project
1.0.12 - polkadot-core-primitives
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-parachain
0.9.27 - rand
0.8.5 - rayon
1.5.3 - sc-executor
0.10.0-dev - sc-executor-common
0.10.0-dev - sc-executor-wasmtime
0.10.0-dev - slotmap
1.0.6 - sp-core
6.0.0 - sp-externalities
0.12.0 - sp-io
6.0.0 - sp-maybe-compressed-blob
4.1.0-dev - sp-tracing
5.0.0 - sp-wasm-interface
6.0.0 - tempfile
3.3.0 - tracing-gum
0.9.27
- always-assert
polkadot-node-core-pvf-checker
0.9.27github.com/paritytech/polkadotβ 9β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-core-runtime-api
0.9.27github.com/paritytech/polkadotβ 9β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-node-jaeger
0.9.27github.com/paritytech/polkadotβ 11β 6sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onpolkadot-node-metrics
0.9.27github.com/paritytech/polkadotβ 12β 3sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onpolkadot-node-network-protocol
0.9.27github.com/paritytech/polkadotβ 14β 13sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused by- polkadot-approval-distribution
0.9.27 - polkadot-availability-bitfield-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27
- polkadot-approval-distribution
polkadot-node-primitives
0.9.27github.com/paritytech/polkadotβ 15β 27sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- bounded-vec
0.6.0 - futures
0.3.23 - parity-scale-codec
3.1.5 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - schnorrkel
0.9.1 - serde
1.0.143 - sp-application-crypto
6.0.0 - sp-consensus-babe
0.10.0-dev - sp-consensus-vrf
0.10.0-dev - sp-core
6.0.0 - sp-keystore
0.12.0 - sp-maybe-compressed-blob
4.1.0-dev - thiserror
1.0.32 - zstd
0.11.2+zstd.1.5.2
used by- cumulus-client-collator
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - polkadot-approval-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-erasure-coding
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-jaeger
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-performance-test
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27 - polkadot-test-service
0.9.27
- bounded-vec
polkadot-node-subsystem
0.9.27github.com/paritytech/polkadotβ 3β 27sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feaused by- cumulus-client-collator
0.1.0 - cumulus-client-pov-recovery
0.1.0 - polkadot-approval-distribution
0.9.27 - polkadot-availability-bitfield-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-bitfield-signing
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-chain-api
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-core-runtime-api
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27 - polkadot-test-service
0.9.27
- cumulus-client-collator
polkadot-node-subsystem-types
0.9.27github.com/paritytech/polkadotβ 16β 4sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- async-trait
0.1.57 - derive_more
0.99.17 - futures
0.3.23 - orchestra
0.0.1 - polkadot-node-jaeger
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-primitives
0.9.27 - polkadot-statement-table
0.9.27 - sc-network
0.10.0-dev - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-consensus-babe
0.10.0-dev - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32
- async-trait
polkadot-node-subsystem-util
0.9.27github.com/paritytech/polkadotβ 26β 23sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- async-trait
0.1.57 - derive_more
0.99.17 - fatality
0.0.6 - futures
0.3.23 - itertools
0.10.3 - kvdb
0.11.0 - lru
0.7.8 - parity-db
0.3.16 - parity-scale-codec
3.1.5 - parity-util-mem
0.11.0 - parking_lot
0.11.2 - pin-project
1.0.12 - polkadot-node-jaeger
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-overseer
0.9.27 - polkadot-primitives
0.9.27 - prioritized-metered-channel
0.2.0 - rand
0.8.5 - sp-application-crypto
6.0.0 - sp-core
6.0.0 - sp-keystore
0.12.0 - thiserror
1.0.32 - tracing-gum
0.9.27
used by- polkadot-approval-distribution
0.9.27 - polkadot-availability-bitfield-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-bitfield-signing
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-chain-api
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-core-runtime-api
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27
- async-trait
polkadot-overseer
0.9.27github.com/paritytech/polkadotβ 16β 12sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- async-trait
0.1.57 - futures
0.3.23 - futures-timer
3.0.2 - lru
0.7.8 - orchestra
0.0.1 - parity-util-mem
0.11.0 - parking_lot
0.12.1 - polkadot-node-metrics
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-primitives
0.9.27 - sc-client-api
4.0.0-dev - sp-api
4.0.0-dev - sp-core
6.0.0 - tracing-gum
0.9.27
used by- cumulus-client-collator
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - cumulus-relay-chain-interface
0.1.0 - polkadot-network-bridge
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-service
0.9.27 - polkadot-test-service
0.9.27
- async-trait
polkadot-parachain
0.9.27github.com/paritytech/polkadotβ 10β 18sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused by- cumulus-client-network
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-utility
0.1.0 - opal-runtime
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-primitives
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - unique-node
0.9.27 - unique-runtime
0.9.27 - westend-runtime
0.9.27 - xcm-builder
0.9.27
- cumulus-client-network
polkadot-performance-test
0.9.27github.com/paritytech/polkadotβ 8β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-primitives
0.9.27github.com/paritytech/polkadotβ 23β 58sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- bitvec
1.0.1 - frame-system
4.0.0-dev - hex-literal
0.3.4 - parity-scale-codec
3.1.5 - parity-util-mem
0.11.0 - polkadot-core-primitives
0.9.27 - polkadot-parachain
0.9.27 - scale-info
2.1.2 - serde
1.0.143 - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-arithmetic
5.0.0 - sp-authority-discovery
4.0.0-dev - sp-consensus-slots
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-staking
4.0.0-dev - sp-std
4.0.0 - sp-trie
6.0.0 - sp-version
5.0.0
used by- cumulus-client-collator
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-utility
0.1.0 - cumulus-test-relay-sproof-builder
0.1.0 - kusama-runtime
0.9.27 - kusama-runtime-constants
0.9.27 - polkadot-approval-distribution
0.9.27 - polkadot-availability-bitfield-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-client
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-erasure-coding
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-bitfield-signing
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-chain-api
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-core-runtime-api
0.9.27 - polkadot-node-jaeger
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-rpc
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-constants
0.9.27 - polkadot-runtime-metrics
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27 - polkadot-statement-table
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - rococo-runtime
0.9.27 - rococo-runtime-constants
0.9.27 - test-runtime-constants
0.9.27 - tracing-gum
0.9.27 - unique-node
0.9.27 - westend-runtime
0.9.27 - westend-runtime-constants
0.9.27
- bitvec
polkadot-rpc
0.9.27github.com/paritytech/polkadotβ 25β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - jsonrpsee
0.14.0 - pallet-mmr-rpc
3.0.0 - pallet-transaction-payment-rpc
4.0.0-dev - polkadot-primitives
0.9.27 - sc-chain-spec
4.0.0-dev - sc-client-api
4.0.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-rpc
4.0.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-transaction-pool-api
4.0.0-dev - sp-api
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-keystore
0.12.0 - sp-runtime
6.0.0 - substrate-frame-rpc-system
4.0.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev
- beefy-gadget
polkadot-runtime
0.9.27github.com/paritytech/polkadotβ 78β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- beefy-primitives
4.0.0-dev - bitvec
1.0.1 - frame-benchmarking
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - frame-try-runtime
0.10.0-dev - hex-literal
0.3.4 - log
0.4.17 - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-election-provider-support-benchmarking
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-membership
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-staking-reward-curve
4.0.0-dev - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - parity-scale-codec
3.1.5 - polkadot-primitives
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-constants
0.9.27 - polkadot-runtime-parachains
0.9.27 - rustc-hex
2.1.0 - scale-info
2.1.2 - serde
1.0.143 - serde_derive
1.0.143 - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-consensus-babe
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0 - sp-transaction-pool
4.0.0-dev - sp-version
5.0.0 - static_assertions
1.1.0 - substrate-wasm-builder
5.0.0-dev - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- beefy-primitives
polkadot-runtime-common
0.9.27github.com/paritytech/polkadotβ 40β 12sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- beefy-primitives
4.0.0-dev - bitvec
1.0.1 - frame-benchmarking
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - impl-trait-for-tuples
0.2.2 - libsecp256k1
0.7.1 - log
0.4.17 - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-session
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-timestamp
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-vesting
4.0.0-dev - parity-scale-codec
3.1.5 - polkadot-primitives
0.9.27 - polkadot-runtime-parachains
0.9.27 - rustc-hex
2.1.0 - scale-info
2.1.2 - serde
1.0.143 - serde_derive
1.0.143 - slot-range-helper
0.9.27 - sp-api
4.0.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-npos-elections
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0 - static_assertions
1.1.0 - xcm
0.9.27
used by- kusama-runtime
0.9.27 - kusama-runtime-constants
0.9.27 - polkadot-client
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-constants
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - rococo-runtime
0.9.27 - rococo-runtime-constants
0.9.27 - test-runtime-constants
0.9.27 - westend-runtime
0.9.27 - westend-runtime-constants
0.9.27
- beefy-primitives
polkadot-runtime-constants
0.9.27github.com/paritytech/polkadotβ 5β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onpolkadot-runtime-metrics
0.9.27github.com/paritytech/polkadotβ 5β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feapolkadot-runtime-parachains
0.9.27github.com/paritytech/polkadotβ 36β 8sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- bitflags
1.3.2 - bitvec
1.0.1 - derive_more
0.99.17 - frame-benchmarking
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - log
0.4.17 - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-session
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-timestamp
4.0.0-dev - pallet-vesting
4.0.0-dev - parity-scale-codec
3.1.5 - polkadot-primitives
0.9.27 - polkadot-runtime-metrics
0.9.27 - rand
0.8.5 - rand_chacha
0.3.1 - rustc-hex
2.1.0 - scale-info
2.1.2 - serde
1.0.143 - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0 - static_assertions
1.1.0 - xcm
0.9.27 - xcm-executor
0.9.27
- bitflags
polkadot-service
0.9.27github.com/paritytech/polkadotβ 96β 6sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- async-trait
0.1.57 - beefy-gadget
4.0.0-dev - beefy-primitives
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - futures
0.3.23 - hex-literal
0.3.4 - kusama-runtime
0.9.27 - kvdb
0.11.0 - kvdb-rocksdb
0.15.2 - lru
0.7.8 - pallet-babe
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - parity-db
0.3.16 - polkadot-approval-distribution
0.9.27 - polkadot-availability-bitfield-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-client
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-bitfield-signing
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-chain-api
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-core-runtime-api
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-rpc
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-constants
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-statement-distribution
0.9.27 - rococo-runtime
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-block-builder
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-consensus-uncles
0.10.0-dev - sc-executor
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-offchain
4.0.0-dev - sc-service
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - sc-transaction-pool
4.0.0-dev - serde
1.0.143 - serde_json
1.0.83 - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-keystore
0.12.0 - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-state-machine
0.12.0 - sp-storage
6.0.0 - sp-timestamp
4.0.0-dev - sp-transaction-pool
4.0.0-dev - sp-trie
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32 - tracing-gum
0.9.27 - westend-runtime
0.9.27
- async-trait
polkadot-statement-distribution
0.9.27github.com/paritytech/polkadotβ 14β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bypolkadot-statement-table
0.9.27github.com/paritytech/polkadotβ 3β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feapolkadot-test-runtime
0.9.27github.com/paritytech/polkadotβ 54β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- beefy-primitives
4.0.0-dev - bitvec
1.0.1 - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - log
0.4.17 - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-offences
4.0.0-dev - pallet-session
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-staking-reward-curve
4.0.0-dev - pallet-sudo
4.0.0-dev - pallet-timestamp
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - parity-scale-codec
3.1.5 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - rustc-hex
2.1.0 - scale-info
2.1.2 - serde
1.0.143 - serde_derive
1.0.143 - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-consensus-babe
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0 - sp-transaction-pool
4.0.0-dev - sp-version
5.0.0 - substrate-wasm-builder
5.0.0-dev - test-runtime-constants
0.9.27 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
used by- beefy-primitives
polkadot-test-service
0.9.27github.com/paritytech/polkadotβ 46β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- frame-benchmarking
4.0.0-dev - frame-system
4.0.0-dev - futures
0.3.23 - hex
0.4.3 - pallet-balances
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem
0.9.27 - polkadot-overseer
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-rpc
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - rand
0.8.5 - sc-authority-discovery
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-executor
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-network
0.10.0-dev - sc-service
0.10.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sp-arithmetic
5.0.0 - sp-authority-discovery
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-inherents
4.0.0-dev - sp-keyring
6.0.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - substrate-test-client
2.0.1 - tempfile
3.3.0 - test-runtime-constants
0.9.27 - tokio
1.20.1 - tracing-gum
0.9.27
used by- frame-benchmarking
polling
2.2.0crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum685404d509889fade3e86fe3a5803bca2ec09b0c0778d5ada6ec8bf7a8de5259used bypoly1305
0.7.2crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum048aeb476be11a4b6ca432ca569e375810de9294ae78f4774e78ea98a9246edeused bypolyval
0.5.3crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8419d2b623c7c0896ff2d5d96e2cb4ede590fed28fcc34934f4c33c036e620a1used byppv-lite86
0.2.16crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumeb9f9e6e233e5c4a35559a617bf40a4ec447db2e84c20b55a6f83167b7e57872primitive-types
0.11.1crates.ioβ 6β 10sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume28720988bff275df1f51b171e1b2a18c30d194c4d2b61defdacecd625a5d94aprioritized-metered-channel
0.2.0github.com/paritytech/polkadotβ 8β 3sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onproc-macro-crate
1.2.1crates.ioβ 3β 17sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumeda0fc3b0fb7c975631757e14d9049da17374063edb6ebbcbc54d880d4fe94e9depends onused by- cumulus-pallet-parachain-system-proc-macro
0.1.0 - fatality-proc-macro
0.0.6 - frame-election-provider-solution-type
4.0.0-dev - frame-support-procedural-tools
4.0.0-dev - jsonrpsee-proc-macros
0.14.0 - multihash-derive
0.8.0 - orchestra-proc-macro
0.0.1 - pallet-staking-reward-curve
4.0.0-dev - parity-scale-codec-derive
2.3.1 - parity-scale-codec-derive
3.1.3 - sc-chain-spec-derive
4.0.0-dev - sc-tracing-proc-macro
4.0.0-dev - scale-info-derive
2.1.2 - sp-api-proc-macro
4.0.0-dev - sp-runtime-interface-proc-macro
5.0.0 - substrate-test-utils-derive
0.10.0-dev - tracing-gum-proc-macro
0.9.27
- cumulus-pallet-parachain-system-proc-macro
proc-macro-error
1.0.4crates.ioβ 5β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumda25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38cproc-macro-error-attr
1.0.4crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869used byproc-macro2
1.0.43crates.ioβ 1β 62sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0a2ca2c61bc9f3d74d2886294ab7b9853abd9c1ad903a3ac7815c58989bb7babdepends onused by- async-trait
0.1.57 - auto_impl
0.5.0 - bindgen
0.59.2 - clap_derive
3.2.17 - cumulus-pallet-parachain-system-proc-macro
0.1.0 - darling_core
0.13.4 - derivative
2.2.0 - derive_more
0.99.17 - dyn-clonable-impl
0.9.0 - enum-as-inner
0.4.0 - enumflags2_derive
0.7.4 - enumn
0.1.5 - evm-coder-macros
0.1.0 - expander
0.0.4 - expander
0.0.6 - fatality-proc-macro
0.0.6 - frame-election-provider-solution-type
4.0.0-dev - frame-support-procedural
4.0.0-dev - frame-support-procedural-tools
4.0.0-dev - frame-support-procedural-tools-derive
3.0.0 - futures-macro
0.3.23 - impl-trait-for-tuples
0.2.2 - jsonrpsee-proc-macros
0.14.0 - multihash-derive
0.8.0 - nalgebra-macros
0.1.0 - orchestra-proc-macro
0.0.1 - pallet-staking-reward-curve
4.0.0-dev - parity-scale-codec-derive
2.3.1 - parity-scale-codec-derive
3.1.3 - parity-util-mem-derive
0.1.0 - pest_generator
2.2.1 - pin-project-internal
1.0.12 - proc-macro-error
1.0.4 - proc-macro-error-attr
1.0.4 - prometheus-client-derive-text-encode
0.2.0 - prost-derive
0.10.1 - quote
1.0.21 - ref-cast-impl
1.0.9 - rlp-derive
0.1.0 - sc-chain-spec-derive
4.0.0-dev - sc-tracing-proc-macro
4.0.0-dev - scale-info-derive
2.1.2 - serde_derive
1.0.143 - sp-api-proc-macro
4.0.0-dev - sp-core-hashing-proc-macro
5.0.0 - sp-debug-derive
4.0.0 - sp-runtime-interface-proc-macro
5.0.0 - sp-version-proc-macro
4.0.0-dev - ss58-registry
1.25.0 - static_init_macro
0.5.0 - strum_macros
0.24.3 - substrate-test-utils-derive
0.10.0-dev - syn
1.0.99 - synstructure
0.12.6 - thiserror-impl
1.0.32 - tokio-macros
1.8.0 - tracing-attributes
0.1.22 - tracing-gum-proc-macro
0.9.27 - wasm-bindgen-backend
0.2.82 - wasm-bindgen-macro-support
0.2.82 - xcm-procedural
0.9.27 - zeroize_derive
1.3.2
- async-trait
prometheus
0.13.1crates.ioβ 6β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcface98dfa6d645ea4c789839f176e4b072265d085bfcc48eaa8d137f58d3c39prometheus-client
0.16.0crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumac1abe0255c04d15f571427a2d1e00099016506cf3297b53853acd2b7eb87825prometheus-client-derive-text-encode
0.2.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume8e12d01b9d66ad9eb4529c57666b6263fc1993cb30261d83ead658fdd932652depends onused byprost
0.10.4crates.ioβ 2β 17sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum71adf41db68aa0daaefc69bb30bcd68ded9b9abaad5d1fbb6304c4fb390e083edepends onused by- libp2p-autonat
0.5.0 - libp2p-core
0.34.0 - libp2p-floodsub
0.37.0 - libp2p-gossipsub
0.39.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-noise
0.37.0 - libp2p-plaintext
0.34.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - prost-build
0.10.4 - prost-codec
0.1.0 - prost-types
0.10.1 - sc-authority-discovery
0.10.0-dev - sc-network
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev
- libp2p-autonat
prost-build
0.10.4crates.ioβ 14β 15sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8ae5a4388762d5815a9fc0dea33c56b021cdc8dde0c55e0c9ca57197254b0cabdepends onused by- libp2p-autonat
0.5.0 - libp2p-core
0.34.0 - libp2p-floodsub
0.37.0 - libp2p-gossipsub
0.39.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-noise
0.37.0 - libp2p-plaintext
0.34.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - sc-authority-discovery
0.10.0-dev - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev
- libp2p-autonat
prost-codec
0.1.0crates.ioβ 5β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum00af1e92c33b4813cc79fda3f2dbf56af5169709be0202df730e9ebc3e4cd007prost-derive
0.10.1crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7b670f45da57fb8542ebdbb6105a925fe571b67f9e7ed9f47a06a84e72b4e7ccused byprost-types
0.10.1crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2d0a014229361011dc8e69c8a1ec6c2e8d0f2af7c91e3ea3f5b2170298461e68depends onused bypsm
0.1.20crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf446d0a6efba22928558c4fb4ce0b3fd6c89b0061343e390bf01a703742b8125depends onused byquartz-runtime
0.9.27workspaceβ 83β 1depends on- cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-timestamp
0.1.0 - cumulus-primitives-utility
0.1.0 - derivative
2.2.0 - evm-coder
0.1.1 - fp-evm-mapping
0.1.0 - fp-rpc
3.0.0-dev - fp-self-contained
1.0.0-dev - frame-benchmarking
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - frame-try-runtime
0.10.0-dev - hex-literal
0.3.4 - log
0.4.17 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-inflation
0.1.1 - pallet-nonfungible
0.1.4 - pallet-randomness-collective-flip
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-structure
0.1.2 - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-xcm
0.9.27 - parachain-info
0.1.0 - parity-scale-codec
3.1.5 - polkadot-parachain
0.9.27 - rmrk-rpc
0.0.2 - scale-info
2.1.2 - serde
1.0.143 - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-arithmetic
5.0.0 - sp-block-builder
4.0.0-dev - sp-consensus-aura
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-std
4.0.0 - sp-transaction-pool
4.0.0-dev - sp-version
5.0.0 - substrate-wasm-builder
5.0.0-dev - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3 - up-sponsorship
0.1.0 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
used by- cumulus-pallet-aura-ext
quick-error
1.2.3crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0quicksink
0.1.2crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum77de3c815e5a160b1539c6592796801df2043ae35e123b46d73380cfa57af858used byquote
1.0.21crates.ioβ 1β 67sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbbe448f377a7d6961e30f5955f9b8d106c3f5e449d493ee1b125c1d43c2b5179depends onused by- async-attributes
1.1.2 - async-trait
0.1.57 - auto_impl
0.5.0 - bindgen
0.59.2 - clap_derive
3.2.17 - ctor
0.1.23 - cumulus-pallet-parachain-system-proc-macro
0.1.0 - darling_core
0.13.4 - darling_macro
0.13.4 - derivative
2.2.0 - derive_more
0.99.17 - dyn-clonable-impl
0.9.0 - enum-as-inner
0.4.0 - enumflags2_derive
0.7.4 - enumn
0.1.5 - evm-coder-macros
0.1.0 - expander
0.0.4 - expander
0.0.6 - fatality-proc-macro
0.0.6 - frame-election-provider-solution-type
4.0.0-dev - frame-support-procedural
4.0.0-dev - frame-support-procedural-tools
4.0.0-dev - frame-support-procedural-tools-derive
3.0.0 - futures-macro
0.3.23 - impl-trait-for-tuples
0.2.2 - jsonrpsee-proc-macros
0.14.0 - libp2p-swarm-derive
0.28.0 - multihash-derive
0.8.0 - nalgebra-macros
0.1.0 - orchestra-proc-macro
0.0.1 - pallet-staking-reward-curve
4.0.0-dev - parity-scale-codec-derive
2.3.1 - parity-scale-codec-derive
3.1.3 - pest_generator
2.2.1 - pin-project-internal
1.0.12 - polkadot-performance-test
0.9.27 - proc-macro-error
1.0.4 - proc-macro-error-attr
1.0.4 - prometheus-client-derive-text-encode
0.2.0 - prost-derive
0.10.1 - ref-cast-impl
1.0.9 - rlp-derive
0.1.0 - sc-chain-spec-derive
4.0.0-dev - sc-tracing-proc-macro
4.0.0-dev - scale-info-derive
2.1.2 - serde_derive
1.0.143 - sp-api-proc-macro
4.0.0-dev - sp-core-hashing-proc-macro
5.0.0 - sp-debug-derive
4.0.0 - sp-runtime-interface-proc-macro
5.0.0 - sp-version-proc-macro
4.0.0-dev - ss58-registry
1.25.0 - static_init_macro
0.5.0 - struct-versioning
0.1.0 - strum_macros
0.24.3 - substrate-test-utils-derive
0.10.0-dev - syn
1.0.99 - synstructure
0.12.6 - thiserror-impl
1.0.32 - tokio-macros
1.8.0 - tracing-attributes
0.1.22 - tracing-gum-proc-macro
0.9.27 - wasm-bindgen-backend
0.2.82 - wasm-bindgen-macro
0.2.82 - wasm-bindgen-macro-support
0.2.82 - xcm-procedural
0.9.27 - zeroize_derive
1.3.2
- async-attributes
radium
0.6.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum643f8f41a8ebc4c5dc4515c82bb8abd397b527fc20fd681b7c011c2aee5d44fbused byradium
0.7.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumdc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09used byrand
0.7.3crates.ioβ 6β 26sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03used by- cuckoofilter
0.5.0 - ed25519-dalek
1.0.1 - libp2p
0.46.1 - libp2p-floodsub
0.37.0 - libp2p-gossipsub
0.39.0 - libp2p-kad
0.38.0 - libp2p-mplex
0.34.0 - libp2p-ping
0.37.0 - libp2p-pnet
0.22.0 - libp2p-request-response
0.19.0 - libp2p-swarm
0.37.0 - pallet-election-provider-multi-phase
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - sc-authority-discovery
0.10.0-dev - sc-cli
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-network
0.10.0-dev - sc-offchain
4.0.0-dev - sc-service
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - schnorrkel
0.9.1 - sp-core
6.0.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - tiny-bip39
0.8.2
- cuckoofilter
rand
0.8.5crates.ioβ 3β 36sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404used by- backoff
0.4.0 - cumulus-client-pov-recovery
0.1.0 - fc-rpc
2.0.0-dev - fixed-hash
0.7.0 - frame-benchmarking-cli
4.0.0-dev - jsonrpsee-core
0.14.0 - libp2p-autonat
0.5.0 - libp2p-core
0.34.0 - libp2p-mdns
0.38.0 - libp2p-noise
0.37.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - libsecp256k1
0.7.1 - mick-jaeger
0.1.8 - nalgebra
0.27.1 - names
0.13.0 - parity-db
0.3.16 - polkadot-approval-distribution
0.9.27 - polkadot-availability-bitfield-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-service
0.9.27 - rand_distr
0.4.3 - sc-finality-grandpa
0.10.0-dev - soketto
0.7.1 - statrs
0.15.0 - trust-dns-proto
0.21.2 - twox-hash
1.6.3 - wasmtime-runtime
0.38.3 - yamux
0.10.2
- backoff
rand_chacha
0.2.2crates.ioβ 2β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402depends onrand_chacha
0.3.1crates.ioβ 2β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88depends onrand_core
0.5.1crates.ioβ 1β 9sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19depends onrand_core
0.6.3crates.ioβ 1β 10sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd34f1408f55294453790c48b2f1ebbb1c5b4b7563eb1f418bcfcfdbb06ebb4e7depends onrand_distr
0.4.3crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum32cb0b9bc82b0a0876c2dd994a7e7a2683d3e7390ca40e6886785ef0c7e3ee31depends onused byrand_hc
0.2.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613cdepends onused byrand_pcg
0.2.1crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429depends onused byrand_pcg
0.3.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum59cad018caf63deb318e5a4586d99a24424a364f40f1e5778c29aca23f4fc73edepends onrawpointer
0.2.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum60a357793950651c4ed0f3f52338f53b2f809f32d83a07f72909fa13e4c6c1e3used byrayon
1.5.3crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbd99e5772ead8baa5215278c9b15bf92087709e9c1b2d1f97cdb5a183c933a7drayon-core
1.9.3crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum258bcdb5ac6dad48491bb2992db6b7cf74878b0384908af124823d118c99683fused byredox_syscall
0.2.16crates.ioβ 1β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519adepends onredox_users
0.4.3crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2breed-solomon-novelpoly
1.0.0crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3bd8f48b2066e9f69ab192797d66da804d1935bf22763204ed3675740cb0f221ref-cast
1.0.9crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumed13bcd201494ab44900a96490291651d200730904221832b9547d24a87d332bdepends onused byref-cast-impl
1.0.9crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5234cd6063258a5e32903b53b1b6ac043a0541c8adc1f610f67b0326c7a578fadepends onused byregalloc2
0.2.3crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4a8d23b35d7177df3b9d31ed8a9ab4bf625c668be77a319d4f5efd4a5257701cused byregex
1.6.0crates.ioβ 3β 14sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4c4eb3267174b8c6c2f654116623910a0fef09c4753f8dd83db29c48a0df988bregex-automata
0.1.10crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132depends onused byregex-syntax
0.6.27crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma3f87b73ce11b1619a3c6332f45341e0047173771e8b8b73f87bfeefb7b56244region
2.2.0crates.ioβ 4β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum877e54ea2adcd70d80e9179344c97f93ef0dffd6b03e1f4529e6e83ab2fa9ae0remote-externalities
0.10.0-devgithub.com/paritytech/substrateβ 10β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused byremove_dir_all
0.5.3crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7depends onused byresolv-conf
0.7.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum52e44394d2086d010551b14b53b1f24e31647570cd1deb0379e2c21b329aba00depends onused byretain_mut
0.1.9crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4389f1d5789befaf6029ebd9f7dac4af7f7e3d61b69d4f30e2ac02b57e7712b0rfc6979
0.1.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum96ef608575f6392792f9ecf7890c00086591d29a83910939d430753f7c050525depends onused byring
0.16.20crates.ioβ 7β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fcrlp
0.5.1crates.ioβ 2β 8sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum999508abb0ae792aabed2460c45b89106d97fe4adac593bdaef433c2605847b5depends onrlp-derive
0.1.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume33d7b2abe0c340d8797fe2907d3f20d3b5ea5908683618bfe80df7f621f672adepends onused byrmrk-traits
0.1.0workspaceβ 3β 4rocksdb
0.18.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum620f4129485ff1a7128d184bc687470c21c7951b64779ebc9cfdad3dcd920290depends onused byrococo-runtime
0.9.27github.com/paritytech/polkadotβ 62β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- beefy-merkle-tree
4.0.0-dev - beefy-primitives
4.0.0-dev - frame-benchmarking
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - hex-literal
0.3.4 - log
0.4.17 - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-offences
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-session
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-sudo
4.0.0-dev - pallet-timestamp
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-utility
4.0.0-dev - pallet-xcm
0.9.27 - parity-scale-codec
3.1.5 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - rococo-runtime-constants
0.9.27 - scale-info
2.1.2 - serde
1.0.143 - serde_derive
1.0.143 - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-consensus-babe
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0 - sp-transaction-pool
4.0.0-dev - sp-version
5.0.0 - substrate-wasm-builder
5.0.0-dev - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
used by- beefy-merkle-tree
rococo-runtime-constants
0.9.27github.com/paritytech/polkadotβ 5β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused byrpassword
5.0.1crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumffc936cf8a7ea60c58f030fd36a612a48f440610214dc54bc36431f9ea0c3efbdepends onused byrtnetlink
0.10.1crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum322c53fd76a18698f1c27381d58091de3a043d356aa5bd0d510608b565f469a0depends onused byrustc_version
0.2.3crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum138e3e0acb6c9fb258b19b67cb8abd63c00679d2851805ea151465464fe9030adepends onused byrustc_version
0.4.0crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366depends onused byrustc-demangle
0.1.21crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7ef03e0a2b150c7a90d01faf6254c9c48a41e95fb2a8c2ac1c6f0d2b9aefc342rustc-hash
1.1.0crates.ioβ 0β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2rustc-hex
2.1.0crates.ioβ 0β 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6rustix
0.33.7crates.ioβ 6β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum938a344304321a9da4973b9ff4f9f8db9caf4597dfd9dda6a60b523340a0fff0rustix
0.35.7crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd51cc38aa10f6bbb377ed28197aa052aa4e2b762c22be9d3153d01822587e787rustls
0.20.6crates.ioβ 4β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5aab8ee6c7097ed6057f43c187a62418d0c05a4bd5f18b3571db50ee0f9ce033depends onrustls-native-certs
0.6.2crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0167bac7a9f490495f3c33013e7722b53cb087ecbe082fb0c6387c96f634ea50rustls-pemfile
1.0.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0864aeff53f8c05aa08d86e5ef839d3dfcf07aeba2db32f12db0ef716e87bd55depends onused byrustversion
1.0.9crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum97477e48b4cf8603ad5f7aaf897467cf42ab4218a38ef76fb14c2d6773a6d6a8rw-stream-sink
0.3.0crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum26338f5e09bb721b85b135ea05af7767c90b52f6de4f087d4f4a3a9d64e7dc04ryu
1.0.11crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4501abdff3ae82a1c1b477a17252eb69cee9e66eb915c1abaa4f44d873df9f09used bysafe-mix
1.0.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6d3d055a2582e6b00ed7a31c1524040aa391092bf636328350813f3a0605215cdepends onsalsa20
0.9.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0c0fbb5f676da676c260ba276a8f43a8dc67cf02d1438423aeb1c677a7212686depends onused bysame-file
1.0.6crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502depends onused bysc-allocator
4.1.0-devgithub.com/paritytech/substrateβ 4β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sc-authority-discovery
0.10.0-devgithub.com/paritytech/substrateβ 20β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- async-trait
0.1.57 - futures
0.3.23 - futures-timer
3.0.2 - ip_network
0.4.1 - libp2p
0.46.1 - log
0.4.17 - parity-scale-codec
3.1.5 - prost
0.10.4 - prost-build
0.10.4 - rand
0.7.3 - sc-client-api
4.0.0-dev - sc-network
0.10.0-dev - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-keystore
0.12.0 - sp-runtime
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32
- async-trait
sc-basic-authorship
0.10.0-devgithub.com/paritytech/substrateβ 16β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- futures
0.3.23 - futures-timer
3.0.2 - log
0.4.17 - parity-scale-codec
3.1.5 - sc-block-builder
0.10.0-dev - sc-client-api
4.0.0-dev - sc-proposer-metrics
0.10.0-dev - sc-telemetry
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-runtime
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev
- futures
sc-block-builder
0.10.0-devgithub.com/paritytech/substrateβ 9β 8sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-chain-spec
4.0.0-devgithub.com/paritytech/substrateβ 10β 12sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-chain-spec-derive
4.0.0-devgithub.com/paritytech/substrateβ 4β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used bysc-cli
0.10.0-devgithub.com/paritytech/substrateβ 32β 8sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- chrono
0.4.22 - clap
3.2.17 - fdlimit
0.2.1 - futures
0.3.23 - hex
0.4.3 - libp2p
0.46.1 - log
0.4.17 - names
0.13.0 - parity-scale-codec
3.1.5 - rand
0.7.3 - regex
1.6.0 - rpassword
5.0.1 - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-service
0.10.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sc-utils
4.0.0-dev - serde
1.0.143 - serde_json
1.0.83 - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-keyring
6.0.0 - sp-keystore
0.12.0 - sp-panic-handler
4.0.0 - sp-runtime
6.0.0 - sp-version
5.0.0 - thiserror
1.0.32 - tiny-bip39
0.8.2 - tokio
1.20.1
- chrono
sc-client-api
4.0.0-devgithub.com/paritytech/substrateβ 21β 51sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- fnv
1.0.7 - futures
0.3.23 - hash-db
0.15.2 - log
0.4.17 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - sc-executor
0.10.0-dev - sc-transaction-pool-api
4.0.0-dev - sc-utils
4.0.0-dev - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-database
4.0.0-dev - sp-externalities
0.12.0 - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - sp-storage
6.0.0 - sp-trie
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev
used by- beefy-gadget
4.0.0-dev - cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-consensus
2.0.0-dev - fc-mapping-sync
2.0.0-dev - fc-rpc
2.0.0-dev - frame-benchmarking-cli
4.0.0-dev - polkadot-client
0.9.27 - polkadot-node-core-chain-api
0.9.27 - polkadot-overseer
0.9.27 - polkadot-rpc
0.9.27 - polkadot-service
0.9.27 - polkadot-test-service
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-block-builder
0.10.0-dev - sc-cli
0.10.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-consensus-uncles
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-informant
0.10.0-dev - sc-network
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-offchain
4.0.0-dev - sc-rpc
4.0.0-dev - sc-service
0.10.0-dev - sc-state-db
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - substrate-frame-rpc-system
4.0.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev - substrate-test-client
2.0.1 - unique-node
0.9.27 - unique-rpc
0.1.1
- fnv
sc-client-db
0.10.0-devgithub.com/paritytech/substrateβ 18β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- hash-db
0.15.2 - kvdb
0.11.0 - kvdb-memorydb
0.11.0 - kvdb-rocksdb
0.15.2 - linked-hash-map
0.5.6 - log
0.4.17 - parity-db
0.3.16 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - sc-client-api
4.0.0-dev - sc-state-db
0.10.0-dev - sp-arithmetic
5.0.0 - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-database
4.0.0-dev - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - sp-trie
6.0.0
- hash-db
sc-consensus
0.10.0-devgithub.com/paritytech/substrateβ 17β 20sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - fc-consensus
2.0.0-dev - polkadot-client
0.9.27 - polkadot-service
0.9.27 - polkadot-test-service
0.9.27 - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-service
0.10.0-dev - substrate-test-client
2.0.1 - unique-node
0.9.27
- cumulus-client-consensus-aura
sc-consensus-aura
0.10.0-devgithub.com/paritytech/substrateβ 22β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- async-trait
0.1.57 - futures
0.3.23 - log
0.4.17 - parity-scale-codec
3.1.5 - sc-block-builder
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-telemetry
4.0.0-dev - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-keystore
0.12.0 - sp-runtime
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32
- async-trait
sc-consensus-babe
0.10.0-devgithub.com/paritytech/substrateβ 36β 9sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- async-trait
0.1.57 - fork-tree
3.0.0 - futures
0.3.23 - log
0.4.17 - merlin
2.0.1 - num-bigint
0.2.6 - num-rational
0.2.4 - num-traits
0.2.15 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - rand
0.7.3 - retain_mut
0.1.9 - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-keystore
4.0.0-dev - sc-telemetry
4.0.0-dev - schnorrkel
0.9.1 - serde
1.0.143 - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-consensus-vrf
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-version
5.0.0 - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32
- async-trait
sc-consensus-babe-rpc
0.10.0-devgithub.com/paritytech/substrateβ 15β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bysc-consensus-epochs
0.10.0-devgithub.com/paritytech/substrateβ 6β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-consensus-manual-seal
0.10.0-devgithub.com/paritytech/substrateβ 27β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- assert_matches
1.5.0 - async-trait
0.1.57 - futures
0.3.23 - jsonrpsee
0.14.0 - log
0.4.17 - parity-scale-codec
3.1.5 - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - serde
1.0.143 - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-timestamp
4.0.0-dev - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32
used by- assert_matches
sc-consensus-slots
0.10.0-devgithub.com/paritytech/substrateβ 18β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- async-trait
0.1.57 - futures
0.3.23 - futures-timer
3.0.2 - log
0.4.17 - parity-scale-codec
3.1.5 - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-telemetry
4.0.0-dev - sp-arithmetic
5.0.0 - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - sp-timestamp
4.0.0-dev - thiserror
1.0.32
- async-trait
sc-consensus-uncles
0.10.0-devgithub.com/paritytech/substrateβ 4β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used bysc-executor
0.10.0-devgithub.com/paritytech/substrateβ 20β 10sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- lazy_static
1.4.0 - lru
0.7.8 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - sc-executor-common
0.10.0-dev - sc-executor-wasmi
0.10.0-dev - sc-executor-wasmtime
0.10.0-dev - sp-api
4.0.0-dev - sp-core
6.0.0 - sp-core-hashing-proc-macro
5.0.0 - sp-externalities
0.12.0 - sp-io
6.0.0 - sp-panic-handler
4.0.0 - sp-runtime-interface
6.0.0 - sp-tasks
4.0.0-dev - sp-trie
6.0.0 - sp-version
5.0.0 - sp-wasm-interface
6.0.0 - tracing
0.1.36 - wasmi
0.9.1
- lazy_static
sc-executor-common
0.10.0-devgithub.com/paritytech/substrateβ 10β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-executor-wasmi
0.10.0-devgithub.com/paritytech/substrateβ 8β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bysc-executor-wasmtime
0.10.0-devgithub.com/paritytech/substrateβ 13β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-finality-grandpa
0.10.0-devgithub.com/paritytech/substrateβ 34β 8sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- ahash
0.7.6 - async-trait
0.1.57 - dyn-clone
1.0.9 - finality-grandpa
0.16.0 - fork-tree
3.0.0 - futures
0.3.23 - futures-timer
3.0.2 - hex
0.4.3 - log
0.4.17 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - rand
0.8.5 - sc-block-builder
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-telemetry
4.0.0-dev - sc-utils
4.0.0-dev - serde_json
1.0.83 - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-arithmetic
5.0.0 - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-keystore
0.12.0 - sp-runtime
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32
- ahash
sc-finality-grandpa-rpc
0.10.0-devgithub.com/paritytech/substrateβ 14β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-informant
0.10.0-devgithub.com/paritytech/substrateβ 10β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bysc-keystore
4.0.0-devgithub.com/paritytech/substrateβ 8β 10sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-network
0.10.0-devgithub.com/paritytech/substrateβ 42β 22sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- async-trait
0.1.57 - asynchronous-codec
0.6.0 - bitflags
1.3.2 - bytes
1.2.1 - cid
0.8.6 - either
1.7.0 - fnv
1.0.7 - fork-tree
3.0.0 - futures
0.3.23 - futures-timer
3.0.2 - hex
0.4.3 - ip_network
0.4.1 - libp2p
0.46.1 - linked-hash-map
0.5.6 - linked_hash_set
0.1.4 - log
0.4.17 - lru
0.7.8 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - pin-project
1.0.12 - prost
0.10.4 - prost-build
0.10.4 - rand
0.7.3 - sc-block-builder
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-network-common
0.10.0-dev - sc-peerset
4.0.0-dev - sc-utils
4.0.0-dev - serde
1.0.143 - serde_json
1.0.83 - smallvec
1.9.0 - sp-arithmetic
5.0.0 - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0 - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32 - unsigned-varint
0.7.1 - void
1.0.2 - zeroize
1.5.7
used by- beefy-gadget
4.0.0-dev - cumulus-relay-chain-inprocess-interface
0.1.0 - fc-rpc
2.0.0-dev - polkadot-availability-recovery
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-jaeger
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-service
0.9.27 - polkadot-test-service
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-informant
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-offchain
4.0.0-dev - sc-service
0.10.0-dev - unique-node
0.9.27 - unique-rpc
0.1.1
- async-trait
sc-network-common
0.10.0-devgithub.com/paritytech/substrateβ 11β 5sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-network-gossip
0.10.0-devgithub.com/paritytech/substrateβ 10β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-network-light
0.10.0-devgithub.com/paritytech/substrateβ 13β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bysc-network-sync
0.10.0-devgithub.com/paritytech/substrateβ 20β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- fork-tree
3.0.0 - futures
0.3.23 - libp2p
0.46.1 - log
0.4.17 - lru
0.7.8 - parity-scale-codec
3.1.5 - prost
0.10.4 - prost-build
0.10.4 - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-network-common
0.10.0-dev - sc-peerset
4.0.0-dev - smallvec
1.9.0 - sp-arithmetic
5.0.0 - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-runtime
6.0.0 - thiserror
1.0.32
used by- fork-tree
sc-offchain
4.0.0-devgithub.com/paritytech/substrateβ 21β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- bytes
1.2.1 - fnv
1.0.7 - futures
0.3.23 - futures-timer
3.0.2 - hex
0.4.3 - hyper
0.14.20 - hyper-rustls
0.23.0 - num_cpus
1.13.1 - once_cell
1.13.0 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - rand
0.7.3 - sc-client-api
4.0.0-dev - sc-network
0.10.0-dev - sc-utils
4.0.0-dev - sp-api
4.0.0-dev - sp-core
6.0.0 - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - threadpool
1.8.1 - tracing
0.1.36
- bytes
sc-peerset
4.0.0-devgithub.com/paritytech/substrateβ 6β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sc-proposer-metrics
0.10.0-devgithub.com/paritytech/substrateβ 2β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sc-rpc
4.0.0-devgithub.com/paritytech/substrateβ 23β 7sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- futures
0.3.23 - hash-db
0.15.2 - jsonrpsee
0.14.0 - log
0.4.17 - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - sc-block-builder
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-client-api
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - sc-utils
4.0.0-dev - serde_json
1.0.83 - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-keystore
0.12.0 - sp-offchain
4.0.0-dev - sp-rpc
6.0.0 - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-version
5.0.0
- futures
sc-rpc-api
0.10.0-devgithub.com/paritytech/substrateβ 16β 7sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-rpc-server
4.0.0-devgithub.com/paritytech/substrateβ 6β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-service
0.10.0-devgithub.com/paritytech/substrateβ 60β 14sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- async-trait
0.1.57 - directories
4.0.1 - exit-future
0.2.0 - futures
0.3.23 - futures-timer
3.0.2 - hash-db
0.15.2 - jsonrpsee
0.14.0 - log
0.4.17 - parity-scale-codec
3.1.5 - parity-util-mem
0.11.0 - parking_lot
0.12.1 - pin-project
1.0.12 - rand
0.7.3 - sc-block-builder
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-executor
0.10.0-dev - sc-informant
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-offchain
4.0.0-dev - sc-rpc
4.0.0-dev - sc-rpc-server
4.0.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - sc-utils
4.0.0-dev - serde
1.0.143 - serde_json
1.0.83 - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-externalities
0.12.0 - sp-inherents
4.0.0-dev - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-state-machine
0.12.0 - sp-storage
6.0.0 - sp-tracing
5.0.0 - sp-transaction-pool
4.0.0-dev - sp-transaction-storage-proof
4.0.0-dev - sp-trie
6.0.0 - sp-version
5.0.0 - substrate-prometheus-endpoint
0.10.0-dev - tempfile
3.3.0 - thiserror
1.0.32 - tokio
1.20.1 - tracing
0.1.36 - tracing-futures
0.2.5
used by- cumulus-client-cli
0.1.0 - cumulus-client-service
0.1.0 - fc-rpc
2.0.0-dev - frame-benchmarking-cli
4.0.0-dev - polkadot-cli
0.9.27 - polkadot-client
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-service
0.9.27 - polkadot-test-service
0.9.27 - sc-cli
0.10.0-dev - substrate-test-client
2.0.1 - try-runtime-cli
0.10.0-dev - unique-node
0.9.27 - unique-rpc
0.1.1
- async-trait
sc-state-db
0.10.0-devgithub.com/paritytech/substrateβ 7β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bysc-sync-state-rpc
0.10.0-devgithub.com/paritytech/substrateβ 12β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-sysinfo
6.0.0-devgithub.com/paritytech/substrateβ 12β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsc-telemetry
4.0.0-devgithub.com/paritytech/substrateβ 11β 14sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-client-consensus-aura
0.1.0 - cumulus-client-service
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - polkadot-service
0.9.27 - sc-basic-authorship
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-service
0.10.0-dev - sc-sysinfo
6.0.0-dev - unique-node
0.9.27
- cumulus-client-consensus-aura
sc-tracing
4.0.0-devgithub.com/paritytech/substrateβ 24β 9sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- ansi_term
0.12.1 - atty
0.2.14 - chrono
0.4.22 - lazy_static
1.4.0 - libc
0.2.131 - log
0.4.17 - once_cell
1.13.0 - parking_lot
0.12.1 - regex
1.6.0 - rustc-hash
1.1.0 - sc-client-api
4.0.0-dev - sc-rpc-server
4.0.0-dev - sc-tracing-proc-macro
4.0.0-dev - serde
1.0.143 - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-rpc
6.0.0 - sp-runtime
6.0.0 - sp-tracing
5.0.0 - thiserror
1.0.32 - tracing
0.1.36 - tracing-log
0.1.3 - tracing-subscriber
0.2.25
- ansi_term
sc-tracing-proc-macro
4.0.0-devgithub.com/paritytech/substrateβ 4β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used bysc-transaction-pool
4.0.0-devgithub.com/paritytech/substrateβ 20β 7sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- futures
0.3.23 - futures-timer
3.0.2 - linked-hash-map
0.5.6 - log
0.4.17 - parity-scale-codec
3.1.5 - parity-util-mem
0.11.0 - parking_lot
0.12.1 - retain_mut
0.1.9 - sc-client-api
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - sc-utils
4.0.0-dev - serde
1.0.143 - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-core
6.0.0 - sp-runtime
6.0.0 - sp-tracing
5.0.0 - sp-transaction-pool
4.0.0-dev - substrate-prometheus-endpoint
0.10.0-dev - thiserror
1.0.32
- futures
sc-transaction-pool-api
4.0.0-devgithub.com/paritytech/substrateβ 6β 11sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sc-utils
4.0.0-devgithub.com/paritytech/substrateβ 6β 12sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05scale-info
2.1.2crates.ioβ 6β 128sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc46be926081c9f4dd5dd9b6f1d3e3229f2360bc6502dd8836f84a93b7c75e99adepends onused by- beefy-primitives
4.0.0-dev - cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - ethbloom
0.12.1 - ethereum
0.12.0 - ethereum-types
0.13.1 - evm
0.35.0 - evm-core
0.35.0 - finality-grandpa
0.16.0 - fp-rpc
3.0.0-dev - fp-self-contained
1.0.0-dev - frame-benchmarking
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-metadata
15.0.0 - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-utilities
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-gilt
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nonfungible
0.1.4 - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-randomness-collective-flip
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-society
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-structure
0.1.2 - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - parachain-info
0.1.0 - polkadot-core-primitives
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - primitive-types
0.11.1 - quartz-runtime
0.9.27 - rmrk-traits
0.1.0 - rococo-runtime
0.9.27 - sc-rpc-api
0.10.0-dev - sp-application-crypto
6.0.0 - sp-arithmetic
5.0.0 - sp-authority-discovery
4.0.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-consensus-vrf
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-transaction-storage-proof
4.0.0-dev - sp-trie
6.0.0 - sp-version
5.0.0 - substrate-state-trie-migration-rpc
4.0.0-dev - tests
0.1.1 - unique-runtime
0.9.27 - up-data-structs
0.2.2 - westend-runtime
0.9.27 - xcm
0.9.27 - xcm-builder
0.9.27
- beefy-primitives
scale-info-derive
2.1.2crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum50e334bb10a245e28e5fd755cabcafd96cfcd167c99ae63a46924ca8d8703a3cused byschannel
0.1.20crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum88d6731146462ea25d9244b2ed5fd1d716d25c52e4d54aa4fb0f3c4e9854dbe2depends onused byschnorrkel
0.9.1crates.ioβ 10β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum021b403afe70d81eea68f6ea12f6b3c9588e5d536a94c3bf80f15e7faa267862depends onscopeguard
1.1.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cdsct
0.7.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd53dcdb7c9f8158937a7981b48accfd39a43af418591a5d008c7b22b5e1b7ca4depends onused bysec1
0.2.1crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum08da66b8b0965a5555b6bd6639e68ccba85e1e2506f5fbb089e93f8a04e1a2d1secp256k1
0.24.0crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb7649a0b3ffb32636e60c7ce0d70511eda9c52c658cd0634e194d5a19943aeffdepends onused bysecp256k1-sys
0.6.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7058dc8eaf3f2810d7828680320acda0b25a288f6d288e19278e249bbf74226bdepends onused bysecrecy
0.8.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9bd1c54ea06cfd2f6b63219704de0b9b4f72dcc2b8fdef820be6cd799780e91edepends onused bysecurity-framework
2.6.1crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2dc14f172faf8a0194a3aded622712b0de276821addc574fa54fc0a1167e10dcdepends onused bysecurity-framework-sys
2.6.1crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0160a13a177a45bfb43ce71c01580998474f556ad854dcbca936dd2841a5c556depends onused bysemver
0.6.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7a3186ec9e65071a2095434b1f5bb24838d4e8e130f584c790f6033c79943537depends onused bysemver
0.9.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1d7eb9ef2c18661902cc47e535f9bc51b78acd254da71d375c2f6720d9a40403depends onused bysemver
1.0.13crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum93f6841e709003d68bb2deee8c343572bf446003ec20a583e76f7b15cebf3711depends onsemver-parser
0.7.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3used byserde
1.0.143crates.ioβ 1β 124sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum53e8e5d5b70924f74ff5c6d64d9a5acd91422117c60f48c4e07855238a254553depends onused by- beef
0.5.2 - beefy-gadget-rpc
4.0.0-dev - bincode
1.3.3 - camino
1.1.1 - cargo-platform
0.1.2 - cargo_metadata
0.14.2 - cid
0.8.6 - cranelift-entity
0.85.3 - cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - ed25519-dalek
1.0.1 - ethereum
0.12.0 - evm
0.35.0 - evm-core
0.35.0 - fc-rpc-core
1.1.0-dev - fp-evm
3.0.0-dev - fp-self-contained
1.0.0-dev - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-metadata
15.0.0 - frame-support
4.0.0-dev - frame-system
4.0.0-dev - handlebars
4.3.3 - impl-serde
0.3.2 - indexmap
1.9.1 - jsonrpsee-core
0.14.0 - jsonrpsee-http-server
0.14.0 - jsonrpsee-types
0.14.0 - kusama-runtime
0.9.27 - libsecp256k1
0.7.1 - multiaddr
0.14.0 - opal-runtime
0.9.27 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-utilities
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-base-fee
1.0.0 - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-common
0.1.5 - pallet-democracy
4.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-foreing-assets
0.1.0 - pallet-inflation
0.1.1 - pallet-mmr-rpc
3.0.0 - pallet-offences
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-xcm
0.9.27 - parachain-info
0.1.0 - parity-scale-codec
2.3.1 - parity-scale-codec
3.1.5 - polkadot-node-primitives
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - remote-externalities
0.10.0-dev - rmrk-rpc
0.0.2 - rmrk-traits
0.1.0 - rococo-runtime
0.9.27 - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-network
0.10.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - scale-info
2.1.2 - semver
1.0.13 - serde_json
1.0.83 - serde_nanos
0.1.2 - sp-application-crypto
6.0.0 - sp-arithmetic
5.0.0 - sp-consensus-babe
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-keystore
0.12.0 - sp-mmr-primitives
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-rpc
6.0.0 - sp-runtime
6.0.0 - sp-serializer
4.0.0-dev - sp-storage
6.0.0 - sp-version
5.0.0 - ss58-registry
1.25.0 - substrate-state-trie-migration-rpc
4.0.0-dev - substrate-test-client
2.0.1 - toml
0.5.9 - tracing-serde
0.1.3 - tracing-subscriber
0.2.25 - try-runtime-cli
0.10.0-dev - unique-node
0.9.27 - unique-rpc
0.1.1 - unique-runtime
0.9.27 - up-data-structs
0.2.2 - wasmtime
0.38.3 - wasmtime-cache
0.38.3 - wasmtime-environ
0.38.3 - wasmtime-jit
0.38.3 - wasmtime-types
0.38.3 - westend-runtime
0.9.27
- beef
serde_derive
1.0.143crates.ioβ 3β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd3d8e8de557aee63c26b85b947f5e59b690d0454c753f3adeb5cd7835ab88391depends onserde_json
1.0.83crates.ioβ 3β 31sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum38dd04e3c8279e75b31ef29dbdceebfe5ad89f4d0937213c53f7d49d01b3d5a7depends onused by- cargo_metadata
0.14.2 - fc-rpc-core
1.1.0-dev - frame-benchmarking-cli
4.0.0-dev - handlebars
4.3.3 - jsonrpsee-core
0.14.0 - jsonrpsee-http-server
0.14.0 - jsonrpsee-types
0.14.0 - jsonrpsee-ws-server
0.14.0 - pallet-foreing-assets
0.1.0 - polkadot-service
0.9.27 - remote-externalities
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-peerset
4.0.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-rpc-server
4.0.0-dev - sc-service
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - sp-serializer
4.0.0-dev - ss58-registry
1.25.0 - substrate-frame-rpc-system
4.0.0-dev - substrate-test-client
2.0.1 - tracing-subscriber
0.2.25 - unique-node
0.9.27
- cargo_metadata
serde_nanos
0.1.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume44969a61f5d316be20a42ff97816efb3b407a924d06824c3d8a49fa8450de0edepends onsha-1
0.9.8crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum99cd6713db3cf16b6c84e06321e049a9b9f699826e16096d23bbcc44d15d51a6used bysha-1
0.10.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum028f48d513f9678cda28f6e4064755b3fbb2af6acd672f2c209b62323f7aea0fdepends onused bysha2
0.8.2crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma256f46ea78a0c0d9ff00077504903ac881a1dafdc20da66545699e7776b3e69used bysha2
0.9.9crates.ioβ 5β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800sha2
0.10.2crates.ioβ 3β 8sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum55deaec60f81eefe3cce0dc50bda92d6d8e88f2a27df7c5033b42afeb1ed2676depends onsha3
0.9.1crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf81199417d4e5de3f04b1e871023acea7389672c4135918f05aa9cbf2f2fa809sha3
0.10.2crates.ioβ 2β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0a31480366ec990f395a61b7c08122d99bd40544fdb5abcfc1b06bb29994312cdepends onsharded-slab
0.1.4crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31depends onused byshlex
1.1.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum43b2853a4d09f215c24cc5489c992ce46052d359b5109343cbafbf26bc62f8a3used bysignal-hook
0.3.14crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma253b5e89e2698464fc26b545c9edceb338e18a89effeeecfea192c3025be29ddepends onused bysignal-hook-registry
1.4.0crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume51e73328dc4ac0c7ccbda3a494dfa03df1de2f46018127f60c693f2648455b0depends onused bysignature
1.4.0crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum02658e48d89f2bec991f9a78e69cfa4c316f8d6a6c4ec12fae1aeb263d486788depends onused bysimba
0.5.1crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8e82063457853d00243beda9952e910b82593e4b07ae9f721b9278a99a0d3d5cused byslab
0.4.7crates.ioβ 1β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4614a76b2a8be0058caa9dbbaf66d988527d86d003c11a94fbd335d7661edcefdepends onslice-group-by
0.3.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum03b634d87b960ab1a38c4fe143b508576f075e7c978bfad18217645ebfdfa2ecused byslot-range-helper
0.9.27github.com/paritytech/polkadotβ 5β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feaslotmap
1.0.6crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume1e08e261d0e8f5c43123b7adf3e4ca1690d655377ac93a03b2c9d3e98de1342depends onused bysmallvec
1.9.0crates.ioβ 0β 46sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2fd0db749597d91ff862fd1d55ea87f7855a744a8425a64695b6fca237d1dad1used by- cranelift-codegen
0.85.3 - cranelift-frontend
0.85.3 - cranelift-wasm
0.85.3 - frame-support
4.0.0-dev - kusama-runtime
0.9.27 - kusama-runtime-constants
0.9.27 - kvdb
0.11.0 - kvdb-rocksdb
0.15.2 - libp2p
0.46.1 - libp2p-core
0.34.0 - libp2p-dns
0.34.0 - libp2p-floodsub
0.37.0 - libp2p-gossipsub
0.39.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-mdns
0.38.0 - libp2p-mplex
0.34.0 - libp2p-relay
0.10.0 - libp2p-request-response
0.19.0 - libp2p-swarm
0.37.0 - multistream-select
0.11.0 - opal-runtime
0.9.27 - pallet-configuration
0.1.1 - parity-util-mem
0.11.0 - parking_lot_core
0.8.5 - parking_lot_core
0.9.3 - polkadot-node-subsystem-types
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-constants
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - regalloc2
0.2.3 - rococo-runtime
0.9.27 - rococo-runtime-constants
0.9.27 - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-sync
0.10.0-dev - sp-state-machine
0.12.0 - test-runtime-constants
0.9.27 - tracing-subscriber
0.2.25 - trie-db
0.23.1 - trust-dns-proto
0.21.2 - trust-dns-resolver
0.21.2 - unique-runtime
0.9.27 - westend-runtime
0.9.27 - westend-runtime-constants
0.9.27
- cranelift-codegen
snap
1.0.5crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum45456094d1983e2ee2a18fdfebce3189fa451699d0502cb8e3b49dba5ba41451used bysnow
0.9.0crates.ioβ 9β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum774d05a3edae07ce6d68ea6984f3c05e9bba8927e3dd591e3b479e5b03213d0ddepends onused bysocket2
0.4.4crates.ioβ 2β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum66d72b759436ae32898a2af0a14218dbf55efde3feeb170eb623637db85ee1e0depends onsoketto
0.7.1crates.ioβ 8β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum41d1c5305e39e09653383c2c7244f2f78b3bcae37cf50c64cb4789c9f5096ec2sp-api
4.0.0-devgithub.com/paritytech/substrateβ 10β 75sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- beefy-gadget
4.0.0-dev - beefy-merkle-tree
4.0.0-dev - beefy-primitives
4.0.0-dev - cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-consensus
2.0.0-dev - fc-mapping-sync
2.0.0-dev - fc-rpc
2.0.0-dev - fp-rpc
3.0.0-dev - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - frame-try-runtime
0.10.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-mmr-rpc
3.0.0 - pallet-nomination-pools-runtime-api
1.0.0-dev - pallet-transaction-payment-rpc
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - polkadot-client
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-overseer
0.9.27 - polkadot-primitives
0.9.27 - polkadot-rpc
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - rmrk-rpc
0.0.2 - rococo-runtime
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-block-builder
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-executor
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-offchain
4.0.0-dev - sc-rpc
4.0.0-dev - sc-service
0.10.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-finality-grandpa
4.0.0-dev - sp-mmr-primitives
4.0.0-dev - sp-offchain
4.0.0-dev - sp-session
4.0.0-dev - sp-timestamp
4.0.0-dev - sp-transaction-pool
4.0.0-dev - substrate-frame-rpc-system
4.0.0-dev - uc-rpc
0.1.3 - unique-node
0.9.27 - unique-rpc
0.1.1 - unique-runtime
0.9.27 - up-rpc
0.1.3 - westend-runtime
0.9.27
- beefy-gadget
sp-api-proc-macro
4.0.0-devgithub.com/paritytech/substrateβ 5β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used bysp-application-crypto
6.0.0github.com/paritytech/substrateβ 6β 29sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used by- beefy-gadget
4.0.0-dev - beefy-primitives
4.0.0-dev - cumulus-client-consensus-aura
0.1.0 - cumulus-pallet-aura-ext
0.1.0 - frame-benchmarking
4.0.0-dev - pallet-aura
4.0.0-dev - pallet-authority-discovery
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-staking
4.0.0-dev - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime-parachains
0.9.27 - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-keystore
4.0.0-dev - sc-service
0.10.0-dev - sp-authority-discovery
4.0.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-finality-grandpa
4.0.0-dev - sp-runtime
6.0.0
- beefy-gadget
sp-arithmetic
5.0.0github.com/paritytech/substrateβ 8β 23sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- beefy-gadget
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-support
4.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-configuration
0.1.1 - pallet-election-provider-multi-phase
4.0.0-dev - pallet-gilt
4.0.0-dev - pallet-staking-reward-fn
4.0.0-dev - polkadot-primitives
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - sc-client-db
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-network
0.10.0-dev - sc-network-sync
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-npos-elections
4.0.0-dev - sp-runtime
6.0.0 - unique-runtime
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- beefy-gadget
sp-authority-discovery
4.0.0-devgithub.com/paritytech/substrateβ 6β 12sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- kusama-runtime
0.9.27 - pallet-authority-discovery
4.0.0-dev - polkadot-client
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - rococo-runtime
0.9.27 - sc-authority-discovery
0.10.0-dev - westend-runtime
0.9.27
- kusama-runtime
sp-authorship
4.0.0-devgithub.com/paritytech/substrateβ 5β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sp-block-builder
4.0.0-devgithub.com/paritytech/substrateβ 5β 21sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used by- cumulus-client-consensus-aura
0.1.0 - fc-consensus
2.0.0-dev - fc-rpc
2.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - polkadot-client
0.9.27 - polkadot-rpc
0.9.27 - polkadot-runtime
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - sc-block-builder
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-service
0.10.0-dev - substrate-frame-rpc-system
4.0.0-dev - unique-node
0.9.27 - unique-rpc
0.1.1 - unique-runtime
0.9.27 - westend-runtime
0.9.27
- cumulus-client-consensus-aura
sp-blockchain
4.0.0-devgithub.com/paritytech/substrateβ 11β 49sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- beefy-gadget
4.0.0-dev - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-service
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - fc-consensus
2.0.0-dev - fc-mapping-sync
2.0.0-dev - fc-rpc
2.0.0-dev - frame-benchmarking-cli
4.0.0-dev - pallet-mmr-rpc
3.0.0 - pallet-transaction-payment-rpc
4.0.0-dev - polkadot-client
0.9.27 - polkadot-node-core-chain-api
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-rpc
0.9.27 - polkadot-service
0.9.27 - polkadot-test-service
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-block-builder
0.10.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-informant
0.10.0-dev - sc-network
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-rpc
4.0.0-dev - sc-service
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - substrate-frame-rpc-system
4.0.0-dev - substrate-test-client
2.0.1 - uc-rpc
0.1.3 - unique-node
0.9.27 - unique-rpc
0.1.1
- beefy-gadget
sp-consensus
0.10.0-devgithub.com/paritytech/substrateβ 12β 34sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- beefy-gadget
4.0.0-dev - cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - fc-consensus
2.0.0-dev - polkadot-client
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-rpc
0.9.27 - polkadot-service
0.9.27 - polkadot-test-service
0.9.27 - sc-basic-authorship
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-service
0.10.0-dev - sp-blockchain
4.0.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - substrate-test-client
2.0.1 - unique-node
0.9.27 - unique-rpc
0.1.1
- beefy-gadget
sp-consensus-aura
0.10.0-devgithub.com/paritytech/substrateβ 11β 11sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-consensus-babe
0.10.0-devgithub.com/paritytech/substrateβ 16β 16sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- kusama-runtime
0.9.27 - pallet-babe
4.0.0-dev - polkadot-client
0.9.27 - polkadot-node-core-runtime-api
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-rpc
0.9.27 - polkadot-runtime
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - rococo-runtime
0.9.27 - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - westend-runtime
0.9.27
- kusama-runtime
sp-consensus-slots
0.10.0-devgithub.com/paritytech/substrateβ 7β 8sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-consensus-vrf
0.10.0-devgithub.com/paritytech/substrateβ 6β 4sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-core
6.0.0github.com/paritytech/substrateβ 39β 155sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- base58
0.2.0 - bitflags
1.3.2 - blake2-rfc
0.2.18 - byteorder
1.4.3 - dyn-clonable
0.9.0 - ed25519-dalek
1.0.1 - futures
0.3.23 - hash-db
0.15.2 - hash256-std-hasher
0.15.2 - hex
0.4.3 - impl-serde
0.3.2 - lazy_static
1.4.0 - libsecp256k1
0.7.1 - log
0.4.17 - merlin
2.0.1 - num-traits
0.2.15 - parity-scale-codec
3.1.5 - parity-util-mem
0.11.0 - parking_lot
0.12.1 - primitive-types
0.11.1 - rand
0.7.3 - regex
1.6.0 - scale-info
2.1.2 - schnorrkel
0.9.1 - secp256k1
0.24.0 - secrecy
0.8.0 - serde
1.0.143 - sp-core-hashing
4.0.0 - sp-debug-derive
4.0.0 - sp-externalities
0.12.0 - sp-runtime-interface
6.0.0 - sp-std
4.0.0 - sp-storage
6.0.0 - ss58-registry
1.25.0 - substrate-bip39
0.4.4 - thiserror
1.0.32 - tiny-bip39
0.8.2 - wasmi
0.9.1 - zeroize
1.5.7
used by- beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - beefy-primitives
4.0.0-dev - cumulus-client-cli
0.1.0 - cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-service
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-db
2.0.0-dev - fc-rpc
2.0.0-dev - fp-consensus
2.0.0-dev - fp-evm
3.0.0-dev - fp-evm-mapping
0.1.0 - fp-rpc
3.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-bags-list
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-election-provider-multi-phase
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-grandpa
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-mmr-rpc
3.0.0 - pallet-nomination-pools
1.0.0 - pallet-nonfungible
0.1.4 - pallet-preimage
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-session
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - pallet-xcm
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-cli
0.9.27 - polkadot-client
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-core-primitives
0.9.27 - polkadot-erasure-coding
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-jaeger
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-table
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - remote-externalities
0.10.0-dev - rmrk-rpc
0.0.2 - rococo-runtime
0.9.27 - sc-allocator
4.1.0-dev - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-block-builder
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-executor
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-offchain
4.0.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sc-state-db
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-consensus
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-consensus-vrf
0.10.0-dev - sp-finality-grandpa
4.0.0-dev - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-keyring
6.0.0 - sp-keystore
0.12.0 - sp-mmr-primitives
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-offchain
4.0.0-dev - sp-rpc
6.0.0 - sp-runtime
6.0.0 - sp-sandbox
0.10.0-dev - sp-session
4.0.0-dev - sp-state-machine
0.12.0 - sp-tasks
4.0.0-dev - sp-transaction-storage-proof
4.0.0-dev - sp-trie
6.0.0 - substrate-frame-rpc-system
4.0.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev - substrate-test-client
2.0.1 - tests
0.1.1 - try-runtime-cli
0.10.0-dev - uc-rpc
0.1.3 - unique-node
0.9.27 - unique-rpc
0.1.1 - unique-runtime
0.9.27 - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3 - westend-runtime
0.9.27 - xcm-executor
0.9.27
- base58
sp-core-hashing
4.0.0github.com/paritytech/substrateβ 7β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sp-core-hashing-proc-macro
5.0.0github.com/paritytech/substrateβ 4β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sp-database
4.0.0-devgithub.com/paritytech/substrateβ 2β 5sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-debug-derive
4.0.0github.com/paritytech/substrateβ 3β 5sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-externalities
0.12.0github.com/paritytech/substrateβ 4β 13sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sp-finality-grandpa
4.0.0-devgithub.com/paritytech/substrateβ 11β 8sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-inherents
4.0.0-devgithub.com/paritytech/substrateβ 7β 37sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-client-consensus-aura
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-primitives-timestamp
0.1.0 - frame-benchmarking-cli
4.0.0-dev - frame-support
4.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-timestamp
4.0.0-dev - polkadot-client
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - sc-basic-authorship
0.10.0-dev - sc-block-builder
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-service
0.10.0-dev - sp-authorship
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-timestamp
4.0.0-dev - sp-transaction-storage-proof
4.0.0-dev - unique-node
0.9.27 - unique-runtime
0.9.27 - westend-runtime
0.9.27
- cumulus-client-consensus-aura
sp-io
6.0.0github.com/paritytech/substrateβ 18β 77sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - fc-rpc
2.0.0-dev - fp-rpc
3.0.0-dev - fp-self-contained
1.0.0-dev - frame-benchmarking
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - orml-traits
0.4.1-dev - orml-utilities
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - polkadot-node-core-pvf
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - remote-externalities
0.10.0-dev - rococo-runtime
0.9.27 - sc-consensus-babe
0.10.0-dev - sc-executor
0.10.0-dev - sc-sysinfo
6.0.0-dev - sp-application-crypto
6.0.0 - sp-runtime
6.0.0 - sp-sandbox
0.10.0-dev - sp-tasks
4.0.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev - tests
0.1.1 - try-runtime-cli
0.10.0-dev - unique-runtime
0.9.27 - westend-runtime
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- cumulus-pallet-dmp-queue
sp-keyring
6.0.0github.com/paritytech/substrateβ 4β 6sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sp-keystore
0.12.0github.com/paritytech/substrateβ 10β 34sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- beefy-gadget
4.0.0-dev - cumulus-client-consensus-aura
0.1.0 - frame-benchmarking-cli
4.0.0-dev - polkadot-availability-distribution
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-bitfield-signing
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-primitives
0.9.27 - polkadot-rpc
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-keystore
4.0.0-dev - sc-rpc
4.0.0-dev - sc-service
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-finality-grandpa
4.0.0-dev - sp-io
6.0.0 - substrate-test-client
2.0.1 - try-runtime-cli
0.10.0-dev - unique-node
0.9.27
- beefy-gadget
sp-maybe-compressed-blob
4.1.0-devgithub.com/paritytech/substrateβ 2β 7sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-mmr-primitives
4.0.0-devgithub.com/paritytech/substrateβ 8β 9sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-npos-elections
4.0.0-devgithub.com/paritytech/substrateβ 7β 8sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-offchain
4.0.0-devgithub.com/paritytech/substrateβ 3β 14sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sp-panic-handler
4.0.0github.com/paritytech/substrateβ 3β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sp-rpc
6.0.0github.com/paritytech/substrateβ 3β 5sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-runtime
6.0.0github.com/paritytech/substrateβ 15β 204sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - beefy-primitives
4.0.0-dev - cumulus-client-cli
0.1.0 - cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-primitives-utility
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - cumulus-test-relay-sproof-builder
0.1.0 - fc-consensus
2.0.0-dev - fc-db
2.0.0-dev - fc-mapping-sync
2.0.0-dev - fc-rpc
2.0.0-dev - fp-consensus
2.0.0-dev - fp-rpc
3.0.0-dev - fp-self-contained
1.0.0-dev - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-try-runtime
0.10.0-dev - kusama-runtime
0.9.27 - kusama-runtime-constants
0.9.27 - opal-runtime
0.9.27 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-utilities
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xcm-support
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-election-provider-support-benchmarking
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-gilt
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-mmr-rpc
3.0.0 - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nonfungible
0.1.4 - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-randomness-collective-flip
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-society
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - polkadot-client
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-core-primitives
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-rpc
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-constants
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - remote-externalities
0.10.0-dev - rmrk-rpc
0.0.2 - rococo-runtime
0.9.27 - rococo-runtime-constants
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-block-builder
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-consensus-uncles
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-informant
0.10.0-dev - sc-network
0.10.0-dev - sc-network-common
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-offchain
4.0.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - slot-range-helper
0.9.27 - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-authorship
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-consensus-vrf
0.10.0-dev - sp-finality-grandpa
4.0.0-dev - sp-inherents
4.0.0-dev - sp-keyring
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-offchain
4.0.0-dev - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-timestamp
4.0.0-dev - sp-transaction-pool
4.0.0-dev - sp-transaction-storage-proof
4.0.0-dev - sp-version
5.0.0 - substrate-frame-rpc-system
4.0.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev - substrate-test-client
2.0.1 - test-runtime-constants
0.9.27 - tests
0.1.1 - try-runtime-cli
0.10.0-dev - uc-rpc
0.1.3 - unique-node
0.9.27 - unique-rpc
0.1.1 - unique-runtime
0.9.27 - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3 - westend-runtime
0.9.27 - westend-runtime-constants
0.9.27 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- beefy-gadget
sp-runtime-interface
6.0.0github.com/paritytech/substrateβ 10β 7sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-runtime-interface-proc-macro
5.0.0github.com/paritytech/substrateβ 5β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used bysp-sandbox
0.10.0-devgithub.com/paritytech/substrateβ 7β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-serializer
4.0.0-devgithub.com/paritytech/substrateβ 2β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bysp-session
4.0.0-devgithub.com/paritytech/substrateβ 7β 20sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- kusama-runtime
0.9.27 - opal-runtime
0.9.27 - pallet-babe
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-session
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - polkadot-client
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-service
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - sc-rpc
4.0.0-dev - sc-service
0.10.0-dev - unique-node
0.9.27 - unique-rpc
0.1.1 - unique-runtime
0.9.27 - westend-runtime
0.9.27
- kusama-runtime
sp-staking
4.0.0-devgithub.com/paritytech/substrateβ 4β 20sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used by- frame-support
4.0.0-dev - kusama-runtime
0.9.27 - pallet-babe
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-session
4.0.0-dev - pallet-staking
4.0.0-dev - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-statement-distribution
0.9.27 - polkadot-test-runtime
0.9.27 - rococo-runtime
0.9.27 - sp-session
4.0.0-dev - westend-runtime
0.9.27
- frame-support
sp-state-machine
0.12.0github.com/paritytech/substrateβ 15β 24sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-client-network
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - cumulus-test-relay-sproof-builder
0.1.0 - frame-benchmarking-cli
4.0.0-dev - frame-support
4.0.0-dev - polkadot-service
0.9.27 - polkadot-test-service
0.9.27 - sc-block-builder
0.10.0-dev - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-service
0.10.0-dev - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-io
6.0.0 - substrate-state-trie-migration-rpc
4.0.0-dev - substrate-test-client
2.0.1 - try-runtime-cli
0.10.0-dev
- cumulus-client-network
sp-std
4.0.0github.com/paritytech/substrateβ 0β 148sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used by- beefy-primitives
4.0.0-dev - cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-primitives-timestamp
0.1.0 - cumulus-primitives-utility
0.1.0 - cumulus-test-relay-sproof-builder
0.1.0 - fp-consensus
2.0.0-dev - fp-evm
3.0.0-dev - fp-rpc
3.0.0-dev - frame-benchmarking
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-try-runtime
0.10.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-utilities
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xcm-support
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-beefy
4.0.0-dev - pallet-beefy-mmr
4.0.0-dev - pallet-bounties
4.0.0-dev - pallet-child-bounties
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-gilt
4.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-inflation
0.1.1 - pallet-membership
4.0.0-dev - pallet-mmr
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nomination-pools-runtime-api
1.0.0-dev - pallet-nonfungible
0.1.4 - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-randomness-collective-flip
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-society
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-structure
0.1.2 - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-tips
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - polkadot-core-primitives
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-metrics
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - rmrk-rpc
0.0.2 - rococo-runtime
0.9.27 - sc-sysinfo
6.0.0-dev - slot-range-helper
0.9.27 - sp-api
4.0.0-dev - sp-application-crypto
6.0.0 - sp-arithmetic
5.0.0 - sp-authority-discovery
4.0.0-dev - sp-authorship
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-consensus-babe
0.10.0-dev - sp-consensus-slots
0.10.0-dev - sp-consensus-vrf
0.10.0-dev - sp-core
6.0.0 - sp-core-hashing
4.0.0 - sp-externalities
0.12.0 - sp-finality-grandpa
4.0.0-dev - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-runtime
6.0.0 - sp-runtime-interface
6.0.0 - sp-sandbox
0.10.0-dev - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-state-machine
0.12.0 - sp-storage
6.0.0 - sp-tasks
4.0.0-dev - sp-timestamp
4.0.0-dev - sp-tracing
5.0.0 - sp-transaction-storage-proof
4.0.0-dev - sp-trie
6.0.0 - sp-version
5.0.0 - sp-wasm-interface
6.0.0 - substrate-state-trie-migration-rpc
4.0.0-dev - tests
0.1.1 - unique-runtime
0.9.27 - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3 - westend-runtime
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- beefy-primitives
sp-storage
6.0.0github.com/paritytech/substrateβ 6β 13sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-primitives-parachain-inherent
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-rpc
2.0.0-dev - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - polkadot-client
0.9.27 - polkadot-service
0.9.27 - sc-client-api
4.0.0-dev - sc-service
0.10.0-dev - sp-core
6.0.0 - sp-externalities
0.12.0 - sp-runtime-interface
6.0.0 - unique-rpc
0.1.1
- cumulus-primitives-parachain-inherent
sp-tasks
4.0.0-devgithub.com/paritytech/substrateβ 6β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used bysp-timestamp
4.0.0-devgithub.com/paritytech/substrateβ 9β 10sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-tracing
5.0.0github.com/paritytech/substrateβ 5β 11sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05sp-transaction-pool
4.0.0-devgithub.com/paritytech/substrateβ 2β 14sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsp-transaction-storage-proof
4.0.0-devgithub.com/paritytech/substrateβ 9β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bysp-trie
6.0.0github.com/paritytech/substrateβ 9β 20sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-client-consensus-common
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-primitives-utility
0.1.0 - frame-benchmarking-cli
4.0.0-dev - pallet-session
4.0.0-dev - polkadot-cli
0.9.27 - polkadot-erasure-coding
0.9.27 - polkadot-primitives
0.9.27 - polkadot-service
0.9.27 - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-executor
0.10.0-dev - sc-service
0.10.0-dev - sp-io
6.0.0 - sp-state-machine
0.12.0 - sp-transaction-storage-proof
4.0.0-dev - substrate-state-trie-migration-rpc
4.0.0-dev - unique-node
0.9.27
- cumulus-client-consensus-common
sp-version
5.0.0github.com/paritytech/substrateβ 10β 21sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused by- cumulus-pallet-parachain-system
0.1.0 - frame-system
4.0.0-dev - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - remote-externalities
0.10.0-dev - rococo-runtime
0.9.27 - sc-cli
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-executor
0.10.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sp-api
4.0.0-dev - sp-consensus
0.10.0-dev - try-runtime-cli
0.10.0-dev - unique-runtime
0.9.27 - westend-runtime
0.9.27
- cumulus-pallet-parachain-system
sp-version-proc-macro
4.0.0-devgithub.com/paritytech/substrateβ 4β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used bysp-wasm-interface
6.0.0github.com/paritytech/substrateβ 6β 9sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onspin
0.5.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042dused byss58-registry
1.25.0crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma039906277e0d8db996cd9d1ef19278c10209d994ecfc1025ced16342873a17cdepends onused bystable_deref_trait
1.2.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3used bystatic_assertions
1.1.0crates.ioβ 0β 15sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543fused by- fixed-hash
0.7.0 - kusama-runtime
0.9.27 - libp2p-noise
0.37.0 - libp2p-relay
0.10.0 - multiaddr
0.14.0 - pallet-election-provider-multi-phase
4.0.0-dev - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - rw-stream-sink
0.3.0 - sp-arithmetic
5.0.0 - sp-runtime-interface
6.0.0 - twox-hash
1.6.3 - uint
0.9.3 - yamux
0.10.2
- fixed-hash
static_init
0.5.2crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum11b73400442027c4adedda20a9f9b7945234a5bd8d5f7e86da22bd5d0622369cused bystatic_init_macro
0.5.0crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf2261c91034a1edc3fc4d1b80e89d82714faede0515c14a75da10cb941546bbfused bystatrs
0.15.0crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum05bdbb8e4e78216a85785a85d3ec3183144f98d0097b9281802c019bb07a6f05used bystrsim
0.10.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623used bystruct-versioning
0.1.0workspaceβ 2β 3strum
0.24.1crates.ioβ 1β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum063e6045c0e62079840579a7e47a355ae92f60eb74daaf156fb1e84ba164e63fdepends onstrum_macros
0.24.3crates.ioβ 5β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59used bysubstrate-bip39
0.4.4crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum49eee6965196b32f882dd2ee85a92b1dbead41b04e53907f269de3b0dc04733cused bysubstrate-build-script-utils
3.0.0github.com/paritytech/substrateβ 1β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsubstrate-frame-rpc-system
4.0.0-devgithub.com/paritytech/substrateβ 14β 3sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsubstrate-prometheus-endpoint
0.10.0-devgithub.com/paritytech/substrateβ 6β 21sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used by- beefy-gadget
4.0.0-dev - cumulus-client-consensus-aura
0.1.0 - fc-rpc
2.0.0-dev - polkadot-node-metrics
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-service
0.9.27 - sc-authority-discovery
0.10.0-dev - sc-basic-authorship
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-network
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-proposer-metrics
0.10.0-dev - sc-rpc-server
4.0.0-dev - sc-service
0.10.0-dev - sc-transaction-pool
4.0.0-dev - unique-node
0.9.27
- beefy-gadget
substrate-state-trie-migration-rpc
4.0.0-devgithub.com/paritytech/substrateβ 14β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onused bysubstrate-test-client
2.0.1github.com/paritytech/substrateβ 19β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- async-trait
0.1.57 - futures
0.3.23 - hex
0.4.3 - parity-scale-codec
3.1.5 - sc-client-api
4.0.0-dev - sc-client-db
0.10.0-dev - sc-consensus
0.10.0-dev - sc-executor
0.10.0-dev - sc-offchain
4.0.0-dev - sc-service
0.10.0-dev - serde
1.0.143 - serde_json
1.0.83 - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-keyring
6.0.0 - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0
used by- async-trait
substrate-test-utils
4.0.0-devgithub.com/paritytech/substrateβ 3β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05used bysubstrate-test-utils-derive
0.10.0-devgithub.com/paritytech/substrateβ 4β 1sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05substrate-wasm-builder
5.0.0-devgithub.com/paritytech/substrateβ 10β 8sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends onsubtle
2.4.1crates.ioβ 0β 16sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601syn
1.0.99crates.ioβ 3β 62sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum58dbef6ec655055e20b86b15a8cc6d439cca19b667537ac6a1369572d151ab13used by- async-attributes
1.1.2 - async-trait
0.1.57 - auto_impl
0.5.0 - clap_derive
3.2.17 - ctor
0.1.23 - cumulus-pallet-parachain-system-proc-macro
0.1.0 - darling_core
0.13.4 - darling_macro
0.13.4 - data-encoding-macro-internal
0.1.10 - derivative
2.2.0 - derive_more
0.99.17 - dyn-clonable-impl
0.9.0 - enum-as-inner
0.4.0 - enumflags2_derive
0.7.4 - enumn
0.1.5 - evm-coder-macros
0.1.0 - expander
0.0.6 - fatality-proc-macro
0.0.6 - frame-election-provider-solution-type
4.0.0-dev - frame-support-procedural
4.0.0-dev - frame-support-procedural-tools
4.0.0-dev - frame-support-procedural-tools-derive
3.0.0 - futures-macro
0.3.23 - impl-trait-for-tuples
0.2.2 - jsonrpsee-proc-macros
0.14.0 - libp2p-swarm-derive
0.28.0 - multihash-derive
0.8.0 - nalgebra-macros
0.1.0 - orchestra-proc-macro
0.0.1 - pallet-staking-reward-curve
4.0.0-dev - parity-scale-codec-derive
2.3.1 - parity-scale-codec-derive
3.1.3 - parity-util-mem-derive
0.1.0 - pest_generator
2.2.1 - pin-project-internal
1.0.12 - proc-macro-error
1.0.4 - prometheus-client-derive-text-encode
0.2.0 - prost-derive
0.10.1 - ref-cast-impl
1.0.9 - rlp-derive
0.1.0 - sc-chain-spec-derive
4.0.0-dev - sc-tracing-proc-macro
4.0.0-dev - scale-info-derive
2.1.2 - serde_derive
1.0.143 - sp-api-proc-macro
4.0.0-dev - sp-core-hashing-proc-macro
5.0.0 - sp-debug-derive
4.0.0 - sp-runtime-interface-proc-macro
5.0.0 - sp-version-proc-macro
4.0.0-dev - static_init_macro
0.5.0 - struct-versioning
0.1.0 - strum_macros
0.24.3 - substrate-test-utils-derive
0.10.0-dev - synstructure
0.12.6 - thiserror-impl
1.0.32 - tokio-macros
1.8.0 - tracing-attributes
0.1.22 - tracing-gum-proc-macro
0.9.27 - wasm-bindgen-backend
0.2.82 - wasm-bindgen-macro-support
0.2.82 - xcm-procedural
0.9.27 - zeroize_derive
1.3.2
- async-attributes
synstructure
0.12.6crates.ioβ 4β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210fsystem-configuration
0.5.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd75182f12f490e953596550b65ee31bda7c8e043d9386174b353bda50838c3fdused bysystem-configuration-sys
0.5.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9depends onused bytap
1.0.1crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369target-lexicon
0.12.4crates.ioβ 0β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc02424087780c9b71cc96799eaeddff35af2bc513278cda5c99fc1f5d026d3c1tempfile
3.3.0crates.ioβ 6β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5cdb1ef4eaeeaddc8fbd371e5017057064af0911902ef36b39801f67cc6d79e4termcolor
1.1.3crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbab24d30b911b2376f3a13cc2cd443142f0c81dda04c118693e35b3835757755depends onused bytest-runtime-constants
0.9.27github.com/paritytech/polkadotβ 5β 2sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends ontests
0.1.1workspaceβ 24β 0depends on- evm-coder
0.1.1 - fp-evm-mapping
0.1.0 - frame-support
4.0.0-dev - frame-system
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-common
0.1.5 - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-fungible
0.1.3 - pallet-nonfungible
0.1.4 - pallet-refungible
0.2.3 - pallet-structure
0.1.2 - pallet-timestamp
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-unique
0.1.3 - parity-scale-codec
3.1.5 - scale-info
2.1.2 - sp-core
6.0.0 - sp-io
6.0.0 - sp-runtime
6.0.0 - sp-std
4.0.0 - up-data-structs
0.2.2 - up-sponsorship
0.1.0
- evm-coder
textwrap
0.15.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb1141d4d61095b28419e22cb0bbf02755f5e54e0526f97f1e3d1d160e60885fbused bythiserror
1.0.32crates.ioβ 1β 100sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf5f6586b7f764adc0231f4c79be7b920e766bb2f3e51b3661cdb263828f19994depends onused by- beefy-gadget
4.0.0-dev - beefy-gadget-rpc
4.0.0-dev - bounded-vec
0.6.0 - cumulus-relay-chain-interface
0.1.0 - fatality
0.0.6 - fatality-proc-macro
0.0.6 - fc-consensus
2.0.0-dev - flexi_logger
0.22.6 - frame-benchmarking-cli
4.0.0-dev - handlebars
4.3.3 - jsonrpsee-client-transport
0.14.0 - jsonrpsee-core
0.14.0 - jsonrpsee-types
0.14.0 - libp2p-core
0.34.0 - libp2p-identify
0.37.0 - libp2p-kad
0.38.0 - libp2p-relay
0.10.0 - libp2p-rendezvous
0.7.0 - libp2p-swarm
0.37.0 - libp2p-yamux
0.38.0 - netlink-packet-utils
0.5.1 - netlink-proto
0.10.0 - orchestra
0.0.1 - pest
2.2.1 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-cli
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-erasure-coding
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-bitfield-signing
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-jaeger
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-primitives
0.9.27 - polkadot-node-subsystem-types
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-performance-test
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27 - prioritized-metered-channel
0.2.0 - proc-macro-crate
1.2.1 - prometheus
0.13.1 - prost-codec
0.1.0 - redox_users
0.4.3 - reed-solomon-novelpoly
1.0.0 - rtnetlink
0.10.1 - sc-allocator
4.1.0-dev - sc-authority-discovery
0.10.0-dev - sc-cli
0.10.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-babe
0.10.0-dev - sc-consensus-babe-rpc
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-consensus-slots
0.10.0-dev - sc-consensus-uncles
0.10.0-dev - sc-executor-common
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-network-light
0.10.0-dev - sc-network-sync
0.10.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sc-sync-state-rpc
0.10.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - sc-transaction-pool-api
4.0.0-dev - sp-api
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-keystore
0.12.0 - sp-maybe-compressed-blob
4.1.0-dev - sp-state-machine
0.12.0 - sp-timestamp
4.0.0-dev - sp-trie
6.0.0 - sp-version
5.0.0 - substrate-prometheus-endpoint
0.10.0-dev - tiny-bip39
0.8.2 - trust-dns-proto
0.21.2 - trust-dns-resolver
0.21.2 - wasmtime-cranelift
0.38.3 - wasmtime-environ
0.38.3 - wasmtime-jit
0.38.3 - wasmtime-runtime
0.38.3 - wasmtime-types
0.38.3
- beefy-gadget
thiserror-impl
1.0.32crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum12bafc5b54507e0149cdf1b145a5d80ab80a90bcd9275df43d4fff68460f6c21depends onused bythousands
0.2.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3bf63baf9f5039dadc247375c29eb13706706cfde997d0330d05aa63a77d8820thread_local
1.1.4crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5516c27b78311c50bf42c071425c560ac799b11c30b31f87e3081965fe5e0180depends onused bythreadpool
1.8.1crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaadepends onthrift
0.15.0crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb82ca8f46f95b3ce96081fe3dd89160fdea970c254bb72925255d1b62aae692eused bytikv-jemalloc-sys
0.4.3+5.2.1-patched.2crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma1792ccb507d955b46af42c123ea8863668fae24d03721e40cad6a41773dbb49depends onused bytime
0.1.44crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6db9e6914ab8b1ae1c260a4ae7a49b6c5611b40328a735b21862567685e73255used bytime
0.3.9crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc2702e08a7a860f005826c6815dcac101b19b5eb330c27fe4a5928fec1d20dddused bytime-macros
0.2.4crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum42657b1a6f4d817cda8e7a0ace261fe0cc946cf3a80314390b22cc61ae080792used bytiny-bip39
0.8.2crates.ioβ 11β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumffc59cb9dfc85bb312c3a78fd6aa8a8582e310b0fa885d5bb877f6dcc601839ddepends onused bytiny-keccak
2.0.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237depends onused bytinyvec
1.6.0crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50depends ontinyvec_macros
0.1.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5cused bytokio
1.20.1crates.ioβ 13β 22sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum7a8325f63a7d4774dd041e363b2409ed1c5cbbd0f867795e661df066b2b0a581depends onused by- backoff
0.4.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-rpc
2.0.0-dev - h2
0.3.13 - hyper
0.14.20 - hyper-rustls
0.23.0 - jsonrpsee-client-transport
0.14.0 - jsonrpsee-core
0.14.0 - jsonrpsee-http-server
0.14.0 - jsonrpsee-ws-server
0.14.0 - netlink-proto
0.10.0 - polkadot-test-service
0.9.27 - sc-cli
0.10.0-dev - sc-rpc-server
4.0.0-dev - sc-service
0.10.0-dev - substrate-prometheus-endpoint
0.10.0-dev - substrate-test-utils
4.0.0-dev - tokio-rustls
0.23.4 - tokio-stream
0.1.9 - tokio-util
0.7.3 - unique-node
0.9.27 - unique-rpc
0.1.1
- backoff
tokio-macros
1.8.0crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9724f9a975fb987ef7a3cd9be0350edcbe130698af5b8f7a631e23d42d052484depends onused bytokio-rustls
0.23.4crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc43ee83903113e03984cb9e5cebe6c04a5116269e900e3ddba8f068a62adda59depends ontokio-stream
0.1.9crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumdf54d54117d6fdc4e4fea40fe1e4e566b3505700e148a6827e59b34b0d2600d9used bytokio-util
0.7.3crates.ioβ 7β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcc463cd8deddc3770d20f9852143d50bf6094e640b485cb2e189a2099085ff45depends ontoml
0.5.9crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8d82e1a7758622a465f8cee077614c73484dac5b836c02ff6a40d5d1010324d7depends ontower-service
0.3.2crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52used bytracing
0.1.36crates.ioβ 4β 31sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2fce9567bd60a67d08a16488756721ba392f24f29006402881e43b19aac64307used by- cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-pov-recovery
0.1.0 - cumulus-client-service
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - h2
0.3.13 - hyper
0.14.20 - jsonrpsee
0.14.0 - jsonrpsee-client-transport
0.14.0 - jsonrpsee-core
0.14.0 - jsonrpsee-http-server
0.14.0 - jsonrpsee-types
0.14.0 - jsonrpsee-ws-server
0.14.0 - orchestra
0.0.1 - prioritized-metered-channel
0.2.0 - sc-executor
0.10.0-dev - sc-network-gossip
0.10.0-dev - sc-offchain
4.0.0-dev - sc-service
0.10.0-dev - sc-tracing
4.0.0-dev - sp-io
6.0.0 - sp-state-machine
0.12.0 - sp-tracing
5.0.0 - tokio-util
0.7.3 - tracing-futures
0.2.5 - tracing-gum
0.9.27 - tracing-subscriber
0.2.25
- cumulus-client-collator
tracing-attributes
0.1.22crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum11c75893af559bc8e10716548bdef5cb2b983f8e637db9d0e15126b61b484ee2depends onused bytracing-core
0.1.29crates.ioβ 2β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5aeea4303076558a00714b823f9ad67d58a3bbda1df83d8827d21193156e22f7depends ontracing-futures
0.2.5crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum97d095ae15e245a057c8e8451bab9b3ee1e1f68e9ba2b4fbc18d0ac5237835f2depends onused bytracing-gum
0.9.27github.com/paritytech/polkadotβ 4β 29sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused by- polkadot-approval-distribution
0.9.27 - polkadot-availability-bitfield-distribution
0.9.27 - polkadot-availability-distribution
0.9.27 - polkadot-availability-recovery
0.9.27 - polkadot-collator-protocol
0.9.27 - polkadot-dispute-distribution
0.9.27 - polkadot-gossip-support
0.9.27 - polkadot-network-bridge
0.9.27 - polkadot-node-collation-generation
0.9.27 - polkadot-node-core-approval-voting
0.9.27 - polkadot-node-core-av-store
0.9.27 - polkadot-node-core-backing
0.9.27 - polkadot-node-core-bitfield-signing
0.9.27 - polkadot-node-core-candidate-validation
0.9.27 - polkadot-node-core-chain-api
0.9.27 - polkadot-node-core-chain-selection
0.9.27 - polkadot-node-core-dispute-coordinator
0.9.27 - polkadot-node-core-parachains-inherent
0.9.27 - polkadot-node-core-provisioner
0.9.27 - polkadot-node-core-pvf
0.9.27 - polkadot-node-core-pvf-checker
0.9.27 - polkadot-node-core-runtime-api
0.9.27 - polkadot-node-metrics
0.9.27 - polkadot-node-network-protocol
0.9.27 - polkadot-node-subsystem-util
0.9.27 - polkadot-overseer
0.9.27 - polkadot-service
0.9.27 - polkadot-statement-distribution
0.9.27 - polkadot-test-service
0.9.27
- polkadot-approval-distribution
tracing-gum-proc-macro
0.9.27github.com/paritytech/polkadotβ 5β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feaused bytracing-log
0.1.3crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922tracing-serde
0.1.3crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbc6b213177105856957181934e4920de57730fc69bf42c37ee5bb664d406d9e1depends onused bytracing-subscriber
0.2.25crates.ioβ 15β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0e0d2eaa99c3c2e41547cfa109e910a68ea03823cccad4a0525dcbc9b01e8c71depends ontrie-db
0.23.1crates.ioβ 5β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd32d034c0d3db64b43c31de38e945f15b40cd4ca6d2dcfc26d4798ce8de4ab83trie-root
0.17.0crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9a36c5ca3911ed3c9a5416ee6c679042064b93fc637ded67e25f92e68d783891depends ontriehash
0.8.4crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma1631b201eb031b563d2e85ca18ec8092508e262a3196ce9bd10a67ec87b9f5cdepends onused bytrust-dns-proto
0.21.2crates.ioβ 16β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9c31f240f59877c3d4bb3b3ea0ec5a6a0cff07323580ff8c7a605cd7d08b255ddepends onused bytrust-dns-resolver
0.21.2crates.ioβ 11β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume4ba72c2ea84515690c9fcef4c6c660bb9df3036ed1051686de84605b74fd558depends ontry-runtime-cli
0.10.0-devgithub.com/paritytech/substrateβ 18β 2sourcegit+https://github.com/paritytech/substrate?branch=polkadot-v0.9.27#8eff668a42325aeb4433eace1604f4d286a6ec05depends on- clap
3.2.17 - jsonrpsee
0.14.0 - log
0.4.17 - parity-scale-codec
3.1.5 - remote-externalities
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-executor
0.10.0-dev - sc-service
0.10.0-dev - serde
1.0.143 - sp-core
6.0.0 - sp-externalities
0.12.0 - sp-io
6.0.0 - sp-keystore
0.12.0 - sp-runtime
6.0.0 - sp-state-machine
0.12.0 - sp-version
5.0.0 - zstd
0.11.2+zstd.1.5.2
- clap
tt-call
1.0.8crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5e66dcbec4290c69dd03c57e76c2469ea5c7ce109c6dd4351c13055cf71ea055used bytwox-hash
1.6.3crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum97fee6b57c6a41524a810daee9286c02d7752c4253064d0b05472833a438f675used bytypenum
1.15.0crates.ioβ 0β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumdcf81ac59edc17cc8697ff311e8f5ef2d99fcbd9817b34cec66f90b6c3dfd987uint
0.9.3crates.ioβ 4β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum12f03af7ccf01dd611cc450a0d10dbc9b745770d096473e2faf0ca6e2d66d1e0unicase
2.6.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum50f37be617794602aabbeee0be4f259dc1778fabe05e2d67ee8f79326d5cb4f6depends onused byunicode-bidi
0.3.8crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum099b7128301d285f79ddd55b9a83d5e6b9e97c92e0ea0daebee7263e932de992used byunicode-ident
1.0.3crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc4f5b37a154999a8f3f98cc23a628d850e154479cd94decf3414696e12e31aafused byunicode-normalization
0.1.21crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum854cbdc4f7bc6ae19c820d44abdc3277ac3e1b2b93db20a636825d9322fb60e6depends onused byunicode-width
0.1.9crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3ed742d4ea2bd1176e236172c8429aaf54486e7ac098db29ffe6529e0ce50973used byunicode-xid
0.2.3crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum957e51f3646910546462e67d5f7599b9e4fb8acdd304b087a6494730f9eebf04unique-node
0.9.27workspaceβ 82β 0depends on- clap
3.2.17 - cumulus-client-cli
0.1.0 - cumulus-client-collator
0.1.0 - cumulus-client-consensus-aura
0.1.0 - cumulus-client-consensus-common
0.1.0 - cumulus-client-network
0.1.0 - cumulus-client-service
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-parachain-inherent
0.1.0 - cumulus-relay-chain-inprocess-interface
0.1.0 - cumulus-relay-chain-interface
0.1.0 - cumulus-relay-chain-rpc-interface
0.1.0 - fc-consensus
2.0.0-dev - fc-db
2.0.0-dev - fc-mapping-sync
2.0.0-dev - fc-rpc
2.0.0-dev - fc-rpc-core
1.1.0-dev - flexi_logger
0.22.6 - fp-rpc
3.0.0-dev - frame-benchmarking
4.0.0-dev - frame-benchmarking-cli
4.0.0-dev - futures
0.3.23 - jsonrpsee
0.14.0 - log
0.4.17 - opal-runtime
0.9.27 - pallet-ethereum
4.0.0-dev - pallet-transaction-payment-rpc
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - parity-scale-codec
3.1.5 - parking_lot
0.12.1 - polkadot-cli
0.9.27 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-service
0.9.27 - polkadot-test-service
0.9.27 - quartz-runtime
0.9.27 - rmrk-rpc
0.0.2 - sc-basic-authorship
0.10.0-dev - sc-chain-spec
4.0.0-dev - sc-cli
0.10.0-dev - sc-client-api
4.0.0-dev - sc-consensus
0.10.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-manual-seal
0.10.0-dev - sc-executor
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sc-sysinfo
6.0.0-dev - sc-telemetry
4.0.0-dev - sc-tracing
4.0.0-dev - sc-transaction-pool
4.0.0-dev - serde
1.0.143 - serde_json
1.0.83 - sp-api
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-core
6.0.0 - sp-finality-grandpa
4.0.0-dev - sp-inherents
4.0.0-dev - sp-keystore
0.12.0 - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-timestamp
4.0.0-dev - sp-transaction-pool
4.0.0-dev - sp-trie
6.0.0 - substrate-build-script-utils
3.0.0 - substrate-frame-rpc-system
4.0.0-dev - substrate-prometheus-endpoint
0.10.0-dev - tokio
1.20.1 - try-runtime-cli
0.10.0-dev - unique-rpc
0.1.1 - unique-runtime
0.9.27 - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3
- clap
unique-rpc
0.1.1workspaceβ 43β 1depends on- fc-db
2.0.0-dev - fc-mapping-sync
2.0.0-dev - fc-rpc
2.0.0-dev - fc-rpc-core
1.1.0-dev - fp-rpc
3.0.0-dev - fp-storage
2.0.0 - futures
0.3.23 - jsonrpsee
0.14.0 - pallet-common
0.1.5 - pallet-ethereum
4.0.0-dev - pallet-transaction-payment-rpc
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-unique
0.1.3 - rmrk-rpc
0.0.2 - sc-client-api
4.0.0-dev - sc-consensus-aura
0.10.0-dev - sc-consensus-epochs
0.10.0-dev - sc-finality-grandpa
0.10.0-dev - sc-finality-grandpa-rpc
0.10.0-dev - sc-keystore
4.0.0-dev - sc-network
0.10.0-dev - sc-rpc
4.0.0-dev - sc-rpc-api
0.10.0-dev - sc-service
0.10.0-dev - sc-transaction-pool
4.0.0-dev - serde
1.0.143 - sp-api
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-blockchain
4.0.0-dev - sp-consensus
0.10.0-dev - sp-consensus-aura
0.10.0-dev - sp-core
6.0.0 - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-storage
6.0.0 - sp-transaction-pool
4.0.0-dev - substrate-frame-rpc-system
4.0.0-dev - tokio
1.20.1 - uc-rpc
0.1.3 - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3
used by- fc-db
unique-runtime
0.9.27workspaceβ 83β 1depends on- cumulus-pallet-aura-ext
0.1.0 - cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-core
0.1.0 - cumulus-primitives-timestamp
0.1.0 - cumulus-primitives-utility
0.1.0 - derivative
2.2.0 - evm-coder
0.1.1 - fp-evm-mapping
0.1.0 - fp-rpc
3.0.0-dev - fp-self-contained
1.0.0-dev - frame-benchmarking
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - frame-try-runtime
0.10.0-dev - hex-literal
0.3.4 - log
0.4.17 - orml-tokens
0.4.1-dev - orml-traits
0.4.1-dev - orml-vesting
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-aura
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-base-fee
1.0.0 - pallet-common
0.1.5 - pallet-configuration
0.1.1 - pallet-ethereum
4.0.0-dev - pallet-evm
6.0.0-dev - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-evm-migration
0.1.1 - pallet-evm-transaction-payment
0.1.1 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-inflation
0.1.1 - pallet-nonfungible
0.1.4 - pallet-randomness-collective-flip
4.0.0-dev - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-structure
0.1.2 - pallet-sudo
4.0.0-dev - pallet-template-transaction-payment
3.0.0 - pallet-timestamp
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-unique
0.1.3 - pallet-unique-scheduler
0.1.1 - pallet-xcm
0.9.27 - parachain-info
0.1.0 - parity-scale-codec
3.1.5 - polkadot-parachain
0.9.27 - rmrk-rpc
0.0.2 - scale-info
2.1.2 - serde
1.0.143 - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-arithmetic
5.0.0 - sp-block-builder
4.0.0-dev - sp-consensus-aura
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-std
4.0.0 - sp-transaction-pool
4.0.0-dev - sp-version
5.0.0 - substrate-wasm-builder
5.0.0-dev - up-common
0.9.27 - up-data-structs
0.2.2 - up-rpc
0.1.3 - up-sponsorship
0.1.0 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
used by- cumulus-pallet-aura-ext
universal-hash
0.4.1crates.ioβ 2β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9f214e8f697e925001e66ec2c6e37a4ef93f0f78c2eed7814394e10c62025b05depends onused byunsigned-varint
0.7.1crates.ioβ 4β 13sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd86a8dc7f45e4c1b0d30e43038c38f274e77af056aa5f74b93c2cf9eb3c1c836untrusted
0.7.1crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4aup-data-structs
0.2.2workspaceβ 12β 19depends onused by- opal-runtime
0.9.27 - pallet-common
0.1.5 - pallet-evm-coder-substrate
0.1.3 - pallet-evm-contract-helpers
0.1.2 - pallet-foreing-assets
0.1.0 - pallet-fungible
0.1.3 - pallet-nonfungible
0.1.4 - pallet-refungible
0.2.3 - pallet-rmrk-core
0.1.2 - pallet-rmrk-equip
0.1.2 - pallet-structure
0.1.2 - pallet-unique
0.1.3 - quartz-runtime
0.9.27 - tests
0.1.1 - uc-rpc
0.1.3 - unique-node
0.9.27 - unique-rpc
0.1.1 - unique-runtime
0.9.27 - up-rpc
0.1.3
- opal-runtime
up-sponsorship
0.1.0github.com/uniquenetwork/pallet-sponsoringβ 1β 8sourcegit+https://github.com/uniquenetwork/pallet-sponsoring?branch=polkadot-v0.9.27#853766d6033ceb68a2bef196790b962dd0663a04depends onurl
2.2.2crates.ioβ 4β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksuma507c383b2d33b5fc35d1861e77e6b383d158b2da5e14fe51b83dfedf6fd578cvaluable
0.1.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6dused byvalue-bag
1.0.0-alpha.9crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2209b78d1249f7e6f3293657c9779fe31ced465df091bbd433a1cf88e916ec55depends onused byvcpkg
0.2.15crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumaccd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426used byversion_check
0.9.4crates.ioβ 0β 7sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483fvoid
1.0.2crates.ioβ 0β 10sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887dwaker-fn
1.1.0crates.ioβ 0β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9d5b2c62b4012a3e1eca5a7e077d13b3bf498c4073e33ccd58626607748ceecawalkdir
2.3.2crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum808cf2735cd4b6866113f648b791c6adc5714537bc222d9347bb203386ffda56want
0.3.0crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0depends onused bywasi
0.9.0+wasi-snapshot-preview1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519used bywasi
0.10.0+wasi-snapshot-preview1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1a143597ca7c7793eff794def352d41792a93c481eb1042423ff7ff72ba2c31fused bywasi
0.11.0+wasi-snapshot-preview1crates.ioβ 0β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423wasm-bindgen
0.2.82crates.ioβ 2β 11sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfc7652e3f6c4706c8d9cd54832c4a4ccb9b5336e2c3bd154d5cccfbf1c1f5f7ddepends onwasm-bindgen-backend
0.2.82crates.ioβ 7β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum662cd44805586bd52971b9586b1df85cdbbd9112e4ef4d8f41559c334dc6ac3fdepends onwasm-bindgen-futures
0.4.32crates.ioβ 4β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumfa76fb221a1f8acddf5b54ace85912606980ad661ac7a503b4570ffd3a624dadwasm-bindgen-macro
0.2.82crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb260f13d3012071dfb1512849c033b1925038373aea48ced3012c09df952c602used bywasm-bindgen-macro-support
0.2.82crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5be8e654bdd9b79216c2929ab90721aa82faf65c48cdf08bdc4e7f51357b80daused bywasm-gc-api
0.1.11crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd0c32691b6c7e6c14e7f8fd55361a9088b507aa49620fcd06c09b3a1082186b9wasm-instrument
0.1.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum962e5b0401bbb6c887f54e69b8c496ea36f704df65db73e81fd5ff8dc3e63a9fdepends onused bywasm-timer
0.2.5crates.ioβ 7β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumbe0ecb0db480561e9a7642b5d3e4187c128914e58aa84330b9493e3eb68c5e7fdepends onwasmi
0.9.1crates.ioβ 8β 6sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumca00c5147c319a8ec91ec1a0edbec31e566ce2c9cc93b3f9bb86a9efd0eb795ddepends onwasmi-validation
0.4.1crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum165343ecd6c018fc09ebcae280752702c9a2ef3e6f8d02f1cfcbdb53ef6d7937depends onused bywasmparser
0.85.0crates.ioβ 1β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum570460c58b21e9150d2df0eaaedbb7816c34bcec009ae0dcc976e40ba81463e7depends onwasmtime
0.38.3crates.ioβ 23β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1f50eadf868ab6a04b7b511460233377d0bfbb92e417b2f6a98b98fef2e098f5depends on- anyhow
1.0.61 - backtrace
0.3.66 - bincode
1.3.3 - cfg-if
1.0.0 - indexmap
1.9.1 - lazy_static
1.4.0 - libc
0.2.131 - log
0.4.17 - object
0.28.4 - once_cell
1.13.0 - paste
1.0.8 - psm
0.1.20 - rayon
1.5.3 - region
2.2.0 - serde
1.0.143 - target-lexicon
0.12.4 - wasmparser
0.85.0 - wasmtime-cache
0.38.3 - wasmtime-cranelift
0.38.3 - wasmtime-environ
0.38.3 - wasmtime-jit
0.38.3 - wasmtime-runtime
0.38.3 - winapi
0.3.9
- anyhow
wasmtime-cache
0.38.3crates.ioβ 12β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd1df23c642e1376892f3b72f311596976979cbf8b85469680cdd3a8a063d12a2depends onused bywasmtime-cranelift
0.38.3crates.ioβ 14β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf264ff6b4df247d15584f2f53d009fbc90032cfdc2605b52b961bffc71b6eccddepends onused bywasmtime-environ
0.38.3crates.ioβ 12β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum839d2820e4b830f4b9e7aa08d4c0acabf4a5036105d639f6dfa1c6891c73bdc6depends onwasmtime-jit
0.38.3crates.ioβ 18β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumef0a0bcbfa18b946d890078ba0e1bc76bcc53eccfb40806c0020ec29dcd1bd49depends onused bywasmtime-jit-debug
0.38.3crates.ioβ 3β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4f4779d976206c458edd643d1ac622b6c37e4a0800a8b1d25dfbf245ac2f2cacdepends onwasmtime-runtime
0.38.3crates.ioβ 18β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumb7eb6ffa169eb5dcd18ac9473c817358cd57bc62c244622210566d473397954adepends onwasmtime-types
0.38.3crates.ioβ 4β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum8d932b0ac5336f7308d869703dd225610a6a3aeaa8e968c52b43eed96cefb1c2web-sys
0.3.59crates.ioβ 2β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumed055ab27f941423197eb86b2035720b1a3ce40504df082cac2ecc6ed73335a1depends onwebpki
0.22.0crates.ioβ 2β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf095d78192e208183081cc07bc5515ef55216397af48b873e5edcd72637fa1bddepends onwebpki-roots
0.22.4crates.ioβ 1β 2sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumf1c760f0d366a6c24a02ed7816e23e691f5d92291f94d15e836006fd11b04dafdepends onwepoll-ffi
0.1.2crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd743fdedc5c64377b5fc2bc036b01c7fd642205a0d96356034ae3404d49eb7fbdepends onused bywestend-runtime
0.9.27github.com/paritytech/polkadotβ 82β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends on- beefy-primitives
4.0.0-dev - bitvec
1.0.1 - frame-benchmarking
4.0.0-dev - frame-election-provider-support
4.0.0-dev - frame-executive
4.0.0-dev - frame-support
4.0.0-dev - frame-system
4.0.0-dev - frame-system-benchmarking
4.0.0-dev - frame-system-rpc-runtime-api
4.0.0-dev - frame-try-runtime
0.10.0-dev - hex-literal
0.3.4 - log
0.4.17 - pallet-authority-discovery
4.0.0-dev - pallet-authorship
4.0.0-dev - pallet-babe
4.0.0-dev - pallet-bags-list
4.0.0-dev - pallet-balances
4.0.0-dev - pallet-collective
4.0.0-dev - pallet-democracy
4.0.0-dev - pallet-election-provider-multi-phase
4.0.0-dev - pallet-election-provider-support-benchmarking
4.0.0-dev - pallet-elections-phragmen
5.0.0-dev - pallet-grandpa
4.0.0-dev - pallet-identity
4.0.0-dev - pallet-im-online
4.0.0-dev - pallet-indices
4.0.0-dev - pallet-membership
4.0.0-dev - pallet-multisig
4.0.0-dev - pallet-nomination-pools
1.0.0 - pallet-nomination-pools-benchmarking
1.0.0 - pallet-nomination-pools-runtime-api
1.0.0-dev - pallet-offences
4.0.0-dev - pallet-offences-benchmarking
4.0.0-dev - pallet-preimage
4.0.0-dev - pallet-proxy
4.0.0-dev - pallet-recovery
4.0.0-dev - pallet-scheduler
4.0.0-dev - pallet-session
4.0.0-dev - pallet-session-benchmarking
4.0.0-dev - pallet-society
4.0.0-dev - pallet-staking
4.0.0-dev - pallet-staking-reward-curve
4.0.0-dev - pallet-sudo
4.0.0-dev - pallet-timestamp
4.0.0-dev - pallet-transaction-payment
4.0.0-dev - pallet-transaction-payment-rpc-runtime-api
4.0.0-dev - pallet-treasury
4.0.0-dev - pallet-utility
4.0.0-dev - pallet-vesting
4.0.0-dev - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - parity-scale-codec
3.1.5 - polkadot-parachain
0.9.27 - polkadot-primitives
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - rustc-hex
2.1.0 - scale-info
2.1.2 - serde
1.0.143 - serde_derive
1.0.143 - smallvec
1.9.0 - sp-api
4.0.0-dev - sp-authority-discovery
4.0.0-dev - sp-block-builder
4.0.0-dev - sp-consensus-babe
0.10.0-dev - sp-core
6.0.0 - sp-inherents
4.0.0-dev - sp-io
6.0.0 - sp-mmr-primitives
4.0.0-dev - sp-npos-elections
4.0.0-dev - sp-offchain
4.0.0-dev - sp-runtime
6.0.0 - sp-session
4.0.0-dev - sp-staking
4.0.0-dev - sp-std
4.0.0 - sp-transaction-pool
4.0.0-dev - sp-version
5.0.0 - substrate-wasm-builder
5.0.0-dev - westend-runtime-constants
0.9.27 - xcm
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
used by- beefy-primitives
westend-runtime-constants
0.9.27github.com/paritytech/polkadotβ 5β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused bywhich
4.2.5crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5c4fb54e6113b6a8772ee41c3404fb0301ac79604489467e0a9ce1f3e97c24aedepends onused bywidestring
0.5.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum17882f045410753661207383517a6f62ec3dbeb6a4ed2acce01f0728238d1983used bywinapi
0.3.9crates.ioβ 2β 36sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419used by- ansi_term
0.12.1 - async-io
1.7.0 - async-process
1.4.0 - atty
0.2.14 - chrono
0.4.22 - dirs-sys
0.3.7 - dirs-sys-next
0.1.2 - errno
0.2.8 - fs-swap
0.2.6 - fs2
0.4.3 - gethostname
0.2.3 - hostname
0.3.1 - iana-time-zone
0.1.45 - if-addrs
0.7.0 - ipconfig
0.3.0 - libloading
0.5.2 - libloading
0.7.3 - parity-util-mem
0.11.0 - parking_lot_core
0.8.5 - polling
2.2.0 - region
2.2.0 - remove_dir_all
0.5.3 - ring
0.16.20 - rpassword
5.0.1 - rustix
0.33.7 - socket2
0.4.4 - tempfile
3.3.0 - time
0.1.44 - tokio
1.20.1 - walkdir
2.3.2 - wasmtime
0.38.3 - wasmtime-cache
0.38.3 - wasmtime-jit
0.38.3 - wasmtime-runtime
0.38.3 - winapi-util
0.1.5 - winreg
0.7.0
- ansi_term
winapi-i686-pc-windows-gnu
0.4.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6used bywinapi-util
0.1.5crates.ioβ 1β 3sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178depends onwinapi-x86_64-pc-windows-gnu
0.4.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183fused bywindows
0.34.0crates.ioβ 5β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum45296b64204227616fdbf2614cefa4c236b98ee64dfaaaa435207ed99fe7829fdepends onused bywindows_aarch64_msvc
0.34.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum17cffbe740121affb56fad0fc0e421804adf0ae00891205213b5cecd30db881dused bywindows_aarch64_msvc
0.36.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9bb8c3fd39ade2d67e9874ac4f3db21f0d710bee00fe7cab16949ec184eeaa47used bywindows_i686_gnu
0.34.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum2564fde759adb79129d9b4f54be42b32c89970c18ebf93124ca8870a498688edused bywindows_i686_gnu
0.36.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum180e6ccf01daf4c426b846dfc66db1fc518f074baa793aa7d9b9aaeffad6a3b6used bywindows_i686_msvc
0.34.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9cd9d32ba70453522332c14d38814bceeb747d80b3958676007acadd7e166956used bywindows_i686_msvc
0.36.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume2e7917148b2812d1eeafaeb22a97e4813dfa60a3f8f78ebe204bcc88f12f024used bywindows_x86_64_gnu
0.34.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumcfce6deae227ee8d356d19effc141a509cc503dfd1f850622ec4b0f84428e1f4used bywindows_x86_64_gnu
0.36.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum4dcd171b8776c41b97521e5da127a2d86ad280114807d0b2ab1e462bc764d9e1used bywindows_x86_64_msvc
0.34.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumd19538ccc21819d01deaf88d6a17eae6596a12e9aafdbb97916fb49896d89de9used bywindows_x86_64_msvc
0.36.1crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc811ca4a8c853ef420abd8592ba53ddbbac90410fab6903b3e79972a631f7680used bywindows-sys
0.36.1crates.ioβ 5β 5sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumea04155a16a59f9eab786fe12a4a450e75cdb175f9e0d80da1e17db09f55b8d2depends onwinreg
0.7.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum0120db82e8a1e0b9fb3345a539c478767c0048d842860994d96113d5b667bd69depends onused bywyz
0.2.0crates.ioβ 0β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum85e60b0d1b5f99db2556934e21937020776a5d31520bf169e851ac44e6420214used bywyz
0.5.0crates.ioβ 1β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum30b31594f29d27036c383b53b59ed3476874d518f0efb151b27a4c275141390edepends onused byx25519-dalek
1.1.1crates.ioβ 3β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum5a0c105152107e3b96f6a00a65e86ce82d9b125230e1c4302940eca58ff71f4fused byxcm
0.9.27github.com/paritytech/polkadotβ 7β 23sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused by- cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-parachain-system
0.1.0 - cumulus-pallet-xcm
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-utility
0.1.0 - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - orml-traits
0.4.1-dev - orml-xcm-support
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-foreing-assets
0.1.0 - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-common
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - unique-runtime
0.9.27 - westend-runtime
0.9.27 - xcm-builder
0.9.27 - xcm-executor
0.9.27
- cumulus-pallet-dmp-queue
xcm-builder
0.9.27github.com/paritytech/polkadotβ 13β 10sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onxcm-executor
0.9.27github.com/paritytech/polkadotβ 11β 18sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feadepends onused by- cumulus-pallet-dmp-queue
0.1.0 - cumulus-pallet-xcmp-queue
0.1.0 - cumulus-primitives-utility
0.1.0 - kusama-runtime
0.9.27 - opal-runtime
0.9.27 - orml-xcm-support
0.4.1-dev - orml-xtokens
0.4.1-dev - pallet-foreing-assets
0.1.0 - pallet-xcm
0.9.27 - pallet-xcm-benchmarks
0.9.27 - polkadot-runtime
0.9.27 - polkadot-runtime-parachains
0.9.27 - polkadot-test-runtime
0.9.27 - quartz-runtime
0.9.27 - rococo-runtime
0.9.27 - unique-runtime
0.9.27 - westend-runtime
0.9.27 - xcm-builder
0.9.27
- cumulus-pallet-dmp-queue
xcm-procedural
0.9.27github.com/paritytech/polkadotβ 4β 1sourcegit+https://github.com/paritytech/polkadot?branch=release-v0.9.27#b017bad50d360a1c6e3cdf9652bdb85e5f479feaused byyamux
0.10.2crates.ioβ 6β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksume5d9ba232399af1783a58d8eb26f6b5006fbefe2dc9ef36bd283324792d03ea5used byzeroize
1.5.7crates.ioβ 1β 20sourceregistry+https://github.com/rust-lang/crates.io-indexchecksumc394b5bd0c6f669e7275d9c20aa90ae064cb22e75a1cad54e1b34088034b149fdepends onused by- chacha20
0.8.2 - chacha20poly1305
0.9.1 - crypto-bigint
0.3.2 - curve25519-dalek
2.1.3 - curve25519-dalek
3.2.0 - curve25519-dalek
4.0.0-pre.1 - ed25519-dalek
1.0.1 - elliptic-curve
0.11.12 - libp2p-core
0.34.0 - libp2p-noise
0.37.0 - merlin
2.0.1 - rfc6979
0.1.0 - sc-network
0.10.0-dev - schnorrkel
0.9.1 - sec1
0.2.1 - secrecy
0.8.0 - sp-core
6.0.0 - substrate-bip39
0.4.4 - tiny-bip39
0.8.2 - x25519-dalek
1.1.1
- chacha20
zeroize_derive
1.3.2crates.ioβ 4β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum3f8f187641dad4f680d25c4bfc4225b418165984179f26ca76ec4fb6441d3a17used byzstd
0.11.2+zstd.1.5.2crates.ioβ 1β 4sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum20cc960326ece64f010d2d2107537f26dc589a6573a316bd5b1dba685fa5fde4depends onzstd-safe
5.0.2+zstd.1.5.2crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum1d2a5585e04f9eea4b2a3d1eca508c4dee9592a89ef6f450c11719da0726f4dbdepends onused byzstd-sys
2.0.1+zstd.1.5.2crates.ioβ 2β 1sourceregistry+https://github.com/rust-lang/crates.io-indexchecksum9fd07cbbc53846d9145dbffdf6dd09a7a0aa52be46741825f5c97bdd4f73f12bdepends onused by
crates/evm-coder-macros/Cargo.tomldiffbeforeafterboth--- a/crates/evm-coder-macros/Cargo.toml
+++ /dev/null
@@ -1,17 +0,0 @@
-[package]
-name = "evm-coder-macros"
-version = "0.1.0"
-license = "GPLv3"
-edition = "2021"
-
-[lib]
-proc-macro = true
-
-[dependencies]
-sha3 = "0.9.1"
-quote = "1.0"
-proc-macro2 = "1.0"
-syn = { version = "1.0", features = ["full"] }
-hex = "0.4.3"
-Inflector = "0.11.4"
-darling = "0.13.0"
crates/evm-coder-macros/src/lib.rsdiffbeforeafterboth--- a/crates/evm-coder-macros/src/lib.rs
+++ /dev/null
@@ -1,300 +0,0 @@
-// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
-// This file is part of Unique Network.
-
-// Unique Network 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.
-
-// Unique Network 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 Unique Network. If not, see <http://www.gnu.org/licenses/>.
-
-#![allow(dead_code)]
-
-use darling::FromMeta;
-use inflector::cases;
-use proc_macro::TokenStream;
-use quote::quote;
-use sha3::{Digest, Keccak256};
-use syn::{
- AttributeArgs, DeriveInput, GenericArgument, Ident, ItemImpl, Pat, Path, PathArguments,
- PathSegment, Type, parse_macro_input, spanned::Spanned,
-};
-
-mod solidity_interface;
-mod to_log;
-
-fn fn_selector_str(input: &str) -> u32 {
- let mut hasher = Keccak256::new();
- hasher.update(input.as_bytes());
- let result = hasher.finalize();
-
- let mut selector_bytes = [0; 4];
- selector_bytes.copy_from_slice(&result[0..4]);
-
- u32::from_be_bytes(selector_bytes)
-}
-
-/// Returns solidity function selector (first 4 bytes of hash) by its
-/// textual representation
-///
-/// ```ignore
-/// use evm_coder_macros::fn_selector;
-///
-/// assert_eq!(fn_selector!(transfer(address, uint256)), 0xa9059cbb);
-/// ```
-#[proc_macro]
-pub fn fn_selector(input: TokenStream) -> TokenStream {
- let input = input.to_string().replace(' ', "");
- let selector = fn_selector_str(&input);
-
- (quote! {
- #selector
- })
- .into()
-}
-
-fn event_selector_str(input: &str) -> [u8; 32] {
- let mut hasher = Keccak256::new();
- hasher.update(input.as_bytes());
- let result = hasher.finalize();
-
- let mut selector_bytes = [0; 32];
- selector_bytes.copy_from_slice(&result[0..32]);
- selector_bytes
-}
-
-/// Returns solidity topic (hash) by its textual representation
-///
-/// ```ignore
-/// use evm_coder_macros::event_topic;
-///
-/// assert_eq!(
-/// format!("{:x}", event_topic!(Transfer(address, address, uint256))),
-/// "ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
-/// );
-/// ```
-#[proc_macro]
-pub fn event_topic(stream: TokenStream) -> TokenStream {
- let input = stream.to_string().replace(' ', "");
- let selector_bytes = event_selector_str(&input);
-
- (quote! {
- ::primitive_types::H256([#(
- #selector_bytes,
- )*])
- })
- .into()
-}
-
-fn parse_path(ty: &Type) -> syn::Result<&Path> {
- match &ty {
- syn::Type::Path(pat) => {
- if let Some(qself) = &pat.qself {
- return Err(syn::Error::new(qself.ty.span(), "no receiver expected"));
- }
- Ok(&pat.path)
- }
- _ => Err(syn::Error::new(ty.span(), "expected ty to be path")),
- }
-}
-
-fn parse_path_segment(path: &Path) -> syn::Result<&PathSegment> {
- if path.segments.len() != 1 {
- return Err(syn::Error::new(
- path.span(),
- "expected path to have only segment",
- ));
- }
- let last_segment = &path.segments.last().unwrap();
- Ok(last_segment)
-}
-
-fn parse_ident_from_pat(pat: &Pat) -> syn::Result<&Ident> {
- match pat {
- Pat::Ident(i) => Ok(&i.ident),
- _ => Err(syn::Error::new(pat.span(), "expected pat ident")),
- }
-}
-
-fn parse_ident_from_segment(segment: &PathSegment, allow_generics: bool) -> syn::Result<&Ident> {
- if segment.arguments != PathArguments::None && !allow_generics {
- return Err(syn::Error::new(
- segment.arguments.span(),
- "unexpected generic type",
- ));
- }
- Ok(&segment.ident)
-}
-
-fn parse_ident_from_path(path: &Path, allow_generics: bool) -> syn::Result<&Ident> {
- let segment = parse_path_segment(path)?;
- parse_ident_from_segment(segment, allow_generics)
-}
-
-fn parse_ident_from_type(ty: &Type, allow_generics: bool) -> syn::Result<&Ident> {
- let path = parse_path(ty)?;
- parse_ident_from_path(path, allow_generics)
-}
-
-// Gets T out of Result<T>
-fn parse_result_ok(ty: &Type) -> syn::Result<&Type> {
- let path = parse_path(ty)?;
- let segment = parse_path_segment(path)?;
-
- if segment.ident != "Result" {
- return Err(syn::Error::new(
- ty.span(),
- "expected Result as return type (no renamed aliases allowed)",
- ));
- }
- let args = match &segment.arguments {
- PathArguments::AngleBracketed(e) => e,
- _ => {
- return Err(syn::Error::new(
- segment.arguments.span(),
- "missing Result generics",
- ))
- }
- };
-
- let args = &args.args;
- let arg = args.first().unwrap();
-
- let ty = match arg {
- GenericArgument::Type(ty) => ty,
- _ => {
- return Err(syn::Error::new(
- arg.span(),
- "expected first generic to be type",
- ))
- }
- };
-
- Ok(ty)
-}
-
-fn pascal_ident_to_call(ident: &Ident) -> Ident {
- let name = format!("{}Call", ident);
- Ident::new(&name, ident.span())
-}
-fn snake_ident_to_pascal(ident: &Ident) -> Ident {
- let name = ident.to_string();
- let name = cases::pascalcase::to_pascal_case(&name);
- Ident::new(&name, ident.span())
-}
-fn snake_ident_to_screaming(ident: &Ident) -> Ident {
- let name = ident.to_string();
- let name = cases::screamingsnakecase::to_screaming_snake_case(&name);
- Ident::new(&name, ident.span())
-}
-fn pascal_ident_to_snake_call(ident: &Ident) -> Ident {
- let name = ident.to_string();
- let name = cases::snakecase::to_snake_case(&name);
- let name = format!("call_{}", name);
- Ident::new(&name, ident.span())
-}
-
-/// Derives call enum implementing [`evm_coder::Callable`], [`evm_coder::Weighted`]
-/// and [`evm_coder::Call`] from impl block
-///
-/// ## Macro syntax
-///
-/// `#[solidity_interface(name, is, inline_is, events)]`
-/// - *name*: used in generated code, and for Call enum name
-/// - *is*: used to provide call inheritance, not found methods will be delegated to all contracts
-/// specified in is/inline_is
-/// - *inline_is*: same as is, but selectors for passed contracts will be used by derived ERC165
-/// implementation
-///
-/// `#[weight(value)]`
-/// Can be added to every method of impl block, used for deriving [`evm_coder::Weighted`], which
-/// is used by substrate bridge
-/// - *value*: expression, which evaluates to weight required to call this method.
-/// This expression can use call arguments to calculate non-constant execution time.
-/// This expression should evaluate faster than actual execution does, and may provide worser case
-/// than one is called
-///
-/// `#[solidity_interface(rename_selector)]`
-/// - *rename_selector*: by default, selector name will be generated by transforming method name
-/// from snake_case to camelCase. Use this option, if other naming convention is required.
-/// I.e: method `token_uri` will be automatically renamed to `tokenUri` in selector, but name
-/// required by ERC721 standard is `tokenURI`, thus we need to specify `rename_selector = "tokenURI"`
-/// explicitly
-///
-/// Also, any contract method may have doc comments, which will be automatically added to generated
-/// solidity interface definitions
-///
-/// ## Example
-///
-/// ```ignore
-/// struct SuperContract;
-/// struct InlineContract;
-/// struct Contract;
-///
-/// #[derive(ToLog)]
-/// enum ContractEvents {
-/// Event(#[indexed] uint32),
-/// }
-///
-/// #[solidity_interface(name = "MyContract", is(SuperContract), inline_is(InlineContract))]
-/// impl Contract {
-/// /// Multiply two numbers
-/// #[weight(200 + a + b)]
-/// #[solidity_interface(rename_selector = "mul")]
-/// fn mul(&mut self, a: uint32, b: uint32) -> Result<uint32> {
-/// Ok(a.checked_mul(b).ok_or("overflow")?)
-/// }
-/// }
-/// ```
-#[proc_macro_attribute]
-pub fn solidity_interface(args: TokenStream, stream: TokenStream) -> TokenStream {
- let args = parse_macro_input!(args as AttributeArgs);
- let args = solidity_interface::InterfaceInfo::from_list(&args).unwrap();
-
- let input: ItemImpl = match syn::parse(stream) {
- Ok(t) => t,
- Err(e) => return e.to_compile_error().into(),
- };
-
- let expanded = match solidity_interface::SolidityInterface::try_from(args, &input) {
- Ok(v) => v.expand(),
- Err(e) => e.to_compile_error(),
- };
-
- (quote! {
- #input
-
- #expanded
- })
- .into()
-}
-
-#[proc_macro_attribute]
-pub fn solidity(_args: TokenStream, stream: TokenStream) -> TokenStream {
- stream
-}
-#[proc_macro_attribute]
-pub fn weight(_args: TokenStream, stream: TokenStream) -> TokenStream {
- stream
-}
-
-/// ## Syntax
-///
-/// `#[indexed]`
-/// Marks this field as indexed, so it will appear in [`ethereum::Log`] topics instead of data
-#[proc_macro_derive(ToLog, attributes(indexed))]
-pub fn to_log(value: TokenStream) -> TokenStream {
- let input = parse_macro_input!(value as DeriveInput);
-
- match to_log::Events::try_from(&input) {
- Ok(e) => e.expand(),
- Err(e) => e.to_compile_error(),
- }
- .into()
-}
crates/evm-coder-macros/src/solidity_interface.rsdiffbeforeafterboth--- a/crates/evm-coder-macros/src/solidity_interface.rs
+++ /dev/null
@@ -1,1005 +0,0 @@
-// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
-// This file is part of Unique Network.
-
-// Unique Network 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.
-
-// Unique Network 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 Unique Network. If not, see <http://www.gnu.org/licenses/>.
-
-#![allow(dead_code)]
-
-use quote::quote;
-use darling::{FromMeta, ToTokens};
-use inflector::cases;
-use std::fmt::Write;
-use syn::{
- Expr, FnArg, GenericArgument, Generics, Ident, ImplItem, ImplItemMethod, ItemImpl, Lit, Meta,
- MetaNameValue, NestedMeta, PatType, Path, PathArguments, ReturnType, Type, spanned::Spanned,
- parse_str,
-};
-
-use crate::{
- fn_selector_str, parse_ident_from_pat, parse_ident_from_path, parse_path, parse_path_segment,
- parse_result_ok, pascal_ident_to_call, pascal_ident_to_snake_call, snake_ident_to_pascal,
- snake_ident_to_screaming,
-};
-
-struct Is {
- name: Ident,
- pascal_call_name: Ident,
- snake_call_name: Ident,
- via: Option<(Type, Ident)>,
-}
-impl Is {
- fn new_via(path: &Path, via: Option<(Type, Ident)>) -> syn::Result<Self> {
- let name = parse_ident_from_path(path, false)?.clone();
- Ok(Self {
- pascal_call_name: pascal_ident_to_call(&name),
- snake_call_name: pascal_ident_to_snake_call(&name),
- name,
- via,
- })
- }
- fn new(path: &Path) -> syn::Result<Self> {
- Self::new_via(path, None)
- }
-
- fn expand_call_def(&self, gen_ref: &proc_macro2::TokenStream) -> proc_macro2::TokenStream {
- let name = &self.name;
- let pascal_call_name = &self.pascal_call_name;
- quote! {
- #name(#pascal_call_name #gen_ref)
- }
- }
-
- fn expand_interface_id(&self) -> proc_macro2::TokenStream {
- let pascal_call_name = &self.pascal_call_name;
- quote! {
- interface_id ^= u32::from_be_bytes(#pascal_call_name::interface_id());
- }
- }
-
- fn expand_supports_interface(
- &self,
- generics: &proc_macro2::TokenStream,
- ) -> proc_macro2::TokenStream {
- let pascal_call_name = &self.pascal_call_name;
- quote! {
- <#pascal_call_name #generics>::supports_interface(interface_id)
- }
- }
-
- fn expand_variant_weight(&self) -> proc_macro2::TokenStream {
- let name = &self.name;
- quote! {
- Self::#name(call) => call.weight()
- }
- }
-
- fn expand_variant_call(
- &self,
- call_name: &proc_macro2::Ident,
- generics: &proc_macro2::TokenStream,
- ) -> proc_macro2::TokenStream {
- let name = &self.name;
- let pascal_call_name = &self.pascal_call_name;
- let via_typ = self
- .via
- .as_ref()
- .map(|(t, _)| quote! {#t})
- .unwrap_or_else(|| quote! {Self});
- let via_map = self
- .via
- .as_ref()
- .map(|(_, i)| quote! {.#i()})
- .unwrap_or_default();
- quote! {
- #call_name::#name(call) => return <#via_typ as ::evm_coder::Callable<#pascal_call_name #generics>>::call(self #via_map, Msg {
- call,
- caller: c.caller,
- value: c.value,
- })
- }
- }
-
- fn expand_parse(&self, generics: &proc_macro2::TokenStream) -> proc_macro2::TokenStream {
- let name = &self.name;
- let pascal_call_name = &self.pascal_call_name;
- quote! {
- if let Some(parsed_call) = <#pascal_call_name #generics>::parse(method_id, reader)? {
- return Ok(Some(Self::#name(parsed_call)))
- }
- }
- }
-
- fn expand_generator(&self, generics: &proc_macro2::TokenStream) -> proc_macro2::TokenStream {
- let pascal_call_name = &self.pascal_call_name;
- quote! {
- <#pascal_call_name #generics>::generate_solidity_interface(tc, is_impl);
- }
- }
-
- fn expand_event_generator(&self) -> proc_macro2::TokenStream {
- let name = &self.name;
- quote! {
- #name::generate_solidity_interface(tc, is_impl);
- }
- }
-}
-
-#[derive(Default)]
-struct IsList(Vec<Is>);
-impl FromMeta for IsList {
- fn from_list(items: &[NestedMeta]) -> darling::Result<Self> {
- let mut out = Vec::new();
- for item in items {
- match item {
- NestedMeta::Meta(Meta::Path(path)) => out.push(Is::new(path)?),
- // TODO: replace meta parsing with manual
- NestedMeta::Meta(Meta::List(list))
- if list.path.is_ident("via") && list.nested.len() == 3 =>
- {
- let mut data = list.nested.iter();
- let typ = match data.next().expect("len == 3") {
- NestedMeta::Lit(Lit::Str(s)) => {
- let v = s.value();
- let typ: Type = parse_str(&v)?;
- typ
- }
- _ => {
- return Err(syn::Error::new(
- item.span(),
- "via typ should be type in string",
- )
- .into())
- }
- };
- let via = match data.next().expect("len == 3") {
- NestedMeta::Meta(Meta::Path(path)) => path
- .get_ident()
- .ok_or_else(|| syn::Error::new(item.span(), "via should be ident"))?,
- _ => return Err(syn::Error::new(item.span(), "via should be ident").into()),
- };
- let path = match data.next().expect("len == 3") {
- NestedMeta::Meta(Meta::Path(path)) => path,
- _ => return Err(syn::Error::new(item.span(), "path should be path").into()),
- };
-
- out.push(Is::new_via(path, Some((typ, via.clone())))?)
- }
- _ => {
- return Err(syn::Error::new(
- item.span(),
- "expected either Name or via(\"Type\", getter, Name)",
- )
- .into())
- }
- }
- }
- Ok(Self(out))
- }
-}
-
-#[derive(FromMeta)]
-pub struct InterfaceInfo {
- name: Ident,
- #[darling(default)]
- is: IsList,
- #[darling(default)]
- inline_is: IsList,
- #[darling(default)]
- events: IsList,
-}
-
-#[derive(FromMeta)]
-struct MethodInfo {
- #[darling(default)]
- rename_selector: Option<String>,
-}
-
-enum AbiType {
- // type
- Plain(Ident),
- // (type1,type2)
- Tuple(Vec<AbiType>),
- // type[]
- Vec(Box<AbiType>),
- // type[20]
- Array(Box<AbiType>, usize),
-}
-impl AbiType {
- fn try_from(value: &Type) -> syn::Result<Self> {
- let value = Self::try_maybe_special_from(value)?;
- if value.is_special() {
- return Err(syn::Error::new(value.span(), "unexpected special type"));
- }
- Ok(value)
- }
- fn try_maybe_special_from(value: &Type) -> syn::Result<Self> {
- match value {
- Type::Array(arr) => {
- let wrapped = AbiType::try_from(&arr.elem)?;
- match &arr.len {
- Expr::Lit(l) => match &l.lit {
- Lit::Int(i) => {
- let num = i.base10_parse::<usize>()?;
- Ok(AbiType::Array(Box::new(wrapped), num as usize))
- }
- _ => Err(syn::Error::new(arr.len.span(), "should be int literal")),
- },
- _ => Err(syn::Error::new(arr.len.span(), "should be literal")),
- }
- }
- Type::Path(_) => {
- let path = parse_path(value)?;
- let segment = parse_path_segment(path)?;
- if segment.ident == "Vec" {
- let args = match &segment.arguments {
- PathArguments::AngleBracketed(e) => e,
- _ => {
- return Err(syn::Error::new(
- segment.arguments.span(),
- "missing Vec generic",
- ))
- }
- };
- let args = &args.args;
- if args.len() != 1 {
- return Err(syn::Error::new(
- args.span(),
- "expected only one generic for vec",
- ));
- }
- let arg = args.first().unwrap();
-
- let ty = match arg {
- GenericArgument::Type(ty) => ty,
- _ => {
- return Err(syn::Error::new(
- arg.span(),
- "expected first generic to be type",
- ))
- }
- };
-
- let wrapped = AbiType::try_from(ty)?;
- Ok(Self::Vec(Box::new(wrapped)))
- } else {
- if !segment.arguments.is_empty() {
- return Err(syn::Error::new(
- segment.arguments.span(),
- "unexpected generic arguments for non-vec type",
- ));
- }
- Ok(Self::Plain(segment.ident.clone()))
- }
- }
- Type::Tuple(t) => {
- let mut out = Vec::with_capacity(t.elems.len());
- for el in t.elems.iter() {
- out.push(AbiType::try_from(el)?)
- }
- Ok(Self::Tuple(out))
- }
- _ => Err(syn::Error::new(
- value.span(),
- "unexpected type, only arrays, plain types and tuples are supported",
- )),
- }
- }
- fn is_value(&self) -> bool {
- matches!(self, Self::Plain(v) if v == "value")
- }
- fn is_caller(&self) -> bool {
- matches!(self, Self::Plain(v) if v == "caller")
- }
- fn is_special(&self) -> bool {
- self.is_caller() || self.is_value()
- }
- fn selector_ty_buf(&self, buf: &mut String) -> std::fmt::Result {
- match self {
- AbiType::Plain(t) => {
- write!(buf, "{}", t)
- }
- AbiType::Tuple(t) => {
- write!(buf, "(")?;
- for (i, t) in t.iter().enumerate() {
- if i != 0 {
- write!(buf, ",")?;
- }
- t.selector_ty_buf(buf)?;
- }
- write!(buf, ")")
- }
- AbiType::Vec(v) => {
- v.selector_ty_buf(buf)?;
- write!(buf, "[]")
- }
- AbiType::Array(v, len) => {
- v.selector_ty_buf(buf)?;
- write!(buf, "[{}]", len)
- }
- }
- }
- fn selector_ty(&self) -> String {
- let mut out = String::new();
- self.selector_ty_buf(&mut out).expect("no fmt error");
- out
- }
-}
-impl ToTokens for AbiType {
- fn to_tokens(&self, tokens: &mut proc_macro2::TokenStream) {
- match self {
- AbiType::Plain(t) => tokens.extend(quote! {#t}),
- AbiType::Tuple(t) => {
- tokens.extend(quote! {(
- #(#t),*
- )});
- }
- AbiType::Vec(v) => tokens.extend(quote! {Vec<#v>}),
- AbiType::Array(v, l) => tokens.extend(quote! {[#v; #l]}),
- }
- }
-}
-
-struct MethodArg {
- name: Ident,
- camel_name: String,
- ty: AbiType,
-}
-impl MethodArg {
- fn try_from(value: &PatType) -> syn::Result<Self> {
- let name = parse_ident_from_pat(&value.pat)?.clone();
- Ok(Self {
- camel_name: cases::camelcase::to_camel_case(&name.to_string()),
- name,
- ty: AbiType::try_maybe_special_from(&value.ty)?,
- })
- }
- fn is_value(&self) -> bool {
- self.ty.is_value()
- }
- fn is_caller(&self) -> bool {
- self.ty.is_caller()
- }
- fn is_special(&self) -> bool {
- self.ty.is_special()
- }
- fn selector_ty(&self) -> String {
- assert!(!self.is_special());
- self.ty.selector_ty()
- }
-
- fn expand_call_def(&self) -> proc_macro2::TokenStream {
- assert!(!self.is_special());
- let name = &self.name;
- let ty = &self.ty;
-
- quote! {
- #name: #ty
- }
- }
-
- fn expand_parse(&self) -> proc_macro2::TokenStream {
- assert!(!self.is_special());
- let name = &self.name;
- quote! {
- #name: reader.abi_read()?
- }
- }
-
- fn expand_call_arg(&self) -> proc_macro2::TokenStream {
- if self.is_value() {
- quote! {
- c.value.clone()
- }
- } else if self.is_caller() {
- quote! {
- c.caller.clone()
- }
- } else {
- let name = &self.name;
- quote! {
- #name
- }
- }
- }
-
- fn expand_solidity_argument(&self) -> proc_macro2::TokenStream {
- let camel_name = &self.camel_name.to_string();
- let ty = &self.ty;
- quote! {
- <NamedArgument<#ty>>::new(#camel_name)
- }
- }
-}
-
-#[derive(PartialEq)]
-enum Mutability {
- Mutable,
- View,
- Pure,
-}
-
-pub struct WeightAttr(syn::Expr);
-
-mod keyword {
- syn::custom_keyword!(weight);
-}
-
-impl syn::parse::Parse for WeightAttr {
- fn parse(input: syn::parse::ParseStream) -> syn::Result<Self> {
- input.parse::<syn::Token![#]>()?;
- let content;
- syn::bracketed!(content in input);
- content.parse::<keyword::weight>()?;
-
- let weight_content;
- syn::parenthesized!(weight_content in content);
- Ok(WeightAttr(weight_content.parse::<syn::Expr>()?))
- }
-}
-
-struct Method {
- name: Ident,
- camel_name: String,
- pascal_name: Ident,
- screaming_name: Ident,
- selector_str: String,
- selector: u32,
- args: Vec<MethodArg>,
- has_normal_args: bool,
- mutability: Mutability,
- result: Type,
- weight: Option<Expr>,
- docs: Vec<String>,
-}
-impl Method {
- fn try_from(value: &ImplItemMethod) -> syn::Result<Self> {
- let mut info = MethodInfo {
- rename_selector: None,
- };
- let mut docs = Vec::new();
- let mut weight = None;
- for attr in &value.attrs {
- let ident = parse_ident_from_path(&attr.path, false)?;
- if ident == "solidity" {
- let args = attr.parse_meta().unwrap();
- info = MethodInfo::from_meta(&args).unwrap();
- } else if ident == "doc" {
- let args = attr.parse_meta().unwrap();
- let value = match args {
- Meta::NameValue(MetaNameValue {
- lit: Lit::Str(str), ..
- }) => str.value(),
- _ => unreachable!(),
- };
- docs.push(value);
- } else if ident == "weight" {
- weight = Some(syn::parse2::<WeightAttr>(attr.to_token_stream())?.0);
- }
- }
- let ident = &value.sig.ident;
- let ident_str = ident.to_string();
- if !cases::snakecase::is_snake_case(&ident_str) {
- return Err(syn::Error::new(ident.span(), "method name should be snake_cased\nif alternative solidity name needs to be set - use #[solidity] attribute"));
- }
-
- let mut mutability = Mutability::Pure;
-
- if let Some(FnArg::Receiver(receiver)) = value
- .sig
- .inputs
- .iter()
- .find(|arg| matches!(arg, FnArg::Receiver(_)))
- {
- if receiver.reference.is_none() {
- return Err(syn::Error::new(
- receiver.span(),
- "receiver should be by ref",
- ));
- }
- if receiver.mutability.is_some() {
- mutability = Mutability::Mutable;
- } else {
- mutability = Mutability::View;
- }
- }
- let mut args = Vec::new();
- for typ in value
- .sig
- .inputs
- .iter()
- .filter(|arg| matches!(arg, FnArg::Typed(_)))
- {
- let typ = match typ {
- FnArg::Typed(typ) => typ,
- _ => unreachable!(),
- };
- args.push(MethodArg::try_from(typ)?);
- }
-
- if mutability != Mutability::Mutable && args.iter().any(|arg| arg.is_value()) {
- return Err(syn::Error::new(
- args.iter().find(|arg| arg.is_value()).unwrap().ty.span(),
- "payable function should be mutable",
- ));
- }
-
- let result = match &value.sig.output {
- ReturnType::Type(_, ty) => ty,
- _ => return Err(syn::Error::new(value.sig.output.span(), "interface method should return Result<value>\nif there is no value to return - specify void (which is alias to unit)")),
- };
- let result = parse_result_ok(result)?;
-
- let camel_name = info
- .rename_selector
- .unwrap_or_else(|| cases::camelcase::to_camel_case(&ident.to_string()));
- let mut selector_str = camel_name.clone();
- selector_str.push('(');
- let mut has_normal_args = false;
- for (i, arg) in args.iter().filter(|arg| !arg.is_special()).enumerate() {
- if i != 0 {
- selector_str.push(',');
- }
- write!(selector_str, "{}", arg.selector_ty()).unwrap();
- has_normal_args = true;
- }
- selector_str.push(')');
- let selector = fn_selector_str(&selector_str);
-
- Ok(Self {
- name: ident.clone(),
- camel_name,
- pascal_name: snake_ident_to_pascal(ident),
- screaming_name: snake_ident_to_screaming(ident),
- selector_str,
- selector,
- args,
- has_normal_args,
- mutability,
- result: result.clone(),
- weight,
- docs,
- })
- }
- fn expand_call_def(&self) -> proc_macro2::TokenStream {
- let defs = self
- .args
- .iter()
- .filter(|a| !a.is_special())
- .map(|a| a.expand_call_def());
- let pascal_name = &self.pascal_name;
-
- if self.has_normal_args {
- quote! {
- #pascal_name {
- #(
- #defs,
- )*
- }
- }
- } else {
- quote! {#pascal_name}
- }
- }
-
- fn expand_const(&self) -> proc_macro2::TokenStream {
- let screaming_name = &self.screaming_name;
- let selector = u32::to_be_bytes(self.selector);
- let selector_str = &self.selector_str;
- quote! {
- #[doc = #selector_str]
- const #screaming_name: ::evm_coder::types::bytes4 = [#(#selector,)*];
- }
- }
-
- fn expand_interface_id(&self) -> proc_macro2::TokenStream {
- let screaming_name = &self.screaming_name;
- quote! {
- interface_id ^= u32::from_be_bytes(Self::#screaming_name);
- }
- }
-
- fn expand_parse(&self) -> proc_macro2::TokenStream {
- let pascal_name = &self.pascal_name;
- let screaming_name = &self.screaming_name;
- if self.has_normal_args {
- let parsers = self
- .args
- .iter()
- .filter(|a| !a.is_special())
- .map(|a| a.expand_parse());
- quote! {
- Self::#screaming_name => return Ok(Some(Self::#pascal_name {
- #(
- #parsers,
- )*
- }))
- }
- } else {
- quote! { Self::#screaming_name => return Ok(Some(Self::#pascal_name)) }
- }
- }
-
- fn expand_variant_call(&self, call_name: &proc_macro2::Ident) -> proc_macro2::TokenStream {
- let pascal_name = &self.pascal_name;
- let name = &self.name;
-
- let matcher = if self.has_normal_args {
- let names = self
- .args
- .iter()
- .filter(|a| !a.is_special())
- .map(|a| &a.name);
-
- quote! {{
- #(
- #names,
- )*
- }}
- } else {
- quote! {}
- };
-
- let receiver = match self.mutability {
- Mutability::Mutable | Mutability::View => quote! {self.},
- Mutability::Pure => quote! {Self::},
- };
- let args = self.args.iter().map(|a| a.expand_call_arg());
-
- quote! {
- #call_name::#pascal_name #matcher => {
- let result = #receiver #name(
- #(
- #args,
- )*
- )?;
- (&result).to_result()
- }
- }
- }
-
- fn expand_variant_weight(&self) -> proc_macro2::TokenStream {
- let pascal_name = &self.pascal_name;
- if let Some(weight) = &self.weight {
- let matcher = if self.has_normal_args {
- let names = self
- .args
- .iter()
- .filter(|a| !a.is_special())
- .map(|a| &a.name);
-
- quote! {{
- #(
- #names,
- )*
- }}
- } else {
- quote! {}
- };
- quote! {
- Self::#pascal_name #matcher => (#weight).into()
- }
- } else {
- let matcher = if self.has_normal_args {
- quote! {{..}}
- } else {
- quote! {}
- };
- quote! {
- Self::#pascal_name #matcher => ().into()
- }
- }
- }
-
- fn expand_solidity_function(&self) -> proc_macro2::TokenStream {
- let camel_name = &self.camel_name;
- let mutability = match self.mutability {
- Mutability::Mutable => quote! {SolidityMutability::Mutable},
- Mutability::View => quote! { SolidityMutability::View },
- Mutability::Pure => quote! {SolidityMutability::Pure},
- };
- let result = &self.result;
-
- let args = self
- .args
- .iter()
- .filter(|a| !a.is_special())
- .map(MethodArg::expand_solidity_argument);
- let docs = self.docs.iter();
- let selector = format!("{} {:0>8x}", self.selector_str, self.selector);
-
- quote! {
- SolidityFunction {
- docs: &[#(#docs),*],
- selector: #selector,
- name: #camel_name,
- mutability: #mutability,
- args: (
- #(
- #args,
- )*
- ),
- result: <UnnamedArgument<#result>>::default(),
- }
- }
- }
-}
-
-fn generics_list(gen: &Generics) -> proc_macro2::TokenStream {
- if gen.params.is_empty() {
- return quote! {};
- }
- let params = gen.params.iter().map(|p| match p {
- syn::GenericParam::Type(id) => {
- let v = &id.ident;
- quote! {#v}
- }
- syn::GenericParam::Lifetime(lt) => {
- let v = <.lifetime;
- quote! {#v}
- }
- syn::GenericParam::Const(c) => {
- let i = &c.ident;
- quote! {#i}
- }
- });
- quote! { #(#params),* }
-}
-fn generics_reference(gen: &Generics) -> proc_macro2::TokenStream {
- if gen.params.is_empty() {
- return quote! {};
- }
- let list = generics_list(gen);
- quote! { <#list> }
-}
-fn generics_data(gen: &Generics) -> proc_macro2::TokenStream {
- let list = generics_list(gen);
- if gen.params.len() == 1 {
- quote! {#list}
- } else {
- quote! { (#list) }
- }
-}
-
-pub struct SolidityInterface {
- generics: Generics,
- name: Box<syn::Type>,
- info: InterfaceInfo,
- methods: Vec<Method>,
-}
-impl SolidityInterface {
- pub fn try_from(info: InterfaceInfo, value: &ItemImpl) -> syn::Result<Self> {
- let mut methods = Vec::new();
-
- for item in &value.items {
- if let ImplItem::Method(method) = item {
- methods.push(Method::try_from(method)?)
- }
- }
- Ok(Self {
- generics: value.generics.clone(),
- name: value.self_ty.clone(),
- info,
- methods,
- })
- }
- pub fn expand(self) -> proc_macro2::TokenStream {
- let name = self.name;
-
- let solidity_name = self.info.name.to_string();
- let call_name = pascal_ident_to_call(&self.info.name);
- let generics = self.generics;
- let gen_ref = generics_reference(&generics);
- let gen_data = generics_data(&generics);
- let gen_where = &generics.where_clause;
-
- let call_sub = self
- .info
- .inline_is
- .0
- .iter()
- .chain(self.info.is.0.iter())
- .map(|c| Is::expand_call_def(c, &gen_ref));
- let call_parse = self
- .info
- .inline_is
- .0
- .iter()
- .chain(self.info.is.0.iter())
- .map(|is| Is::expand_parse(is, &gen_ref));
- let call_variants = self
- .info
- .inline_is
- .0
- .iter()
- .chain(self.info.is.0.iter())
- .map(|c| Is::expand_variant_call(c, &call_name, &gen_ref));
- let weight_variants = self
- .info
- .inline_is
- .0
- .iter()
- .chain(self.info.is.0.iter())
- .map(Is::expand_variant_weight);
-
- let inline_interface_id = self.info.inline_is.0.iter().map(Is::expand_interface_id);
- let supports_interface = self
- .info
- .is
- .0
- .iter()
- .map(|is| Is::expand_supports_interface(is, &gen_ref));
-
- let calls = self.methods.iter().map(Method::expand_call_def);
- let consts = self.methods.iter().map(Method::expand_const);
- let interface_id = self.methods.iter().map(Method::expand_interface_id);
- let parsers = self.methods.iter().map(Method::expand_parse);
- let call_variants_this = self
- .methods
- .iter()
- .map(|m| Method::expand_variant_call(m, &call_name));
- let weight_variants_this = self.methods.iter().map(Method::expand_variant_weight);
- let solidity_functions = self.methods.iter().map(Method::expand_solidity_function);
-
- // TODO: Inline inline_is
- let solidity_is = self
- .info
- .is
- .0
- .iter()
- .chain(self.info.inline_is.0.iter())
- .map(|is| is.name.to_string());
- let solidity_events_is = self.info.events.0.iter().map(|is| is.name.to_string());
- let solidity_generators = self
- .info
- .is
- .0
- .iter()
- .chain(self.info.inline_is.0.iter())
- .map(|is| Is::expand_generator(is, &gen_ref));
- let solidity_event_generators = self.info.events.0.iter().map(Is::expand_event_generator);
-
- // let methods = self.methods.iter().map(Method::solidity_def);
-
- quote! {
- #[derive(Debug)]
- pub enum #call_name #gen_ref {
- ERC165Call(::evm_coder::ERC165Call, ::core::marker::PhantomData<#gen_data>),
- #(
- #calls,
- )*
- #(
- #call_sub,
- )*
- }
- impl #gen_ref #call_name #gen_ref {
- #(
- #consts
- )*
- pub fn interface_id() -> ::evm_coder::types::bytes4 {
- let mut interface_id = 0;
- #(#interface_id)*
- #(#inline_interface_id)*
- u32::to_be_bytes(interface_id)
- }
- pub fn supports_interface(interface_id: ::evm_coder::types::bytes4) -> bool {
- interface_id != u32::to_be_bytes(0xffffff) && (
- interface_id == ::evm_coder::ERC165Call::INTERFACE_ID ||
- interface_id == Self::interface_id()
- #(
- || #supports_interface
- )*
- )
- }
- pub fn generate_solidity_interface(tc: &evm_coder::solidity::TypeCollector, is_impl: bool) {
- use evm_coder::solidity::*;
- use core::fmt::Write;
- let interface = SolidityInterface {
- name: #solidity_name,
- selector: Self::interface_id(),
- is: &["Dummy", "ERC165", #(
- #solidity_is,
- )* #(
- #solidity_events_is,
- )* ],
- functions: (#(
- #solidity_functions,
- )*),
- };
- if is_impl {
- tc.collect("// Common stubs holder\ncontract Dummy {\n\tuint8 dummy;\n\tstring stub_error = \"this contract is implemented in native\";\n}\ncontract ERC165 is Dummy {\n\tfunction supportsInterface(bytes4 interfaceID) external view returns (bool) {\n\t\trequire(false, stub_error);\n\t\tinterfaceID;\n\t\treturn true;\n\t}\n}\n".into());
- } else {
- tc.collect("// Common stubs holder\ninterface Dummy {\n}\ninterface ERC165 is Dummy {\n\tfunction supportsInterface(bytes4 interfaceID) external view returns (bool);\n}\n".into());
- }
- #(
- #solidity_generators
- )*
- #(
- #solidity_event_generators
- )*
-
- let mut out = string::new();
- // In solidity interface usage (is) should be preceeded by interface definition
- // This comment helps to sort it in a set
- if #solidity_name.starts_with("Inline") {
- out.push_str("// Inline\n");
- }
- let _ = interface.format(is_impl, &mut out, tc);
- tc.collect(out);
- }
- }
- impl #gen_ref ::evm_coder::Call for #call_name #gen_ref {
- fn parse(method_id: ::evm_coder::types::bytes4, reader: &mut ::evm_coder::abi::AbiReader) -> ::evm_coder::execution::Result<Option<Self>> {
- use ::evm_coder::abi::AbiRead;
- match method_id {
- ::evm_coder::ERC165Call::INTERFACE_ID => return Ok(
- ::evm_coder::ERC165Call::parse(method_id, reader)?
- .map(|c| Self::ERC165Call(c, ::core::marker::PhantomData))
- ),
- #(
- #parsers,
- )*
- _ => {},
- }
- #(
- #call_parse
- )else*
- return Ok(None);
- }
- }
- impl #generics ::evm_coder::Weighted for #call_name #gen_ref
- #gen_where
- {
- #[allow(unused_variables)]
- fn weight(&self) -> ::evm_coder::execution::DispatchInfo {
- match self {
- #(
- #weight_variants,
- )*
- // TODO: It should be very cheap, but not free
- Self::ERC165Call(::evm_coder::ERC165Call::SupportsInterface {..}, _) => 100u64.into(),
- #(
- #weight_variants_this,
- )*
- }
- }
- }
- impl #generics ::evm_coder::Callable<#call_name #gen_ref> for #name
- #gen_where
- {
- #[allow(unreachable_code)] // In case of no inner calls
- fn call(&mut self, c: Msg<#call_name #gen_ref>) -> ::evm_coder::execution::ResultWithPostInfo<::evm_coder::abi::AbiWriter> {
- use ::evm_coder::abi::AbiWrite;
- match c.call {
- #(
- #call_variants,
- )*
- #call_name::ERC165Call(::evm_coder::ERC165Call::SupportsInterface {interface_id}, _) => {
- let mut writer = ::evm_coder::abi::AbiWriter::default();
- writer.bool(&<#call_name #gen_ref>::supports_interface(interface_id));
- return Ok(writer.into());
- }
- _ => {},
- }
- let mut writer = ::evm_coder::abi::AbiWriter::default();
- match c.call {
- #(
- #call_variants_this,
- )*
- _ => unreachable!()
- }
- }
- }
- }
- }
-}
crates/evm-coder-macros/src/to_log.rsdiffbeforeafterboth--- a/crates/evm-coder-macros/src/to_log.rs
+++ /dev/null
@@ -1,237 +0,0 @@
-// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
-// This file is part of Unique Network.
-
-// Unique Network 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.
-
-// Unique Network 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 Unique Network. If not, see <http://www.gnu.org/licenses/>.
-
-use inflector::cases;
-use syn::{Data, DeriveInput, Field, Fields, Ident, Variant, spanned::Spanned};
-use std::fmt::Write;
-use quote::quote;
-
-use crate::{parse_ident_from_path, parse_ident_from_type, snake_ident_to_screaming};
-
-struct EventField {
- name: Ident,
- camel_name: String,
- ty: Ident,
- indexed: bool,
-}
-
-impl EventField {
- fn try_from(field: &Field) -> syn::Result<Self> {
- let name = field.ident.as_ref().unwrap();
- let ty = parse_ident_from_type(&field.ty, false)?;
- let mut indexed = false;
- for attr in &field.attrs {
- if let Ok(ident) = parse_ident_from_path(&attr.path, false) {
- if ident == "indexed" {
- indexed = true;
- }
- }
- }
- Ok(Self {
- name: name.to_owned(),
- camel_name: cases::camelcase::to_camel_case(&name.to_string()),
- ty: ty.to_owned(),
- indexed,
- })
- }
- fn expand_solidity_argument(&self) -> proc_macro2::TokenStream {
- let camel_name = &self.camel_name;
- let ty = &self.ty;
- let indexed = self.indexed;
- quote! {
- <SolidityEventArgument<#ty>>::new(#indexed, #camel_name)
- }
- }
-}
-
-struct Event {
- name: Ident,
- name_screaming: Ident,
- fields: Vec<EventField>,
- selector: [u8; 32],
- selector_str: String,
-}
-
-impl Event {
- fn try_from(variant: &Variant) -> syn::Result<Self> {
- let name = &variant.ident;
- let name_screaming = snake_ident_to_screaming(name);
-
- let named = match &variant.fields {
- Fields::Named(named) => named,
- _ => {
- return Err(syn::Error::new(
- variant.fields.span(),
- "expected named fields",
- ))
- }
- };
- let mut fields = Vec::new();
- for field in &named.named {
- fields.push(EventField::try_from(field)?);
- }
- if fields.iter().filter(|f| f.indexed).count() > 3 {
- return Err(syn::Error::new(
- variant.fields.span(),
- "events can have at most 4 indexed fields (1 indexed field is reserved for event signature)"
- ));
- }
- let mut selector_str = format!("{}(", name);
- for (i, arg) in fields.iter().enumerate() {
- if i != 0 {
- write!(selector_str, ",").unwrap();
- }
- write!(selector_str, "{}", arg.ty).unwrap();
- }
- selector_str.push(')');
- let selector = crate::event_selector_str(&selector_str);
-
- Ok(Self {
- name: name.to_owned(),
- name_screaming,
- fields,
- selector,
- selector_str,
- })
- }
-
- fn expand_serializers(&self) -> proc_macro2::TokenStream {
- let name = &self.name;
- let name_screaming = &self.name_screaming;
- let fields = self.fields.iter().map(|f| &f.name);
-
- let indexed = self.fields.iter().filter(|f| f.indexed).map(|f| &f.name);
- let plain = self.fields.iter().filter(|f| !f.indexed).map(|f| &f.name);
-
- quote! {
- Self::#name {#(
- #fields,
- )*} => {
- topics.push(topic::from(Self::#name_screaming));
- #(
- topics.push(#indexed.to_topic());
- )*
- #(
- #plain.abi_write(&mut writer);
- )*
- }
- }
- }
-
- fn expand_consts(&self) -> proc_macro2::TokenStream {
- let name_screaming = &self.name_screaming;
- let selector_str = &self.selector_str;
- let selector = &self.selector;
-
- quote! {
- #[doc = #selector_str]
- const #name_screaming: [u8; 32] = [#(
- #selector,
- )*];
- }
- }
-
- fn expand_solidity_function(&self) -> proc_macro2::TokenStream {
- let name = self.name.to_string();
- let args = self.fields.iter().map(EventField::expand_solidity_argument);
- quote! {
- SolidityEvent {
- name: #name,
- args: (
- #(
- #args,
- )*
- ),
- }
- }
- }
-}
-
-pub struct Events {
- name: Ident,
- events: Vec<Event>,
-}
-
-impl Events {
- pub fn try_from(data: &DeriveInput) -> syn::Result<Self> {
- let name = &data.ident;
- let en = match &data.data {
- Data::Enum(en) => en,
- _ => return Err(syn::Error::new(data.span(), "expected enum")),
- };
- let mut events = Vec::new();
- for variant in &en.variants {
- events.push(Event::try_from(variant)?);
- }
- Ok(Self {
- name: name.to_owned(),
- events,
- })
- }
- pub fn expand(&self) -> proc_macro2::TokenStream {
- let name = &self.name;
-
- let consts = self.events.iter().map(Event::expand_consts);
- let serializers = self.events.iter().map(Event::expand_serializers);
- let solidity_name = self.name.to_string();
- let solidity_functions = self.events.iter().map(Event::expand_solidity_function);
-
- quote! {
- impl #name {
- #(
- #consts
- )*
-
- pub fn generate_solidity_interface(tc: &evm_coder::solidity::TypeCollector, is_impl: bool) {
- use evm_coder::solidity::*;
- use core::fmt::Write;
- let interface = SolidityInterface {
- selector: [0; 4],
- name: #solidity_name,
- is: &[],
- functions: (#(
- #solidity_functions,
- )*),
- };
- let mut out = string::new();
- out.push_str("// Inline\n");
- let _ = interface.format(is_impl, &mut out, tc);
- tc.collect(out);
- }
- }
-
- #[automatically_derived]
- impl ::evm_coder::events::ToLog for #name {
- fn to_log(&self, contract: address) -> ::ethereum::Log {
- use ::evm_coder::events::ToTopic;
- use ::evm_coder::abi::AbiWrite;
- let mut writer = ::evm_coder::abi::AbiWriter::new();
- let mut topics = Vec::new();
- match self {
- #(
- #serializers,
- )*
- }
- ::ethereum::Log {
- address: contract,
- topics,
- data: writer.finish(),
- }
- }
- }
- }
- }
-}
crates/evm-coder/CHANGELOG.mddiffbeforeafterboth--- a/crates/evm-coder/CHANGELOG.md
+++ b/crates/evm-coder/CHANGELOG.md
@@ -1,4 +1,24 @@
+# Change Log
+
+All notable changes to this project will be documented in this file.
+
+## [0.1.3] - 2022-08-29
+
+### Fixed
+
+ - Parsing simple values.
+
<!-- bureaucrate goes here -->
+## [v0.1.2] 2022-08-19
+
+### Added
+
+ - Implementation `AbiWrite` for tuples.
+
+ ### Fixes
+
+ - Tuple generation for solidity.
+
## [v0.1.1] 2022-08-16
### Other changes
@@ -7,4 +27,4 @@
- build: Upgrade polkadot to v0.9.26 85515e54c4ca1b82a2630034e55dcc804c643bf8
-- build: Upgrade polkadot to v0.9.25 cdfb9bdc7b205ff1b5134f034ef9973d769e5e6b
\ No newline at end of file
+- build: Upgrade polkadot to v0.9.25 cdfb9bdc7b205ff1b5134f034ef9973d769e5e6b
crates/evm-coder/Cargo.tomldiffbeforeafterboth--- a/crates/evm-coder/Cargo.toml
+++ b/crates/evm-coder/Cargo.toml
@@ -1,19 +1,26 @@
[package]
name = "evm-coder"
-version = "0.1.1"
+version = "0.1.3"
license = "GPLv3"
edition = "2021"
[dependencies]
-evm-coder-macros = { path = "../evm-coder-macros" }
+# evm-coder reexports those proc-macro
+evm-coder-procedural = { path = "./procedural" }
+# Evm uses primitive-types for H160, H256 and others
primitive-types = { version = "0.11.1", default-features = false }
-hex-literal = "0.3.3"
+# Evm doesn't have reexports for log and others
ethereum = { version = "0.12.0", default-features = false }
-evm-core = { default-features = false, git = "https://github.com/uniquenetwork/evm", branch = "unique-polkadot-v0.9.27" }
-impl-trait-for-tuples = "0.2.1"
+sp-std = { default-features = false, git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.27" }
+# Error types for execution
+evm-core = { default-features = false , git = "https://github.com/uniquenetwork/evm", branch = "unique-polkadot-v0.9.27" }
+# We have tuple-heavy code in solidity.rs
+impl-trait-for-tuples = "0.2.2"
[dev-dependencies]
+# We want to assert some large binary blobs equality in tests
hex = "0.4.3"
+hex-literal = "0.3.4"
[features]
default = ["std"]
crates/evm-coder/README.mddiffbeforeafterboth--- /dev/null
+++ b/crates/evm-coder/README.md
@@ -0,0 +1,15 @@
+# evm-coder
+
+Library for seamless call translation between Rust and Solidity code
+
+By encoding solidity definitions in Rust, this library also provides generation of
+solidity interfaces for ethereum developers
+
+## Overview
+
+Most of this library functionality shouldn't be used directly, but via macros
+
+- [`solidity_interface`]
+- [`ToLog`]
+
+<!-- TODO: make links useable on github, by publishing crate to docs.rs, and linking it from here instead -->
\ No newline at end of file
crates/evm-coder/procedural/Cargo.tomldiffbeforeafterboth--- /dev/null
+++ b/crates/evm-coder/procedural/Cargo.toml
@@ -0,0 +1,19 @@
+[package]
+name = "evm-coder-procedural"
+version = "0.2.0"
+license = "GPLv3"
+edition = "2021"
+
+[lib]
+proc-macro = true
+
+[dependencies]
+# Ethereum uses keccak (=sha3) for selectors
+sha3 = "0.10.1"
+# Value formatting
+hex = "0.4.3"
+Inflector = "0.11.4"
+# General proc-macro utilities
+quote = "1.0"
+proc-macro2 = "1.0"
+syn = { version = "1.0", features = ["full"] }
crates/evm-coder/procedural/src/lib.rsdiffbeforeafterboth--- /dev/null
+++ b/crates/evm-coder/procedural/src/lib.rs
@@ -0,0 +1,244 @@
+// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
+// This file is part of Unique Network.
+
+// Unique Network 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.
+
+// Unique Network 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 Unique Network. If not, see <http://www.gnu.org/licenses/>.
+
+#![allow(dead_code)]
+
+use inflector::cases;
+use proc_macro::TokenStream;
+use quote::quote;
+use sha3::{Digest, Keccak256};
+use syn::{
+ DeriveInput, GenericArgument, Ident, ItemImpl, Pat, Path, PathArguments, PathSegment, Type,
+ parse_macro_input, spanned::Spanned,
+};
+
+mod solidity_interface;
+mod to_log;
+
+fn fn_selector_str(input: &str) -> u32 {
+ let mut hasher = Keccak256::new();
+ hasher.update(input.as_bytes());
+ let result = hasher.finalize();
+
+ let mut selector_bytes = [0; 4];
+ selector_bytes.copy_from_slice(&result[0..4]);
+
+ u32::from_be_bytes(selector_bytes)
+}
+
+/// Returns solidity function selector (first 4 bytes of hash) by its
+/// textual representation
+///
+/// ```ignore
+/// use evm_coder_macros::fn_selector;
+///
+/// assert_eq!(fn_selector!(transfer(address, uint256)), 0xa9059cbb);
+/// ```
+#[proc_macro]
+pub fn fn_selector(input: TokenStream) -> TokenStream {
+ let input = input.to_string().replace(' ', "");
+ let selector = fn_selector_str(&input);
+
+ (quote! {
+ #selector
+ })
+ .into()
+}
+
+fn event_selector_str(input: &str) -> [u8; 32] {
+ let mut hasher = Keccak256::new();
+ hasher.update(input.as_bytes());
+ let result = hasher.finalize();
+
+ let mut selector_bytes = [0; 32];
+ selector_bytes.copy_from_slice(&result[0..32]);
+ selector_bytes
+}
+
+/// Returns solidity topic (hash) by its textual representation
+///
+/// ```ignore
+/// use evm_coder_macros::event_topic;
+///
+/// assert_eq!(
+/// format!("{:x}", event_topic!(Transfer(address, address, uint256))),
+/// "ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
+/// );
+/// ```
+#[proc_macro]
+pub fn event_topic(stream: TokenStream) -> TokenStream {
+ let input = stream.to_string().replace(' ', "");
+ let selector_bytes = event_selector_str(&input);
+
+ (quote! {
+ ::primitive_types::H256([#(
+ #selector_bytes,
+ )*])
+ })
+ .into()
+}
+
+fn parse_path(ty: &Type) -> syn::Result<&Path> {
+ match &ty {
+ syn::Type::Path(pat) => {
+ if let Some(qself) = &pat.qself {
+ return Err(syn::Error::new(qself.ty.span(), "no receiver expected"));
+ }
+ Ok(&pat.path)
+ }
+ _ => Err(syn::Error::new(ty.span(), "expected ty to be path")),
+ }
+}
+
+fn parse_path_segment(path: &Path) -> syn::Result<&PathSegment> {
+ if path.segments.len() != 1 {
+ return Err(syn::Error::new(
+ path.span(),
+ "expected path to have only segment",
+ ));
+ }
+ let last_segment = &path.segments.last().unwrap();
+ Ok(last_segment)
+}
+
+fn parse_ident_from_pat(pat: &Pat) -> syn::Result<&Ident> {
+ match pat {
+ Pat::Ident(i) => Ok(&i.ident),
+ _ => Err(syn::Error::new(pat.span(), "expected pat ident")),
+ }
+}
+
+fn parse_ident_from_segment(segment: &PathSegment, allow_generics: bool) -> syn::Result<&Ident> {
+ if segment.arguments != PathArguments::None && !allow_generics {
+ return Err(syn::Error::new(
+ segment.arguments.span(),
+ "unexpected generic type",
+ ));
+ }
+ Ok(&segment.ident)
+}
+
+fn parse_ident_from_path(path: &Path, allow_generics: bool) -> syn::Result<&Ident> {
+ let segment = parse_path_segment(path)?;
+ parse_ident_from_segment(segment, allow_generics)
+}
+
+fn parse_ident_from_type(ty: &Type, allow_generics: bool) -> syn::Result<&Ident> {
+ let path = parse_path(ty)?;
+ parse_ident_from_path(path, allow_generics)
+}
+
+// Gets T out of Result<T>
+fn parse_result_ok(ty: &Type) -> syn::Result<&Type> {
+ let path = parse_path(ty)?;
+ let segment = parse_path_segment(path)?;
+
+ if segment.ident != "Result" {
+ return Err(syn::Error::new(
+ ty.span(),
+ "expected Result as return type (no renamed aliases allowed)",
+ ));
+ }
+ let args = match &segment.arguments {
+ PathArguments::AngleBracketed(e) => e,
+ _ => {
+ return Err(syn::Error::new(
+ segment.arguments.span(),
+ "missing Result generics",
+ ))
+ }
+ };
+
+ let args = &args.args;
+ let arg = args.first().unwrap();
+
+ let ty = match arg {
+ GenericArgument::Type(ty) => ty,
+ _ => {
+ return Err(syn::Error::new(
+ arg.span(),
+ "expected first generic to be type",
+ ))
+ }
+ };
+
+ Ok(ty)
+}
+
+fn pascal_ident_to_call(ident: &Ident) -> Ident {
+ let name = format!("{}Call", ident);
+ Ident::new(&name, ident.span())
+}
+fn snake_ident_to_pascal(ident: &Ident) -> Ident {
+ let name = ident.to_string();
+ let name = cases::pascalcase::to_pascal_case(&name);
+ Ident::new(&name, ident.span())
+}
+fn snake_ident_to_screaming(ident: &Ident) -> Ident {
+ let name = ident.to_string();
+ let name = cases::screamingsnakecase::to_screaming_snake_case(&name);
+ Ident::new(&name, ident.span())
+}
+fn pascal_ident_to_snake_call(ident: &Ident) -> Ident {
+ let name = ident.to_string();
+ let name = cases::snakecase::to_snake_case(&name);
+ let name = format!("call_{}", name);
+ Ident::new(&name, ident.span())
+}
+
+/// See documentation for this proc-macro reexported in `evm-coder` crate
+#[proc_macro_attribute]
+pub fn solidity_interface(args: TokenStream, stream: TokenStream) -> TokenStream {
+ let args = parse_macro_input!(args as solidity_interface::InterfaceInfo);
+
+ let input: ItemImpl = match syn::parse(stream) {
+ Ok(t) => t,
+ Err(e) => return e.to_compile_error().into(),
+ };
+
+ let expanded = match solidity_interface::SolidityInterface::try_from(args, &input) {
+ Ok(v) => v.expand(),
+ Err(e) => e.to_compile_error(),
+ };
+
+ (quote! {
+ #input
+
+ #expanded
+ })
+ .into()
+}
+
+#[proc_macro_attribute]
+pub fn solidity(_args: TokenStream, stream: TokenStream) -> TokenStream {
+ stream
+}
+#[proc_macro_attribute]
+pub fn weight(_args: TokenStream, stream: TokenStream) -> TokenStream {
+ stream
+}
+
+/// See documentation for this proc-macro reexported in `evm-coder` crate
+#[proc_macro_derive(ToLog, attributes(indexed))]
+pub fn to_log(value: TokenStream) -> TokenStream {
+ let input = parse_macro_input!(value as DeriveInput);
+
+ match to_log::Events::try_from(&input) {
+ Ok(e) => e.expand(),
+ Err(e) => e.to_compile_error(),
+ }
+ .into()
+}
crates/evm-coder/procedural/src/solidity_interface.rsdiffbeforeafterboth--- /dev/null
+++ b/crates/evm-coder/procedural/src/solidity_interface.rs
@@ -0,0 +1,1110 @@
+// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
+// This file is part of Unique Network.
+
+// Unique Network 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.
+
+// Unique Network 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 Unique Network. If not, see <http://www.gnu.org/licenses/>.
+
+#![allow(dead_code)]
+
+// NOTE: In order to understand this Rust macro better, first read this chapter
+// about Procedural Macros in Rust book:
+// https://doc.rust-lang.org/reference/procedural-macros.html
+
+use quote::{quote, ToTokens};
+use inflector::cases;
+use std::fmt::Write;
+use syn::{
+ Expr, FnArg, GenericArgument, Generics, Ident, ImplItem, ImplItemMethod, ItemImpl, Lit, Meta,
+ MetaNameValue, PatType, PathArguments, ReturnType, Type,
+ spanned::Spanned,
+ parse::{Parse, ParseStream},
+ parenthesized, Token, LitInt, LitStr,
+};
+
+use crate::{
+ fn_selector_str, parse_ident_from_pat, parse_ident_from_path, parse_path, parse_path_segment,
+ parse_result_ok, pascal_ident_to_call, pascal_ident_to_snake_call, snake_ident_to_pascal,
+ snake_ident_to_screaming,
+};
+
+struct Is {
+ name: Ident,
+ pascal_call_name: Ident,
+ snake_call_name: Ident,
+ via: Option<(Type, Ident)>,
+}
+impl Is {
+ fn expand_call_def(&self, gen_ref: &proc_macro2::TokenStream) -> proc_macro2::TokenStream {
+ let name = &self.name;
+ let pascal_call_name = &self.pascal_call_name;
+ quote! {
+ #name(#pascal_call_name #gen_ref)
+ }
+ }
+
+ fn expand_interface_id(&self) -> proc_macro2::TokenStream {
+ let pascal_call_name = &self.pascal_call_name;
+ quote! {
+ interface_id ^= u32::from_be_bytes(#pascal_call_name::interface_id());
+ }
+ }
+
+ fn expand_supports_interface(
+ &self,
+ generics: &proc_macro2::TokenStream,
+ ) -> proc_macro2::TokenStream {
+ let pascal_call_name = &self.pascal_call_name;
+ quote! {
+ <#pascal_call_name #generics>::supports_interface(interface_id)
+ }
+ }
+
+ fn expand_variant_weight(&self) -> proc_macro2::TokenStream {
+ let name = &self.name;
+ quote! {
+ Self::#name(call) => call.weight()
+ }
+ }
+
+ fn expand_variant_call(
+ &self,
+ call_name: &proc_macro2::Ident,
+ generics: &proc_macro2::TokenStream,
+ ) -> proc_macro2::TokenStream {
+ let name = &self.name;
+ let pascal_call_name = &self.pascal_call_name;
+ let via_typ = self
+ .via
+ .as_ref()
+ .map(|(t, _)| quote! {#t})
+ .unwrap_or_else(|| quote! {Self});
+ let via_map = self
+ .via
+ .as_ref()
+ .map(|(_, i)| quote! {.#i()})
+ .unwrap_or_default();
+ quote! {
+ #call_name::#name(call) => return <#via_typ as ::evm_coder::Callable<#pascal_call_name #generics>>::call(self #via_map, Msg {
+ call,
+ caller: c.caller,
+ value: c.value,
+ })
+ }
+ }
+
+ fn expand_parse(&self, generics: &proc_macro2::TokenStream) -> proc_macro2::TokenStream {
+ let name = &self.name;
+ let pascal_call_name = &self.pascal_call_name;
+ quote! {
+ if let Some(parsed_call) = <#pascal_call_name #generics>::parse(method_id, reader)? {
+ return Ok(Some(Self::#name(parsed_call)))
+ }
+ }
+ }
+
+ fn expand_generator(&self, generics: &proc_macro2::TokenStream) -> proc_macro2::TokenStream {
+ let pascal_call_name = &self.pascal_call_name;
+ quote! {
+ <#pascal_call_name #generics>::generate_solidity_interface(tc, is_impl);
+ }
+ }
+
+ fn expand_event_generator(&self) -> proc_macro2::TokenStream {
+ let name = &self.name;
+ quote! {
+ #name::generate_solidity_interface(tc, is_impl);
+ }
+ }
+}
+
+#[derive(Default)]
+struct IsList(Vec<Is>);
+impl Parse for IsList {
+ fn parse(input: ParseStream) -> syn::Result<Self> {
+ let mut out = vec![];
+ loop {
+ if input.is_empty() {
+ break;
+ }
+ let name = input.parse::<Ident>()?;
+ let lookahead = input.lookahead1();
+ let via = if lookahead.peek(syn::token::Paren) {
+ let contents;
+ parenthesized!(contents in input);
+ let method = contents.parse::<Ident>()?;
+ contents.parse::<Token![,]>()?;
+ let ty = contents.parse::<Type>()?;
+ Some((ty, method))
+ } else if lookahead.peek(Token![,]) {
+ None
+ } else if input.is_empty() {
+ None
+ } else {
+ return Err(lookahead.error());
+ };
+ out.push(Is {
+ pascal_call_name: pascal_ident_to_call(&name),
+ snake_call_name: pascal_ident_to_snake_call(&name),
+ name,
+ via,
+ });
+ if input.peek(Token![,]) {
+ input.parse::<Token![,]>()?;
+ continue;
+ } else {
+ break;
+ }
+ }
+ Ok(Self(out))
+ }
+}
+
+pub struct InterfaceInfo {
+ name: Ident,
+ is: IsList,
+ inline_is: IsList,
+ events: IsList,
+ expect_selector: Option<u32>,
+}
+impl Parse for InterfaceInfo {
+ fn parse(input: ParseStream) -> syn::Result<Self> {
+ let mut name = None;
+ let mut is = None;
+ let mut inline_is = None;
+ let mut events = None;
+ let mut expect_selector = None;
+ // TODO: create proc-macro to optimize proc-macro boilerplate? :D
+ loop {
+ let lookahead = input.lookahead1();
+ if lookahead.peek(kw::name) {
+ let k = input.parse::<kw::name>()?;
+ input.parse::<Token![=]>()?;
+ if name.replace(input.parse::<Ident>()?).is_some() {
+ return Err(syn::Error::new(k.span(), "name is already set"));
+ }
+ } else if lookahead.peek(kw::is) {
+ let k = input.parse::<kw::is>()?;
+ let contents;
+ parenthesized!(contents in input);
+ if is.replace(contents.parse::<IsList>()?).is_some() {
+ return Err(syn::Error::new(k.span(), "is is already set"));
+ }
+ } else if lookahead.peek(kw::inline_is) {
+ let k = input.parse::<kw::inline_is>()?;
+ let contents;
+ parenthesized!(contents in input);
+ if inline_is.replace(contents.parse::<IsList>()?).is_some() {
+ return Err(syn::Error::new(k.span(), "inline_is is already set"));
+ }
+ } else if lookahead.peek(kw::events) {
+ let k = input.parse::<kw::events>()?;
+ let contents;
+ parenthesized!(contents in input);
+ if events.replace(contents.parse::<IsList>()?).is_some() {
+ return Err(syn::Error::new(k.span(), "events is already set"));
+ }
+ } else if lookahead.peek(kw::expect_selector) {
+ let k = input.parse::<kw::expect_selector>()?;
+ input.parse::<Token![=]>()?;
+ let value = input.parse::<LitInt>()?;
+ if expect_selector
+ .replace(value.base10_parse::<u32>()?)
+ .is_some()
+ {
+ return Err(syn::Error::new(k.span(), "expect_selector is already set"));
+ }
+ } else if input.is_empty() {
+ break;
+ } else {
+ return Err(lookahead.error());
+ }
+ if input.peek(Token![,]) {
+ input.parse::<Token![,]>()?;
+ } else {
+ break;
+ }
+ }
+ Ok(Self {
+ name: name.ok_or_else(|| syn::Error::new(input.span(), "missing name"))?,
+ is: is.unwrap_or_default(),
+ inline_is: inline_is.unwrap_or_default(),
+ events: events.unwrap_or_default(),
+ expect_selector,
+ })
+ }
+}
+
+struct MethodInfo {
+ rename_selector: Option<String>,
+}
+impl Parse for MethodInfo {
+ fn parse(input: ParseStream) -> syn::Result<Self> {
+ let mut rename_selector = None;
+ let lookahead = input.lookahead1();
+ if lookahead.peek(kw::rename_selector) {
+ let k = input.parse::<kw::rename_selector>()?;
+ input.parse::<Token![=]>()?;
+ if rename_selector
+ .replace(input.parse::<LitStr>()?.value())
+ .is_some()
+ {
+ return Err(syn::Error::new(k.span(), "rename_selector is already set"));
+ }
+ }
+ Ok(Self { rename_selector })
+ }
+}
+
+enum AbiType {
+ // type
+ Plain(Ident),
+ // (type1,type2)
+ Tuple(Vec<AbiType>),
+ // type[]
+ Vec(Box<AbiType>),
+ // type[20]
+ Array(Box<AbiType>, usize),
+}
+impl AbiType {
+ fn try_from(value: &Type) -> syn::Result<Self> {
+ let value = Self::try_maybe_special_from(value)?;
+ if value.is_special() {
+ return Err(syn::Error::new(value.span(), "unexpected special type"));
+ }
+ Ok(value)
+ }
+ fn try_maybe_special_from(value: &Type) -> syn::Result<Self> {
+ match value {
+ Type::Array(arr) => {
+ let wrapped = AbiType::try_from(&arr.elem)?;
+ match &arr.len {
+ Expr::Lit(l) => match &l.lit {
+ Lit::Int(i) => {
+ let num = i.base10_parse::<usize>()?;
+ Ok(AbiType::Array(Box::new(wrapped), num as usize))
+ }
+ _ => Err(syn::Error::new(arr.len.span(), "should be int literal")),
+ },
+ _ => Err(syn::Error::new(arr.len.span(), "should be literal")),
+ }
+ }
+ Type::Path(_) => {
+ let path = parse_path(value)?;
+ let segment = parse_path_segment(path)?;
+ if segment.ident == "Vec" {
+ let args = match &segment.arguments {
+ PathArguments::AngleBracketed(e) => e,
+ _ => {
+ return Err(syn::Error::new(
+ segment.arguments.span(),
+ "missing Vec generic",
+ ))
+ }
+ };
+ let args = &args.args;
+ if args.len() != 1 {
+ return Err(syn::Error::new(
+ args.span(),
+ "expected only one generic for vec",
+ ));
+ }
+ let arg = args.first().expect("first arg");
+
+ let ty = match arg {
+ GenericArgument::Type(ty) => ty,
+ _ => {
+ return Err(syn::Error::new(
+ arg.span(),
+ "expected first generic to be type",
+ ))
+ }
+ };
+
+ let wrapped = AbiType::try_from(ty)?;
+ Ok(Self::Vec(Box::new(wrapped)))
+ } else {
+ if !segment.arguments.is_empty() {
+ return Err(syn::Error::new(
+ segment.arguments.span(),
+ "unexpected generic arguments for non-vec type",
+ ));
+ }
+ Ok(Self::Plain(segment.ident.clone()))
+ }
+ }
+ Type::Tuple(t) => {
+ let mut out = Vec::with_capacity(t.elems.len());
+ for el in t.elems.iter() {
+ out.push(AbiType::try_from(el)?)
+ }
+ Ok(Self::Tuple(out))
+ }
+ _ => Err(syn::Error::new(
+ value.span(),
+ "unexpected type, only arrays, plain types and tuples are supported",
+ )),
+ }
+ }
+ fn is_value(&self) -> bool {
+ matches!(self, Self::Plain(v) if v == "value")
+ }
+ fn is_caller(&self) -> bool {
+ matches!(self, Self::Plain(v) if v == "caller")
+ }
+ fn is_special(&self) -> bool {
+ self.is_caller() || self.is_value()
+ }
+ fn selector_ty_buf(&self, buf: &mut String) -> std::fmt::Result {
+ match self {
+ AbiType::Plain(t) => {
+ write!(buf, "{}", t)
+ }
+ AbiType::Tuple(t) => {
+ write!(buf, "(")?;
+ for (i, t) in t.iter().enumerate() {
+ if i != 0 {
+ write!(buf, ",")?;
+ }
+ t.selector_ty_buf(buf)?;
+ }
+ write!(buf, ")")
+ }
+ AbiType::Vec(v) => {
+ v.selector_ty_buf(buf)?;
+ write!(buf, "[]")
+ }
+ AbiType::Array(v, len) => {
+ v.selector_ty_buf(buf)?;
+ write!(buf, "[{}]", len)
+ }
+ }
+ }
+ fn selector_ty(&self) -> String {
+ let mut out = String::new();
+ self.selector_ty_buf(&mut out).expect("no fmt error");
+ out
+ }
+}
+impl ToTokens for AbiType {
+ fn to_tokens(&self, tokens: &mut proc_macro2::TokenStream) {
+ match self {
+ AbiType::Plain(t) => tokens.extend(quote! {#t}),
+ AbiType::Tuple(t) => {
+ tokens.extend(quote! {(
+ #(#t),*
+ )});
+ }
+ AbiType::Vec(v) => tokens.extend(quote! {Vec<#v>}),
+ AbiType::Array(v, l) => tokens.extend(quote! {[#v; #l]}),
+ }
+ }
+}
+
+struct MethodArg {
+ name: Ident,
+ camel_name: String,
+ ty: AbiType,
+}
+impl MethodArg {
+ fn try_from(value: &PatType) -> syn::Result<Self> {
+ let name = parse_ident_from_pat(&value.pat)?.clone();
+ Ok(Self {
+ camel_name: cases::camelcase::to_camel_case(&name.to_string()),
+ name,
+ ty: AbiType::try_maybe_special_from(&value.ty)?,
+ })
+ }
+ fn is_value(&self) -> bool {
+ self.ty.is_value()
+ }
+ fn is_caller(&self) -> bool {
+ self.ty.is_caller()
+ }
+ fn is_special(&self) -> bool {
+ self.ty.is_special()
+ }
+ fn selector_ty(&self) -> String {
+ assert!(!self.is_special());
+ self.ty.selector_ty()
+ }
+
+ fn expand_call_def(&self) -> proc_macro2::TokenStream {
+ assert!(!self.is_special());
+ let name = &self.name;
+ let ty = &self.ty;
+
+ quote! {
+ #name: #ty
+ }
+ }
+
+ fn expand_parse(&self) -> proc_macro2::TokenStream {
+ assert!(!self.is_special());
+ let name = &self.name;
+ quote! {
+ #name: reader.abi_read()?
+ }
+ }
+
+ fn expand_call_arg(&self) -> proc_macro2::TokenStream {
+ if self.is_value() {
+ quote! {
+ c.value.clone()
+ }
+ } else if self.is_caller() {
+ quote! {
+ c.caller.clone()
+ }
+ } else {
+ let name = &self.name;
+ quote! {
+ #name
+ }
+ }
+ }
+
+ fn expand_solidity_argument(&self) -> proc_macro2::TokenStream {
+ let camel_name = &self.camel_name.to_string();
+ let ty = &self.ty;
+ quote! {
+ <NamedArgument<#ty>>::new(#camel_name)
+ }
+ }
+}
+
+#[derive(PartialEq)]
+enum Mutability {
+ Mutable,
+ View,
+ Pure,
+}
+
+/// Group all keywords for this macro. Usage example:
+/// #[solidity_interface(name = "B", inline_is(A))]
+mod kw {
+ syn::custom_keyword!(weight);
+
+ syn::custom_keyword!(via);
+ syn::custom_keyword!(name);
+ syn::custom_keyword!(is);
+ syn::custom_keyword!(inline_is);
+ syn::custom_keyword!(events);
+ syn::custom_keyword!(expect_selector);
+
+ syn::custom_keyword!(rename_selector);
+}
+
+/// Rust methods are parsed into this structure when Solidity code is generated
+struct Method {
+ name: Ident,
+ camel_name: String,
+ pascal_name: Ident,
+ screaming_name: Ident,
+ selector_str: String,
+ selector: u32,
+ args: Vec<MethodArg>,
+ has_normal_args: bool,
+ mutability: Mutability,
+ result: Type,
+ weight: Option<Expr>,
+ docs: Vec<String>,
+}
+impl Method {
+ fn try_from(value: &ImplItemMethod) -> syn::Result<Self> {
+ let mut info = MethodInfo {
+ rename_selector: None,
+ };
+ let mut docs = Vec::new();
+ let mut weight = None;
+ for attr in &value.attrs {
+ let ident = parse_ident_from_path(&attr.path, false)?;
+ if ident == "solidity" {
+ info = attr.parse_args::<MethodInfo>()?;
+ } else if ident == "doc" {
+ let args = attr.parse_meta().unwrap();
+ let value = match args {
+ Meta::NameValue(MetaNameValue {
+ lit: Lit::Str(str), ..
+ }) => str.value(),
+ _ => unreachable!(),
+ };
+ docs.push(value);
+ } else if ident == "weight" {
+ weight = Some(attr.parse_args::<Expr>()?);
+ }
+ }
+ let ident = &value.sig.ident;
+ let ident_str = ident.to_string();
+ if !cases::snakecase::is_snake_case(&ident_str) {
+ return Err(syn::Error::new(ident.span(), "method name should be snake_cased\nif alternative solidity name needs to be set - use #[solidity] attribute"));
+ }
+
+ let mut mutability = Mutability::Pure;
+
+ if let Some(FnArg::Receiver(receiver)) = value
+ .sig
+ .inputs
+ .iter()
+ .find(|arg| matches!(arg, FnArg::Receiver(_)))
+ {
+ if receiver.reference.is_none() {
+ return Err(syn::Error::new(
+ receiver.span(),
+ "receiver should be by ref",
+ ));
+ }
+ if receiver.mutability.is_some() {
+ mutability = Mutability::Mutable;
+ } else {
+ mutability = Mutability::View;
+ }
+ }
+ let mut args = Vec::new();
+ for typ in value
+ .sig
+ .inputs
+ .iter()
+ .filter(|arg| matches!(arg, FnArg::Typed(_)))
+ {
+ let typ = match typ {
+ FnArg::Typed(typ) => typ,
+ _ => unreachable!(),
+ };
+ args.push(MethodArg::try_from(typ)?);
+ }
+
+ if mutability != Mutability::Mutable && args.iter().any(|arg| arg.is_value()) {
+ return Err(syn::Error::new(
+ args.iter().find(|arg| arg.is_value()).unwrap().ty.span(),
+ "payable function should be mutable",
+ ));
+ }
+
+ let result = match &value.sig.output {
+ ReturnType::Type(_, ty) => ty,
+ _ => return Err(syn::Error::new(value.sig.output.span(), "interface method should return Result<value>\nif there is no value to return - specify void (which is alias to unit)")),
+ };
+ let result = parse_result_ok(result)?;
+
+ let camel_name = info
+ .rename_selector
+ .unwrap_or_else(|| cases::camelcase::to_camel_case(&ident.to_string()));
+ let mut selector_str = camel_name.clone();
+ selector_str.push('(');
+ let mut has_normal_args = false;
+ for (i, arg) in args.iter().filter(|arg| !arg.is_special()).enumerate() {
+ if i != 0 {
+ selector_str.push(',');
+ }
+ write!(selector_str, "{}", arg.selector_ty()).unwrap();
+ has_normal_args = true;
+ }
+ selector_str.push(')');
+ let selector = fn_selector_str(&selector_str);
+
+ Ok(Self {
+ name: ident.clone(),
+ camel_name,
+ pascal_name: snake_ident_to_pascal(ident),
+ screaming_name: snake_ident_to_screaming(ident),
+ selector_str,
+ selector,
+ args,
+ has_normal_args,
+ mutability,
+ result: result.clone(),
+ weight,
+ docs,
+ })
+ }
+ fn expand_call_def(&self) -> proc_macro2::TokenStream {
+ let defs = self
+ .args
+ .iter()
+ .filter(|a| !a.is_special())
+ .map(|a| a.expand_call_def());
+ let pascal_name = &self.pascal_name;
+ let docs = &self.docs;
+
+ if self.has_normal_args {
+ quote! {
+ #(#[doc = #docs])*
+ #[allow(missing_docs)]
+ #pascal_name {
+ #(
+ #defs,
+ )*
+ }
+ }
+ } else {
+ quote! {#pascal_name}
+ }
+ }
+
+ fn expand_const(&self) -> proc_macro2::TokenStream {
+ let screaming_name = &self.screaming_name;
+ let selector = u32::to_be_bytes(self.selector);
+ let selector_str = &self.selector_str;
+ quote! {
+ #[doc = #selector_str]
+ const #screaming_name: ::evm_coder::types::bytes4 = [#(#selector,)*];
+ }
+ }
+
+ fn expand_interface_id(&self) -> proc_macro2::TokenStream {
+ let screaming_name = &self.screaming_name;
+ quote! {
+ interface_id ^= u32::from_be_bytes(Self::#screaming_name);
+ }
+ }
+
+ fn expand_parse(&self) -> proc_macro2::TokenStream {
+ let pascal_name = &self.pascal_name;
+ let screaming_name = &self.screaming_name;
+ if self.has_normal_args {
+ let parsers = self
+ .args
+ .iter()
+ .filter(|a| !a.is_special())
+ .map(|a| a.expand_parse());
+ quote! {
+ Self::#screaming_name => return Ok(Some(Self::#pascal_name {
+ #(
+ #parsers,
+ )*
+ }))
+ }
+ } else {
+ quote! { Self::#screaming_name => return Ok(Some(Self::#pascal_name)) }
+ }
+ }
+
+ fn expand_variant_call(&self, call_name: &proc_macro2::Ident) -> proc_macro2::TokenStream {
+ let pascal_name = &self.pascal_name;
+ let name = &self.name;
+
+ let matcher = if self.has_normal_args {
+ let names = self
+ .args
+ .iter()
+ .filter(|a| !a.is_special())
+ .map(|a| &a.name);
+
+ quote! {{
+ #(
+ #names,
+ )*
+ }}
+ } else {
+ quote! {}
+ };
+
+ let receiver = match self.mutability {
+ Mutability::Mutable | Mutability::View => quote! {self.},
+ Mutability::Pure => quote! {Self::},
+ };
+ let args = self.args.iter().map(|a| a.expand_call_arg());
+
+ quote! {
+ #call_name::#pascal_name #matcher => {
+ let result = #receiver #name(
+ #(
+ #args,
+ )*
+ )?;
+ (&result).to_result()
+ }
+ }
+ }
+
+ fn expand_variant_weight(&self) -> proc_macro2::TokenStream {
+ let pascal_name = &self.pascal_name;
+ if let Some(weight) = &self.weight {
+ let matcher = if self.has_normal_args {
+ let names = self
+ .args
+ .iter()
+ .filter(|a| !a.is_special())
+ .map(|a| &a.name);
+
+ quote! {{
+ #(
+ #names,
+ )*
+ }}
+ } else {
+ quote! {}
+ };
+ quote! {
+ Self::#pascal_name #matcher => (#weight).into()
+ }
+ } else {
+ let matcher = if self.has_normal_args {
+ quote! {{..}}
+ } else {
+ quote! {}
+ };
+ quote! {
+ Self::#pascal_name #matcher => ().into()
+ }
+ }
+ }
+
+ fn expand_solidity_function(&self) -> proc_macro2::TokenStream {
+ let camel_name = &self.camel_name;
+ let mutability = match self.mutability {
+ Mutability::Mutable => quote! {SolidityMutability::Mutable},
+ Mutability::View => quote! { SolidityMutability::View },
+ Mutability::Pure => quote! {SolidityMutability::Pure},
+ };
+ let result = &self.result;
+
+ let args = self
+ .args
+ .iter()
+ .filter(|a| !a.is_special())
+ .map(MethodArg::expand_solidity_argument);
+ let docs = &self.docs;
+ let selector_str = &self.selector_str;
+ let selector = self.selector;
+
+ quote! {
+ SolidityFunction {
+ docs: &[#(#docs),*],
+ selector_str: #selector_str,
+ selector: #selector,
+ name: #camel_name,
+ mutability: #mutability,
+ args: (
+ #(
+ #args,
+ )*
+ ),
+ result: <UnnamedArgument<#result>>::default(),
+ }
+ }
+ }
+}
+
+fn generics_list(gen: &Generics) -> proc_macro2::TokenStream {
+ if gen.params.is_empty() {
+ return quote! {};
+ }
+ let params = gen.params.iter().map(|p| match p {
+ syn::GenericParam::Type(id) => {
+ let v = &id.ident;
+ quote! {#v}
+ }
+ syn::GenericParam::Lifetime(lt) => {
+ let v = <.lifetime;
+ quote! {#v}
+ }
+ syn::GenericParam::Const(c) => {
+ let i = &c.ident;
+ quote! {#i}
+ }
+ });
+ quote! { #(#params),* }
+}
+fn generics_reference(gen: &Generics) -> proc_macro2::TokenStream {
+ if gen.params.is_empty() {
+ return quote! {};
+ }
+ let list = generics_list(gen);
+ quote! { <#list> }
+}
+fn generics_data(gen: &Generics) -> proc_macro2::TokenStream {
+ let list = generics_list(gen);
+ if gen.params.len() == 1 {
+ quote! {#list}
+ } else {
+ quote! { (#list) }
+ }
+}
+
+pub struct SolidityInterface {
+ generics: Generics,
+ name: Box<syn::Type>,
+ info: InterfaceInfo,
+ methods: Vec<Method>,
+ docs: Vec<String>,
+}
+impl SolidityInterface {
+ pub fn try_from(info: InterfaceInfo, value: &ItemImpl) -> syn::Result<Self> {
+ let mut methods = Vec::new();
+
+ for item in &value.items {
+ if let ImplItem::Method(method) = item {
+ methods.push(Method::try_from(method)?)
+ }
+ }
+ let mut docs = vec![];
+ for attr in &value.attrs {
+ let ident = parse_ident_from_path(&attr.path, false)?;
+ if ident == "doc" {
+ let args = attr.parse_meta().unwrap();
+ let value = match args {
+ Meta::NameValue(MetaNameValue {
+ lit: Lit::Str(str), ..
+ }) => str.value(),
+ _ => unreachable!(),
+ };
+ docs.push(value);
+ }
+ }
+ Ok(Self {
+ generics: value.generics.clone(),
+ name: value.self_ty.clone(),
+ info,
+ methods,
+ docs,
+ })
+ }
+ pub fn expand(self) -> proc_macro2::TokenStream {
+ let name = self.name;
+
+ let solidity_name = self.info.name.to_string();
+ let call_name = pascal_ident_to_call(&self.info.name);
+ let generics = self.generics;
+ let gen_ref = generics_reference(&generics);
+ let gen_data = generics_data(&generics);
+ let gen_where = &generics.where_clause;
+
+ let call_sub = self
+ .info
+ .inline_is
+ .0
+ .iter()
+ .chain(self.info.is.0.iter())
+ .map(|c| Is::expand_call_def(c, &gen_ref));
+ let call_parse = self
+ .info
+ .inline_is
+ .0
+ .iter()
+ .chain(self.info.is.0.iter())
+ .map(|is| Is::expand_parse(is, &gen_ref));
+ let call_variants = self
+ .info
+ .inline_is
+ .0
+ .iter()
+ .chain(self.info.is.0.iter())
+ .map(|c| Is::expand_variant_call(c, &call_name, &gen_ref));
+ let weight_variants = self
+ .info
+ .inline_is
+ .0
+ .iter()
+ .chain(self.info.is.0.iter())
+ .map(Is::expand_variant_weight);
+
+ let inline_interface_id = self.info.inline_is.0.iter().map(Is::expand_interface_id);
+ let supports_interface = self
+ .info
+ .is
+ .0
+ .iter()
+ .map(|is| Is::expand_supports_interface(is, &gen_ref));
+
+ let calls = self.methods.iter().map(Method::expand_call_def);
+ let consts = self.methods.iter().map(Method::expand_const);
+ let interface_id = self.methods.iter().map(Method::expand_interface_id);
+ let parsers = self.methods.iter().map(Method::expand_parse);
+ let call_variants_this = self
+ .methods
+ .iter()
+ .map(|m| Method::expand_variant_call(m, &call_name));
+ let weight_variants_this = self.methods.iter().map(Method::expand_variant_weight);
+ let solidity_functions = self.methods.iter().map(Method::expand_solidity_function);
+
+ // TODO: Inline inline_is
+ let solidity_is = self
+ .info
+ .is
+ .0
+ .iter()
+ .chain(self.info.inline_is.0.iter())
+ .map(|is| is.name.to_string());
+ let solidity_events_is = self.info.events.0.iter().map(|is| is.name.to_string());
+ let solidity_generators = self
+ .info
+ .is
+ .0
+ .iter()
+ .chain(self.info.inline_is.0.iter())
+ .map(|is| Is::expand_generator(is, &gen_ref));
+ let solidity_event_generators = self.info.events.0.iter().map(Is::expand_event_generator);
+
+ let docs = &self.docs;
+
+ if let Some(expect_selector) = &self.info.expect_selector {
+ if !self.info.inline_is.0.is_empty() {
+ return syn::Error::new(
+ name.span(),
+ "expect_selector is not compatible with inline_is",
+ )
+ .to_compile_error();
+ }
+ let selector = self
+ .methods
+ .iter()
+ .map(|m| m.selector)
+ .fold(0, |a, b| a ^ b);
+
+ if *expect_selector != selector {
+ let mut methods = String::new();
+ for meth in self.methods.iter() {
+ write!(methods, "\n- {}", meth.selector_str).expect("write to string");
+ }
+ return syn::Error::new(name.span(), format!("expected selector mismatch, expected {expect_selector:0>8x}, but implementation has {selector:0>8x}{methods}")).to_compile_error();
+ }
+ }
+ // let methods = self.methods.iter().map(Method::solidity_def);
+
+ quote! {
+ #[derive(Debug)]
+ #(#[doc = #docs])*
+ pub enum #call_name #gen_ref {
+ /// Inherited method
+ ERC165Call(::evm_coder::ERC165Call, ::core::marker::PhantomData<#gen_data>),
+ #(
+ #calls,
+ )*
+ #(
+ #call_sub,
+ )*
+ }
+ impl #gen_ref #call_name #gen_ref {
+ #(
+ #consts
+ )*
+ /// Return this call ERC165 selector
+ pub fn interface_id() -> ::evm_coder::types::bytes4 {
+ let mut interface_id = 0;
+ #(#interface_id)*
+ #(#inline_interface_id)*
+ u32::to_be_bytes(interface_id)
+ }
+ /// Is this contract implements specified ERC165 selector
+ pub fn supports_interface(interface_id: ::evm_coder::types::bytes4) -> bool {
+ interface_id != u32::to_be_bytes(0xffffff) && (
+ interface_id == ::evm_coder::ERC165Call::INTERFACE_ID ||
+ interface_id == Self::interface_id()
+ #(
+ || #supports_interface
+ )*
+ )
+ }
+ /// Generate solidity definitions for methods described in this interface
+ pub fn generate_solidity_interface(tc: &evm_coder::solidity::TypeCollector, is_impl: bool) {
+ use evm_coder::solidity::*;
+ use core::fmt::Write;
+ let interface = SolidityInterface {
+ docs: &[#(#docs),*],
+ name: #solidity_name,
+ selector: Self::interface_id(),
+ is: &["Dummy", "ERC165", #(
+ #solidity_is,
+ )* #(
+ #solidity_events_is,
+ )* ],
+ functions: (#(
+ #solidity_functions,
+ )*),
+ };
+
+ let mut out = string::new();
+ if #solidity_name.starts_with("Inline") {
+ out.push_str("/// @dev inlined interface\n");
+ }
+ let _ = interface.format(is_impl, &mut out, tc);
+ tc.collect(out);
+ #(
+ #solidity_event_generators
+ )*
+ #(
+ #solidity_generators
+ )*
+ if is_impl {
+ tc.collect("/// @dev common stubs holder\ncontract Dummy {\n\tuint8 dummy;\n\tstring stub_error = \"this contract is implemented in native\";\n}\ncontract ERC165 is Dummy {\n\tfunction supportsInterface(bytes4 interfaceID) external view returns (bool) {\n\t\trequire(false, stub_error);\n\t\tinterfaceID;\n\t\treturn true;\n\t}\n}\n".into());
+ } else {
+ tc.collect("/// @dev common stubs holder\ninterface Dummy {\n}\ninterface ERC165 is Dummy {\n\tfunction supportsInterface(bytes4 interfaceID) external view returns (bool);\n}\n".into());
+ }
+ }
+ }
+ impl #gen_ref ::evm_coder::Call for #call_name #gen_ref {
+ fn parse(method_id: ::evm_coder::types::bytes4, reader: &mut ::evm_coder::abi::AbiReader) -> ::evm_coder::execution::Result<Option<Self>> {
+ use ::evm_coder::abi::AbiRead;
+ match method_id {
+ ::evm_coder::ERC165Call::INTERFACE_ID => return Ok(
+ ::evm_coder::ERC165Call::parse(method_id, reader)?
+ .map(|c| Self::ERC165Call(c, ::core::marker::PhantomData))
+ ),
+ #(
+ #parsers,
+ )*
+ _ => {},
+ }
+ #(
+ #call_parse
+ )else*
+ return Ok(None);
+ }
+ }
+ impl #generics ::evm_coder::Weighted for #call_name #gen_ref
+ #gen_where
+ {
+ #[allow(unused_variables)]
+ fn weight(&self) -> ::evm_coder::execution::DispatchInfo {
+ match self {
+ #(
+ #weight_variants,
+ )*
+ // TODO: It should be very cheap, but not free
+ Self::ERC165Call(::evm_coder::ERC165Call::SupportsInterface {..}, _) => 100u64.into(),
+ #(
+ #weight_variants_this,
+ )*
+ }
+ }
+ }
+ impl #generics ::evm_coder::Callable<#call_name #gen_ref> for #name
+ #gen_where
+ {
+ #[allow(unreachable_code)] // In case of no inner calls
+ fn call(&mut self, c: Msg<#call_name #gen_ref>) -> ::evm_coder::execution::ResultWithPostInfo<::evm_coder::abi::AbiWriter> {
+ use ::evm_coder::abi::AbiWrite;
+ match c.call {
+ #(
+ #call_variants,
+ )*
+ #call_name::ERC165Call(::evm_coder::ERC165Call::SupportsInterface {interface_id}, _) => {
+ let mut writer = ::evm_coder::abi::AbiWriter::default();
+ writer.bool(&<#call_name #gen_ref>::supports_interface(interface_id));
+ return Ok(writer.into());
+ }
+ _ => {},
+ }
+ let mut writer = ::evm_coder::abi::AbiWriter::default();
+ match c.call {
+ #(
+ #call_variants_this,
+ )*
+ _ => unreachable!()
+ }
+ }
+ }
+ }
+ }
+}
crates/evm-coder/procedural/src/to_log.rsdiffbeforeafterboth--- /dev/null
+++ b/crates/evm-coder/procedural/src/to_log.rs
@@ -0,0 +1,238 @@
+// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
+// This file is part of Unique Network.
+
+// Unique Network 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.
+
+// Unique Network 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 Unique Network. If not, see <http://www.gnu.org/licenses/>.
+
+use inflector::cases;
+use syn::{Data, DeriveInput, Field, Fields, Ident, Variant, spanned::Spanned};
+use std::fmt::Write;
+use quote::quote;
+
+use crate::{parse_ident_from_path, parse_ident_from_type, snake_ident_to_screaming};
+
+struct EventField {
+ name: Ident,
+ camel_name: String,
+ ty: Ident,
+ indexed: bool,
+}
+
+impl EventField {
+ fn try_from(field: &Field) -> syn::Result<Self> {
+ let name = field.ident.as_ref().unwrap();
+ let ty = parse_ident_from_type(&field.ty, false)?;
+ let mut indexed = false;
+ for attr in &field.attrs {
+ if let Ok(ident) = parse_ident_from_path(&attr.path, false) {
+ if ident == "indexed" {
+ indexed = true;
+ }
+ }
+ }
+ Ok(Self {
+ name: name.to_owned(),
+ camel_name: cases::camelcase::to_camel_case(&name.to_string()),
+ ty: ty.to_owned(),
+ indexed,
+ })
+ }
+ fn expand_solidity_argument(&self) -> proc_macro2::TokenStream {
+ let camel_name = &self.camel_name;
+ let ty = &self.ty;
+ let indexed = self.indexed;
+ quote! {
+ <SolidityEventArgument<#ty>>::new(#indexed, #camel_name)
+ }
+ }
+}
+
+struct Event {
+ name: Ident,
+ name_screaming: Ident,
+ fields: Vec<EventField>,
+ selector: [u8; 32],
+ selector_str: String,
+}
+
+impl Event {
+ fn try_from(variant: &Variant) -> syn::Result<Self> {
+ let name = &variant.ident;
+ let name_screaming = snake_ident_to_screaming(name);
+
+ let named = match &variant.fields {
+ Fields::Named(named) => named,
+ _ => {
+ return Err(syn::Error::new(
+ variant.fields.span(),
+ "expected named fields",
+ ))
+ }
+ };
+ let mut fields = Vec::new();
+ for field in &named.named {
+ fields.push(EventField::try_from(field)?);
+ }
+ if fields.iter().filter(|f| f.indexed).count() > 3 {
+ return Err(syn::Error::new(
+ variant.fields.span(),
+ "events can have at most 4 indexed fields (1 indexed field is reserved for event signature)"
+ ));
+ }
+ let mut selector_str = format!("{}(", name);
+ for (i, arg) in fields.iter().enumerate() {
+ if i != 0 {
+ write!(selector_str, ",").unwrap();
+ }
+ write!(selector_str, "{}", arg.ty).unwrap();
+ }
+ selector_str.push(')');
+ let selector = crate::event_selector_str(&selector_str);
+
+ Ok(Self {
+ name: name.to_owned(),
+ name_screaming,
+ fields,
+ selector,
+ selector_str,
+ })
+ }
+
+ fn expand_serializers(&self) -> proc_macro2::TokenStream {
+ let name = &self.name;
+ let name_screaming = &self.name_screaming;
+ let fields = self.fields.iter().map(|f| &f.name);
+
+ let indexed = self.fields.iter().filter(|f| f.indexed).map(|f| &f.name);
+ let plain = self.fields.iter().filter(|f| !f.indexed).map(|f| &f.name);
+
+ quote! {
+ Self::#name {#(
+ #fields,
+ )*} => {
+ topics.push(topic::from(Self::#name_screaming));
+ #(
+ topics.push(#indexed.to_topic());
+ )*
+ #(
+ #plain.abi_write(&mut writer);
+ )*
+ }
+ }
+ }
+
+ fn expand_consts(&self) -> proc_macro2::TokenStream {
+ let name_screaming = &self.name_screaming;
+ let selector_str = &self.selector_str;
+ let selector = &self.selector;
+
+ quote! {
+ #[doc = #selector_str]
+ const #name_screaming: [u8; 32] = [#(
+ #selector,
+ )*];
+ }
+ }
+
+ fn expand_solidity_function(&self) -> proc_macro2::TokenStream {
+ let name = self.name.to_string();
+ let args = self.fields.iter().map(EventField::expand_solidity_argument);
+ quote! {
+ SolidityEvent {
+ name: #name,
+ args: (
+ #(
+ #args,
+ )*
+ ),
+ }
+ }
+ }
+}
+
+pub struct Events {
+ name: Ident,
+ events: Vec<Event>,
+}
+
+impl Events {
+ pub fn try_from(data: &DeriveInput) -> syn::Result<Self> {
+ let name = &data.ident;
+ let en = match &data.data {
+ Data::Enum(en) => en,
+ _ => return Err(syn::Error::new(data.span(), "expected enum")),
+ };
+ let mut events = Vec::new();
+ for variant in &en.variants {
+ events.push(Event::try_from(variant)?);
+ }
+ Ok(Self {
+ name: name.to_owned(),
+ events,
+ })
+ }
+ pub fn expand(&self) -> proc_macro2::TokenStream {
+ let name = &self.name;
+
+ let consts = self.events.iter().map(Event::expand_consts);
+ let serializers = self.events.iter().map(Event::expand_serializers);
+ let solidity_name = self.name.to_string();
+ let solidity_functions = self.events.iter().map(Event::expand_solidity_function);
+
+ quote! {
+ impl #name {
+ #(
+ #consts
+ )*
+
+ pub fn generate_solidity_interface(tc: &evm_coder::solidity::TypeCollector, is_impl: bool) {
+ use evm_coder::solidity::*;
+ use core::fmt::Write;
+ let interface = SolidityInterface {
+ docs: &[],
+ selector: [0; 4],
+ name: #solidity_name,
+ is: &[],
+ functions: (#(
+ #solidity_functions,
+ )*),
+ };
+ let mut out = string::new();
+ out.push_str("/// @dev inlined interface\n");
+ let _ = interface.format(is_impl, &mut out, tc);
+ tc.collect(out);
+ }
+ }
+
+ #[automatically_derived]
+ impl ::evm_coder::events::ToLog for #name {
+ fn to_log(&self, contract: address) -> ::ethereum::Log {
+ use ::evm_coder::events::ToTopic;
+ use ::evm_coder::abi::AbiWrite;
+ let mut writer = ::evm_coder::abi::AbiWriter::new();
+ let mut topics = Vec::new();
+ match self {
+ #(
+ #serializers,
+ )*
+ }
+ ::ethereum::Log {
+ address: contract,
+ topics,
+ data: writer.finish(),
+ }
+ }
+ }
+ }
+ }
+}
crates/evm-coder/src/abi.rsdiffbeforeafterboth--- a/crates/evm-coder/src/abi.rs
+++ b/crates/evm-coder/src/abi.rs
@@ -14,8 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
-//! TODO: I misunterstood therminology, abi IS rlp encoded, so
-//! this module should be replaced with rlp crate
+//! Implementation of EVM RLP reader/writer
#![allow(dead_code)]
@@ -32,6 +31,11 @@
const ABI_ALIGNMENT: usize = 32;
+trait TypeHelper {
+ fn is_dynamic() -> bool;
+}
+
+/// View into RLP data, which provides method to read typed items from it
#[derive(Clone)]
pub struct AbiReader<'i> {
buf: &'i [u8],
@@ -39,6 +43,7 @@
offset: usize,
}
impl<'i> AbiReader<'i> {
+ /// Start reading RLP buffer, assuming there is no padding bytes
pub fn new(buf: &'i [u8]) -> Self {
Self {
buf,
@@ -46,6 +51,7 @@
offset: 0,
}
}
+ /// Start reading RLP buffer, parsing first 4 bytes as selector
pub fn new_call(buf: &'i [u8]) -> Result<(types::bytes4, Self)> {
if buf.len() < 4 {
return Err(Error::Error(ExitError::OutOfOffset));
@@ -75,8 +81,8 @@
return Err(Error::Error(ExitError::OutOfOffset));
}
let mut block = [0; S];
- // Verify padding is empty
- if !buf[pad_start..pad_size].iter().all(|&v| v == 0) {
+ let is_pad_zeroed = buf[pad_start..pad_size].iter().all(|&v| v == 0);
+ if !is_pad_zeroed {
return Err(Error::Error(ExitError::InvalidRange));
}
block.copy_from_slice(&buf[block_start..block_size]);
@@ -109,10 +115,12 @@
)
}
+ /// Read [`H160`] at current position, then advance
pub fn address(&mut self) -> Result<H160> {
Ok(H160(self.read_padleft()?))
}
+ /// Read [`bool`] at current position, then advance
pub fn bool(&mut self) -> Result<bool> {
let data: [u8; 1] = self.read_padleft()?;
match data[0] {
@@ -122,64 +130,89 @@
}
}
+ /// Read [`[u8; 4]`] at current position, then advance
pub fn bytes4(&mut self) -> Result<[u8; 4]> {
self.read_padright()
}
+ /// Read [`Vec<u8>`] at current position, then advance
pub fn bytes(&mut self) -> Result<Vec<u8>> {
- let mut subresult = self.subresult()?;
- let length = subresult.read_usize()?;
+ let mut subresult = self.subresult(None)?;
+ let length = subresult.uint32()? as usize;
if subresult.buf.len() < subresult.offset + length {
return Err(Error::Error(ExitError::OutOfOffset));
}
Ok(subresult.buf[subresult.offset..subresult.offset + length].into())
}
+
+ /// Read [`string`] at current position, then advance
pub fn string(&mut self) -> Result<string> {
string::from_utf8(self.bytes()?).map_err(|_| Error::Error(ExitError::InvalidRange))
}
+ /// Read [`u8`] at current position, then advance
pub fn uint8(&mut self) -> Result<u8> {
Ok(self.read_padleft::<1>()?[0])
}
+ /// Read [`u32`] at current position, then advance
pub fn uint32(&mut self) -> Result<u32> {
Ok(u32::from_be_bytes(self.read_padleft()?))
}
+ /// Read [`u128`] at current position, then advance
pub fn uint128(&mut self) -> Result<u128> {
Ok(u128::from_be_bytes(self.read_padleft()?))
}
+ /// Read [`U256`] at current position, then advance
pub fn uint256(&mut self) -> Result<U256> {
let buf: [u8; 32] = self.read_padleft()?;
Ok(U256::from_big_endian(&buf))
}
+ /// Read [`u64`] at current position, then advance
pub fn uint64(&mut self) -> Result<u64> {
Ok(u64::from_be_bytes(self.read_padleft()?))
}
+ /// Read [`usize`] at current position, then advance
+ #[deprecated = "dangerous, as usize may have different width in wasm and native execution"]
pub fn read_usize(&mut self) -> Result<usize> {
Ok(usize::from_be_bytes(self.read_padleft()?))
}
- fn subresult(&mut self) -> Result<AbiReader<'i>> {
- let offset = self.read_usize()?;
+ /// Slice recursive buffer, advance one word for buffer offset
+ /// If `size` is [`None`] then [`Self::offset`] and [`Self::subresult_offset`] evals from [`Self::buf`].
+ fn subresult(&mut self, size: Option<usize>) -> Result<AbiReader<'i>> {
+ let subresult_offset = self.subresult_offset;
+ let offset = if let Some(size) = size {
+ self.offset += size;
+ self.subresult_offset += size;
+ 0
+ } else {
+ self.uint32()? as usize
+ };
+
if offset + self.subresult_offset > self.buf.len() {
return Err(Error::Error(ExitError::InvalidRange));
}
+
+ let new_offset = offset + subresult_offset;
Ok(AbiReader {
buf: self.buf,
- subresult_offset: offset + self.subresult_offset,
- offset: offset + self.subresult_offset,
+ subresult_offset: new_offset,
+ offset: new_offset,
})
}
+ /// Is this parser reached end of buffer?
pub fn is_finished(&self) -> bool {
self.buf.len() == self.offset
}
}
+/// Writer for RLP encoded data
#[derive(Default)]
pub struct AbiWriter {
static_part: Vec<u8>,
@@ -187,9 +220,11 @@
had_call: bool,
}
impl AbiWriter {
+ /// Initialize internal buffers for output data, assuming no padding required
pub fn new() -> Self {
Self::default()
}
+ /// Initialize internal buffers, inserting method selector at beginning
pub fn new_call(method_id: u32) -> Self {
let mut val = Self::new();
val.static_part.extend(&method_id.to_be_bytes());
@@ -211,59 +246,71 @@
.extend(&[0; ABI_ALIGNMENT][0..ABI_ALIGNMENT - bytes.len()]);
}
+ /// Write [`H160`] to end of buffer
pub fn address(&mut self, address: &H160) {
self.write_padleft(&address.0)
}
+ /// Write [`bool`] to end of buffer
pub fn bool(&mut self, value: &bool) {
self.write_padleft(&[if *value { 1 } else { 0 }])
}
+ /// Write [`u8`] to end of buffer
pub fn uint8(&mut self, value: &u8) {
self.write_padleft(&[*value])
}
+ /// Write [`u32`] to end of buffer
pub fn uint32(&mut self, value: &u32) {
self.write_padleft(&u32::to_be_bytes(*value))
}
+ /// Write [`u128`] to end of buffer
pub fn uint128(&mut self, value: &u128) {
self.write_padleft(&u128::to_be_bytes(*value))
}
+ /// Write [`U256`] to end of buffer
pub fn uint256(&mut self, value: &U256) {
let mut out = [0; 32];
value.to_big_endian(&mut out);
self.write_padleft(&out)
}
+ /// Write [`usize`] to end of buffer
+ #[deprecated = "dangerous, as usize may have different width in wasm and native execution"]
pub fn write_usize(&mut self, value: &usize) {
self.write_padleft(&usize::to_be_bytes(*value))
}
+ /// Append recursive data, writing pending offset at end of buffer
pub fn write_subresult(&mut self, result: Self) {
self.dynamic_part.push((self.static_part.len(), result));
// Empty block, to be filled later
self.write_padleft(&[]);
}
- pub fn memory(&mut self, value: &[u8]) {
+ fn memory(&mut self, value: &[u8]) {
let mut sub = Self::new();
- sub.write_usize(&value.len());
+ sub.uint32(&(value.len() as u32));
for chunk in value.chunks(ABI_ALIGNMENT) {
sub.write_padright(chunk);
}
self.write_subresult(sub);
}
+ /// Append recursive [`str`] at end of buffer
pub fn string(&mut self, value: &str) {
self.memory(value.as_bytes())
}
+ /// Append recursive [`[u8]`] at end of buffer
pub fn bytes(&mut self, value: &[u8]) {
self.memory(value)
}
+ /// Finish writer, concatenating all internal buffers
pub fn finish(mut self) -> Vec<u8> {
for (static_offset, part) in self.dynamic_part {
let part_offset = self.static_part.len() - self.had_call.then(|| 4).unwrap_or(0);
@@ -278,30 +325,48 @@
}
}
+/// [`AbiReader`] implements reading of many types, but it should
+/// be limited to types defined in spec
+///
+/// As this trait can't be made sealed,
+/// instead of having `impl AbiRead for T`, we have `impl AbiRead<T> for AbiReader`
pub trait AbiRead<T> {
+ /// Read item from current position, advanding decoder
fn abi_read(&mut self) -> Result<T>;
+
+ /// Size for type aligned to [`ABI_ALIGNMENT`].
+ fn size() -> usize;
}
macro_rules! impl_abi_readable {
- ($ty:ty, $method:ident) => {
+ ($ty:ty, $method:ident, $dynamic:literal) => {
+ impl TypeHelper for $ty {
+ fn is_dynamic() -> bool {
+ $dynamic
+ }
+ }
impl AbiRead<$ty> for AbiReader<'_> {
fn abi_read(&mut self) -> Result<$ty> {
self.$method()
}
+
+ fn size() -> usize {
+ ABI_ALIGNMENT
+ }
}
};
}
-impl_abi_readable!(u8, uint8);
-impl_abi_readable!(u32, uint32);
-impl_abi_readable!(u64, uint64);
-impl_abi_readable!(u128, uint128);
-impl_abi_readable!(U256, uint256);
-impl_abi_readable!([u8; 4], bytes4);
-impl_abi_readable!(H160, address);
-impl_abi_readable!(Vec<u8>, bytes);
-impl_abi_readable!(bool, bool);
-impl_abi_readable!(string, string);
+impl_abi_readable!(u8, uint8, false);
+impl_abi_readable!(u32, uint32, false);
+impl_abi_readable!(u64, uint64, false);
+impl_abi_readable!(u128, uint128, false);
+impl_abi_readable!(U256, uint256, false);
+impl_abi_readable!([u8; 4], bytes4, false);
+impl_abi_readable!(H160, address, false);
+impl_abi_readable!(Vec<u8>, bytes, true);
+impl_abi_readable!(bool, bool, true);
+impl_abi_readable!(string, string, true);
mod sealed {
/// Not all types can be placed in vec, i.e `Vec<u8>` is restricted, `bytes` should be used instead
@@ -317,8 +382,8 @@
Self: AbiRead<R>,
{
fn abi_read(&mut self) -> Result<Vec<R>> {
- let mut sub = self.subresult()?;
- let size = sub.read_usize()?;
+ let mut sub = self.subresult(None)?;
+ let size = sub.uint32()? as usize;
sub.subresult_offset = sub.offset;
let mut out = Vec::with_capacity(size);
for _ in 0..size {
@@ -326,21 +391,51 @@
}
Ok(out)
}
+
+ fn size() -> usize {
+ ABI_ALIGNMENT
+ }
}
macro_rules! impl_tuples {
($($ident:ident)+) => {
+ impl<$($ident: TypeHelper,)+> TypeHelper for ($($ident,)+) {
+ fn is_dynamic() -> bool {
+ false
+ $(
+ || <$ident>::is_dynamic()
+ )*
+ }
+ }
impl<$($ident),+> sealed::CanBePlacedInVec for ($($ident,)+) {}
impl<$($ident),+> AbiRead<($($ident,)+)> for AbiReader<'_>
where
- $(Self: AbiRead<$ident>),+
+ $(
+ Self: AbiRead<$ident>,
+ )+
+ ($($ident,)+): TypeHelper,
{
fn abi_read(&mut self) -> Result<($($ident,)+)> {
- let mut subresult = self.subresult()?;
+ let size = if !<($($ident,)+)>::is_dynamic() { Some(<Self as AbiRead<($($ident,)+)>>::size()) } else { None };
+ let mut subresult = self.subresult(size)?;
Ok((
$(<Self as AbiRead<$ident>>::abi_read(&mut subresult)?,)+
))
}
+
+ fn size() -> usize {
+ 0 $(+ <AbiReader<'_> as AbiRead<$ident>>::size())+
+ }
+ }
+ #[allow(non_snake_case)]
+ impl<$($ident),+> AbiWrite for &($($ident,)+)
+ where
+ $($ident: AbiWrite,)+
+ {
+ fn abi_write(&self, writer: &mut AbiWriter) {
+ let ($($ident,)+) = self;
+ $($ident.abi_write(writer);)+
+ }
}
};
}
@@ -356,8 +451,13 @@
impl_tuples! {A B C D E F G H I}
impl_tuples! {A B C D E F G H I J}
+/// For questions about inability to provide custom implementations,
+/// see [`AbiRead`]
pub trait AbiWrite {
+ /// Write value to end of specified encoder
fn abi_write(&self, writer: &mut AbiWriter);
+ /// Specialization for [`crate::solidity_interface`] implementation,
+ /// see comment in `impl AbiWrite for ResultWithPostInfo`
fn to_result(&self) -> ResultWithPostInfo<AbiWriter> {
let mut writer = AbiWriter::new();
self.abi_write(&mut writer);
@@ -365,13 +465,11 @@
}
}
+/// This particular AbiWrite implementation should be split to another trait,
+/// which only implements `to_result`, but due to lack of specialization feature
+/// in stable Rust, we can't have blanket impl of this trait `for T where T: AbiWrite`,
+/// so here we abusing default trait methods for it
impl<T: AbiWrite> AbiWrite for ResultWithPostInfo<T> {
- // this particular AbiWrite implementation should be split to another trait,
- // which only implements [`to_result`]
- //
- // But due to lack of specialization feature in stable Rust, we can't have
- // blanket impl of this trait `for T where T: AbiWrite`, so here we abusing
- // default trait methods for it
fn abi_write(&self, _writer: &mut AbiWriter) {
debug_assert!(false, "shouldn't be called, see comment")
}
@@ -422,6 +520,8 @@
fn abi_write(&self, _writer: &mut AbiWriter) {}
}
+/// Helper macros to parse reader into variables
+#[deprecated]
#[macro_export]
macro_rules! abi_decode {
($reader:expr, $($name:ident: $typ:ident),+ $(,)?) => {
@@ -430,6 +530,9 @@
)+
}
}
+
+/// Helper macros to construct RLP-encoded buffer
+#[deprecated]
#[macro_export]
macro_rules! abi_encode {
($($typ:ident($value:expr)),* $(,)?) => {{
@@ -479,7 +582,7 @@
assert_eq!(encoded, alternative_encoded);
let mut decoder = AbiReader::new(&encoded);
- assert_eq!(decoder.bool().unwrap(), true);
+ assert!(decoder.bool().unwrap());
assert_eq!(decoder.string().unwrap(), "test");
}
@@ -548,4 +651,49 @@
]
);
}
+
+ #[test]
+ fn parse_vec_with_simple_type() {
+ use crate::types::address;
+ use primitive_types::{H160, U256};
+
+ let (call, mut decoder) = AbiReader::new_call(&hex!(
+ "
+ 1ACF2D55
+ 0000000000000000000000000000000000000000000000000000000000000020 // offset of (address, uint256)[]
+ 0000000000000000000000000000000000000000000000000000000000000003 // length of (address, uint256)[]
+
+ 0000000000000000000000002D2FF76104B7BACB2E8F6731D5BFC184EBECDDBC // address
+ 000000000000000000000000000000000000000000000000000000000000000A // uint256
+
+ 000000000000000000000000AB8E3D9134955566483B11E6825C9223B6737B10 // address
+ 0000000000000000000000000000000000000000000000000000000000000014 // uint256
+
+ 0000000000000000000000008C582BDF2953046705FC56F189385255EFC1BE18 // address
+ 000000000000000000000000000000000000000000000000000000000000001E // uint256
+ "
+ ))
+ .unwrap();
+ assert_eq!(call, u32::to_be_bytes(0x1ACF2D55));
+ let data =
+ <AbiReader<'_> as AbiRead<Vec<(address, uint256)>>>::abi_read(&mut decoder).unwrap();
+ assert_eq!(data.len(), 3);
+ assert_eq!(
+ data,
+ vec![
+ (
+ H160(hex!("2D2FF76104B7BACB2E8F6731D5BFC184EBECDDBC")),
+ U256([10, 0, 0, 0])
+ ),
+ (
+ H160(hex!("AB8E3D9134955566483B11E6825C9223B6737B10")),
+ U256([20, 0, 0, 0])
+ ),
+ (
+ H160(hex!("8C582BDF2953046705FC56F189385255EFC1BE18")),
+ U256([30, 0, 0, 0])
+ ),
+ ]
+ );
+ }
}
crates/evm-coder/src/events.rsdiffbeforeafterboth--- a/crates/evm-coder/src/events.rs
+++ b/crates/evm-coder/src/events.rs
@@ -19,11 +19,23 @@
use crate::types::*;
+/// Implementation of this trait should not be written manually,
+/// instead use [`crate::ToLog`] proc macros.
+///
+/// See also [`evm_coder_procedural::ToLog`], [solidity docs on events](https://docs.soliditylang.org/en/develop/contracts.html#events)
pub trait ToLog {
+ /// Convert event to [`ethereum::Log`].
+ /// Because event by itself doesn't contains current contract
+ /// address, it should be specified manually.
fn to_log(&self, contract: H160) -> Log;
}
+/// Only items implementing `ToTopic` may be used as `#[indexed]` field
+/// in [`crate::ToLog`] macro usage.
+///
+/// See also (solidity docs on events)[<https://docs.soliditylang.org/en/develop/contracts.html#events>]
pub trait ToTopic {
+ /// Convert value to topic to be used in [`ethereum::Log`]
fn to_topic(&self) -> H256;
}
crates/evm-coder/src/execution.rsdiffbeforeafterboth--- a/crates/evm-coder/src/execution.rs
+++ b/crates/evm-coder/src/execution.rs
@@ -14,6 +14,8 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+//! Contract execution related types
+
#[cfg(not(feature = "std"))]
use alloc::string::{String, ToString};
use evm_core::{ExitError, ExitFatal};
@@ -22,10 +24,14 @@
use crate::Weight;
+/// Execution error, should be convertible between EVM and Substrate.
#[derive(Debug, Clone)]
pub enum Error {
+ /// Non-fatal contract error occured
Revert(String),
+ /// EVM fatal error
Fatal(ExitFatal),
+ /// EVM normal error
Error(ExitError),
}
@@ -38,9 +44,12 @@
}
}
+/// To be used in [`crate::solidity_interface`] implementation.
pub type Result<T> = core::result::Result<T, Error>;
+/// Static information collected from [`crate::weight`].
pub struct DispatchInfo {
+ /// Statically predicted call weight
pub weight: Weight,
}
@@ -55,16 +64,22 @@
}
}
+/// Weight information that is only available post dispatch.
+/// Note: This can only be used to reduce the weight or fee, not increase it.
#[derive(Default, Clone)]
pub struct PostDispatchInfo {
+ /// Actual weight consumed by call
actual_weight: Option<Weight>,
}
impl PostDispatchInfo {
+ /// Calculate amount to be returned back to user
pub fn calc_unspent(&self, info: &DispatchInfo) -> Weight {
info.weight - self.calc_actual_weight(info)
}
+ /// Calculate actual consumed weight, saturating to weight reported
+ /// pre-dispatch
pub fn calc_actual_weight(&self, info: &DispatchInfo) -> Weight {
if let Some(actual_weight) = self.actual_weight {
actual_weight.min(info.weight)
@@ -74,9 +89,12 @@
}
}
+/// Wrapper for PostDispatchInfo and any user-provided data
#[derive(Clone)]
pub struct WithPostDispatchInfo<T> {
+ /// User provided data
pub data: T,
+ /// Info known after dispatch
pub post_info: PostDispatchInfo,
}
@@ -89,5 +107,6 @@
}
}
+/// Return type of items in [`crate::solidity_interface`] definition
pub type ResultWithPostInfo<T> =
core::result::Result<WithPostDispatchInfo<T>, WithPostDispatchInfo<Error>>;
crates/evm-coder/src/lib.rsdiffbeforeafterboth--- a/crates/evm-coder/src/lib.rs
+++ b/crates/evm-coder/src/lib.rs
@@ -14,22 +14,103 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+#![doc = include_str!("../README.md")]
+#![deny(missing_docs)]
#![cfg_attr(not(feature = "std"), no_std)]
#[cfg(not(feature = "std"))]
extern crate alloc;
use abi::{AbiRead, AbiReader, AbiWriter};
-pub use evm_coder_macros::{event_topic, fn_selector, solidity_interface, solidity, weight, ToLog};
+pub use evm_coder_procedural::{event_topic, fn_selector};
pub mod abi;
-pub mod events;
-pub use events::ToLog;
+pub use events::{ToLog, ToTopic};
use execution::DispatchInfo;
pub mod execution;
+
+/// Derives call enum implementing [`crate::Callable`], [`crate::Weighted`]
+/// and [`crate::Call`] from impl block.
+///
+/// ## Macro syntax
+///
+/// `#[solidity_interface(name, is, inline_is, events)]`
+/// - *name* - used in generated code, and for Call enum name
+/// - *is* - used to provide inheritance in Solidity
+/// - *inline_is* - same as `is`, but ERC165::SupportsInterface will work differently: For `is` SupportsInterface(A) will return true
+/// if A is one of the interfaces the contract is inherited from (e.g. B is created as `is(A)`). If B is created as `inline_is(A)`
+/// SupportsInterface(A) will internally create a new interface that combines all methods of A and B, so SupportsInterface(A) will return
+/// false.
+///
+/// `#[weight(value)]`
+/// Can be added to every method of impl block, used for deriving [`crate::Weighted`], which
+/// is used by substrate bridge.
+/// - *value*: expression, which evaluates to weight required to call this method.
+/// This expression can use call arguments to calculate non-constant execution time.
+/// This expression should evaluate faster than actual execution does, and may provide worse case
+/// than one is called.
+///
+/// `#[solidity_interface(rename_selector)]`
+/// - *rename_selector* - by default, selector name will be generated by transforming method name
+/// from snake_case to camelCase. Use this option, if other naming convention is required.
+/// I.e: method `token_uri` will be automatically renamed to `tokenUri` in selector, but name
+/// required by ERC721 standard is `tokenURI`, thus we need to specify `rename_selector = "tokenURI"`
+/// explicitly.
+///
+/// Both contract and contract methods may have doccomments, which will end up in a generated
+/// solidity interface file, thus you should use [solidity syntax](https://docs.soliditylang.org/en/latest/natspec-format.html) for writing documentation in this macro
+///
+/// ## Example
+///
+/// ```ignore
+/// struct SuperContract;
+/// struct InlineContract;
+/// struct Contract;
+///
+/// #[derive(ToLog)]
+/// enum ContractEvents {
+/// Event(#[indexed] uint32),
+/// }
+///
+/// /// @dev This contract provides function to multiply two numbers
+/// #[solidity_interface(name = MyContract, is(SuperContract), inline_is(InlineContract))]
+/// impl Contract {
+/// /// Multiply two numbers
+/// /// @param a First number
+/// /// @param b Second number
+/// /// @return uint32 Product of two passed numbers
+/// /// @dev This function returns error in case of overflow
+/// #[weight(200 + a + b)]
+/// #[solidity_interface(rename_selector = "mul")]
+/// fn mul(&mut self, a: uint32, b: uint32) -> Result<uint32> {
+/// Ok(a.checked_mul(b).ok_or("overflow")?)
+/// }
+/// }
+/// ```
+pub use evm_coder_procedural::solidity_interface;
+/// See [`solidity_interface`]
+pub use evm_coder_procedural::solidity;
+/// See [`solidity_interface`]
+pub use evm_coder_procedural::weight;
+
+/// Derives [`ToLog`] for enum
+///
+/// Selectors will be derived from variant names, there is currently no way to have custom naming
+/// for them
+///
+/// `#[indexed]`
+/// Marks this field as indexed, so it will appear in [`ethereum::Log`] topics instead of data
+pub use evm_coder_procedural::ToLog;
+
+// Api of those modules shouldn't be consumed directly, it is only exported for usage in proc macros
+#[doc(hidden)]
+pub mod events;
+#[doc(hidden)]
pub mod solidity;
-/// Solidity type definitions
+/// Solidity type definitions (aliases from solidity name to rust type)
+/// To be used in [`solidity_interface`] definitions, to make sure there is no
+/// type conflict between Rust code and generated definitions
pub mod types {
- #![allow(non_camel_case_types)]
+ #![allow(non_camel_case_types, missing_docs)]
#[cfg(not(feature = "std"))]
use alloc::{vec::Vec};
@@ -54,6 +135,8 @@
pub type string = ::std::string::String;
pub type bytes = Vec<u8>;
+ /// Solidity doesn't have `void` type, however we have special implementation
+ /// for empty tuple return type
pub type void = ();
//#region Special types
@@ -63,36 +146,64 @@
pub type caller = address;
//#endregion
+ /// Ethereum typed call message, similar to solidity
+ /// `msg` object.
pub struct Msg<C> {
pub call: C,
+ /// Address of user, which called this contract.
pub caller: H160,
+ /// Payment amount to contract.
+ /// Contract should reject payment, if target call is not payable,
+ /// and there is no `receiver()` function defined.
pub value: U256,
}
}
+/// Parseable EVM call, this trait should be implemented with [`solidity_interface`] macro
pub trait Call: Sized {
+ /// Parse call buffer into typed call enum
fn parse(selector: types::bytes4, input: &mut AbiReader) -> execution::Result<Option<Self>>;
}
+/// Intended to be used as `#[weight]` output type
+/// Should be same between evm-coder and substrate to avoid confusion
+///
+/// Isn't same thing as gas, some mapping is required between those types
pub type Weight = u64;
+/// In substrate, we have benchmarking, which allows
+/// us to not rely on gas metering, but instead predict amount of gas to execute call
pub trait Weighted: Call {
+ /// Predict weight of this call
fn weight(&self) -> DispatchInfo;
}
+/// Type callable with ethereum message, may be implemented by [`solidity_interface`] macro
+/// on interface implementation, or for externally-owned real EVM contract
pub trait Callable<C: Call> {
+ /// Call contract using specified call data
fn call(&mut self, call: types::Msg<C>) -> execution::ResultWithPostInfo<AbiWriter>;
}
-/// Implementation is implicitly provided for all interfaces
+/// Implementation of ERC165 is implicitly generated for all interfaces in [`solidity_interface`],
+/// this structure holds parsed data for ERC165Call subvariant
+///
+/// Note: no [`Callable`] implementation is provided, call implementation is inlined into every
+/// implementing contract
///
-/// Note: no Callable implementation is provided
+/// See <https://eips.ethereum.org/EIPS/eip-165>
#[derive(Debug)]
pub enum ERC165Call {
- SupportsInterface { interface_id: types::bytes4 },
+ /// ERC165 provides single method, which returns true, if contract
+ /// implements specified interface
+ SupportsInterface {
+ /// Requested interface
+ interface_id: types::bytes4,
+ },
}
impl ERC165Call {
+ /// ERC165 selector is provided by standard
pub const INTERFACE_ID: types::bytes4 = u32::to_be_bytes(0x01ffc9a7);
}
crates/evm-coder/src/solidity.rsdiffbeforeafterboth--- a/crates/evm-coder/src/solidity.rs
+++ b/crates/evm-coder/src/solidity.rs
@@ -14,26 +14,31 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+//! Implementation detail of [`crate::solidity_interface`] macro code-generation.
+//! You should not rely on any public item from this module, as it is only intended to be used
+//! by procedural macro, API and output format may be changed at any time.
+//!
+//! Purpose of this module is to receive solidity contract definition in module-specified
+//! format, and then output string, representing interface of this contract in solidity language
+
#[cfg(not(feature = "std"))]
-use alloc::{
- string::String,
- vec::Vec,
- collections::{BTreeSet, BTreeMap},
- format,
-};
+use alloc::{string::String, vec::Vec, collections::BTreeMap, format};
#[cfg(feature = "std")]
-use std::collections::{BTreeSet, BTreeMap};
+use std::collections::BTreeMap;
use core::{
fmt::{self, Write},
marker::PhantomData,
cell::{Cell, RefCell},
+ cmp::Reverse,
};
use impl_trait_for_tuples::impl_for_tuples;
use crate::types::*;
#[derive(Default)]
pub struct TypeCollector {
- structs: RefCell<BTreeSet<string>>,
+ /// Code => id
+ /// id ordering is required to perform topo-sort on the resulting data
+ structs: RefCell<BTreeMap<string, usize>>,
anonymous: RefCell<BTreeMap<Vec<string>, usize>>,
id: Cell<usize>,
}
@@ -42,7 +47,8 @@
Self::default()
}
pub fn collect(&self, item: string) {
- self.structs.borrow_mut().insert(item);
+ let id = self.next_id();
+ self.structs.borrow_mut().insert(item, id);
}
pub fn next_id(&self) -> usize {
let v = self.id.get();
@@ -56,7 +62,7 @@
}
let id = self.next_id();
let mut str = String::new();
- writeln!(str, "// Anonymous struct").unwrap();
+ writeln!(str, "/// @dev anonymous struct").unwrap();
writeln!(str, "struct Tuple{} {{", id).unwrap();
for (i, name) in names.iter().enumerate() {
writeln!(str, "\t{} field_{};", name, i).unwrap();
@@ -66,15 +72,19 @@
self.anonymous.borrow_mut().insert(names, id);
format!("Tuple{}", id)
}
- pub fn finish(self) -> BTreeSet<string> {
- self.structs.into_inner()
+ pub fn finish(self) -> Vec<string> {
+ let mut data = self.structs.into_inner().into_iter().collect::<Vec<_>>();
+ data.sort_by_key(|(_, id)| Reverse(*id));
+ data.into_iter().map(|(code, _)| code).collect()
}
}
pub trait SolidityTypeName: 'static {
fn solidity_name(writer: &mut impl fmt::Write, tc: &TypeCollector) -> fmt::Result;
+ /// "simple" types are stored inline, no `memory` modifier should be used in solidity
fn is_simple() -> bool;
fn solidity_default(writer: &mut impl fmt::Write, tc: &TypeCollector) -> fmt::Result;
+ /// Specialization
fn is_void() -> bool {
false
}
@@ -125,6 +135,10 @@
}
mod sealed {
+ /// Not every type should be directly placed in vec.
+ /// Vec encoding is not memory efficient, as every item will be padded
+ /// to 32 bytes.
+ /// Instead you should use specialized types (`bytes` in case of `Vec<u8>`)
pub trait CanBePlacedInVec {}
}
@@ -180,9 +194,16 @@
fn is_simple() -> bool {
false
}
+ #[allow(unused_assignments)]
fn solidity_default(writer: &mut impl fmt::Write, tc: &TypeCollector) -> fmt::Result {
write!(writer, "{}(", tc.collect_tuple::<Self>())?;
+ let mut first = true;
$(
+ if !first {
+ write!(writer, ",")?;
+ } else {
+ first = false;
+ }
<$ident>::solidity_default(writer, tc)?;
)*
write!(writer, ")")
@@ -395,7 +416,8 @@
}
pub struct SolidityFunction<A, R> {
pub docs: &'static [&'static str],
- pub selector: &'static str,
+ pub selector_str: &'static str,
+ pub selector: u32,
pub name: &'static str,
pub args: A,
pub result: R,
@@ -409,12 +431,14 @@
tc: &TypeCollector,
) -> fmt::Result {
for doc in self.docs {
- writeln!(writer, "\t//{}", doc)?;
+ writeln!(writer, "\t///{}", doc)?;
}
- if !self.docs.is_empty() {
- writeln!(writer, "\t//")?;
- }
- writeln!(writer, "\t// Selector: {}", self.selector)?;
+ writeln!(
+ writer,
+ "\t/// @dev EVM selector for this function is: 0x{:0>8x},",
+ self.selector
+ )?;
+ writeln!(writer, "\t/// or in textual repr: {}", self.selector_str)?;
write!(writer, "\tfunction {}(", self.name)?;
self.args.solidity_name(writer, tc)?;
write!(writer, ")")?;
@@ -455,7 +479,7 @@
}
}
-#[impl_for_tuples(0, 24)]
+#[impl_for_tuples(0, 48)]
impl SolidityFunctions for Tuple {
for_tuples!( where #( Tuple: SolidityFunctions ),* );
@@ -474,6 +498,7 @@
}
pub struct SolidityInterface<F: SolidityFunctions> {
+ pub docs: &'static [&'static str],
pub selector: bytes4,
pub name: &'static str,
pub is: &'static [&'static str],
@@ -488,10 +513,13 @@
tc: &TypeCollector,
) -> fmt::Result {
const ZERO_BYTES: [u8; 4] = [0; 4];
+ for doc in self.docs {
+ writeln!(out, "///{}", doc)?;
+ }
if self.selector != ZERO_BYTES {
writeln!(
out,
- "// Selector: {:0>8x}",
+ "/// @dev the ERC-165 identifier for this interface is 0x{:0>8x}",
u32::from_be_bytes(self.selector)
)?;
}
crates/evm-coder/tests/generics.rsdiffbeforeafterboth--- a/crates/evm-coder/tests/generics.rs
+++ b/crates/evm-coder/tests/generics.rs
@@ -19,14 +19,14 @@
struct Generic<T>(PhantomData<T>);
-#[solidity_interface(name = "GenericIs")]
+#[solidity_interface(name = GenericIs)]
impl<T> Generic<T> {
fn test_1(&self) -> Result<uint256> {
unreachable!()
}
}
-#[solidity_interface(name = "Generic", is(GenericIs))]
+#[solidity_interface(name = Generic, is(GenericIs))]
impl<T: Into<u32>> Generic<T> {
fn test_2(&self) -> Result<uint256> {
unreachable!()
@@ -35,7 +35,7 @@
generate_stubgen!(gen_iface, GenericCall<()>, false);
-#[solidity_interface(name = "GenericWhere")]
+#[solidity_interface(name = GenericWhere)]
impl<T> Generic<T>
where
T: core::fmt::Debug,
crates/evm-coder/tests/random.rsdiffbeforeafterboth--- a/crates/evm-coder/tests/random.rs
+++ b/crates/evm-coder/tests/random.rs
@@ -16,19 +16,18 @@
#![allow(dead_code)] // This test only checks that macros is not panicking
-use evm_coder::{ToLog, execution::Result, solidity_interface, types::*};
-use evm_coder_macros::{solidity, weight};
+use evm_coder::{ToLog, execution::Result, solidity_interface, types::*, solidity, weight};
struct Impls;
-#[solidity_interface(name = "OurInterface")]
+#[solidity_interface(name = OurInterface)]
impl Impls {
fn fn_a(&self, _input: uint256) -> Result<bool> {
unreachable!()
}
}
-#[solidity_interface(name = "OurInterface1")]
+#[solidity_interface(name = OurInterface1)]
impl Impls {
fn fn_b(&self, _input: uint128) -> Result<uint32> {
unreachable!()
@@ -48,7 +47,7 @@
}
#[solidity_interface(
- name = "OurInterface2",
+ name = OurInterface2,
is(OurInterface),
inline_is(OurInterface1),
events(OurEvents)
@@ -79,3 +78,9 @@
unreachable!()
}
}
+
+#[solidity_interface(
+ name = ValidSelector,
+ expect_selector = 0x00000000,
+)]
+impl Impls {}
crates/evm-coder/tests/solidity_generation.rsdiffbeforeafterboth--- a/crates/evm-coder/tests/solidity_generation.rs
+++ b/crates/evm-coder/tests/solidity_generation.rs
@@ -18,7 +18,7 @@
struct ERC20;
-#[solidity_interface(name = "ERC20")]
+#[solidity_interface(name = ERC20)]
impl ERC20 {
fn decimals(&self) -> Result<uint8> {
unreachable!()
node/cli/src/chain_spec.rsdiffbeforeafterboth--- a/node/cli/src/chain_spec.rs
+++ b/node/cli/src/chain_spec.rs
@@ -123,7 +123,7 @@
.public()
}
-/// The extensions for the [`ChainSpec`].
+/// The extensions for the [`DefaultChainSpec`].
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize, ChainSpecGroup, ChainSpecExtension)]
#[serde(deny_unknown_fields)]
pub struct Extensions {
pallets/common/CHANGELOG.mddiffbeforeafterboth--- a/pallets/common/CHANGELOG.md
+++ b/pallets/common/CHANGELOG.md
@@ -2,6 +2,28 @@
All notable changes to this project will be documented in this file.
+## [0.1.8] - 2022-08-24
+
+## Added
+ - Eth methods for collection
+ + set_collection_sponsor_substrate
+ + has_collection_pending_sponsor
+ + remove_collection_sponsor
+ + get_collection_sponsor
+- Add convert function from `uint256` to `CrossAccountId`.
+
+## [0.1.7] - 2022-08-19
+
+### Added
+
+ - Add convert funtion from `CrossAccountId` to eth `uint256`.
+
+
+## [0.1.6] - 2022-08-16
+
+### Added
+- New Ethereum API methods: changeOwner, changeOwner(Substrate) and verifyOwnerOrAdmin(Substrate).
+
<!-- bureaucrate goes here -->
## [v0.1.5] 2022-08-16
pallets/common/Cargo.tomldiffbeforeafterboth--- a/pallets/common/Cargo.toml
+++ b/pallets/common/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "pallet-common"
-version = "0.1.5"
+version = "0.1.8"
license = "GPLv3"
edition = "2021"
pallets/common/src/erc.rsdiffbeforeafterboth--- a/pallets/common/src/erc.rs
+++ b/pallets/common/src/erc.rs
@@ -26,11 +26,14 @@
use sp_std::vec::Vec;
use up_data_structs::{
AccessMode, CollectionMode, CollectionPermissions, OwnerRestrictedSet, Property,
- SponsoringRateLimit,
+ SponsoringRateLimit, SponsorshipState,
};
use alloc::format;
-use crate::{Pallet, CollectionHandle, Config, CollectionProperties};
+use crate::{
+ Pallet, CollectionHandle, Config, CollectionProperties,
+ eth::{convert_cross_account_to_uint256, convert_uint256_to_cross_account},
+};
/// Events for ethereum collection helper.
#[derive(ToLog)]
@@ -57,10 +60,10 @@
}
/// @title A contract that allows you to work with collections.
-#[solidity_interface(name = "Collection")]
+#[solidity_interface(name = Collection)]
impl<T: Config> CollectionHandle<T>
where
- T::AccountId: From<[u8; 32]>,
+ T::AccountId: From<[u8; 32]> + AsRef<[u8; 32]>,
{
/// Set collection property.
///
@@ -125,6 +128,32 @@
save(self)
}
+ /// Set the substrate sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Substrate address of the sponsor from whose account funds will be debited for operations with the contract.
+ fn set_collection_sponsor_substrate(
+ &mut self,
+ caller: caller,
+ sponsor: uint256,
+ ) -> Result<void> {
+ check_is_owner_or_admin(caller, self)?;
+
+ let sponsor = convert_uint256_to_cross_account::<T>(sponsor);
+ self.set_sponsor(sponsor.as_sub().clone())
+ .map_err(dispatch_to_evm::<T>)?;
+ save(self)
+ }
+
+ // /// Whether there is a pending sponsor.
+ fn has_collection_pending_sponsor(&self) -> Result<bool> {
+ Ok(matches!(
+ self.collection.sponsorship,
+ SponsorshipState::Unconfirmed(_)
+ ))
+ }
+
/// Collection sponsorship confirmation.
///
/// @dev After setting the sponsor for the collection, it must be confirmed with this function.
@@ -139,6 +168,32 @@
save(self)
}
+ /// Remove collection sponsor.
+ fn remove_collection_sponsor(&mut self, caller: caller) -> Result<void> {
+ check_is_owner_or_admin(caller, self)?;
+ self.remove_sponsor().map_err(dispatch_to_evm::<T>)?;
+ save(self)
+ }
+
+ /// Get current sponsor.
+ ///
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ fn get_collection_sponsor(&self) -> Result<(address, uint256)> {
+ let sponsor = match self.collection.sponsorship.sponsor() {
+ Some(sponsor) => sponsor,
+ None => return Ok(Default::default()),
+ };
+ let sponsor = T::CrossAccountId::from_sub(sponsor.clone());
+ let result: (address, uint256) = if sponsor.is_canonical_substrate() {
+ let sponsor = convert_cross_account_to_uint256::<T>(&sponsor);
+ (Default::default(), sponsor)
+ } else {
+ let sponsor = *sponsor.as_eth();
+ (sponsor, Default::default())
+ };
+ Ok(result)
+ }
+
/// Set limits for the collection.
/// @dev Throws error if limit not found.
/// @param limit Name of the limit. Valid names:
@@ -225,17 +280,14 @@
}
/// Add collection admin by substrate address.
- /// @param new_admin Substrate administrator address.
+ /// @param newAdmin Substrate administrator address.
fn add_collection_admin_substrate(
&mut self,
caller: caller,
new_admin: uint256,
) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
- let mut new_admin_arr: [u8; 32] = Default::default();
- new_admin.to_big_endian(&mut new_admin_arr);
- let account_id = T::AccountId::from(new_admin_arr);
- let new_admin = T::CrossAccountId::from_sub(account_id);
+ let new_admin = convert_uint256_to_cross_account::<T>(new_admin);
<Pallet<T>>::toggle_admin(self, &caller, &new_admin, true).map_err(dispatch_to_evm::<T>)?;
Ok(())
}
@@ -248,16 +300,13 @@
admin: uint256,
) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
- let mut admin_arr: [u8; 32] = Default::default();
- admin.to_big_endian(&mut admin_arr);
- let account_id = T::AccountId::from(admin_arr);
- let admin = T::CrossAccountId::from_sub(account_id);
+ let admin = convert_uint256_to_cross_account::<T>(admin);
<Pallet<T>>::toggle_admin(self, &caller, &admin, false).map_err(dispatch_to_evm::<T>)?;
Ok(())
}
/// Add collection admin.
- /// @param new_admin Address of the added administrator.
+ /// @param newAdmin Address of the added administrator.
fn add_collection_admin(&mut self, caller: caller, new_admin: address) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let new_admin = T::CrossAccountId::from_eth(new_admin);
@@ -267,7 +316,7 @@
/// Remove collection admin.
///
- /// @param new_admin Address of the removed administrator.
+ /// @param admin Address of the removed administrator.
fn remove_collection_admin(&mut self, caller: caller, admin: address) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let admin = T::CrossAccountId::from_eth(admin);
@@ -414,12 +463,21 @@
///
/// @param user account to verify
/// @return "true" if account is the owner or admin
- fn verify_owner_or_admin(&self, user: address) -> Result<bool> {
- Ok(check_is_owner_or_admin(user, self)
- .map(|_| true)
- .unwrap_or(false))
+ #[solidity(rename_selector = "isOwnerOrAdmin")]
+ fn is_owner_or_admin_eth(&self, user: address) -> Result<bool> {
+ let user = T::CrossAccountId::from_eth(user);
+ Ok(self.is_owner_or_admin(&user))
}
+ /// Check that substrate account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ fn is_owner_or_admin_substrate(&self, user: uint256) -> Result<bool> {
+ let user = convert_uint256_to_cross_account::<T>(user);
+ Ok(self.is_owner_or_admin(&user))
+ }
+
/// Returns collection type
///
/// @return `Fungible` or `NFT` or `ReFungible`
@@ -431,6 +489,28 @@
};
Ok(mode.into())
}
+
+ /// Changes collection owner to another account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner account
+ fn set_owner(&mut self, caller: caller, new_owner: address) -> Result<void> {
+ let caller = T::CrossAccountId::from_eth(caller);
+ let new_owner = T::CrossAccountId::from_eth(new_owner);
+ self.set_owner_internal(caller, new_owner)
+ .map_err(dispatch_to_evm::<T>)
+ }
+
+ /// Changes collection owner to another substrate account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner substrate account
+ fn set_owner_substrate(&mut self, caller: caller, new_owner: uint256) -> Result<void> {
+ let caller = T::CrossAccountId::from_eth(caller);
+ let new_owner = convert_uint256_to_cross_account::<T>(new_owner);
+ self.set_owner_internal(caller, new_owner)
+ .map_err(dispatch_to_evm::<T>)
+ }
}
fn check_is_owner_or_admin<T: Config>(
@@ -440,16 +520,17 @@
let caller = T::CrossAccountId::from_eth(caller);
collection
.check_is_owner_or_admin(&caller)
- .map_err(pallet_evm_coder_substrate::dispatch_to_evm::<T>)?;
+ .map_err(dispatch_to_evm::<T>)?;
Ok(caller)
}
fn save<T: Config>(collection: &CollectionHandle<T>) -> Result<void> {
// TODO possibly delete for the lack of transaction
+ collection.consume_store_writes(1)?;
collection
.check_is_internal()
.map_err(dispatch_to_evm::<T>)?;
- <crate::CollectionById<T>>::insert(collection.id, collection.collection.clone());
+ collection.save().map_err(dispatch_to_evm::<T>)?;
Ok(())
}
pallets/common/src/eth.rsdiffbeforeafterboth--- a/pallets/common/src/eth.rs
+++ b/pallets/common/src/eth.rs
@@ -16,8 +16,10 @@
//! The module contains a number of functions for converting and checking ethereum identifiers.
+use evm_coder::types::uint256;
+pub use pallet_evm::account::{Config, CrossAccountId};
+use sp_core::H160;
use up_data_structs::CollectionId;
-use sp_core::H160;
// 0x17c4e6453Cc49AAAaEACA894e6D9683e00000001 - collection 1
// TODO: Unhardcode prefix
@@ -47,3 +49,23 @@
pub fn is_collection(address: &H160) -> bool {
address[0..16] == ETH_COLLECTION_PREFIX
}
+
+/// Convert `CrossAccountId` to `uint256`.
+pub fn convert_cross_account_to_uint256<T: Config>(from: &T::CrossAccountId) -> uint256
+where
+ T::AccountId: AsRef<[u8; 32]>,
+{
+ let slice = from.as_sub().as_ref();
+ uint256::from_big_endian(slice)
+}
+
+/// Convert `uint256` to `CrossAccountId`.
+pub fn convert_uint256_to_cross_account<T: Config>(from: uint256) -> T::CrossAccountId
+where
+ T::AccountId: From<[u8; 32]>,
+{
+ let mut new_admin_arr = [0_u8; 32];
+ from.to_big_endian(&mut new_admin_arr);
+ let account_id = T::AccountId::from(new_admin_arr);
+ T::CrossAccountId::from_sub(account_id)
+}
pallets/common/src/lib.rsdiffbeforeafterboth--- a/pallets/common/src/lib.rs
+++ b/pallets/common/src/lib.rs
@@ -203,8 +203,8 @@
}
/// Save collection to storage.
- pub fn save(self) -> DispatchResult {
- <CollectionById<T>>::insert(self.id, self.collection);
+ pub fn save(&self) -> DispatchResult {
+ <CollectionById<T>>::insert(self.id, &self.collection);
Ok(())
}
@@ -231,6 +231,12 @@
Ok(true)
}
+ /// Remove collection sponsor.
+ pub fn remove_sponsor(&mut self) -> DispatchResult {
+ self.collection.sponsorship = SponsorshipState::Disabled;
+ Ok(())
+ }
+
/// Checks that the collection was created with, and must be operated upon through **Unique API**.
/// Now check only the `external_collection` flag and if it's **true**, then return [`Error::CollectionIsExternal`] error.
pub fn check_is_internal(&self) -> DispatchResult {
@@ -302,6 +308,17 @@
);
Ok(())
}
+
+ /// Changes collection owner to another account
+ fn set_owner_internal(
+ &mut self,
+ caller: T::CrossAccountId,
+ new_owner: T::CrossAccountId,
+ ) -> DispatchResult {
+ self.check_is_owner(&caller)?;
+ self.collection.owner = new_owner.as_sub().clone();
+ self.save()
+ }
}
#[frame_support::pallet]
@@ -721,12 +738,7 @@
/// Get the effective limits for the collection.
pub fn effective_collection_limits(collection: CollectionId) -> Option<CollectionLimits> {
- let collection = <CollectionById<T>>::get(collection);
- if collection.is_none() {
- return None;
- }
-
- let collection = collection.unwrap();
+ let collection = <CollectionById<T>>::get(collection)?;
let limits = collection.limits;
let effective_limits = CollectionLimits {
account_token_ownership_limit: Some(limits.account_token_ownership_limit()),
pallets/evm-contract-helpers/CHANGELOG.mddiffbeforeafterboth--- a/pallets/evm-contract-helpers/CHANGELOG.md
+++ b/pallets/evm-contract-helpers/CHANGELOG.md
@@ -1,4 +1,24 @@
-<!-- bureaucrate goes here -->
+# Change Log
+
+All notable changes to this project will be documented in this file.
+
+## [v0.2.0] - 2022-08-19
+
+### Added
+
+ - Set arbitrary evm address as contract sponsor.
+ - Ability to remove current sponsor.
+
+### Removed
+ - Remove methods
+ + sponsoring_enabled
+ + toggle_sponsoring
+
+ ### Changed
+
+ - Change `toggle_sponsoring` to `self_sponsored_enable`.
+
+
## [v0.1.2] 2022-08-16
### Other changes
pallets/evm-contract-helpers/Cargo.tomldiffbeforeafterboth--- a/pallets/evm-contract-helpers/Cargo.toml
+++ b/pallets/evm-contract-helpers/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "pallet-evm-contract-helpers"
-version = "0.1.2"
+version = "0.2.0"
license = "GPLv3"
edition = "2021"
pallets/evm-contract-helpers/README.mddiffbeforeafterboth--- /dev/null
+++ b/pallets/evm-contract-helpers/README.md
@@ -0,0 +1,13 @@
+# EVM Contract Helpers
+
+This pallet extends pallet-evm contracts with several new functions.
+
+## Overview
+
+Evm contract helpers pallet provides ability to
+
+- Tracking and getting of user, which deployed contract
+- Sponsoring EVM contract calls (Make transaction calls to be free for users, instead making them being paid from contract address)
+- Allowlist access mode
+
+As most of those functions are intented to be consumed by ethereum users, only API provided by this pallet is [ContractHelpers magic contract](./src/stubs/ContractHelpers.sol)
\ No newline at end of file
pallets/evm-contract-helpers/src/eth.rsdiffbeforeafterboth--- a/pallets/evm-contract-helpers/src/eth.rs
+++ b/pallets/evm-contract-helpers/src/eth.rs
@@ -14,22 +14,27 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+//! Implementation of magic contract
+
use core::marker::PhantomData;
use evm_coder::{abi::AbiWriter, execution::Result, generate_stubgen, solidity_interface, types::*};
-use pallet_evm_coder_substrate::{SubstrateRecorder, WithRecorder};
+use pallet_evm_coder_substrate::{SubstrateRecorder, WithRecorder, dispatch_to_evm};
use pallet_evm::{
ExitRevert, OnCreate, OnMethodCall, PrecompileResult, PrecompileFailure, PrecompileHandle,
account::CrossAccountId,
};
use sp_core::H160;
+use up_data_structs::SponsorshipState;
use crate::{
AllowlistEnabled, Config, Owner, Pallet, SponsorBasket, SponsoringRateLimit, SponsoringModeT,
+ Sponsoring,
};
use frame_support::traits::Get;
use up_sponsorship::SponsorshipHandler;
use sp_std::vec::Vec;
-struct ContractHelpers<T: Config>(SubstrateRecorder<T>);
+/// See [`ContractHelpersCall`]
+pub struct ContractHelpers<T: Config>(SubstrateRecorder<T>);
impl<T: Config> WithRecorder<T> for ContractHelpers<T> {
fn recorder(&self) -> &SubstrateRecorder<T> {
&self.0
@@ -40,96 +45,238 @@
}
}
-#[solidity_interface(name = "ContractHelpers")]
-impl<T: Config> ContractHelpers<T> {
+/// @title Magic contract, which allows users to reconfigure other contracts
+#[solidity_interface(name = ContractHelpers)]
+impl<T: Config> ContractHelpers<T>
+where
+ T::AccountId: AsRef<[u8; 32]>,
+{
+ /// Get user, which deployed specified contract
+ /// @dev May return zero address in case if contract is deployed
+ /// using uniquenetwork evm-migration pallet, or using other terms not
+ /// intended by pallet-evm
+ /// @dev Returns zero address if contract does not exists
+ /// @param contractAddress Contract to get owner of
+ /// @return address Owner of contract
fn contract_owner(&self, contract_address: address) -> Result<address> {
Ok(<Owner<T>>::get(contract_address))
}
- fn sponsoring_enabled(&self, contract_address: address) -> Result<bool> {
- Ok(<Pallet<T>>::sponsoring_mode(contract_address) != SponsoringModeT::Disabled)
- }
-
- /// Deprecated
- fn toggle_sponsoring(
+ /// Set sponsor.
+ /// @param contractAddress Contract for which a sponsor is being established.
+ /// @param sponsor User address who set as pending sponsor.
+ fn set_sponsor(
&mut self,
caller: caller,
contract_address: address,
- enabled: bool,
+ sponsor: address,
) -> Result<void> {
- <Pallet<T>>::ensure_owner(contract_address, caller)?;
- <Pallet<T>>::toggle_sponsoring(contract_address, enabled);
+ self.recorder().consume_sload()?;
+ self.recorder().consume_sstore()?;
+
+ Pallet::<T>::set_sponsor(
+ &T::CrossAccountId::from_eth(caller),
+ contract_address,
+ &T::CrossAccountId::from_eth(sponsor),
+ )
+ .map_err(dispatch_to_evm::<T>)?;
+
+ Ok(())
+ }
+
+ /// Set contract as self sponsored.
+ ///
+ /// @param contractAddress Contract for which a self sponsoring is being enabled.
+ fn self_sponsored_enable(&mut self, caller: caller, contract_address: address) -> Result<void> {
+ self.recorder().consume_sload()?;
+ self.recorder().consume_sstore()?;
+
+ Pallet::<T>::self_sponsored_enable(&T::CrossAccountId::from_eth(caller), contract_address)
+ .map_err(dispatch_to_evm::<T>)?;
+
Ok(())
}
+ /// Remove sponsor.
+ ///
+ /// @param contractAddress Contract for which a sponsorship is being removed.
+ fn remove_sponsor(&mut self, caller: caller, contract_address: address) -> Result<void> {
+ self.recorder().consume_sload()?;
+ self.recorder().consume_sstore()?;
+
+ Pallet::<T>::remove_sponsor(&T::CrossAccountId::from_eth(caller), contract_address)
+ .map_err(dispatch_to_evm::<T>)?;
+
+ Ok(())
+ }
+
+ /// Confirm sponsorship.
+ ///
+ /// @dev Caller must be same that set via [`setSponsor`].
+ ///
+ /// @param contractAddress Π‘ontract for which need to confirm sponsorship.
+ fn confirm_sponsorship(&mut self, caller: caller, contract_address: address) -> Result<void> {
+ self.recorder().consume_sload()?;
+ self.recorder().consume_sstore()?;
+
+ Pallet::<T>::confirm_sponsorship(&T::CrossAccountId::from_eth(caller), contract_address)
+ .map_err(dispatch_to_evm::<T>)?;
+
+ Ok(())
+ }
+
+ /// Get current sponsor.
+ ///
+ /// @param contractAddress The contract for which a sponsor is requested.
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ fn get_sponsor(&self, contract_address: address) -> Result<(address, uint256)> {
+ let sponsor =
+ Pallet::<T>::get_sponsor(contract_address).ok_or("Contract has no sponsor")?;
+ let result: (address, uint256) = if sponsor.is_canonical_substrate() {
+ let sponsor = pallet_common::eth::convert_cross_account_to_uint256::<T>(&sponsor);
+ (Default::default(), sponsor)
+ } else {
+ let sponsor = *sponsor.as_eth();
+ (sponsor, Default::default())
+ };
+ Ok(result)
+ }
+
+ /// Check tat contract has confirmed sponsor.
+ ///
+ /// @param contractAddress The contract for which the presence of a confirmed sponsor is checked.
+ /// @return **true** if contract has confirmed sponsor.
+ fn has_sponsor(&self, contract_address: address) -> Result<bool> {
+ Ok(Pallet::<T>::get_sponsor(contract_address).is_some())
+ }
+
+ /// Check tat contract has pending sponsor.
+ ///
+ /// @param contractAddress The contract for which the presence of a pending sponsor is checked.
+ /// @return **true** if contract has pending sponsor.
+ fn has_pending_sponsor(&self, contract_address: address) -> Result<bool> {
+ Ok(match Sponsoring::<T>::get(contract_address) {
+ SponsorshipState::Disabled | SponsorshipState::Confirmed(_) => false,
+ SponsorshipState::Unconfirmed(_) => true,
+ })
+ }
+
+ fn sponsoring_enabled(&self, contract_address: address) -> Result<bool> {
+ Ok(<Pallet<T>>::sponsoring_mode(contract_address) != SponsoringModeT::Disabled)
+ }
+
fn set_sponsoring_mode(
&mut self,
caller: caller,
contract_address: address,
+ // TODO: implement support for enums in evm-coder
mode: uint8,
) -> Result<void> {
- <Pallet<T>>::ensure_owner(contract_address, caller)?;
+ self.recorder().consume_sload()?;
+ self.recorder().consume_sstore()?;
+
+ <Pallet<T>>::ensure_owner(contract_address, caller).map_err(dispatch_to_evm::<T>)?;
let mode = SponsoringModeT::from_eth(mode).ok_or("unknown mode")?;
<Pallet<T>>::set_sponsoring_mode(contract_address, mode);
+
Ok(())
}
- fn sponsoring_mode(&self, contract_address: address) -> Result<uint8> {
- Ok(<Pallet<T>>::sponsoring_mode(contract_address).to_eth())
+ /// Get current contract sponsoring rate limit
+ /// @param contractAddress Contract to get sponsoring mode of
+ /// @return uint32 Amount of blocks between two sponsored transactions
+ fn get_sponsoring_rate_limit(&self, contract_address: address) -> Result<uint32> {
+ Ok(<SponsoringRateLimit<T>>::get(contract_address)
+ .try_into()
+ .map_err(|_| "rate limit > u32::MAX")?)
}
+ /// Set contract sponsoring rate limit
+ /// @dev Sponsoring rate limit - is a minimum amount of blocks that should
+ /// pass between two sponsored transactions
+ /// @param contractAddress Contract to change sponsoring rate limit of
+ /// @param rateLimit Target rate limit
+ /// @dev Only contract owner can change this setting
fn set_sponsoring_rate_limit(
&mut self,
caller: caller,
contract_address: address,
rate_limit: uint32,
) -> Result<void> {
- <Pallet<T>>::ensure_owner(contract_address, caller)?;
+ self.recorder().consume_sload()?;
+ self.recorder().consume_sstore()?;
+
+ <Pallet<T>>::ensure_owner(contract_address, caller).map_err(dispatch_to_evm::<T>)?;
<Pallet<T>>::set_sponsoring_rate_limit(contract_address, rate_limit.into());
Ok(())
}
- fn get_sponsoring_rate_limit(&self, contract_address: address) -> Result<uint32> {
- Ok(<SponsoringRateLimit<T>>::get(contract_address)
- .try_into()
- .map_err(|_| "rate limit > u32::MAX")?)
- }
-
+ /// Is specified user present in contract allow list
+ /// @dev Contract owner always implicitly included
+ /// @param contractAddress Contract to check allowlist of
+ /// @param user User to check
+ /// @return bool Is specified users exists in contract allowlist
fn allowed(&self, contract_address: address, user: address) -> Result<bool> {
self.0.consume_sload()?;
Ok(<Pallet<T>>::allowed(contract_address, user))
}
- fn allowlist_enabled(&self, contract_address: address) -> Result<bool> {
- Ok(<AllowlistEnabled<T>>::get(contract_address))
- }
-
- fn toggle_allowlist(
+ /// Toggle user presence in contract allowlist
+ /// @param contractAddress Contract to change allowlist of
+ /// @param user Which user presence should be toggled
+ /// @param isAllowed `true` if user should be allowed to be sponsored
+ /// or call this contract, `false` otherwise
+ /// @dev Only contract owner can change this setting
+ fn toggle_allowed(
&mut self,
caller: caller,
contract_address: address,
- enabled: bool,
+ user: address,
+ is_allowed: bool,
) -> Result<void> {
- <Pallet<T>>::ensure_owner(contract_address, caller)?;
- <Pallet<T>>::toggle_allowlist(contract_address, enabled);
+ self.recorder().consume_sload()?;
+ self.recorder().consume_sstore()?;
+
+ <Pallet<T>>::ensure_owner(contract_address, caller).map_err(dispatch_to_evm::<T>)?;
+ <Pallet<T>>::toggle_allowed(contract_address, user, is_allowed);
+
Ok(())
}
- fn toggle_allowed(
+ /// Is this contract has allowlist access enabled
+ /// @dev Allowlist always can have users, and it is used for two purposes:
+ /// in case of allowlist sponsoring mode, users will be sponsored if they exist in allowlist
+ /// in case of allowlist access enabled, only users from allowlist may call this contract
+ /// @param contractAddress Contract to get allowlist access of
+ /// @return bool Is specified contract has allowlist access enabled
+ fn allowlist_enabled(&self, contract_address: address) -> Result<bool> {
+ Ok(<AllowlistEnabled<T>>::get(contract_address))
+ }
+
+ /// Toggle contract allowlist access
+ /// @param contractAddress Contract to change allowlist access of
+ /// @param enabled Should allowlist access to be enabled?
+ fn toggle_allowlist(
&mut self,
caller: caller,
contract_address: address,
- user: address,
- allowed: bool,
+ enabled: bool,
) -> Result<void> {
- <Pallet<T>>::ensure_owner(contract_address, caller)?;
- <Pallet<T>>::toggle_allowed(contract_address, user, allowed);
+ self.recorder().consume_sload()?;
+ self.recorder().consume_sstore()?;
+
+ <Pallet<T>>::ensure_owner(contract_address, caller).map_err(dispatch_to_evm::<T>)?;
+ <Pallet<T>>::toggle_allowlist(contract_address, enabled);
Ok(())
}
}
+/// Implements [`OnMethodCall`], which delegates call to [`ContractHelpers`]
pub struct HelpersOnMethodCall<T: Config>(PhantomData<*const T>);
-impl<T: Config> OnMethodCall<T> for HelpersOnMethodCall<T> {
+impl<T: Config> OnMethodCall<T> for HelpersOnMethodCall<T>
+where
+ T::AccountId: AsRef<[u8; 32]>,
+{
fn is_reserved(contract: &sp_core::H160) -> bool {
contract == &T::ContractAddress::get()
}
@@ -167,6 +314,7 @@
}
}
+/// Hooks into contract creation, storing owner of newly deployed contract
pub struct HelpersOnCreate<T: Config>(PhantomData<*const T>);
impl<T: Config> OnCreate<T> for HelpersOnCreate<T> {
fn on_create(owner: H160, contract: H160) {
@@ -174,23 +322,32 @@
}
}
+/// Bridge to pallet-sponsoring
pub struct HelpersContractSponsoring<T: Config>(PhantomData<*const T>);
impl<T: Config> SponsorshipHandler<T::CrossAccountId, (H160, Vec<u8>)>
for HelpersContractSponsoring<T>
{
fn get_sponsor(who: &T::CrossAccountId, call: &(H160, Vec<u8>)) -> Option<T::CrossAccountId> {
- let mode = <Pallet<T>>::sponsoring_mode(call.0);
+ let (contract_address, _) = call;
+ let mode = <Pallet<T>>::sponsoring_mode(*contract_address);
if mode == SponsoringModeT::Disabled {
return None;
}
- if mode == SponsoringModeT::Allowlisted && !<Pallet<T>>::allowed(call.0, *who.as_eth()) {
+ let sponsor = match <Pallet<T>>::get_sponsor(*contract_address) {
+ Some(sponsor) => sponsor,
+ None => return None,
+ };
+
+ if mode == SponsoringModeT::Allowlisted
+ && !<Pallet<T>>::allowed(*contract_address, *who.as_eth())
+ {
return None;
}
let block_number = <frame_system::Pallet<T>>::block_number() as T::BlockNumber;
- if let Some(last_tx_block) = <SponsorBasket<T>>::get(&call.0, who.as_eth()) {
- let limit = <SponsoringRateLimit<T>>::get(&call.0);
+ if let Some(last_tx_block) = <SponsorBasket<T>>::get(contract_address, who.as_eth()) {
+ let limit = <SponsoringRateLimit<T>>::get(contract_address);
let timeout = last_tx_block + limit;
if block_number < timeout {
@@ -198,9 +355,8 @@
}
}
- <SponsorBasket<T>>::insert(&call.0, who.as_eth(), block_number);
+ <SponsorBasket<T>>::insert(contract_address, who.as_eth(), block_number);
- let sponsor = T::CrossAccountId::from_eth(call.0);
Some(sponsor)
}
}
pallets/evm-contract-helpers/src/lib.rsdiffbeforeafterboth--- a/pallets/evm-contract-helpers/src/lib.rs
+++ b/pallets/evm-contract-helpers/src/lib.rs
@@ -14,7 +14,9 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+#![doc = include_str!("../README.md")]
#![cfg_attr(not(feature = "std"), no_std)]
+#![deny(missing_docs)]
use codec::{Decode, Encode, MaxEncodedLen};
pub use pallet::*;
@@ -25,28 +27,40 @@
#[frame_support::pallet]
pub mod pallet {
pub use super::*;
- use evm_coder::execution::Result;
use frame_support::pallet_prelude::*;
+ use pallet_evm_coder_substrate::DispatchResult;
use sp_core::H160;
+ use pallet_evm::account::CrossAccountId;
+ use up_data_structs::SponsorshipState;
#[pallet::config]
pub trait Config:
frame_system::Config + pallet_evm_coder_substrate::Config + pallet_evm::account::Config
{
+ /// Address, under which magic contract will be available
type ContractAddress: Get<H160>;
+ /// In case of enabled sponsoring, but no sponsoring rate limit set,
+ /// this value will be used implicitly
type DefaultSponsoringRateLimit: Get<Self::BlockNumber>;
}
#[pallet::error]
pub enum Error<T> {
- /// This method is only executable by owner
+ /// This method is only executable by contract owner
NoPermission,
+
+ /// No pending sponsor for contract.
+ NoPendingSponsor,
}
#[pallet::pallet]
#[pallet::generate_store(pub(super) trait Store)]
pub struct Pallet<T>(_);
+ /// Store owner for contract.
+ ///
+ /// * **Key** - contract address.
+ /// * **Value** - owner for contract.
#[pallet::storage]
pub(super) type Owner<T: Config> =
StorageMap<Hasher = Twox128, Key = H160, Value = H160, QueryKind = ValueQuery>;
@@ -56,10 +70,33 @@
pub(super) type SelfSponsoring<T: Config> =
StorageMap<Hasher = Twox128, Key = H160, Value = bool, QueryKind = ValueQuery>;
+ /// Store for contract sponsorship state.
+ ///
+ /// * **Key** - contract address.
+ /// * **Value** - sponsorship state.
+ #[pallet::storage]
+ pub(super) type Sponsoring<T: Config> = StorageMap<
+ Hasher = Twox64Concat,
+ Key = H160,
+ Value = SponsorshipState<T::CrossAccountId>,
+ QueryKind = ValueQuery,
+ >;
+
+ /// Store for sponsoring mode.
+ ///
+ /// ### Usage
+ /// Prefer to delete collection from storage if mode chaged to [`Disabled`](SponsoringModeT::Disabled).
+ ///
+ /// * **Key** - contract address.
+ /// * **Value** - [`sponsoring mode`](SponsoringModeT).
#[pallet::storage]
pub(super) type SponsoringMode<T: Config> =
StorageMap<Hasher = Twox128, Key = H160, Value = SponsoringModeT, QueryKind = OptionQuery>;
+ /// Storage for sponsoring rate limit in blocks.
+ ///
+ /// * **Key** - contract address.
+ /// * **Value** - amount of sponsored blocks.
#[pallet::storage]
pub(super) type SponsoringRateLimit<T: Config> = StorageMap<
Hasher = Twox128,
@@ -69,6 +106,11 @@
OnEmpty = T::DefaultSponsoringRateLimit,
>;
+ /// Storage for last sponsored block.
+ ///
+ /// * **Key1** - contract address.
+ /// * **Key2** - sponsored user address.
+ /// * **Value** - last sponsored block number.
#[pallet::storage]
pub(super) type SponsorBasket<T: Config> = StorageDoubleMap<
Hasher1 = Twox128,
@@ -79,10 +121,25 @@
QueryKind = OptionQuery,
>;
+ /// Storege for contracts with [`Allowlisted`](SponsoringModeT::Allowlisted) sponsoring mode.
+ ///
+ /// ### Usage
+ /// Prefer to delete collection from storage if mode chaged to non `Allowlisted`, than set **Value** to **false**.
+ ///
+ /// * **Key** - contract address.
+ /// * **Value** - is contract in [`Allowlisted`](SponsoringModeT::Allowlisted) mode.
#[pallet::storage]
pub(super) type AllowlistEnabled<T: Config> =
StorageMap<Hasher = Twox128, Key = H160, Value = bool, QueryKind = ValueQuery>;
+ /// Storage for users that allowed for sponsorship.
+ ///
+ /// ### Usage
+ /// Prefer to delete record from storage if user no more allowed for sponsorship.
+ ///
+ /// * **Key1** - contract address.
+ /// * **Key2** - user that allowed for sponsorship.
+ /// * **Value** - allowance for sponsorship.
#[pallet::storage]
pub(super) type Allowlist<T: Config> = StorageDoubleMap<
Hasher1 = Twox128,
@@ -94,6 +151,78 @@
>;
impl<T: Config> Pallet<T> {
+ /// Get contract owner.
+ pub fn contract_owner(contract: H160) -> H160 {
+ <Owner<T>>::get(contract)
+ }
+
+ /// Set `sponsor` for `contract`.
+ ///
+ /// `sender` must be owner of contract.
+ pub fn set_sponsor(
+ sender: &T::CrossAccountId,
+ contract: H160,
+ sponsor: &T::CrossAccountId,
+ ) -> DispatchResult {
+ Pallet::<T>::ensure_owner(contract, *sender.as_eth())?;
+ Sponsoring::<T>::insert(
+ contract,
+ SponsorshipState::<T::CrossAccountId>::Unconfirmed(sponsor.clone()),
+ );
+ Ok(())
+ }
+
+ /// Set `contract` as self sponsored.
+ ///
+ /// `sender` must be owner of contract.
+ pub fn self_sponsored_enable(sender: &T::CrossAccountId, contract: H160) -> DispatchResult {
+ Pallet::<T>::ensure_owner(contract, *sender.as_eth())?;
+ Sponsoring::<T>::insert(
+ contract,
+ SponsorshipState::<T::CrossAccountId>::Confirmed(T::CrossAccountId::from_eth(
+ contract,
+ )),
+ );
+ Ok(())
+ }
+
+ /// Remove sponsor for `contract`.
+ ///
+ /// `sender` must be owner of contract.
+ pub fn remove_sponsor(sender: &T::CrossAccountId, contract: H160) -> DispatchResult {
+ Pallet::<T>::ensure_owner(contract, *sender.as_eth())?;
+ Sponsoring::<T>::remove(contract);
+ Ok(())
+ }
+
+ /// Confirm sponsorship.
+ ///
+ /// `sender` must be same that set via [`set_sponsor`].
+ pub fn confirm_sponsorship(sender: &T::CrossAccountId, contract: H160) -> DispatchResult {
+ match Sponsoring::<T>::get(contract) {
+ SponsorshipState::Unconfirmed(sponsor) => {
+ ensure!(sponsor == *sender, Error::<T>::NoPermission);
+ Sponsoring::<T>::insert(
+ contract,
+ SponsorshipState::<T::CrossAccountId>::Confirmed(sponsor),
+ );
+ Ok(())
+ }
+ SponsorshipState::Disabled | SponsorshipState::Confirmed(_) => {
+ Err(Error::<T>::NoPendingSponsor.into())
+ }
+ }
+ }
+
+ /// Get sponsor.
+ pub fn get_sponsor(contract: H160) -> Option<T::CrossAccountId> {
+ match Sponsoring::<T>::get(contract) {
+ SponsorshipState::Disabled | SponsorshipState::Unconfirmed(_) => None,
+ SponsorshipState::Confirmed(sponsor) => Some(sponsor),
+ }
+ }
+
+ /// Get current sponsoring mode, performing lazy migration from legacy storage
pub fn sponsoring_mode(contract: H160) -> SponsoringModeT {
<SponsoringMode<T>>::get(contract)
.or_else(|| {
@@ -101,6 +230,8 @@
})
.unwrap_or_default()
}
+
+ /// Reconfigure contract sponsoring mode
pub fn set_sponsoring_mode(contract: H160, mode: SponsoringModeT) {
if mode == SponsoringModeT::Disabled {
<SponsoringMode<T>>::remove(contract);
@@ -110,44 +241,43 @@
<SelfSponsoring<T>>::remove(contract)
}
- pub fn toggle_sponsoring(contract: H160, enabled: bool) {
- Self::set_sponsoring_mode(
- contract,
- if enabled {
- SponsoringModeT::Allowlisted
- } else {
- SponsoringModeT::Disabled
- },
- )
- }
-
+ /// Set duration between two sponsored contract calls
pub fn set_sponsoring_rate_limit(contract: H160, rate_limit: T::BlockNumber) {
<SponsoringRateLimit<T>>::insert(contract, rate_limit);
}
+ /// Is user added to allowlist, or he is owner of specified contract
pub fn allowed(contract: H160, user: H160) -> bool {
<Allowlist<T>>::get(&contract, &user) || <Owner<T>>::get(&contract) == user
}
+ /// Toggle contract allowlist access
pub fn toggle_allowlist(contract: H160, enabled: bool) {
<AllowlistEnabled<T>>::insert(contract, enabled)
}
+ /// Toggle user presence in contract's allowlist
pub fn toggle_allowed(contract: H160, user: H160, allowed: bool) {
<Allowlist<T>>::insert(contract, user, allowed);
}
- pub fn ensure_owner(contract: H160, user: H160) -> Result<()> {
- ensure!(<Owner<T>>::get(&contract) == user, "no permission");
+ /// Throw error if user is not allowed to reconfigure target contract
+ pub fn ensure_owner(contract: H160, user: H160) -> DispatchResult {
+ ensure!(<Owner<T>>::get(&contract) == user, Error::<T>::NoPermission);
Ok(())
}
}
}
-#[derive(Encode, Decode, PartialEq, TypeInfo, MaxEncodedLen)]
+/// Available contract sponsoring modes
+#[derive(Encode, Decode, PartialEq, TypeInfo, MaxEncodedLen, Default)]
pub enum SponsoringModeT {
+ /// Sponsoring is disabled
+ #[default]
Disabled,
+ /// Only users from allowlist will be sponsored
Allowlisted,
+ /// All users will be sponsored
Generous,
}
@@ -166,11 +296,5 @@
SponsoringModeT::Allowlisted => 1,
SponsoringModeT::Generous => 2,
}
- }
-}
-
-impl Default for SponsoringModeT {
- fn default() -> Self {
- Self::Disabled
}
}
pallets/evm-contract-helpers/src/stubs/ContractHelpers.rawdiffbeforeafterbothbinary blob β no preview
pallets/evm-contract-helpers/src/stubs/ContractHelpers.soldiffbeforeafterboth--- a/pallets/evm-contract-helpers/src/stubs/ContractHelpers.sol
+++ b/pallets/evm-contract-helpers/src/stubs/ContractHelpers.sol
@@ -3,7 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Common stubs holder
+/// @dev common stubs holder
contract Dummy {
uint8 dummy;
string stub_error = "this contract is implemented in native";
@@ -21,9 +21,18 @@
}
}
-// Selector: 7b4866f9
+/// @title Magic contract, which allows users to reconfigure other contracts
+/// @dev the ERC-165 identifier for this interface is 0xd77fab70
contract ContractHelpers is Dummy, ERC165 {
- // Selector: contractOwner(address) 5152b14c
+ /// Get user, which deployed specified contract
+ /// @dev May return zero address in case if contract is deployed
+ /// using uniquenetwork evm-migration pallet, or using other terms not
+ /// intended by pallet-evm
+ /// @dev Returns zero address if contract does not exists
+ /// @param contractAddress Contract to get owner of
+ /// @return address Owner of contract
+ /// @dev EVM selector for this function is: 0x5152b14c,
+ /// or in textual repr: contractOwner(address)
function contractOwner(address contractAddress)
public
view
@@ -35,8 +44,90 @@
return 0x0000000000000000000000000000000000000000;
}
- // Selector: sponsoringEnabled(address) 6027dc61
- function sponsoringEnabled(address contractAddress)
+ /// Set sponsor.
+ /// @param contractAddress Contract for which a sponsor is being established.
+ /// @param sponsor User address who set as pending sponsor.
+ /// @dev EVM selector for this function is: 0xf01fba93,
+ /// or in textual repr: setSponsor(address,address)
+ function setSponsor(address contractAddress, address sponsor) public {
+ require(false, stub_error);
+ contractAddress;
+ sponsor;
+ dummy = 0;
+ }
+
+ /// Set contract as self sponsored.
+ ///
+ /// @param contractAddress Contract for which a self sponsoring is being enabled.
+ /// @dev EVM selector for this function is: 0x89f7d9ae,
+ /// or in textual repr: selfSponsoredEnable(address)
+ function selfSponsoredEnable(address contractAddress) public {
+ require(false, stub_error);
+ contractAddress;
+ dummy = 0;
+ }
+
+ /// Remove sponsor.
+ ///
+ /// @param contractAddress Contract for which a sponsorship is being removed.
+ /// @dev EVM selector for this function is: 0xef784250,
+ /// or in textual repr: removeSponsor(address)
+ function removeSponsor(address contractAddress) public {
+ require(false, stub_error);
+ contractAddress;
+ dummy = 0;
+ }
+
+ /// Confirm sponsorship.
+ ///
+ /// @dev Caller must be same that set via [`setSponsor`].
+ ///
+ /// @param contractAddress Π‘ontract for which need to confirm sponsorship.
+ /// @dev EVM selector for this function is: 0xabc00001,
+ /// or in textual repr: confirmSponsorship(address)
+ function confirmSponsorship(address contractAddress) public {
+ require(false, stub_error);
+ contractAddress;
+ dummy = 0;
+ }
+
+ /// Get current sponsor.
+ ///
+ /// @param contractAddress The contract for which a sponsor is requested.
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ /// @dev EVM selector for this function is: 0x743fc745,
+ /// or in textual repr: getSponsor(address)
+ function getSponsor(address contractAddress)
+ public
+ view
+ returns (Tuple0 memory)
+ {
+ require(false, stub_error);
+ contractAddress;
+ dummy;
+ return Tuple0(0x0000000000000000000000000000000000000000, 0);
+ }
+
+ /// Check tat contract has confirmed sponsor.
+ ///
+ /// @param contractAddress The contract for which the presence of a confirmed sponsor is checked.
+ /// @return **true** if contract has confirmed sponsor.
+ /// @dev EVM selector for this function is: 0x97418603,
+ /// or in textual repr: hasSponsor(address)
+ function hasSponsor(address contractAddress) public view returns (bool) {
+ require(false, stub_error);
+ contractAddress;
+ dummy;
+ return false;
+ }
+
+ /// Check tat contract has pending sponsor.
+ ///
+ /// @param contractAddress The contract for which the presence of a pending sponsor is checked.
+ /// @return **true** if contract has pending sponsor.
+ /// @dev EVM selector for this function is: 0x39b9b242,
+ /// or in textual repr: hasPendingSponsor(address)
+ function hasPendingSponsor(address contractAddress)
public
view
returns (bool)
@@ -47,17 +138,21 @@
return false;
}
- // Deprecated
- //
- // Selector: toggleSponsoring(address,bool) fcac6d86
- function toggleSponsoring(address contractAddress, bool enabled) public {
+ /// @dev EVM selector for this function is: 0x6027dc61,
+ /// or in textual repr: sponsoringEnabled(address)
+ function sponsoringEnabled(address contractAddress)
+ public
+ view
+ returns (bool)
+ {
require(false, stub_error);
contractAddress;
- enabled;
- dummy = 0;
+ dummy;
+ return false;
}
- // Selector: setSponsoringMode(address,uint8) fde8a560
+ /// @dev EVM selector for this function is: 0xfde8a560,
+ /// or in textual repr: setSponsoringMode(address,uint8)
function setSponsoringMode(address contractAddress, uint8 mode) public {
require(false, stub_error);
contractAddress;
@@ -65,11 +160,15 @@
dummy = 0;
}
- // Selector: sponsoringMode(address) b70c7267
- function sponsoringMode(address contractAddress)
+ /// Get current contract sponsoring rate limit
+ /// @param contractAddress Contract to get sponsoring mode of
+ /// @return uint32 Amount of blocks between two sponsored transactions
+ /// @dev EVM selector for this function is: 0x610cfabd,
+ /// or in textual repr: getSponsoringRateLimit(address)
+ function getSponsoringRateLimit(address contractAddress)
public
view
- returns (uint8)
+ returns (uint32)
{
require(false, stub_error);
contractAddress;
@@ -77,7 +176,14 @@
return 0;
}
- // Selector: setSponsoringRateLimit(address,uint32) 77b6c908
+ /// Set contract sponsoring rate limit
+ /// @dev Sponsoring rate limit - is a minimum amount of blocks that should
+ /// pass between two sponsored transactions
+ /// @param contractAddress Contract to change sponsoring rate limit of
+ /// @param rateLimit Target rate limit
+ /// @dev Only contract owner can change this setting
+ /// @dev EVM selector for this function is: 0x77b6c908,
+ /// or in textual repr: setSponsoringRateLimit(address,uint32)
function setSponsoringRateLimit(address contractAddress, uint32 rateLimit)
public
{
@@ -87,32 +193,53 @@
dummy = 0;
}
- // Selector: getSponsoringRateLimit(address) 610cfabd
- function getSponsoringRateLimit(address contractAddress)
+ /// Is specified user present in contract allow list
+ /// @dev Contract owner always implicitly included
+ /// @param contractAddress Contract to check allowlist of
+ /// @param user User to check
+ /// @return bool Is specified users exists in contract allowlist
+ /// @dev EVM selector for this function is: 0x5c658165,
+ /// or in textual repr: allowed(address,address)
+ function allowed(address contractAddress, address user)
public
view
- returns (uint32)
+ returns (bool)
{
require(false, stub_error);
contractAddress;
+ user;
dummy;
- return 0;
+ return false;
}
- // Selector: allowed(address,address) 5c658165
- function allowed(address contractAddress, address user)
- public
- view
- returns (bool)
- {
+ /// Toggle user presence in contract allowlist
+ /// @param contractAddress Contract to change allowlist of
+ /// @param user Which user presence should be toggled
+ /// @param isAllowed `true` if user should be allowed to be sponsored
+ /// or call this contract, `false` otherwise
+ /// @dev Only contract owner can change this setting
+ /// @dev EVM selector for this function is: 0x4706cc1c,
+ /// or in textual repr: toggleAllowed(address,address,bool)
+ function toggleAllowed(
+ address contractAddress,
+ address user,
+ bool isAllowed
+ ) public {
require(false, stub_error);
contractAddress;
user;
- dummy;
- return false;
+ isAllowed;
+ dummy = 0;
}
- // Selector: allowlistEnabled(address) c772ef6c
+ /// Is this contract has allowlist access enabled
+ /// @dev Allowlist always can have users, and it is used for two purposes:
+ /// in case of allowlist sponsoring mode, users will be sponsored if they exist in allowlist
+ /// in case of allowlist access enabled, only users from allowlist may call this contract
+ /// @param contractAddress Contract to get allowlist access of
+ /// @return bool Is specified contract has allowlist access enabled
+ /// @dev EVM selector for this function is: 0xc772ef6c,
+ /// or in textual repr: allowlistEnabled(address)
function allowlistEnabled(address contractAddress)
public
view
@@ -124,24 +251,21 @@
return false;
}
- // Selector: toggleAllowlist(address,bool) 36de20f5
+ /// Toggle contract allowlist access
+ /// @param contractAddress Contract to change allowlist access of
+ /// @param enabled Should allowlist access to be enabled?
+ /// @dev EVM selector for this function is: 0x36de20f5,
+ /// or in textual repr: toggleAllowlist(address,bool)
function toggleAllowlist(address contractAddress, bool enabled) public {
require(false, stub_error);
contractAddress;
enabled;
dummy = 0;
}
+}
- // Selector: toggleAllowed(address,address,bool) 4706cc1c
- function toggleAllowed(
- address contractAddress,
- address user,
- bool allowed
- ) public {
- require(false, stub_error);
- contractAddress;
- user;
- allowed;
- dummy = 0;
- }
+/// @dev anonymous struct
+struct Tuple0 {
+ address field_0;
+ uint256 field_1;
}
pallets/evm-migration/README.mddiffbeforeafterboth--- /dev/null
+++ b/pallets/evm-migration/README.md
@@ -0,0 +1,18 @@
+# EVM contract migration pallet
+
+This pallet is only callable by root, it has functionality to migrate contract
+from other ethereum chain to pallet-evm
+
+Contract data includes contract code, and contract storage,
+where contract storage is a mapping from evm word to evm word (evm word = 32 byte)
+
+To import contract data into pallet-evm admin should call this pallet multiple times:
+1. Start migration via `begin`
+2. Insert all contract data using single or
+ multiple (If data can't be fit into single extrinsic) calls
+ to `set_data`
+3. Finish migration using `finish`, providing contract code
+
+During migration no one can insert code at address of this contract,
+as [`pallet::OnMethodCall`] prevents this, and no one can call this contract,
+as code is only supplied at final stage of contract deployment
\ No newline at end of file
pallets/evm-migration/src/benchmarking.rsdiffbeforeafterboth--- a/pallets/evm-migration/src/benchmarking.rs
+++ b/pallets/evm-migration/src/benchmarking.rs
@@ -14,6 +14,8 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+#![allow(missing_docs)]
+
use super::{Call, Config, Pallet};
use frame_benchmarking::benchmarks;
use frame_system::RawOrigin;
pallets/evm-migration/src/lib.rsdiffbeforeafterboth--- a/pallets/evm-migration/src/lib.rs
+++ b/pallets/evm-migration/src/lib.rs
@@ -14,7 +14,9 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+#![doc = include_str!("../README.md")]
#![cfg_attr(not(feature = "std"), no_std)]
+#![deny(missing_docs)]
pub use pallet::*;
#[cfg(feature = "runtime-benchmarks")]
@@ -32,6 +34,7 @@
#[pallet::config]
pub trait Config: frame_system::Config + pallet_evm::Config {
+ /// Weights
type WeightInfo: WeightInfo;
}
@@ -43,7 +46,9 @@
#[pallet::error]
pub enum Error<T> {
+ /// Can only migrate to empty address.
AccountNotEmpty,
+ /// Migration of this account is not yet started, or already finished.
AccountIsNotMigrating,
}
@@ -53,6 +58,8 @@
#[pallet::call]
impl<T: Config> Pallet<T> {
+ /// Start contract migration, inserts contract stub at target address,
+ /// and marks account as pending, allowing to insert storage
#[pallet::weight(<SelfWeightOf<T>>::begin())]
pub fn begin(origin: OriginFor<T>, address: H160) -> DispatchResult {
ensure_root(origin)?;
@@ -65,6 +72,8 @@
Ok(())
}
+ /// Insert items into contract storage, this method can be called
+ /// multiple times
#[pallet::weight(<SelfWeightOf<T>>::set_data(data.len() as u32))]
pub fn set_data(
origin: OriginFor<T>,
@@ -83,6 +92,9 @@
Ok(())
}
+ /// Finish contract migration, allows it to be called.
+ /// It is not possible to alter contract storage via [`Self::set_data`]
+ /// after this call.
#[pallet::weight(<SelfWeightOf<T>>::finish(code.len() as u32))]
pub fn finish(origin: OriginFor<T>, address: H160, code: Vec<u8>) -> DispatchResult {
ensure_root(origin)?;
@@ -97,6 +109,7 @@
}
}
+ /// Implements [`pallet_evm::OnMethodCall`], which reserves accounts with pending migration
pub struct OnMethodCall<T>(PhantomData<T>);
impl<T: Config> pallet_evm::OnMethodCall<T> for OnMethodCall<T> {
fn is_reserved(contract: &H160) -> bool {
pallets/evm-migration/src/weights.rsdiffbeforeafterboth--- a/pallets/evm-migration/src/weights.rs
+++ b/pallets/evm-migration/src/weights.rs
@@ -26,6 +26,7 @@
#![cfg_attr(rustfmt, rustfmt_skip)]
#![allow(unused_parens)]
#![allow(unused_imports)]
+#![allow(missing_docs)]
#![allow(clippy::unnecessary_cast)]
use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}};
pallets/evm-transaction-payment/README.mddiffbeforeafterboth--- /dev/null
+++ b/pallets/evm-transaction-payment/README.md
@@ -0,0 +1,5 @@
+# Evm transaction payment pallet
+
+pallet-evm-transaction-payment is a bridge between pallet-evm substrate calls and pallet-sponsoring.
+It doesn't provide any sponsoring logic by itself, instead all sponsoring handlers
+are loosly coupled via [`Config::EvmSponsorshipHandler`] trait.
\ No newline at end of file
pallets/evm-transaction-payment/src/lib.rsdiffbeforeafterboth--- a/pallets/evm-transaction-payment/src/lib.rs
+++ b/pallets/evm-transaction-payment/src/lib.rs
@@ -14,7 +14,9 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+#![doc = include_str!("../README.md")]
#![cfg_attr(not(feature = "std"), no_std)]
+#![deny(missing_docs)]
use core::marker::PhantomData;
use fp_evm::WithdrawReason;
@@ -29,13 +31,12 @@
pub mod pallet {
use super::*;
- use frame_support::traits::Currency;
use sp_std::vec::Vec;
#[pallet::config]
pub trait Config: frame_system::Config + pallet_evm::account::Config {
+ /// Loosly-coupled handlers for evm call sponsoring
type EvmSponsorshipHandler: SponsorshipHandler<Self::CrossAccountId, (H160, Vec<u8>)>;
- type Currency: Currency<Self::AccountId>;
}
#[pallet::pallet]
@@ -43,6 +44,7 @@
pub struct Pallet<T>(_);
}
+/// Implements [`fp_evm::TransactionValidityHack`], which provides sponsor address to pallet-evm
pub struct TransactionValidityHack<T: Config>(PhantomData<*const T>);
impl<T: Config> fp_evm::TransactionValidityHack<T::CrossAccountId> for TransactionValidityHack<T> {
fn who_pays_fee(origin: H160, reason: &WithdrawReason) -> Option<T::CrossAccountId> {
pallets/fungible/CHANGELOG.mddiffbeforeafterboth--- a/pallets/fungible/CHANGELOG.md
+++ b/pallets/fungible/CHANGELOG.md
@@ -2,6 +2,18 @@
All notable changes to this project will be documented in this file.
+
+## [0.1.5] - 2022-08-29
+
+### Added
+
+ - Implementation of `mint` and `mint_bulk` methods for ERC20 API.
+
+## [v0.1.4] - 2022-08-24
+
+### Change
+ - Add bound `AsRef<[u8; 32]>` to `T::CrossAccountId`.
+
<!-- bureaucrate goes here -->
## [v0.1.3] 2022-08-16
pallets/fungible/Cargo.tomldiffbeforeafterboth--- a/pallets/fungible/Cargo.toml
+++ b/pallets/fungible/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "pallet-fungible"
-version = "0.1.3"
+version = "0.1.5"
license = "GPLv3"
edition = "2021"
pallets/fungible/src/erc.rsdiffbeforeafterboth--- a/pallets/fungible/src/erc.rs
+++ b/pallets/fungible/src/erc.rs
@@ -50,7 +50,7 @@
},
}
-#[solidity_interface(name = "ERC20", events(ERC20Events))]
+#[solidity_interface(name = ERC20, events(ERC20Events))]
impl<T: Config> FungibleHandle<T> {
fn name(&self) -> Result<string> {
Ok(decode_utf16(self.name.iter().copied())
@@ -129,8 +129,32 @@
}
}
-#[solidity_interface(name = "ERC20UniqueExtensions")]
+#[solidity_interface(name = ERC20Mintable)]
+impl<T: Config> FungibleHandle<T> {
+ /// Mint tokens for `to` account.
+ /// @param to account that will receive minted tokens
+ /// @param amount amount of tokens to mint
+ #[weight(<SelfWeightOf<T>>::create_item())]
+ fn mint(&mut self, caller: caller, to: address, amount: uint256) -> Result<bool> {
+ let caller = T::CrossAccountId::from_eth(caller);
+ let to = T::CrossAccountId::from_eth(to);
+ let amount = amount.try_into().map_err(|_| "amount overflow")?;
+ let budget = self
+ .recorder
+ .weight_calls_budget(<StructureWeight<T>>::find_parent());
+ <Pallet<T>>::create_item(&self, &caller, (to, amount), &budget)
+ .map_err(dispatch_to_evm::<T>)?;
+ Ok(true)
+ }
+}
+
+#[solidity_interface(name = ERC20UniqueExtensions)]
impl<T: Config> FungibleHandle<T> {
+ /// Burn tokens from account
+ /// @dev Function that burns an `amount` of the tokens of a given account,
+ /// deducting from the sender's allowance for said account.
+ /// @param from The account whose tokens will be burnt.
+ /// @param amount The amount that will be burnt.
#[weight(<SelfWeightOf<T>>::burn_from())]
fn burn_from(&mut self, caller: caller, from: address, amount: uint256) -> Result<bool> {
let caller = T::CrossAccountId::from_eth(caller);
@@ -144,24 +168,48 @@
.map_err(dispatch_to_evm::<T>)?;
Ok(true)
}
+
+ /// Mint tokens for multiple accounts.
+ /// @param amounts array of pairs of account address and amount
+ #[weight(<SelfWeightOf<T>>::create_multiple_items_ex(amounts.len() as u32))]
+ fn mint_bulk(&mut self, caller: caller, amounts: Vec<(address, uint256)>) -> Result<bool> {
+ let caller = T::CrossAccountId::from_eth(caller);
+ let budget = self
+ .recorder
+ .weight_calls_budget(<StructureWeight<T>>::find_parent());
+ let amounts = amounts
+ .into_iter()
+ .map(|(to, amount)| {
+ Ok((
+ T::CrossAccountId::from_eth(to),
+ amount.try_into().map_err(|_| "amount overflow")?,
+ ))
+ })
+ .collect::<Result<_>>()?;
+
+ <Pallet<T>>::create_multiple_items(&self, &caller, amounts, &budget)
+ .map_err(dispatch_to_evm::<T>)?;
+ Ok(true)
+ }
}
#[solidity_interface(
- name = "UniqueFungible",
+ name = UniqueFungible,
is(
ERC20,
+ ERC20Mintable,
ERC20UniqueExtensions,
- via("CollectionHandle<T>", common_mut, Collection)
+ Collection(common_mut, CollectionHandle<T>),
)
)]
-impl<T: Config> FungibleHandle<T> where T::AccountId: From<[u8; 32]> {}
+impl<T: Config> FungibleHandle<T> where T::AccountId: From<[u8; 32]> + AsRef<[u8; 32]> {}
generate_stubgen!(gen_impl, UniqueFungibleCall<()>, true);
generate_stubgen!(gen_iface, UniqueFungibleCall<()>, false);
impl<T: Config> CommonEvmHandler for FungibleHandle<T>
where
- T::AccountId: From<[u8; 32]>,
+ T::AccountId: From<[u8; 32]> + AsRef<[u8; 32]>,
{
const CODE: &'static [u8] = include_bytes!("./stubs/UniqueFungible.raw");
pallets/fungible/src/stubs/UniqueFungible.rawdiffbeforeafterbothbinary blob β no preview
pallets/fungible/src/stubs/UniqueFungible.soldiffbeforeafterboth--- a/pallets/fungible/src/stubs/UniqueFungible.sol
+++ b/pallets/fungible/src/stubs/UniqueFungible.sol
@@ -3,7 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Common stubs holder
+/// @dev common stubs holder
contract Dummy {
uint8 dummy;
string stub_error = "this contract is implemented in native";
@@ -21,24 +21,15 @@
}
}
-// Inline
-contract ERC20Events {
- event Transfer(address indexed from, address indexed to, uint256 value);
- event Approval(
- address indexed owner,
- address indexed spender,
- uint256 value
- );
-}
-
-// Selector: 6cf113cd
+/// @title A contract that allows you to work with collections.
+/// @dev the ERC-165 identifier for this interface is 0xe54be640
contract Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
+ /// Set collection property.
+ ///
+ /// @param key Property key.
+ /// @param value Propery value.
+ /// @dev EVM selector for this function is: 0x2f073f66,
+ /// or in textual repr: setCollectionProperty(string,bytes)
function setCollectionProperty(string memory key, bytes memory value)
public
{
@@ -48,25 +39,25 @@
dummy = 0;
}
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
+ /// Delete collection property.
+ ///
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x7b7debce,
+ /// or in textual repr: deleteCollectionProperty(string)
function deleteCollectionProperty(string memory key) public {
require(false, stub_error);
key;
dummy = 0;
}
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
+ /// Get collection property.
+ ///
+ /// @dev Throws error if key not found.
+ ///
+ /// @param key Property key.
+ /// @return bytes The property corresponding to the key.
+ /// @dev EVM selector for this function is: 0xcf24fd6d,
+ /// or in textual repr: collectionProperty(string)
function collectionProperty(string memory key)
public
view
@@ -78,41 +69,81 @@
return hex"";
}
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
+ /// Set the sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0x7623402e,
+ /// or in textual repr: setCollectionSponsor(address)
function setCollectionSponsor(address sponsor) public {
require(false, stub_error);
sponsor;
dummy = 0;
}
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
+ /// Set the substrate sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Substrate address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0xc74d6751,
+ /// or in textual repr: setCollectionSponsorSubstrate(uint256)
+ function setCollectionSponsorSubstrate(uint256 sponsor) public {
+ require(false, stub_error);
+ sponsor;
+ dummy = 0;
+ }
+
+ /// @dev EVM selector for this function is: 0x058ac185,
+ /// or in textual repr: hasCollectionPendingSponsor()
+ function hasCollectionPendingSponsor() public view returns (bool) {
+ require(false, stub_error);
+ dummy;
+ return false;
+ }
+
+ /// Collection sponsorship confirmation.
+ ///
+ /// @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ /// @dev EVM selector for this function is: 0x3c50e97a,
+ /// or in textual repr: confirmCollectionSponsorship()
function confirmCollectionSponsorship() public {
require(false, stub_error);
dummy = 0;
}
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
+ /// Remove collection sponsor.
+ /// @dev EVM selector for this function is: 0x6e0326a3,
+ /// or in textual repr: removeCollectionSponsor()
+ function removeCollectionSponsor() public {
+ require(false, stub_error);
+ dummy = 0;
+ }
+
+ /// Get current sponsor.
+ ///
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ /// @dev EVM selector for this function is: 0xb66bbc14,
+ /// or in textual repr: getCollectionSponsor()
+ function getCollectionSponsor() public view returns (Tuple6 memory) {
+ require(false, stub_error);
+ dummy;
+ return Tuple6(0x0000000000000000000000000000000000000000, 0);
+ }
+
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "accountTokenOwnershipLimit",
+ /// "sponsoredDataSize",
+ /// "sponsoredDataRateLimit",
+ /// "tokenLimit",
+ /// "sponsorTransferTimeout",
+ /// "sponsorApproveTimeout"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x6a3841db,
+ /// or in textual repr: setCollectionLimit(string,uint32)
function setCollectionLimit(string memory limit, uint32 value) public {
require(false, stub_error);
limit;
@@ -120,15 +151,15 @@
dummy = 0;
}
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "ownerCanTransfer",
+ /// "ownerCanDestroy",
+ /// "transfersEnabled"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x993b7fba,
+ /// or in textual repr: setCollectionLimit(string,bool)
function setCollectionLimit(string memory limit, bool value) public {
require(false, stub_error);
limit;
@@ -136,73 +167,73 @@
dummy = 0;
}
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
+ /// Get contract address.
+ /// @dev EVM selector for this function is: 0xf6b4dfb4,
+ /// or in textual repr: contractAddress()
function contractAddress() public view returns (address) {
require(false, stub_error);
dummy;
return 0x0000000000000000000000000000000000000000;
}
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
+ /// Add collection admin by substrate address.
+ /// @param newAdmin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x5730062b,
+ /// or in textual repr: addCollectionAdminSubstrate(uint256)
function addCollectionAdminSubstrate(uint256 newAdmin) public {
require(false, stub_error);
newAdmin;
dummy = 0;
}
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
+ /// Remove collection admin by substrate address.
+ /// @param admin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x4048fcf9,
+ /// or in textual repr: removeCollectionAdminSubstrate(uint256)
function removeCollectionAdminSubstrate(uint256 admin) public {
require(false, stub_error);
admin;
dummy = 0;
}
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
+ /// Add collection admin.
+ /// @param newAdmin Address of the added administrator.
+ /// @dev EVM selector for this function is: 0x92e462c7,
+ /// or in textual repr: addCollectionAdmin(address)
function addCollectionAdmin(address newAdmin) public {
require(false, stub_error);
newAdmin;
dummy = 0;
}
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
+ /// Remove collection admin.
+ ///
+ /// @param admin Address of the removed administrator.
+ /// @dev EVM selector for this function is: 0xfafd7b42,
+ /// or in textual repr: removeCollectionAdmin(address)
function removeCollectionAdmin(address admin) public {
require(false, stub_error);
admin;
dummy = 0;
}
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ /// @dev EVM selector for this function is: 0x112d4586,
+ /// or in textual repr: setCollectionNesting(bool)
function setCollectionNesting(bool enable) public {
require(false, stub_error);
enable;
dummy = 0;
}
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ /// @param collections Addresses of collections that will be available for nesting.
+ /// @dev EVM selector for this function is: 0x64872396,
+ /// or in textual repr: setCollectionNesting(bool,address[])
function setCollectionNesting(bool enable, address[] memory collections)
public
{
@@ -212,79 +243,122 @@
dummy = 0;
}
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
+ /// Set the collection access method.
+ /// @param mode Access mode
+ /// 0 for Normal
+ /// 1 for AllowList
+ /// @dev EVM selector for this function is: 0x41835d4c,
+ /// or in textual repr: setCollectionAccess(uint8)
function setCollectionAccess(uint8 mode) public {
require(false, stub_error);
mode;
dummy = 0;
}
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
+ /// Add the user to the allowed list.
+ ///
+ /// @param user Address of a trusted user.
+ /// @dev EVM selector for this function is: 0x67844fe6,
+ /// or in textual repr: addToCollectionAllowList(address)
function addToCollectionAllowList(address user) public {
require(false, stub_error);
user;
dummy = 0;
}
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
+ /// Remove the user from the allowed list.
+ ///
+ /// @param user Address of a removed user.
+ /// @dev EVM selector for this function is: 0x85c51acb,
+ /// or in textual repr: removeFromCollectionAllowList(address)
function removeFromCollectionAllowList(address user) public {
require(false, stub_error);
user;
dummy = 0;
}
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
+ /// Switch permission for minting.
+ ///
+ /// @param mode Enable if "true".
+ /// @dev EVM selector for this function is: 0x00018e84,
+ /// or in textual repr: setCollectionMintMode(bool)
function setCollectionMintMode(bool mode) public {
require(false, stub_error);
mode;
dummy = 0;
}
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) public view returns (bool) {
+ /// Check that account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x9811b0c7,
+ /// or in textual repr: isOwnerOrAdmin(address)
+ function isOwnerOrAdmin(address user) public view returns (bool) {
require(false, stub_error);
user;
dummy;
return false;
}
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
+ /// Check that substrate account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x68910e00,
+ /// or in textual repr: isOwnerOrAdminSubstrate(uint256)
+ function isOwnerOrAdminSubstrate(uint256 user) public view returns (bool) {
+ require(false, stub_error);
+ user;
+ dummy;
+ return false;
+ }
+
+ /// Returns collection type
+ ///
+ /// @return `Fungible` or `NFT` or `ReFungible`
+ /// @dev EVM selector for this function is: 0xd34b55b8,
+ /// or in textual repr: uniqueCollectionType()
function uniqueCollectionType() public returns (string memory) {
require(false, stub_error);
dummy = 0;
return "";
}
+
+ /// Changes collection owner to another account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner account
+ /// @dev EVM selector for this function is: 0x13af4035,
+ /// or in textual repr: setOwner(address)
+ function setOwner(address newOwner) public {
+ require(false, stub_error);
+ newOwner;
+ dummy = 0;
+ }
+
+ /// Changes collection owner to another substrate account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner substrate account
+ /// @dev EVM selector for this function is: 0xb212138f,
+ /// or in textual repr: setOwnerSubstrate(uint256)
+ function setOwnerSubstrate(uint256 newOwner) public {
+ require(false, stub_error);
+ newOwner;
+ dummy = 0;
+ }
}
-// Selector: 79cc6790
+/// @dev the ERC-165 identifier for this interface is 0x63034ac5
contract ERC20UniqueExtensions is Dummy, ERC165 {
- // Selector: burnFrom(address,uint256) 79cc6790
+ /// Burn tokens from account
+ /// @dev Function that burns an `amount` of the tokens of a given account,
+ /// deducting from the sender's allowance for said account.
+ /// @param from The account whose tokens will be burnt.
+ /// @param amount The amount that will be burnt.
+ /// @dev EVM selector for this function is: 0x79cc6790,
+ /// or in textual repr: burnFrom(address,uint256)
function burnFrom(address from, uint256 amount) public returns (bool) {
require(false, stub_error);
from;
@@ -292,39 +366,87 @@
dummy = 0;
return false;
}
+
+ /// Mint tokens for multiple accounts.
+ /// @param amounts array of pairs of account address and amount
+ /// @dev EVM selector for this function is: 0x1acf2d55,
+ /// or in textual repr: mintBulk((address,uint256)[])
+ function mintBulk(Tuple6[] memory amounts) public returns (bool) {
+ require(false, stub_error);
+ amounts;
+ dummy = 0;
+ return false;
+ }
+}
+
+/// @dev anonymous struct
+struct Tuple6 {
+ address field_0;
+ uint256 field_1;
}
-// Selector: 942e8b22
+/// @dev the ERC-165 identifier for this interface is 0x40c10f19
+contract ERC20Mintable is Dummy, ERC165 {
+ /// Mint tokens for `to` account.
+ /// @param to account that will receive minted tokens
+ /// @param amount amount of tokens to mint
+ /// @dev EVM selector for this function is: 0x40c10f19,
+ /// or in textual repr: mint(address,uint256)
+ function mint(address to, uint256 amount) public returns (bool) {
+ require(false, stub_error);
+ to;
+ amount;
+ dummy = 0;
+ return false;
+ }
+}
+
+/// @dev inlined interface
+contract ERC20Events {
+ event Transfer(address indexed from, address indexed to, uint256 value);
+ event Approval(
+ address indexed owner,
+ address indexed spender,
+ uint256 value
+ );
+}
+
+/// @dev the ERC-165 identifier for this interface is 0x942e8b22
contract ERC20 is Dummy, ERC165, ERC20Events {
- // Selector: name() 06fdde03
+ /// @dev EVM selector for this function is: 0x06fdde03,
+ /// or in textual repr: name()
function name() public view returns (string memory) {
require(false, stub_error);
dummy;
return "";
}
- // Selector: symbol() 95d89b41
+ /// @dev EVM selector for this function is: 0x95d89b41,
+ /// or in textual repr: symbol()
function symbol() public view returns (string memory) {
require(false, stub_error);
dummy;
return "";
}
- // Selector: totalSupply() 18160ddd
+ /// @dev EVM selector for this function is: 0x18160ddd,
+ /// or in textual repr: totalSupply()
function totalSupply() public view returns (uint256) {
require(false, stub_error);
dummy;
return 0;
}
- // Selector: decimals() 313ce567
+ /// @dev EVM selector for this function is: 0x313ce567,
+ /// or in textual repr: decimals()
function decimals() public view returns (uint8) {
require(false, stub_error);
dummy;
return 0;
}
- // Selector: balanceOf(address) 70a08231
+ /// @dev EVM selector for this function is: 0x70a08231,
+ /// or in textual repr: balanceOf(address)
function balanceOf(address owner) public view returns (uint256) {
require(false, stub_error);
owner;
@@ -332,7 +454,8 @@
return 0;
}
- // Selector: transfer(address,uint256) a9059cbb
+ /// @dev EVM selector for this function is: 0xa9059cbb,
+ /// or in textual repr: transfer(address,uint256)
function transfer(address to, uint256 amount) public returns (bool) {
require(false, stub_error);
to;
@@ -341,7 +464,8 @@
return false;
}
- // Selector: transferFrom(address,address,uint256) 23b872dd
+ /// @dev EVM selector for this function is: 0x23b872dd,
+ /// or in textual repr: transferFrom(address,address,uint256)
function transferFrom(
address from,
address to,
@@ -355,7 +479,8 @@
return false;
}
- // Selector: approve(address,uint256) 095ea7b3
+ /// @dev EVM selector for this function is: 0x095ea7b3,
+ /// or in textual repr: approve(address,uint256)
function approve(address spender, uint256 amount) public returns (bool) {
require(false, stub_error);
spender;
@@ -364,7 +489,8 @@
return false;
}
- // Selector: allowance(address,address) dd62ed3e
+ /// @dev EVM selector for this function is: 0xdd62ed3e,
+ /// or in textual repr: allowance(address,address)
function allowance(address owner, address spender)
public
view
@@ -382,6 +508,7 @@
Dummy,
ERC165,
ERC20,
+ ERC20Mintable,
ERC20UniqueExtensions,
Collection
{}
pallets/nonfungible/CHANGELOG.mddiffbeforeafterboth--- a/pallets/nonfungible/CHANGELOG.md
+++ b/pallets/nonfungible/CHANGELOG.md
@@ -2,6 +2,11 @@
All notable changes to this project will be documented in this file.
+## [v0.1.5] - 2022-08-24
+
+### Change
+ - Add bound `AsRef<[u8; 32]>` to `T::CrossAccountId`.
+
<!-- bureaucrate goes here -->
## [v0.1.4] 2022-08-16
pallets/nonfungible/Cargo.tomldiffbeforeafterboth--- a/pallets/nonfungible/Cargo.toml
+++ b/pallets/nonfungible/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "pallet-nonfungible"
-version = "0.1.4"
+version = "0.1.5"
license = "GPLv3"
edition = "2021"
pallets/nonfungible/src/erc.rsdiffbeforeafterboth--- a/pallets/nonfungible/src/erc.rs
+++ b/pallets/nonfungible/src/erc.rs
@@ -50,14 +50,14 @@
};
/// @title A contract that allows to set and delete token properties and change token property permissions.
-#[solidity_interface(name = "TokenProperties")]
+#[solidity_interface(name = TokenProperties)]
impl<T: Config> NonfungibleHandle<T> {
/// @notice Set permissions for token property.
/// @dev Throws error if `msg.sender` is not admin or owner of the collection.
/// @param key Property key.
- /// @param is_mutable Permission to mutate property.
- /// @param collection_admin Permission to mutate property by collection admin if property is mutable.
- /// @param token_owner Permission to mutate property by token owner if property is mutable.
+ /// @param isMutable Permission to mutate property.
+ /// @param collectionAdmin Permission to mutate property by collection admin if property is mutable.
+ /// @param tokenOwner Permission to mutate property by token owner if property is mutable.
fn set_token_property_permission(
&mut self,
caller: caller,
@@ -201,7 +201,7 @@
/// @title ERC-721 Non-Fungible Token Standard, optional metadata extension
/// @dev See https://eips.ethereum.org/EIPS/eip-721
-#[solidity_interface(name = "ERC721Metadata")]
+#[solidity_interface(name = ERC721Metadata, expect_selector = 0x5b5e139f)]
impl<T: Config> NonfungibleHandle<T> {
/// @notice A descriptive name for a collection of NFTs in this contract
fn name(&self) -> Result<string> {
@@ -262,7 +262,7 @@
/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
/// @dev See https://eips.ethereum.org/EIPS/eip-721
-#[solidity_interface(name = "ERC721Enumerable")]
+#[solidity_interface(name = ERC721Enumerable, expect_selector = 0x780e9d63)]
impl<T: Config> NonfungibleHandle<T> {
/// @notice Enumerate valid NFTs
/// @param index A counter less than `totalSupply()`
@@ -289,7 +289,7 @@
/// @title ERC-721 Non-Fungible Token Standard
/// @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md
-#[solidity_interface(name = "ERC721", events(ERC721Events))]
+#[solidity_interface(name = ERC721, events(ERC721Events), expect_selector = 0x80ac58cd)]
impl<T: Config> NonfungibleHandle<T> {
/// @notice Count all NFTs assigned to an owner
/// @dev NFTs assigned to the zero address are considered invalid, and this
@@ -316,13 +316,13 @@
.as_eth())
}
/// @dev Not implemented
+ #[solidity(rename_selector = "safeTransferFrom")]
fn safe_transfer_from_with_data(
&mut self,
_from: address,
_to: address,
_token_id: uint256,
_data: bytes,
- _value: value,
) -> Result<void> {
// TODO: Not implemetable
Err("not implemented".into())
@@ -333,7 +333,6 @@
_from: address,
_to: address,
_token_id: uint256,
- _value: value,
) -> Result<void> {
// TODO: Not implemetable
Err("not implemented".into())
@@ -348,7 +347,6 @@
/// @param from The current owner of the NFT
/// @param to The new owner
/// @param tokenId The NFT to transfer
- /// @param _value Not used for an NFT
#[weight(<SelfWeightOf<T>>::transfer_from())]
fn transfer_from(
&mut self,
@@ -356,7 +354,6 @@
from: address,
to: address,
token_id: uint256,
- _value: value,
) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let from = T::CrossAccountId::from_eth(from);
@@ -378,13 +375,7 @@
/// @param approved The new approved NFT controller
/// @param tokenId The NFT to approve
#[weight(<SelfWeightOf<T>>::approve())]
- fn approve(
- &mut self,
- caller: caller,
- approved: address,
- token_id: uint256,
- _value: value,
- ) -> Result<void> {
+ fn approve(&mut self, caller: caller, approved: address, token_id: uint256) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let approved = T::CrossAccountId::from_eth(approved);
let token = token_id.try_into()?;
@@ -419,7 +410,7 @@
}
/// @title ERC721 Token that can be irreversibly burned (destroyed).
-#[solidity_interface(name = "ERC721Burnable")]
+#[solidity_interface(name = ERC721Burnable)]
impl<T: Config> NonfungibleHandle<T> {
/// @notice Burns a specific ERC721 token.
/// @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
@@ -436,7 +427,7 @@
}
/// @title ERC721 minting logic.
-#[solidity_interface(name = "ERC721Mintable", events(ERC721MintableEvents))]
+#[solidity_interface(name = ERC721Mintable, events(ERC721MintableEvents))]
impl<T: Config> NonfungibleHandle<T> {
fn minting_finished(&self) -> Result<bool> {
Ok(false)
@@ -597,22 +588,15 @@
}
/// @title Unique extensions for ERC721.
-#[solidity_interface(name = "ERC721UniqueExtensions")]
+#[solidity_interface(name = ERC721UniqueExtensions)]
impl<T: Config> NonfungibleHandle<T> {
/// @notice Transfer ownership of an NFT
/// @dev Throws unless `msg.sender` is the current owner. Throws if `to`
/// is the zero address. Throws if `tokenId` is not a valid NFT.
/// @param to The new owner
/// @param tokenId The NFT to transfer
- /// @param _value Not used for an NFT
#[weight(<SelfWeightOf<T>>::transfer())]
- fn transfer(
- &mut self,
- caller: caller,
- to: address,
- token_id: uint256,
- _value: value,
- ) -> Result<void> {
+ fn transfer(&mut self, caller: caller, to: address, token_id: uint256) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let to = T::CrossAccountId::from_eth(to);
let token = token_id.try_into()?;
@@ -630,15 +614,8 @@
/// if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
/// @param from The current owner of the NFT
/// @param tokenId The NFT to transfer
- /// @param _value Not used for an NFT
#[weight(<SelfWeightOf<T>>::burn_from())]
- fn burn_from(
- &mut self,
- caller: caller,
- from: address,
- token_id: uint256,
- _value: value,
- ) -> Result<void> {
+ fn burn_from(&mut self, caller: caller, from: address, token_id: uint256) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let from = T::CrossAccountId::from_eth(from);
let token = token_id.try_into()?;
@@ -751,7 +728,7 @@
}
#[solidity_interface(
- name = "UniqueNFT",
+ name = UniqueNFT,
is(
ERC721,
ERC721Metadata,
@@ -759,11 +736,11 @@
ERC721UniqueExtensions,
ERC721Mintable,
ERC721Burnable,
- via("CollectionHandle<T>", common_mut, Collection),
+ Collection(common_mut, CollectionHandle<T>),
TokenProperties,
)
)]
-impl<T: Config> NonfungibleHandle<T> where T::AccountId: From<[u8; 32]> {}
+impl<T: Config> NonfungibleHandle<T> where T::AccountId: From<[u8; 32]> + AsRef<[u8; 32]> {}
// Not a tests, but code generators
generate_stubgen!(gen_impl, UniqueNFTCall<()>, true);
@@ -771,7 +748,7 @@
impl<T: Config> CommonEvmHandler for NonfungibleHandle<T>
where
- T::AccountId: From<[u8; 32]>,
+ T::AccountId: From<[u8; 32]> + AsRef<[u8; 32]>,
{
const CODE: &'static [u8] = include_bytes!("./stubs/UniqueNFT.raw");
pallets/nonfungible/src/stubs/UniqueNFT.rawdiffbeforeafterbothbinary blob β no preview
pallets/nonfungible/src/stubs/UniqueNFT.soldiffbeforeafterboth--- a/pallets/nonfungible/src/stubs/UniqueNFT.sol
+++ b/pallets/nonfungible/src/stubs/UniqueNFT.sol
@@ -3,13 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Anonymous struct
-struct Tuple0 {
- uint256 field_0;
- string field_1;
-}
-
-// Common stubs holder
+/// @dev common stubs holder
contract Dummy {
uint8 dummy;
string stub_error = "this contract is implemented in native";
@@ -27,40 +21,17 @@
}
}
-// Inline
-contract ERC721Events {
- event Transfer(
- address indexed from,
- address indexed to,
- uint256 indexed tokenId
- );
- event Approval(
- address indexed owner,
- address indexed approved,
- uint256 indexed tokenId
- );
- event ApprovalForAll(
- address indexed owner,
- address indexed operator,
- bool approved
- );
-}
-
-// Inline
-contract ERC721MintableEvents {
- event MintingFinished();
-}
-
-// Selector: 41369377
+/// @title A contract that allows to set and delete token properties and change token property permissions.
+/// @dev the ERC-165 identifier for this interface is 0x41369377
contract TokenProperties is Dummy, ERC165 {
- // @notice Set permissions for token property.
- // @dev Throws error if `msg.sender` is not admin or owner of the collection.
- // @param key Property key.
- // @param is_mutable Permission to mutate property.
- // @param collection_admin Permission to mutate property by collection admin if property is mutable.
- // @param token_owner Permission to mutate property by token owner if property is mutable.
- //
- // Selector: setTokenPropertyPermission(string,bool,bool,bool) 222d97fa
+ /// @notice Set permissions for token property.
+ /// @dev Throws error if `msg.sender` is not admin or owner of the collection.
+ /// @param key Property key.
+ /// @param isMutable Permission to mutate property.
+ /// @param collectionAdmin Permission to mutate property by collection admin if property is mutable.
+ /// @param tokenOwner Permission to mutate property by token owner if property is mutable.
+ /// @dev EVM selector for this function is: 0x222d97fa,
+ /// or in textual repr: setTokenPropertyPermission(string,bool,bool,bool)
function setTokenPropertyPermission(
string memory key,
bool isMutable,
@@ -75,13 +46,13 @@
dummy = 0;
}
- // @notice Set token property value.
- // @dev Throws error if `msg.sender` has no permission to edit the property.
- // @param tokenId ID of the token.
- // @param key Property key.
- // @param value Property value.
- //
- // Selector: setProperty(uint256,string,bytes) 1752d67b
+ /// @notice Set token property value.
+ /// @dev Throws error if `msg.sender` has no permission to edit the property.
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @param value Property value.
+ /// @dev EVM selector for this function is: 0x1752d67b,
+ /// or in textual repr: setProperty(uint256,string,bytes)
function setProperty(
uint256 tokenId,
string memory key,
@@ -94,12 +65,12 @@
dummy = 0;
}
- // @notice Delete token property value.
- // @dev Throws error if `msg.sender` has no permission to edit the property.
- // @param tokenId ID of the token.
- // @param key Property key.
- //
- // Selector: deleteProperty(uint256,string) 066111d1
+ /// @notice Delete token property value.
+ /// @dev Throws error if `msg.sender` has no permission to edit the property.
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x066111d1,
+ /// or in textual repr: deleteProperty(uint256,string)
function deleteProperty(uint256 tokenId, string memory key) public {
require(false, stub_error);
tokenId;
@@ -107,13 +78,13 @@
dummy = 0;
}
- // @notice Get token property value.
- // @dev Throws error if key not found
- // @param tokenId ID of the token.
- // @param key Property key.
- // @return Property value bytes
- //
- // Selector: property(uint256,string) 7228c327
+ /// @notice Get token property value.
+ /// @dev Throws error if key not found
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @return Property value bytes
+ /// @dev EVM selector for this function is: 0x7228c327,
+ /// or in textual repr: property(uint256,string)
function property(uint256 tokenId, string memory key)
public
view
@@ -127,511 +98,513 @@
}
}
-// Selector: 42966c68
-contract ERC721Burnable is Dummy, ERC165 {
- // @notice Burns a specific ERC721 token.
- // @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
- // operator of the current owner.
- // @param tokenId The NFT to approve
- //
- // Selector: burn(uint256) 42966c68
- function burn(uint256 tokenId) public {
+/// @title A contract that allows you to work with collections.
+/// @dev the ERC-165 identifier for this interface is 0xe54be640
+contract Collection is Dummy, ERC165 {
+ /// Set collection property.
+ ///
+ /// @param key Property key.
+ /// @param value Propery value.
+ /// @dev EVM selector for this function is: 0x2f073f66,
+ /// or in textual repr: setCollectionProperty(string,bytes)
+ function setCollectionProperty(string memory key, bytes memory value)
+ public
+ {
require(false, stub_error);
- tokenId;
+ key;
+ value;
dummy = 0;
}
-}
-// Selector: 58800161
-contract ERC721 is Dummy, ERC165, ERC721Events {
- // @notice Count all NFTs assigned to an owner
- // @dev NFTs assigned to the zero address are considered invalid, and this
- // function throws for queries about the zero address.
- // @param owner An address for whom to query the balance
- // @return The number of NFTs owned by `owner`, possibly zero
- //
- // Selector: balanceOf(address) 70a08231
- function balanceOf(address owner) public view returns (uint256) {
+ /// Delete collection property.
+ ///
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x7b7debce,
+ /// or in textual repr: deleteCollectionProperty(string)
+ function deleteCollectionProperty(string memory key) public {
require(false, stub_error);
- owner;
- dummy;
- return 0;
+ key;
+ dummy = 0;
}
- // @notice Find the owner of an NFT
- // @dev NFTs assigned to zero address are considered invalid, and queries
- // about them do throw.
- // @param tokenId The identifier for an NFT
- // @return The address of the owner of the NFT
- //
- // Selector: ownerOf(uint256) 6352211e
- function ownerOf(uint256 tokenId) public view returns (address) {
+ /// Get collection property.
+ ///
+ /// @dev Throws error if key not found.
+ ///
+ /// @param key Property key.
+ /// @return bytes The property corresponding to the key.
+ /// @dev EVM selector for this function is: 0xcf24fd6d,
+ /// or in textual repr: collectionProperty(string)
+ function collectionProperty(string memory key)
+ public
+ view
+ returns (bytes memory)
+ {
require(false, stub_error);
- tokenId;
+ key;
dummy;
- return 0x0000000000000000000000000000000000000000;
+ return hex"";
}
- // @dev Not implemented
- //
- // Selector: safeTransferFromWithData(address,address,uint256,bytes) 60a11672
- function safeTransferFromWithData(
- address from,
- address to,
- uint256 tokenId,
- bytes memory data
- ) public {
+ /// Set the sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0x7623402e,
+ /// or in textual repr: setCollectionSponsor(address)
+ function setCollectionSponsor(address sponsor) public {
require(false, stub_error);
- from;
- to;
- tokenId;
- data;
+ sponsor;
dummy = 0;
}
- // @dev Not implemented
- //
- // Selector: safeTransferFrom(address,address,uint256) 42842e0e
- function safeTransferFrom(
- address from,
- address to,
- uint256 tokenId
- ) public {
+ /// Set the substrate sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Substrate address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0xc74d6751,
+ /// or in textual repr: setCollectionSponsorSubstrate(uint256)
+ function setCollectionSponsorSubstrate(uint256 sponsor) public {
require(false, stub_error);
- from;
- to;
- tokenId;
+ sponsor;
dummy = 0;
}
- // @notice Transfer ownership of an NFT -- THE CALLER IS RESPONSIBLE
- // TO CONFIRM THAT `to` IS CAPABLE OF RECEIVING NFTS OR ELSE
- // THEY MAY BE PERMANENTLY LOST
- // @dev Throws unless `msg.sender` is the current owner or an authorized
- // operator for this NFT. Throws if `from` is not the current owner. Throws
- // if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
- // @param from The current owner of the NFT
- // @param to The new owner
- // @param tokenId The NFT to transfer
- // @param _value Not used for an NFT
- //
- // Selector: transferFrom(address,address,uint256) 23b872dd
- function transferFrom(
- address from,
- address to,
- uint256 tokenId
- ) public {
+ /// @dev EVM selector for this function is: 0x058ac185,
+ /// or in textual repr: hasCollectionPendingSponsor()
+ function hasCollectionPendingSponsor() public view returns (bool) {
require(false, stub_error);
- from;
- to;
- tokenId;
- dummy = 0;
+ dummy;
+ return false;
}
- // @notice Set or reaffirm the approved address for an NFT
- // @dev The zero address indicates there is no approved address.
- // @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
- // operator of the current owner.
- // @param approved The new approved NFT controller
- // @param tokenId The NFT to approve
- //
- // Selector: approve(address,uint256) 095ea7b3
- function approve(address approved, uint256 tokenId) public {
+ /// Collection sponsorship confirmation.
+ ///
+ /// @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ /// @dev EVM selector for this function is: 0x3c50e97a,
+ /// or in textual repr: confirmCollectionSponsorship()
+ function confirmCollectionSponsorship() public {
require(false, stub_error);
- approved;
- tokenId;
dummy = 0;
}
- // @dev Not implemented
- //
- // Selector: setApprovalForAll(address,bool) a22cb465
- function setApprovalForAll(address operator, bool approved) public {
+ /// Remove collection sponsor.
+ /// @dev EVM selector for this function is: 0x6e0326a3,
+ /// or in textual repr: removeCollectionSponsor()
+ function removeCollectionSponsor() public {
require(false, stub_error);
- operator;
- approved;
dummy = 0;
}
- // @dev Not implemented
- //
- // Selector: getApproved(uint256) 081812fc
- function getApproved(uint256 tokenId) public view returns (address) {
+ /// Get current sponsor.
+ ///
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ /// @dev EVM selector for this function is: 0xb66bbc14,
+ /// or in textual repr: getCollectionSponsor()
+ function getCollectionSponsor() public view returns (Tuple17 memory) {
require(false, stub_error);
- tokenId;
dummy;
- return 0x0000000000000000000000000000000000000000;
+ return Tuple17(0x0000000000000000000000000000000000000000, 0);
}
- // @dev Not implemented
- //
- // Selector: isApprovedForAll(address,address) e985e9c5
- function isApprovedForAll(address owner, address operator)
- public
- view
- returns (address)
- {
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "accountTokenOwnershipLimit",
+ /// "sponsoredDataSize",
+ /// "sponsoredDataRateLimit",
+ /// "tokenLimit",
+ /// "sponsorTransferTimeout",
+ /// "sponsorApproveTimeout"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x6a3841db,
+ /// or in textual repr: setCollectionLimit(string,uint32)
+ function setCollectionLimit(string memory limit, uint32 value) public {
require(false, stub_error);
- owner;
- operator;
- dummy;
- return 0x0000000000000000000000000000000000000000;
+ limit;
+ value;
+ dummy = 0;
}
-}
-// Selector: 5b5e139f
-contract ERC721Metadata is Dummy, ERC165 {
- // @notice A descriptive name for a collection of NFTs in this contract
- //
- // Selector: name() 06fdde03
- function name() public view returns (string memory) {
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "ownerCanTransfer",
+ /// "ownerCanDestroy",
+ /// "transfersEnabled"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x993b7fba,
+ /// or in textual repr: setCollectionLimit(string,bool)
+ function setCollectionLimit(string memory limit, bool value) public {
require(false, stub_error);
- dummy;
- return "";
+ limit;
+ value;
+ dummy = 0;
}
- // @notice An abbreviated name for NFTs in this contract
- //
- // Selector: symbol() 95d89b41
- function symbol() public view returns (string memory) {
+ /// Get contract address.
+ /// @dev EVM selector for this function is: 0xf6b4dfb4,
+ /// or in textual repr: contractAddress()
+ function contractAddress() public view returns (address) {
require(false, stub_error);
dummy;
- return "";
+ return 0x0000000000000000000000000000000000000000;
}
- // @notice A distinct Uniform Resource Identifier (URI) for a given asset.
- //
- // @dev If the token has a `url` property and it is not empty, it is returned.
- // Else If the collection does not have a property with key `schemaName` or its value is not equal to `ERC721Metadata`, it return an error `tokenURI not set`.
- // If the collection property `baseURI` is empty or absent, return "" (empty string)
- // otherwise, if token property `suffix` present and is non-empty, return concatenation of baseURI and suffix
- // otherwise, return concatenation of `baseURI` and stringified token id (decimal stringifying, without paddings).
- //
- // @return token's const_metadata
- //
- // Selector: tokenURI(uint256) c87b56dd
- function tokenURI(uint256 tokenId) public view returns (string memory) {
+ /// Add collection admin by substrate address.
+ /// @param newAdmin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x5730062b,
+ /// or in textual repr: addCollectionAdminSubstrate(uint256)
+ function addCollectionAdminSubstrate(uint256 newAdmin) public {
require(false, stub_error);
- tokenId;
- dummy;
- return "";
+ newAdmin;
+ dummy = 0;
}
-}
-// Selector: 68ccfe89
-contract ERC721Mintable is Dummy, ERC165, ERC721MintableEvents {
- // Selector: mintingFinished() 05d2035b
- function mintingFinished() public view returns (bool) {
+ /// Remove collection admin by substrate address.
+ /// @param admin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x4048fcf9,
+ /// or in textual repr: removeCollectionAdminSubstrate(uint256)
+ function removeCollectionAdminSubstrate(uint256 admin) public {
require(false, stub_error);
- dummy;
- return false;
+ admin;
+ dummy = 0;
}
- // @notice Function to mint token.
- // @dev `tokenId` should be obtained with `nextTokenId` method,
- // unlike standard, you can't specify it manually
- // @param to The new owner
- // @param tokenId ID of the minted NFT
- //
- // Selector: mint(address,uint256) 40c10f19
- function mint(address to, uint256 tokenId) public returns (bool) {
+ /// Add collection admin.
+ /// @param newAdmin Address of the added administrator.
+ /// @dev EVM selector for this function is: 0x92e462c7,
+ /// or in textual repr: addCollectionAdmin(address)
+ function addCollectionAdmin(address newAdmin) public {
require(false, stub_error);
- to;
- tokenId;
+ newAdmin;
dummy = 0;
- return false;
}
- // @notice Function to mint token with the given tokenUri.
- // @dev `tokenId` should be obtained with `nextTokenId` method,
- // unlike standard, you can't specify it manually
- // @param to The new owner
- // @param tokenId ID of the minted NFT
- // @param tokenUri Token URI that would be stored in the NFT properties
- //
- // Selector: mintWithTokenURI(address,uint256,string) 50bb4e7f
- function mintWithTokenURI(
- address to,
- uint256 tokenId,
- string memory tokenUri
- ) public returns (bool) {
+ /// Remove collection admin.
+ ///
+ /// @param admin Address of the removed administrator.
+ /// @dev EVM selector for this function is: 0xfafd7b42,
+ /// or in textual repr: removeCollectionAdmin(address)
+ function removeCollectionAdmin(address admin) public {
require(false, stub_error);
- to;
- tokenId;
- tokenUri;
+ admin;
dummy = 0;
- return false;
}
- // @dev Not implemented
- //
- // Selector: finishMinting() 7d64bcb4
- function finishMinting() public returns (bool) {
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ /// @dev EVM selector for this function is: 0x112d4586,
+ /// or in textual repr: setCollectionNesting(bool)
+ function setCollectionNesting(bool enable) public {
require(false, stub_error);
+ enable;
dummy = 0;
- return false;
}
-}
-// Selector: 6cf113cd
-contract Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
- function setCollectionProperty(string memory key, bytes memory value)
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ /// @param collections Addresses of collections that will be available for nesting.
+ /// @dev EVM selector for this function is: 0x64872396,
+ /// or in textual repr: setCollectionNesting(bool,address[])
+ function setCollectionNesting(bool enable, address[] memory collections)
public
{
require(false, stub_error);
- key;
- value;
+ enable;
+ collections;
dummy = 0;
}
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
- function deleteCollectionProperty(string memory key) public {
+ /// Set the collection access method.
+ /// @param mode Access mode
+ /// 0 for Normal
+ /// 1 for AllowList
+ /// @dev EVM selector for this function is: 0x41835d4c,
+ /// or in textual repr: setCollectionAccess(uint8)
+ function setCollectionAccess(uint8 mode) public {
require(false, stub_error);
- key;
+ mode;
dummy = 0;
}
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
- function collectionProperty(string memory key)
- public
- view
- returns (bytes memory)
- {
- require(false, stub_error);
- key;
- dummy;
- return hex"";
- }
-
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
- function setCollectionSponsor(address sponsor) public {
+ /// Add the user to the allowed list.
+ ///
+ /// @param user Address of a trusted user.
+ /// @dev EVM selector for this function is: 0x67844fe6,
+ /// or in textual repr: addToCollectionAllowList(address)
+ function addToCollectionAllowList(address user) public {
require(false, stub_error);
- sponsor;
+ user;
dummy = 0;
}
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
- function confirmCollectionSponsorship() public {
+ /// Remove the user from the allowed list.
+ ///
+ /// @param user Address of a removed user.
+ /// @dev EVM selector for this function is: 0x85c51acb,
+ /// or in textual repr: removeFromCollectionAllowList(address)
+ function removeFromCollectionAllowList(address user) public {
require(false, stub_error);
+ user;
dummy = 0;
}
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
- function setCollectionLimit(string memory limit, uint32 value) public {
+ /// Switch permission for minting.
+ ///
+ /// @param mode Enable if "true".
+ /// @dev EVM selector for this function is: 0x00018e84,
+ /// or in textual repr: setCollectionMintMode(bool)
+ function setCollectionMintMode(bool mode) public {
require(false, stub_error);
- limit;
- value;
+ mode;
dummy = 0;
}
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
- function setCollectionLimit(string memory limit, bool value) public {
+ /// Check that account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x9811b0c7,
+ /// or in textual repr: isOwnerOrAdmin(address)
+ function isOwnerOrAdmin(address user) public view returns (bool) {
require(false, stub_error);
- limit;
- value;
- dummy = 0;
+ user;
+ dummy;
+ return false;
}
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
- function contractAddress() public view returns (address) {
+ /// Check that substrate account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x68910e00,
+ /// or in textual repr: isOwnerOrAdminSubstrate(uint256)
+ function isOwnerOrAdminSubstrate(uint256 user) public view returns (bool) {
require(false, stub_error);
+ user;
dummy;
- return 0x0000000000000000000000000000000000000000;
+ return false;
}
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
- function addCollectionAdminSubstrate(uint256 newAdmin) public {
+ /// Returns collection type
+ ///
+ /// @return `Fungible` or `NFT` or `ReFungible`
+ /// @dev EVM selector for this function is: 0xd34b55b8,
+ /// or in textual repr: uniqueCollectionType()
+ function uniqueCollectionType() public returns (string memory) {
require(false, stub_error);
- newAdmin;
dummy = 0;
+ return "";
}
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
- function removeCollectionAdminSubstrate(uint256 admin) public {
+ /// Changes collection owner to another account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner account
+ /// @dev EVM selector for this function is: 0x13af4035,
+ /// or in textual repr: setOwner(address)
+ function setOwner(address newOwner) public {
require(false, stub_error);
- admin;
+ newOwner;
dummy = 0;
}
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
- function addCollectionAdmin(address newAdmin) public {
+ /// Changes collection owner to another substrate account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner substrate account
+ /// @dev EVM selector for this function is: 0xb212138f,
+ /// or in textual repr: setOwnerSubstrate(uint256)
+ function setOwnerSubstrate(uint256 newOwner) public {
require(false, stub_error);
- newAdmin;
+ newOwner;
dummy = 0;
}
+}
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
- function removeCollectionAdmin(address admin) public {
+/// @dev anonymous struct
+struct Tuple17 {
+ address field_0;
+ uint256 field_1;
+}
+
+/// @title ERC721 Token that can be irreversibly burned (destroyed).
+/// @dev the ERC-165 identifier for this interface is 0x42966c68
+contract ERC721Burnable is Dummy, ERC165 {
+ /// @notice Burns a specific ERC721 token.
+ /// @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
+ /// operator of the current owner.
+ /// @param tokenId The NFT to approve
+ /// @dev EVM selector for this function is: 0x42966c68,
+ /// or in textual repr: burn(uint256)
+ function burn(uint256 tokenId) public {
require(false, stub_error);
- admin;
+ tokenId;
dummy = 0;
}
+}
+
+/// @dev inlined interface
+contract ERC721MintableEvents {
+ event MintingFinished();
+}
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
- function setCollectionNesting(bool enable) public {
+/// @title ERC721 minting logic.
+/// @dev the ERC-165 identifier for this interface is 0x68ccfe89
+contract ERC721Mintable is Dummy, ERC165, ERC721MintableEvents {
+ /// @dev EVM selector for this function is: 0x05d2035b,
+ /// or in textual repr: mintingFinished()
+ function mintingFinished() public view returns (bool) {
require(false, stub_error);
- enable;
- dummy = 0;
+ dummy;
+ return false;
}
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
- function setCollectionNesting(bool enable, address[] memory collections)
- public
- {
+ /// @notice Function to mint token.
+ /// @dev `tokenId` should be obtained with `nextTokenId` method,
+ /// unlike standard, you can't specify it manually
+ /// @param to The new owner
+ /// @param tokenId ID of the minted NFT
+ /// @dev EVM selector for this function is: 0x40c10f19,
+ /// or in textual repr: mint(address,uint256)
+ function mint(address to, uint256 tokenId) public returns (bool) {
require(false, stub_error);
- enable;
- collections;
+ to;
+ tokenId;
dummy = 0;
+ return false;
}
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
- function setCollectionAccess(uint8 mode) public {
+ /// @notice Function to mint token with the given tokenUri.
+ /// @dev `tokenId` should be obtained with `nextTokenId` method,
+ /// unlike standard, you can't specify it manually
+ /// @param to The new owner
+ /// @param tokenId ID of the minted NFT
+ /// @param tokenUri Token URI that would be stored in the NFT properties
+ /// @dev EVM selector for this function is: 0x50bb4e7f,
+ /// or in textual repr: mintWithTokenURI(address,uint256,string)
+ function mintWithTokenURI(
+ address to,
+ uint256 tokenId,
+ string memory tokenUri
+ ) public returns (bool) {
require(false, stub_error);
- mode;
+ to;
+ tokenId;
+ tokenUri;
dummy = 0;
+ return false;
}
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
- function addToCollectionAllowList(address user) public {
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x7d64bcb4,
+ /// or in textual repr: finishMinting()
+ function finishMinting() public returns (bool) {
require(false, stub_error);
- user;
dummy = 0;
+ return false;
}
+}
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
- function removeFromCollectionAllowList(address user) public {
+/// @title Unique extensions for ERC721.
+/// @dev the ERC-165 identifier for this interface is 0xd74d154f
+contract ERC721UniqueExtensions is Dummy, ERC165 {
+ /// @notice Transfer ownership of an NFT
+ /// @dev Throws unless `msg.sender` is the current owner. Throws if `to`
+ /// is the zero address. Throws if `tokenId` is not a valid NFT.
+ /// @param to The new owner
+ /// @param tokenId The NFT to transfer
+ /// @dev EVM selector for this function is: 0xa9059cbb,
+ /// or in textual repr: transfer(address,uint256)
+ function transfer(address to, uint256 tokenId) public {
require(false, stub_error);
- user;
+ to;
+ tokenId;
dummy = 0;
}
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
- function setCollectionMintMode(bool mode) public {
+ /// @notice Burns a specific ERC721 token.
+ /// @dev Throws unless `msg.sender` is the current owner or an authorized
+ /// operator for this NFT. Throws if `from` is not the current owner. Throws
+ /// if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
+ /// @param from The current owner of the NFT
+ /// @param tokenId The NFT to transfer
+ /// @dev EVM selector for this function is: 0x79cc6790,
+ /// or in textual repr: burnFrom(address,uint256)
+ function burnFrom(address from, uint256 tokenId) public {
require(false, stub_error);
- mode;
+ from;
+ tokenId;
dummy = 0;
}
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) public view returns (bool) {
+ /// @notice Returns next free NFT ID.
+ /// @dev EVM selector for this function is: 0x75794a3c,
+ /// or in textual repr: nextTokenId()
+ function nextTokenId() public view returns (uint256) {
require(false, stub_error);
- user;
dummy;
+ return 0;
+ }
+
+ /// @notice Function to mint multiple tokens.
+ /// @dev `tokenIds` should be an array of consecutive numbers and first number
+ /// should be obtained with `nextTokenId` method
+ /// @param to The new owner
+ /// @param tokenIds IDs of the minted NFTs
+ /// @dev EVM selector for this function is: 0x44a9945e,
+ /// or in textual repr: mintBulk(address,uint256[])
+ function mintBulk(address to, uint256[] memory tokenIds)
+ public
+ returns (bool)
+ {
+ require(false, stub_error);
+ to;
+ tokenIds;
+ dummy = 0;
return false;
}
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
- function uniqueCollectionType() public returns (string memory) {
+ /// @notice Function to mint multiple tokens with the given tokenUris.
+ /// @dev `tokenIds` is array of pairs of token ID and token URI. Token IDs should be consecutive
+ /// numbers and first number should be obtained with `nextTokenId` method
+ /// @param to The new owner
+ /// @param tokens array of pairs of token ID and token URI for minted tokens
+ /// @dev EVM selector for this function is: 0x36543006,
+ /// or in textual repr: mintBulkWithTokenURI(address,(uint256,string)[])
+ function mintBulkWithTokenURI(address to, Tuple8[] memory tokens)
+ public
+ returns (bool)
+ {
require(false, stub_error);
+ to;
+ tokens;
dummy = 0;
- return "";
+ return false;
}
}
-// Selector: 780e9d63
+/// @dev anonymous struct
+struct Tuple8 {
+ uint256 field_0;
+ string field_1;
+}
+
+/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
+/// @dev See https://eips.ethereum.org/EIPS/eip-721
+/// @dev the ERC-165 identifier for this interface is 0x780e9d63
contract ERC721Enumerable is Dummy, ERC165 {
- // @notice Enumerate valid NFTs
- // @param index A counter less than `totalSupply()`
- // @return The token identifier for the `index`th NFT,
- // (sort order not specified)
- //
- // Selector: tokenByIndex(uint256) 4f6ccce7
+ /// @notice Enumerate valid NFTs
+ /// @param index A counter less than `totalSupply()`
+ /// @return The token identifier for the `index`th NFT,
+ /// (sort order not specified)
+ /// @dev EVM selector for this function is: 0x4f6ccce7,
+ /// or in textual repr: tokenByIndex(uint256)
function tokenByIndex(uint256 index) public view returns (uint256) {
require(false, stub_error);
index;
@@ -639,9 +612,9 @@
return 0;
}
- // @dev Not implemented
- //
- // Selector: tokenOfOwnerByIndex(address,uint256) 2f745c59
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x2f745c59,
+ /// or in textual repr: tokenOfOwnerByIndex(address,uint256)
function tokenOfOwnerByIndex(address owner, uint256 index)
public
view
@@ -654,11 +627,11 @@
return 0;
}
- // @notice Count NFTs tracked by this contract
- // @return A count of valid NFTs tracked by this contract, where each one of
- // them has an assigned and queryable owner not equal to the zero address
- //
- // Selector: totalSupply() 18160ddd
+ /// @notice Count NFTs tracked by this contract
+ /// @return A count of valid NFTs tracked by this contract, where each one of
+ /// them has an assigned and queryable owner not equal to the zero address
+ /// @dev EVM selector for this function is: 0x18160ddd,
+ /// or in textual repr: totalSupply()
function totalSupply() public view returns (uint256) {
require(false, stub_error);
dummy;
@@ -666,82 +639,201 @@
}
}
-// Selector: d74d154f
-contract ERC721UniqueExtensions is Dummy, ERC165 {
- // @notice Transfer ownership of an NFT
- // @dev Throws unless `msg.sender` is the current owner. Throws if `to`
- // is the zero address. Throws if `tokenId` is not a valid NFT.
- // @param to The new owner
- // @param tokenId The NFT to transfer
- // @param _value Not used for an NFT
- //
- // Selector: transfer(address,uint256) a9059cbb
- function transfer(address to, uint256 tokenId) public {
+/// @title ERC-721 Non-Fungible Token Standard, optional metadata extension
+/// @dev See https://eips.ethereum.org/EIPS/eip-721
+/// @dev the ERC-165 identifier for this interface is 0x5b5e139f
+contract ERC721Metadata is Dummy, ERC165 {
+ /// @notice A descriptive name for a collection of NFTs in this contract
+ /// @dev EVM selector for this function is: 0x06fdde03,
+ /// or in textual repr: name()
+ function name() public view returns (string memory) {
+ require(false, stub_error);
+ dummy;
+ return "";
+ }
+
+ /// @notice An abbreviated name for NFTs in this contract
+ /// @dev EVM selector for this function is: 0x95d89b41,
+ /// or in textual repr: symbol()
+ function symbol() public view returns (string memory) {
+ require(false, stub_error);
+ dummy;
+ return "";
+ }
+
+ /// @notice A distinct Uniform Resource Identifier (URI) for a given asset.
+ ///
+ /// @dev If the token has a `url` property and it is not empty, it is returned.
+ /// Else If the collection does not have a property with key `schemaName` or its value is not equal to `ERC721Metadata`, it return an error `tokenURI not set`.
+ /// If the collection property `baseURI` is empty or absent, return "" (empty string)
+ /// otherwise, if token property `suffix` present and is non-empty, return concatenation of baseURI and suffix
+ /// otherwise, return concatenation of `baseURI` and stringified token id (decimal stringifying, without paddings).
+ ///
+ /// @return token's const_metadata
+ /// @dev EVM selector for this function is: 0xc87b56dd,
+ /// or in textual repr: tokenURI(uint256)
+ function tokenURI(uint256 tokenId) public view returns (string memory) {
+ require(false, stub_error);
+ tokenId;
+ dummy;
+ return "";
+ }
+}
+
+/// @dev inlined interface
+contract ERC721Events {
+ event Transfer(
+ address indexed from,
+ address indexed to,
+ uint256 indexed tokenId
+ );
+ event Approval(
+ address indexed owner,
+ address indexed approved,
+ uint256 indexed tokenId
+ );
+ event ApprovalForAll(
+ address indexed owner,
+ address indexed operator,
+ bool approved
+ );
+}
+
+/// @title ERC-721 Non-Fungible Token Standard
+/// @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md
+/// @dev the ERC-165 identifier for this interface is 0x80ac58cd
+contract ERC721 is Dummy, ERC165, ERC721Events {
+ /// @notice Count all NFTs assigned to an owner
+ /// @dev NFTs assigned to the zero address are considered invalid, and this
+ /// function throws for queries about the zero address.
+ /// @param owner An address for whom to query the balance
+ /// @return The number of NFTs owned by `owner`, possibly zero
+ /// @dev EVM selector for this function is: 0x70a08231,
+ /// or in textual repr: balanceOf(address)
+ function balanceOf(address owner) public view returns (uint256) {
+ require(false, stub_error);
+ owner;
+ dummy;
+ return 0;
+ }
+
+ /// @notice Find the owner of an NFT
+ /// @dev NFTs assigned to zero address are considered invalid, and queries
+ /// about them do throw.
+ /// @param tokenId The identifier for an NFT
+ /// @return The address of the owner of the NFT
+ /// @dev EVM selector for this function is: 0x6352211e,
+ /// or in textual repr: ownerOf(uint256)
+ function ownerOf(uint256 tokenId) public view returns (address) {
+ require(false, stub_error);
+ tokenId;
+ dummy;
+ return 0x0000000000000000000000000000000000000000;
+ }
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xb88d4fde,
+ /// or in textual repr: safeTransferFrom(address,address,uint256,bytes)
+ function safeTransferFrom(
+ address from,
+ address to,
+ uint256 tokenId,
+ bytes memory data
+ ) public {
+ require(false, stub_error);
+ from;
+ to;
+ tokenId;
+ data;
+ dummy = 0;
+ }
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x42842e0e,
+ /// or in textual repr: safeTransferFrom(address,address,uint256)
+ function safeTransferFrom(
+ address from,
+ address to,
+ uint256 tokenId
+ ) public {
require(false, stub_error);
+ from;
to;
tokenId;
dummy = 0;
}
- // @notice Burns a specific ERC721 token.
- // @dev Throws unless `msg.sender` is the current owner or an authorized
- // operator for this NFT. Throws if `from` is not the current owner. Throws
- // if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
- // @param from The current owner of the NFT
- // @param tokenId The NFT to transfer
- // @param _value Not used for an NFT
- //
- // Selector: burnFrom(address,uint256) 79cc6790
- function burnFrom(address from, uint256 tokenId) public {
+ /// @notice Transfer ownership of an NFT -- THE CALLER IS RESPONSIBLE
+ /// TO CONFIRM THAT `to` IS CAPABLE OF RECEIVING NFTS OR ELSE
+ /// THEY MAY BE PERMANENTLY LOST
+ /// @dev Throws unless `msg.sender` is the current owner or an authorized
+ /// operator for this NFT. Throws if `from` is not the current owner. Throws
+ /// if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
+ /// @param from The current owner of the NFT
+ /// @param to The new owner
+ /// @param tokenId The NFT to transfer
+ /// @dev EVM selector for this function is: 0x23b872dd,
+ /// or in textual repr: transferFrom(address,address,uint256)
+ function transferFrom(
+ address from,
+ address to,
+ uint256 tokenId
+ ) public {
require(false, stub_error);
from;
+ to;
tokenId;
dummy = 0;
}
- // @notice Returns next free NFT ID.
- //
- // Selector: nextTokenId() 75794a3c
- function nextTokenId() public view returns (uint256) {
+ /// @notice Set or reaffirm the approved address for an NFT
+ /// @dev The zero address indicates there is no approved address.
+ /// @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
+ /// operator of the current owner.
+ /// @param approved The new approved NFT controller
+ /// @param tokenId The NFT to approve
+ /// @dev EVM selector for this function is: 0x095ea7b3,
+ /// or in textual repr: approve(address,uint256)
+ function approve(address approved, uint256 tokenId) public {
require(false, stub_error);
- dummy;
- return 0;
+ approved;
+ tokenId;
+ dummy = 0;
}
- // @notice Function to mint multiple tokens.
- // @dev `tokenIds` should be an array of consecutive numbers and first number
- // should be obtained with `nextTokenId` method
- // @param to The new owner
- // @param tokenIds IDs of the minted NFTs
- //
- // Selector: mintBulk(address,uint256[]) 44a9945e
- function mintBulk(address to, uint256[] memory tokenIds)
- public
- returns (bool)
- {
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xa22cb465,
+ /// or in textual repr: setApprovalForAll(address,bool)
+ function setApprovalForAll(address operator, bool approved) public {
require(false, stub_error);
- to;
- tokenIds;
+ operator;
+ approved;
dummy = 0;
- return false;
}
- // @notice Function to mint multiple tokens with the given tokenUris.
- // @dev `tokenIds` is array of pairs of token ID and token URI. Token IDs should be consecutive
- // numbers and first number should be obtained with `nextTokenId` method
- // @param to The new owner
- // @param tokens array of pairs of token ID and token URI for minted tokens
- //
- // Selector: mintBulkWithTokenURI(address,(uint256,string)[]) 36543006
- function mintBulkWithTokenURI(address to, Tuple0[] memory tokens)
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x081812fc,
+ /// or in textual repr: getApproved(uint256)
+ function getApproved(uint256 tokenId) public view returns (address) {
+ require(false, stub_error);
+ tokenId;
+ dummy;
+ return 0x0000000000000000000000000000000000000000;
+ }
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xe985e9c5,
+ /// or in textual repr: isApprovedForAll(address,address)
+ function isApprovedForAll(address owner, address operator)
public
- returns (bool)
+ view
+ returns (address)
{
require(false, stub_error);
- to;
- tokens;
- dummy = 0;
- return false;
+ owner;
+ operator;
+ dummy;
+ return 0x0000000000000000000000000000000000000000;
}
}
pallets/refungible/CHANGELOG.mddiffbeforeafterboth--- a/pallets/refungible/CHANGELOG.md
+++ b/pallets/refungible/CHANGELOG.md
@@ -2,6 +2,11 @@
All notable changes to this project will be documented in this file.
+## [v0.2.4] - 2022-08-24
+
+### Change
+ - Add bound `AsRef<[u8; 32]>` to `T::CrossAccountId`.
+
<!-- bureaucrate goes here -->
## [v0.2.3] 2022-08-16
pallets/refungible/Cargo.tomldiffbeforeafterboth--- a/pallets/refungible/Cargo.toml
+++ b/pallets/refungible/Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "pallet-refungible"
-version = "0.2.3"
+version = "0.2.4"
license = "GPLv3"
edition = "2021"
pallets/refungible/src/benchmarking.rsdiffbeforeafterboth--- a/pallets/refungible/src/benchmarking.rs
+++ b/pallets/refungible/src/benchmarking.rs
@@ -281,15 +281,6 @@
let item = create_max_item(&collection, &sender, [(owner.clone(), 100)])?;
}: {<Pallet<T>>::repartition(&collection, &owner, item, 200)?}
- set_parent_nft_unchecked {
- bench_init!{
- owner: sub; collection: collection(owner);
- sender: cross_from_sub(owner); owner: cross_sub;
- };
- let item = create_max_item(&collection, &sender, [(owner.clone(), 100)])?;
-
- }: {<Pallet<T>>::set_parent_nft_unchecked(&collection, item, owner, T::CrossAccountId::from_eth(H160::default()))?}
-
token_owner {
bench_init!{
owner: sub; collection: collection(owner);
pallets/refungible/src/erc.rsdiffbeforeafterboth--- a/pallets/refungible/src/erc.rs
+++ b/pallets/refungible/src/erc.rs
@@ -53,14 +53,14 @@
pub const ADDRESS_FOR_PARTIALLY_OWNED_TOKENS: H160 = H160::repeat_byte(0xff);
/// @title A contract that allows to set and delete token properties and change token property permissions.
-#[solidity_interface(name = "TokenProperties")]
+#[solidity_interface(name = TokenProperties)]
impl<T: Config> RefungibleHandle<T> {
/// @notice Set permissions for token property.
/// @dev Throws error if `msg.sender` is not admin or owner of the collection.
/// @param key Property key.
- /// @param is_mutable Permission to mutate property.
- /// @param collection_admin Permission to mutate property by collection admin if property is mutable.
- /// @param token_owner Permission to mutate property by token owner if property is mutable.
+ /// @param isMutable Permission to mutate property.
+ /// @param collectionAdmin Permission to mutate property by collection admin if property is mutable.
+ /// @param tokenOwner Permission to mutate property by token owner if property is mutable.
fn set_token_property_permission(
&mut self,
caller: caller,
@@ -197,7 +197,7 @@
MintingFinished {},
}
-#[solidity_interface(name = "ERC721Metadata")]
+#[solidity_interface(name = ERC721Metadata)]
impl<T: Config> RefungibleHandle<T> {
/// @notice A descriptive name for a collection of RFTs in this contract
fn name(&self) -> Result<string> {
@@ -258,7 +258,7 @@
/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
/// @dev See https://eips.ethereum.org/EIPS/eip-721
-#[solidity_interface(name = "ERC721Enumerable")]
+#[solidity_interface(name = ERC721Enumerable)]
impl<T: Config> RefungibleHandle<T> {
/// @notice Enumerate valid RFTs
/// @param index A counter less than `totalSupply()`
@@ -285,7 +285,7 @@
/// @title ERC-721 Non-Fungible Token Standard
/// @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md
-#[solidity_interface(name = "ERC721", events(ERC721Events))]
+#[solidity_interface(name = ERC721, events(ERC721Events))]
impl<T: Config> RefungibleHandle<T> {
/// @notice Count all RFTs assigned to an owner
/// @dev RFTs assigned to the zero address are considered invalid, and this
@@ -322,7 +322,6 @@
_to: address,
_token_id: uint256,
_data: bytes,
- _value: value,
) -> Result<void> {
// TODO: Not implemetable
Err("not implemented".into())
@@ -334,7 +333,6 @@
_from: address,
_to: address,
_token_id: uint256,
- _value: value,
) -> Result<void> {
// TODO: Not implemetable
Err("not implemented".into())
@@ -350,7 +348,6 @@
/// @param from The current owner of the NFT
/// @param to The new owner
/// @param tokenId The NFT to transfer
- /// @param _value Not used for an NFT
#[weight(<SelfWeightOf<T>>::transfer_from_creating_removing())]
fn transfer_from(
&mut self,
@@ -358,7 +355,6 @@
from: address,
to: address,
token_id: uint256,
- _value: value,
) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let from = T::CrossAccountId::from_eth(from);
@@ -378,13 +374,7 @@
}
/// @dev Not implemented
- fn approve(
- &mut self,
- _caller: caller,
- _approved: address,
- _token_id: uint256,
- _value: value,
- ) -> Result<void> {
+ fn approve(&mut self, _caller: caller, _approved: address, _token_id: uint256) -> Result<void> {
Err("not implemented".into())
}
@@ -438,7 +428,7 @@
}
/// @title ERC721 Token that can be irreversibly burned (destroyed).
-#[solidity_interface(name = "ERC721Burnable")]
+#[solidity_interface(name = ERC721Burnable)]
impl<T: Config> RefungibleHandle<T> {
/// @notice Burns a specific ERC721 token.
/// @dev Throws unless `msg.sender` is the current RFT owner, or an authorized
@@ -458,7 +448,7 @@
}
/// @title ERC721 minting logic.
-#[solidity_interface(name = "ERC721Mintable", events(ERC721MintableEvents))]
+#[solidity_interface(name = ERC721Mintable, events(ERC721MintableEvents))]
impl<T: Config> RefungibleHandle<T> {
fn minting_finished(&self) -> Result<bool> {
Ok(false)
@@ -616,7 +606,7 @@
}
/// @title Unique extensions for ERC721.
-#[solidity_interface(name = "ERC721UniqueExtensions")]
+#[solidity_interface(name = ERC721UniqueExtensions)]
impl<T: Config> RefungibleHandle<T> {
/// @notice Transfer ownership of an RFT
/// @dev Throws unless `msg.sender` is the current owner. Throws if `to`
@@ -624,15 +614,8 @@
/// Throws if RFT pieces have multiple owners.
/// @param to The new owner
/// @param tokenId The RFT to transfer
- /// @param _value Not used for an RFT
#[weight(<SelfWeightOf<T>>::transfer_creating_removing())]
- fn transfer(
- &mut self,
- caller: caller,
- to: address,
- token_id: uint256,
- _value: value,
- ) -> Result<void> {
+ fn transfer(&mut self, caller: caller, to: address, token_id: uint256) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let to = T::CrossAccountId::from_eth(to);
let token = token_id.try_into()?;
@@ -655,15 +638,8 @@
/// Throws if RFT pieces have multiple owners.
/// @param from The current owner of the RFT
/// @param tokenId The RFT to transfer
- /// @param _value Not used for an RFT
#[weight(<SelfWeightOf<T>>::burn_from())]
- fn burn_from(
- &mut self,
- caller: caller,
- from: address,
- token_id: uint256,
- _value: value,
- ) -> Result<void> {
+ fn burn_from(&mut self, caller: caller, from: address, token_id: uint256) -> Result<void> {
let caller = T::CrossAccountId::from_eth(caller);
let from = T::CrossAccountId::from_eth(from);
let token = token_id.try_into()?;
@@ -801,7 +777,7 @@
}
#[solidity_interface(
- name = "UniqueRefungible",
+ name = UniqueRefungible,
is(
ERC721,
ERC721Metadata,
@@ -809,11 +785,11 @@
ERC721UniqueExtensions,
ERC721Mintable,
ERC721Burnable,
- via("CollectionHandle<T>", common_mut, Collection),
+ Collection(common_mut, CollectionHandle<T>),
TokenProperties,
)
)]
-impl<T: Config> RefungibleHandle<T> where T::AccountId: From<[u8; 32]> {}
+impl<T: Config> RefungibleHandle<T> where T::AccountId: From<[u8; 32]> + AsRef<[u8; 32]> {}
// Not a tests, but code generators
generate_stubgen!(gen_impl, UniqueRefungibleCall<()>, true);
@@ -821,7 +797,7 @@
impl<T: Config> CommonEvmHandler for RefungibleHandle<T>
where
- T::AccountId: From<[u8; 32]>,
+ T::AccountId: From<[u8; 32]> + AsRef<[u8; 32]>,
{
const CODE: &'static [u8] = include_bytes!("./stubs/UniqueRefungible.raw");
fn call(
pallets/refungible/src/erc_token.rsdiffbeforeafterboth--- a/pallets/refungible/src/erc_token.rs
+++ b/pallets/refungible/src/erc_token.rs
@@ -29,86 +29,36 @@
convert::TryInto,
ops::Deref,
};
-use evm_coder::{ToLog, execution::*, generate_stubgen, solidity, solidity_interface, types::*, weight};
+use evm_coder::{ToLog, execution::*, generate_stubgen, solidity_interface, types::*, weight};
use pallet_common::{
CommonWeightInfo,
- erc::{CommonEvmHandler, PrecompileResult, static_property::key},
- eth::map_eth_to_id,
+ erc::{CommonEvmHandler, PrecompileResult},
+ eth::collection_id_to_address,
};
use pallet_evm::{account::CrossAccountId, PrecompileHandle};
use pallet_evm_coder_substrate::{call, dispatch_to_evm, WithRecorder};
use pallet_structure::{SelfWeightOf as StructureWeight, weights::WeightInfo as _};
-use sp_core::H160;
use sp_std::vec::Vec;
-use up_data_structs::{mapping::TokenAddressMapping, PropertyScope, TokenId};
+use up_data_structs::TokenId;
use crate::{
Allowance, Balance, common::CommonWeights, Config, Pallet, RefungibleHandle, SelfWeightOf,
- TokenProperties, TotalSupply, weights::WeightInfo,
+ TotalSupply, weights::WeightInfo,
};
pub struct RefungibleTokenHandle<T: Config>(pub RefungibleHandle<T>, pub TokenId);
-#[solidity_interface(name = "ERC1633")]
+#[solidity_interface(name = ERC1633)]
impl<T: Config> RefungibleTokenHandle<T> {
fn parent_token(&self) -> Result<address> {
- self.consume_store_reads(2)?;
- let props = <TokenProperties<T>>::get((self.id, self.1));
- let key = key::parent_nft();
-
- let key_scoped = PropertyScope::Eth
- .apply(key)
- .expect("property key shouldn't exceed length limit");
- if let Some(value) = props.get(&key_scoped) {
- Ok(H160::from_slice(value.as_slice()))
- } else {
- Ok(*T::CrossTokenAddressMapping::token_to_address(self.id, self.1).as_eth())
- }
+ Ok(collection_id_to_address(self.id))
}
fn parent_token_id(&self) -> Result<uint256> {
- self.consume_store_reads(2)?;
- let props = <TokenProperties<T>>::get((self.id, self.1));
- let key = key::parent_nft();
-
- let key_scoped = PropertyScope::Eth
- .apply(key)
- .expect("property key shouldn't exceed length limit");
- if let Some(value) = props.get(&key_scoped) {
- let nft_token_address = H160::from_slice(value.as_slice());
- let nft_token_account = T::CrossAccountId::from_eth(nft_token_address);
- let (_, token_id) = T::CrossTokenAddressMapping::address_to_token(&nft_token_account)
- .ok_or("parent NFT should contain NFT token address")?;
-
- Ok(token_id.into())
- } else {
- Ok(self.1.into())
- }
+ Ok(self.1.into())
}
}
-#[solidity_interface(name = "ERC1633UniqueExtensions")]
-impl<T: Config> RefungibleTokenHandle<T> {
- #[solidity(rename_selector = "setParentNFT")]
- #[weight(<CommonWeights<T>>::token_owner() + <SelfWeightOf<T>>::set_parent_nft_unchecked())]
- fn set_parent_nft(
- &mut self,
- caller: caller,
- collection: address,
- nft_id: uint256,
- ) -> Result<bool> {
- self.consume_store_reads(1)?;
- let caller = T::CrossAccountId::from_eth(caller);
- let nft_collection = map_eth_to_id(&collection).ok_or("collection not found")?;
- let nft_token = nft_id.try_into()?;
-
- <Pallet<T>>::set_parent_nft(&self.0, self.1, caller, nft_collection, nft_token)
- .map_err(dispatch_to_evm::<T>)?;
-
- Ok(true)
- }
-}
-
#[derive(ToLog)]
pub enum ERC20Events {
/// @dev This event is emitted when the amount of tokens (value) is sent
@@ -137,7 +87,7 @@
///
/// @dev Implementation of the basic standard token.
/// https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md
-#[solidity_interface(name = "ERC20", events(ERC20Events))]
+#[solidity_interface(name = ERC20, events(ERC20Events))]
impl<T: Config> RefungibleTokenHandle<T> {
/// @return the name of the token.
fn name(&self) -> Result<string> {
@@ -246,7 +196,7 @@
}
}
-#[solidity_interface(name = "ERC20UniqueExtensions")]
+#[solidity_interface(name = ERC20UniqueExtensions)]
impl<T: Config> RefungibleTokenHandle<T> {
/// @dev Function that burns an amount of the token of a given account,
/// deducting from the sender's allowance for said account.
@@ -306,8 +256,8 @@
}
#[solidity_interface(
- name = "UniqueRefungibleToken",
- is(ERC20, ERC20UniqueExtensions, ERC1633, ERC1633UniqueExtensions)
+ name = UniqueRefungibleToken,
+ is(ERC20, ERC20UniqueExtensions, ERC1633)
)]
impl<T: Config> RefungibleTokenHandle<T> where T::AccountId: From<[u8; 32]> {}
pallets/refungible/src/lib.rsdiffbeforeafterboth--- a/pallets/refungible/src/lib.rs
+++ b/pallets/refungible/src/lib.rs
@@ -1379,68 +1379,4 @@
Some(res)
}
}
-
- /// Sets the NFT token as a parent for the RFT token
- ///
- /// Throws if `sender` is not the owner of the NFT token.
- /// Throws if `sender` is not the owner of all of the RFT token pieces.
- pub fn set_parent_nft(
- collection: &RefungibleHandle<T>,
- rft_token_id: TokenId,
- sender: T::CrossAccountId,
- nft_collection: CollectionId,
- nft_token: TokenId,
- ) -> DispatchResult {
- let handle = <CollectionHandle<T>>::try_get(nft_collection)?;
- if handle.mode != CollectionMode::NFT {
- return Err("Only NFT token could be parent to RFT".into());
- }
- let dispatch = T::CollectionDispatch::dispatch(handle);
- let dispatch = dispatch.as_dyn();
-
- let owner = dispatch.token_owner(nft_token).ok_or("owner not found")?;
- if owner != sender {
- return Err("Only owned token could be set as parent".into());
- }
-
- let nft_token_address =
- T::CrossTokenAddressMapping::token_to_address(nft_collection, nft_token);
-
- Self::set_parent_nft_unchecked(collection, rft_token_id, sender, nft_token_address)
- }
-
- /// Sets the NFT token as a parent for the RFT token
- ///
- /// `sender` should be the owner of the NFT token.
- /// Throws if `sender` is not the owner of all of the RFT token pieces.
- pub fn set_parent_nft_unchecked(
- collection: &RefungibleHandle<T>,
- rft_token_id: TokenId,
- sender: T::CrossAccountId,
- nft_token_address: T::CrossAccountId,
- ) -> DispatchResult {
- let owner_balance = <Balance<T>>::get((collection.id, rft_token_id, &sender));
- let total_supply = <TotalSupply<T>>::get((collection.id, rft_token_id));
- if total_supply != owner_balance {
- return Err("token has multiple owners".into());
- }
-
- let parent_nft_property_key = key::parent_nft();
-
- let parent_nft_property_value =
- property_value_from_bytes(&nft_token_address.as_eth().to_fixed_bytes())
- .expect("address should fit in value length limit");
-
- <Pallet<T>>::set_scoped_token_property(
- collection.id,
- rft_token_id,
- PropertyScope::Eth,
- Property {
- key: parent_nft_property_key,
- value: parent_nft_property_value,
- },
- )?;
-
- Ok(())
- }
}
pallets/refungible/src/stubs/UniqueRefungible.rawdiffbeforeafterbothbinary blob β no preview
pallets/refungible/src/stubs/UniqueRefungible.soldiffbeforeafterboth--- a/pallets/refungible/src/stubs/UniqueRefungible.sol
+++ b/pallets/refungible/src/stubs/UniqueRefungible.sol
@@ -3,13 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Anonymous struct
-struct Tuple0 {
- uint256 field_0;
- string field_1;
-}
-
-// Common stubs holder
+/// @dev common stubs holder
contract Dummy {
uint8 dummy;
string stub_error = "this contract is implemented in native";
@@ -27,40 +21,17 @@
}
}
-// Inline
-contract ERC721Events {
- event Transfer(
- address indexed from,
- address indexed to,
- uint256 indexed tokenId
- );
- event Approval(
- address indexed owner,
- address indexed approved,
- uint256 indexed tokenId
- );
- event ApprovalForAll(
- address indexed owner,
- address indexed operator,
- bool approved
- );
-}
-
-// Inline
-contract ERC721MintableEvents {
- event MintingFinished();
-}
-
-// Selector: 41369377
+/// @title A contract that allows to set and delete token properties and change token property permissions.
+/// @dev the ERC-165 identifier for this interface is 0x41369377
contract TokenProperties is Dummy, ERC165 {
- // @notice Set permissions for token property.
- // @dev Throws error if `msg.sender` is not admin or owner of the collection.
- // @param key Property key.
- // @param is_mutable Permission to mutate property.
- // @param collection_admin Permission to mutate property by collection admin if property is mutable.
- // @param token_owner Permission to mutate property by token owner if property is mutable.
- //
- // Selector: setTokenPropertyPermission(string,bool,bool,bool) 222d97fa
+ /// @notice Set permissions for token property.
+ /// @dev Throws error if `msg.sender` is not admin or owner of the collection.
+ /// @param key Property key.
+ /// @param isMutable Permission to mutate property.
+ /// @param collectionAdmin Permission to mutate property by collection admin if property is mutable.
+ /// @param tokenOwner Permission to mutate property by token owner if property is mutable.
+ /// @dev EVM selector for this function is: 0x222d97fa,
+ /// or in textual repr: setTokenPropertyPermission(string,bool,bool,bool)
function setTokenPropertyPermission(
string memory key,
bool isMutable,
@@ -75,13 +46,13 @@
dummy = 0;
}
- // @notice Set token property value.
- // @dev Throws error if `msg.sender` has no permission to edit the property.
- // @param tokenId ID of the token.
- // @param key Property key.
- // @param value Property value.
- //
- // Selector: setProperty(uint256,string,bytes) 1752d67b
+ /// @notice Set token property value.
+ /// @dev Throws error if `msg.sender` has no permission to edit the property.
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @param value Property value.
+ /// @dev EVM selector for this function is: 0x1752d67b,
+ /// or in textual repr: setProperty(uint256,string,bytes)
function setProperty(
uint256 tokenId,
string memory key,
@@ -94,12 +65,12 @@
dummy = 0;
}
- // @notice Delete token property value.
- // @dev Throws error if `msg.sender` has no permission to edit the property.
- // @param tokenId ID of the token.
- // @param key Property key.
- //
- // Selector: deleteProperty(uint256,string) 066111d1
+ /// @notice Delete token property value.
+ /// @dev Throws error if `msg.sender` has no permission to edit the property.
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x066111d1,
+ /// or in textual repr: deleteProperty(uint256,string)
function deleteProperty(uint256 tokenId, string memory key) public {
require(false, stub_error);
tokenId;
@@ -107,13 +78,13 @@
dummy = 0;
}
- // @notice Get token property value.
- // @dev Throws error if key not found
- // @param tokenId ID of the token.
- // @param key Property key.
- // @return Property value bytes
- //
- // Selector: property(uint256,string) 7228c327
+ /// @notice Get token property value.
+ /// @dev Throws error if key not found
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @return Property value bytes
+ /// @dev EVM selector for this function is: 0x7228c327,
+ /// or in textual repr: property(uint256,string)
function property(uint256 tokenId, string memory key)
public
view
@@ -127,509 +98,527 @@
}
}
-// Selector: 42966c68
-contract ERC721Burnable is Dummy, ERC165 {
- // @notice Burns a specific ERC721 token.
- // @dev Throws unless `msg.sender` is the current RFT owner, or an authorized
- // operator of the current owner.
- // @param tokenId The RFT to approve
- //
- // Selector: burn(uint256) 42966c68
- function burn(uint256 tokenId) public {
+/// @title A contract that allows you to work with collections.
+/// @dev the ERC-165 identifier for this interface is 0xe54be640
+contract Collection is Dummy, ERC165 {
+ /// Set collection property.
+ ///
+ /// @param key Property key.
+ /// @param value Propery value.
+ /// @dev EVM selector for this function is: 0x2f073f66,
+ /// or in textual repr: setCollectionProperty(string,bytes)
+ function setCollectionProperty(string memory key, bytes memory value)
+ public
+ {
require(false, stub_error);
- tokenId;
+ key;
+ value;
dummy = 0;
}
-}
-// Selector: 58800161
-contract ERC721 is Dummy, ERC165, ERC721Events {
- // @notice Count all RFTs assigned to an owner
- // @dev RFTs assigned to the zero address are considered invalid, and this
- // function throws for queries about the zero address.
- // @param owner An address for whom to query the balance
- // @return The number of RFTs owned by `owner`, possibly zero
- //
- // Selector: balanceOf(address) 70a08231
- function balanceOf(address owner) public view returns (uint256) {
+ /// Delete collection property.
+ ///
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x7b7debce,
+ /// or in textual repr: deleteCollectionProperty(string)
+ function deleteCollectionProperty(string memory key) public {
require(false, stub_error);
- owner;
- dummy;
- return 0;
+ key;
+ dummy = 0;
}
- // @notice Find the owner of an RFT
- // @dev RFTs assigned to zero address are considered invalid, and queries
- // about them do throw.
- // Returns special 0xffffffffffffffffffffffffffffffffffffffff address for
- // the tokens that are partially owned.
- // @param tokenId The identifier for an RFT
- // @return The address of the owner of the RFT
- //
- // Selector: ownerOf(uint256) 6352211e
- function ownerOf(uint256 tokenId) public view returns (address) {
+ /// Get collection property.
+ ///
+ /// @dev Throws error if key not found.
+ ///
+ /// @param key Property key.
+ /// @return bytes The property corresponding to the key.
+ /// @dev EVM selector for this function is: 0xcf24fd6d,
+ /// or in textual repr: collectionProperty(string)
+ function collectionProperty(string memory key)
+ public
+ view
+ returns (bytes memory)
+ {
require(false, stub_error);
- tokenId;
+ key;
dummy;
- return 0x0000000000000000000000000000000000000000;
+ return hex"";
}
- // @dev Not implemented
- //
- // Selector: safeTransferFromWithData(address,address,uint256,bytes) 60a11672
- function safeTransferFromWithData(
- address from,
- address to,
- uint256 tokenId,
- bytes memory data
- ) public {
+ /// Set the sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0x7623402e,
+ /// or in textual repr: setCollectionSponsor(address)
+ function setCollectionSponsor(address sponsor) public {
require(false, stub_error);
- from;
- to;
- tokenId;
- data;
+ sponsor;
dummy = 0;
}
- // @dev Not implemented
- //
- // Selector: safeTransferFrom(address,address,uint256) 42842e0e
- function safeTransferFrom(
- address from,
- address to,
- uint256 tokenId
- ) public {
+ /// Set the substrate sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Substrate address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0xc74d6751,
+ /// or in textual repr: setCollectionSponsorSubstrate(uint256)
+ function setCollectionSponsorSubstrate(uint256 sponsor) public {
require(false, stub_error);
- from;
- to;
- tokenId;
+ sponsor;
dummy = 0;
}
- // @notice Transfer ownership of an RFT -- THE CALLER IS RESPONSIBLE
- // TO CONFIRM THAT `to` IS CAPABLE OF RECEIVING NFTS OR ELSE
- // THEY MAY BE PERMANENTLY LOST
- // @dev Throws unless `msg.sender` is the current owner or an authorized
- // operator for this RFT. Throws if `from` is not the current owner. Throws
- // if `to` is the zero address. Throws if `tokenId` is not a valid RFT.
- // Throws if RFT pieces have multiple owners.
- // @param from The current owner of the NFT
- // @param to The new owner
- // @param tokenId The NFT to transfer
- // @param _value Not used for an NFT
- //
- // Selector: transferFrom(address,address,uint256) 23b872dd
- function transferFrom(
- address from,
- address to,
- uint256 tokenId
- ) public {
+ /// @dev EVM selector for this function is: 0x058ac185,
+ /// or in textual repr: hasCollectionPendingSponsor()
+ function hasCollectionPendingSponsor() public view returns (bool) {
require(false, stub_error);
- from;
- to;
- tokenId;
- dummy = 0;
+ dummy;
+ return false;
}
- // @dev Not implemented
- //
- // Selector: approve(address,uint256) 095ea7b3
- function approve(address approved, uint256 tokenId) public {
+ /// Collection sponsorship confirmation.
+ ///
+ /// @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ /// @dev EVM selector for this function is: 0x3c50e97a,
+ /// or in textual repr: confirmCollectionSponsorship()
+ function confirmCollectionSponsorship() public {
require(false, stub_error);
- approved;
- tokenId;
dummy = 0;
}
- // @dev Not implemented
- //
- // Selector: setApprovalForAll(address,bool) a22cb465
- function setApprovalForAll(address operator, bool approved) public {
+ /// Remove collection sponsor.
+ /// @dev EVM selector for this function is: 0x6e0326a3,
+ /// or in textual repr: removeCollectionSponsor()
+ function removeCollectionSponsor() public {
require(false, stub_error);
- operator;
- approved;
dummy = 0;
}
- // @dev Not implemented
- //
- // Selector: getApproved(uint256) 081812fc
- function getApproved(uint256 tokenId) public view returns (address) {
+ /// Get current sponsor.
+ ///
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ /// @dev EVM selector for this function is: 0xb66bbc14,
+ /// or in textual repr: getCollectionSponsor()
+ function getCollectionSponsor() public view returns (Tuple17 memory) {
require(false, stub_error);
- tokenId;
dummy;
- return 0x0000000000000000000000000000000000000000;
+ return Tuple17(0x0000000000000000000000000000000000000000, 0);
}
- // @dev Not implemented
- //
- // Selector: isApprovedForAll(address,address) e985e9c5
- function isApprovedForAll(address owner, address operator)
- public
- view
- returns (address)
- {
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "accountTokenOwnershipLimit",
+ /// "sponsoredDataSize",
+ /// "sponsoredDataRateLimit",
+ /// "tokenLimit",
+ /// "sponsorTransferTimeout",
+ /// "sponsorApproveTimeout"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x6a3841db,
+ /// or in textual repr: setCollectionLimit(string,uint32)
+ function setCollectionLimit(string memory limit, uint32 value) public {
require(false, stub_error);
- owner;
- operator;
- dummy;
- return 0x0000000000000000000000000000000000000000;
+ limit;
+ value;
+ dummy = 0;
}
-}
-// Selector: 5b5e139f
-contract ERC721Metadata is Dummy, ERC165 {
- // @notice A descriptive name for a collection of RFTs in this contract
- //
- // Selector: name() 06fdde03
- function name() public view returns (string memory) {
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "ownerCanTransfer",
+ /// "ownerCanDestroy",
+ /// "transfersEnabled"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x993b7fba,
+ /// or in textual repr: setCollectionLimit(string,bool)
+ function setCollectionLimit(string memory limit, bool value) public {
require(false, stub_error);
- dummy;
- return "";
+ limit;
+ value;
+ dummy = 0;
}
- // @notice An abbreviated name for RFTs in this contract
- //
- // Selector: symbol() 95d89b41
- function symbol() public view returns (string memory) {
+ /// Get contract address.
+ /// @dev EVM selector for this function is: 0xf6b4dfb4,
+ /// or in textual repr: contractAddress()
+ function contractAddress() public view returns (address) {
require(false, stub_error);
dummy;
- return "";
+ return 0x0000000000000000000000000000000000000000;
}
- // @notice A distinct Uniform Resource Identifier (URI) for a given asset.
- //
- // @dev If the token has a `url` property and it is not empty, it is returned.
- // Else If the collection does not have a property with key `schemaName` or its value is not equal to `ERC721Metadata`, it return an error `tokenURI not set`.
- // If the collection property `baseURI` is empty or absent, return "" (empty string)
- // otherwise, if token property `suffix` present and is non-empty, return concatenation of baseURI and suffix
- // otherwise, return concatenation of `baseURI` and stringified token id (decimal stringifying, without paddings).
- //
- // @return token's const_metadata
- //
- // Selector: tokenURI(uint256) c87b56dd
- function tokenURI(uint256 tokenId) public view returns (string memory) {
+ /// Add collection admin by substrate address.
+ /// @param newAdmin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x5730062b,
+ /// or in textual repr: addCollectionAdminSubstrate(uint256)
+ function addCollectionAdminSubstrate(uint256 newAdmin) public {
require(false, stub_error);
- tokenId;
- dummy;
- return "";
+ newAdmin;
+ dummy = 0;
}
-}
-// Selector: 68ccfe89
-contract ERC721Mintable is Dummy, ERC165, ERC721MintableEvents {
- // Selector: mintingFinished() 05d2035b
- function mintingFinished() public view returns (bool) {
+ /// Remove collection admin by substrate address.
+ /// @param admin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x4048fcf9,
+ /// or in textual repr: removeCollectionAdminSubstrate(uint256)
+ function removeCollectionAdminSubstrate(uint256 admin) public {
require(false, stub_error);
- dummy;
- return false;
+ admin;
+ dummy = 0;
}
- // @notice Function to mint token.
- // @dev `tokenId` should be obtained with `nextTokenId` method,
- // unlike standard, you can't specify it manually
- // @param to The new owner
- // @param tokenId ID of the minted RFT
- //
- // Selector: mint(address,uint256) 40c10f19
- function mint(address to, uint256 tokenId) public returns (bool) {
+ /// Add collection admin.
+ /// @param newAdmin Address of the added administrator.
+ /// @dev EVM selector for this function is: 0x92e462c7,
+ /// or in textual repr: addCollectionAdmin(address)
+ function addCollectionAdmin(address newAdmin) public {
require(false, stub_error);
- to;
- tokenId;
+ newAdmin;
dummy = 0;
- return false;
}
- // @notice Function to mint token with the given tokenUri.
- // @dev `tokenId` should be obtained with `nextTokenId` method,
- // unlike standard, you can't specify it manually
- // @param to The new owner
- // @param tokenId ID of the minted RFT
- // @param tokenUri Token URI that would be stored in the RFT properties
- //
- // Selector: mintWithTokenURI(address,uint256,string) 50bb4e7f
- function mintWithTokenURI(
- address to,
- uint256 tokenId,
- string memory tokenUri
- ) public returns (bool) {
+ /// Remove collection admin.
+ ///
+ /// @param admin Address of the removed administrator.
+ /// @dev EVM selector for this function is: 0xfafd7b42,
+ /// or in textual repr: removeCollectionAdmin(address)
+ function removeCollectionAdmin(address admin) public {
require(false, stub_error);
- to;
- tokenId;
- tokenUri;
+ admin;
dummy = 0;
- return false;
}
- // @dev Not implemented
- //
- // Selector: finishMinting() 7d64bcb4
- function finishMinting() public returns (bool) {
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ /// @dev EVM selector for this function is: 0x112d4586,
+ /// or in textual repr: setCollectionNesting(bool)
+ function setCollectionNesting(bool enable) public {
require(false, stub_error);
+ enable;
dummy = 0;
- return false;
}
-}
-// Selector: 6cf113cd
-contract Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
- function setCollectionProperty(string memory key, bytes memory value)
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ /// @param collections Addresses of collections that will be available for nesting.
+ /// @dev EVM selector for this function is: 0x64872396,
+ /// or in textual repr: setCollectionNesting(bool,address[])
+ function setCollectionNesting(bool enable, address[] memory collections)
public
{
require(false, stub_error);
- key;
- value;
+ enable;
+ collections;
dummy = 0;
}
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
- function deleteCollectionProperty(string memory key) public {
+ /// Set the collection access method.
+ /// @param mode Access mode
+ /// 0 for Normal
+ /// 1 for AllowList
+ /// @dev EVM selector for this function is: 0x41835d4c,
+ /// or in textual repr: setCollectionAccess(uint8)
+ function setCollectionAccess(uint8 mode) public {
require(false, stub_error);
- key;
+ mode;
dummy = 0;
}
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
- function collectionProperty(string memory key)
- public
- view
- returns (bytes memory)
- {
+ /// Add the user to the allowed list.
+ ///
+ /// @param user Address of a trusted user.
+ /// @dev EVM selector for this function is: 0x67844fe6,
+ /// or in textual repr: addToCollectionAllowList(address)
+ function addToCollectionAllowList(address user) public {
require(false, stub_error);
- key;
- dummy;
- return hex"";
- }
-
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
- function setCollectionSponsor(address sponsor) public {
- require(false, stub_error);
- sponsor;
+ user;
dummy = 0;
}
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
- function confirmCollectionSponsorship() public {
+ /// Remove the user from the allowed list.
+ ///
+ /// @param user Address of a removed user.
+ /// @dev EVM selector for this function is: 0x85c51acb,
+ /// or in textual repr: removeFromCollectionAllowList(address)
+ function removeFromCollectionAllowList(address user) public {
require(false, stub_error);
+ user;
dummy = 0;
}
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
- function setCollectionLimit(string memory limit, uint32 value) public {
+ /// Switch permission for minting.
+ ///
+ /// @param mode Enable if "true".
+ /// @dev EVM selector for this function is: 0x00018e84,
+ /// or in textual repr: setCollectionMintMode(bool)
+ function setCollectionMintMode(bool mode) public {
require(false, stub_error);
- limit;
- value;
+ mode;
dummy = 0;
}
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
- function setCollectionLimit(string memory limit, bool value) public {
+ /// Check that account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x9811b0c7,
+ /// or in textual repr: isOwnerOrAdmin(address)
+ function isOwnerOrAdmin(address user) public view returns (bool) {
require(false, stub_error);
- limit;
- value;
- dummy = 0;
+ user;
+ dummy;
+ return false;
}
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
- function contractAddress() public view returns (address) {
+ /// Check that substrate account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x68910e00,
+ /// or in textual repr: isOwnerOrAdminSubstrate(uint256)
+ function isOwnerOrAdminSubstrate(uint256 user) public view returns (bool) {
require(false, stub_error);
+ user;
dummy;
- return 0x0000000000000000000000000000000000000000;
+ return false;
}
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
- function addCollectionAdminSubstrate(uint256 newAdmin) public {
+ /// Returns collection type
+ ///
+ /// @return `Fungible` or `NFT` or `ReFungible`
+ /// @dev EVM selector for this function is: 0xd34b55b8,
+ /// or in textual repr: uniqueCollectionType()
+ function uniqueCollectionType() public returns (string memory) {
require(false, stub_error);
- newAdmin;
dummy = 0;
+ return "";
}
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
- function removeCollectionAdminSubstrate(uint256 admin) public {
+ /// Changes collection owner to another account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner account
+ /// @dev EVM selector for this function is: 0x13af4035,
+ /// or in textual repr: setOwner(address)
+ function setOwner(address newOwner) public {
require(false, stub_error);
- admin;
+ newOwner;
dummy = 0;
}
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
- function addCollectionAdmin(address newAdmin) public {
+ /// Changes collection owner to another substrate account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner substrate account
+ /// @dev EVM selector for this function is: 0xb212138f,
+ /// or in textual repr: setOwnerSubstrate(uint256)
+ function setOwnerSubstrate(uint256 newOwner) public {
require(false, stub_error);
- newAdmin;
+ newOwner;
dummy = 0;
}
+}
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
- function removeCollectionAdmin(address admin) public {
+/// @dev anonymous struct
+struct Tuple17 {
+ address field_0;
+ uint256 field_1;
+}
+
+/// @title ERC721 Token that can be irreversibly burned (destroyed).
+/// @dev the ERC-165 identifier for this interface is 0x42966c68
+contract ERC721Burnable is Dummy, ERC165 {
+ /// @notice Burns a specific ERC721 token.
+ /// @dev Throws unless `msg.sender` is the current RFT owner, or an authorized
+ /// operator of the current owner.
+ /// @param tokenId The RFT to approve
+ /// @dev EVM selector for this function is: 0x42966c68,
+ /// or in textual repr: burn(uint256)
+ function burn(uint256 tokenId) public {
require(false, stub_error);
- admin;
+ tokenId;
dummy = 0;
}
+}
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
- function setCollectionNesting(bool enable) public {
+/// @dev inlined interface
+contract ERC721MintableEvents {
+ event MintingFinished();
+}
+
+/// @title ERC721 minting logic.
+/// @dev the ERC-165 identifier for this interface is 0x68ccfe89
+contract ERC721Mintable is Dummy, ERC165, ERC721MintableEvents {
+ /// @dev EVM selector for this function is: 0x05d2035b,
+ /// or in textual repr: mintingFinished()
+ function mintingFinished() public view returns (bool) {
require(false, stub_error);
- enable;
- dummy = 0;
+ dummy;
+ return false;
}
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
- function setCollectionNesting(bool enable, address[] memory collections)
- public
- {
+ /// @notice Function to mint token.
+ /// @dev `tokenId` should be obtained with `nextTokenId` method,
+ /// unlike standard, you can't specify it manually
+ /// @param to The new owner
+ /// @param tokenId ID of the minted RFT
+ /// @dev EVM selector for this function is: 0x40c10f19,
+ /// or in textual repr: mint(address,uint256)
+ function mint(address to, uint256 tokenId) public returns (bool) {
require(false, stub_error);
- enable;
- collections;
+ to;
+ tokenId;
dummy = 0;
+ return false;
}
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
- function setCollectionAccess(uint8 mode) public {
+ /// @notice Function to mint token with the given tokenUri.
+ /// @dev `tokenId` should be obtained with `nextTokenId` method,
+ /// unlike standard, you can't specify it manually
+ /// @param to The new owner
+ /// @param tokenId ID of the minted RFT
+ /// @param tokenUri Token URI that would be stored in the RFT properties
+ /// @dev EVM selector for this function is: 0x50bb4e7f,
+ /// or in textual repr: mintWithTokenURI(address,uint256,string)
+ function mintWithTokenURI(
+ address to,
+ uint256 tokenId,
+ string memory tokenUri
+ ) public returns (bool) {
require(false, stub_error);
- mode;
+ to;
+ tokenId;
+ tokenUri;
dummy = 0;
+ return false;
}
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
- function addToCollectionAllowList(address user) public {
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x7d64bcb4,
+ /// or in textual repr: finishMinting()
+ function finishMinting() public returns (bool) {
require(false, stub_error);
- user;
dummy = 0;
+ return false;
}
+}
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
- function removeFromCollectionAllowList(address user) public {
+/// @title Unique extensions for ERC721.
+/// @dev the ERC-165 identifier for this interface is 0x7c3bef89
+contract ERC721UniqueExtensions is Dummy, ERC165 {
+ /// @notice Transfer ownership of an RFT
+ /// @dev Throws unless `msg.sender` is the current owner. Throws if `to`
+ /// is the zero address. Throws if `tokenId` is not a valid RFT.
+ /// Throws if RFT pieces have multiple owners.
+ /// @param to The new owner
+ /// @param tokenId The RFT to transfer
+ /// @dev EVM selector for this function is: 0xa9059cbb,
+ /// or in textual repr: transfer(address,uint256)
+ function transfer(address to, uint256 tokenId) public {
require(false, stub_error);
- user;
+ to;
+ tokenId;
dummy = 0;
}
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
- function setCollectionMintMode(bool mode) public {
+ /// @notice Burns a specific ERC721 token.
+ /// @dev Throws unless `msg.sender` is the current owner or an authorized
+ /// operator for this RFT. Throws if `from` is not the current owner. Throws
+ /// if `to` is the zero address. Throws if `tokenId` is not a valid RFT.
+ /// Throws if RFT pieces have multiple owners.
+ /// @param from The current owner of the RFT
+ /// @param tokenId The RFT to transfer
+ /// @dev EVM selector for this function is: 0x79cc6790,
+ /// or in textual repr: burnFrom(address,uint256)
+ function burnFrom(address from, uint256 tokenId) public {
require(false, stub_error);
- mode;
+ from;
+ tokenId;
dummy = 0;
}
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) public view returns (bool) {
+ /// @notice Returns next free RFT ID.
+ /// @dev EVM selector for this function is: 0x75794a3c,
+ /// or in textual repr: nextTokenId()
+ function nextTokenId() public view returns (uint256) {
require(false, stub_error);
- user;
dummy;
+ return 0;
+ }
+
+ /// @notice Function to mint multiple tokens.
+ /// @dev `tokenIds` should be an array of consecutive numbers and first number
+ /// should be obtained with `nextTokenId` method
+ /// @param to The new owner
+ /// @param tokenIds IDs of the minted RFTs
+ /// @dev EVM selector for this function is: 0x44a9945e,
+ /// or in textual repr: mintBulk(address,uint256[])
+ function mintBulk(address to, uint256[] memory tokenIds)
+ public
+ returns (bool)
+ {
+ require(false, stub_error);
+ to;
+ tokenIds;
+ dummy = 0;
return false;
}
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
- function uniqueCollectionType() public returns (string memory) {
+ /// @notice Function to mint multiple tokens with the given tokenUris.
+ /// @dev `tokenIds` is array of pairs of token ID and token URI. Token IDs should be consecutive
+ /// numbers and first number should be obtained with `nextTokenId` method
+ /// @param to The new owner
+ /// @param tokens array of pairs of token ID and token URI for minted tokens
+ /// @dev EVM selector for this function is: 0x36543006,
+ /// or in textual repr: mintBulkWithTokenURI(address,(uint256,string)[])
+ function mintBulkWithTokenURI(address to, Tuple8[] memory tokens)
+ public
+ returns (bool)
+ {
require(false, stub_error);
+ to;
+ tokens;
dummy = 0;
- return "";
+ return false;
}
+
+ /// Returns EVM address for refungible token
+ ///
+ /// @param token ID of the token
+ /// @dev EVM selector for this function is: 0xab76fac6,
+ /// or in textual repr: tokenContractAddress(uint256)
+ function tokenContractAddress(uint256 token) public view returns (address) {
+ require(false, stub_error);
+ token;
+ dummy;
+ return 0x0000000000000000000000000000000000000000;
+ }
}
-// Selector: 780e9d63
+/// @dev anonymous struct
+struct Tuple8 {
+ uint256 field_0;
+ string field_1;
+}
+
+/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
+/// @dev See https://eips.ethereum.org/EIPS/eip-721
+/// @dev the ERC-165 identifier for this interface is 0x780e9d63
contract ERC721Enumerable is Dummy, ERC165 {
- // @notice Enumerate valid RFTs
- // @param index A counter less than `totalSupply()`
- // @return The token identifier for the `index`th NFT,
- // (sort order not specified)
- //
- // Selector: tokenByIndex(uint256) 4f6ccce7
+ /// @notice Enumerate valid RFTs
+ /// @param index A counter less than `totalSupply()`
+ /// @return The token identifier for the `index`th NFT,
+ /// (sort order not specified)
+ /// @dev EVM selector for this function is: 0x4f6ccce7,
+ /// or in textual repr: tokenByIndex(uint256)
function tokenByIndex(uint256 index) public view returns (uint256) {
require(false, stub_error);
index;
@@ -637,9 +626,9 @@
return 0;
}
- // Not implemented
- //
- // Selector: tokenOfOwnerByIndex(address,uint256) 2f745c59
+ /// Not implemented
+ /// @dev EVM selector for this function is: 0x2f745c59,
+ /// or in textual repr: tokenOfOwnerByIndex(address,uint256)
function tokenOfOwnerByIndex(address owner, uint256 index)
public
view
@@ -652,11 +641,11 @@
return 0;
}
- // @notice Count RFTs tracked by this contract
- // @return A count of valid RFTs tracked by this contract, where each one of
- // them has an assigned and queryable owner not equal to the zero address
- //
- // Selector: totalSupply() 18160ddd
+ /// @notice Count RFTs tracked by this contract
+ /// @return A count of valid RFTs tracked by this contract, where each one of
+ /// them has an assigned and queryable owner not equal to the zero address
+ /// @dev EVM selector for this function is: 0x18160ddd,
+ /// or in textual repr: totalSupply()
function totalSupply() public view returns (uint256) {
require(false, stub_error);
dummy;
@@ -664,94 +653,195 @@
}
}
-// Selector: 7c3bef89
-contract ERC721UniqueExtensions is Dummy, ERC165 {
- // @notice Transfer ownership of an RFT
- // @dev Throws unless `msg.sender` is the current owner. Throws if `to`
- // is the zero address. Throws if `tokenId` is not a valid RFT.
- // Throws if RFT pieces have multiple owners.
- // @param to The new owner
- // @param tokenId The RFT to transfer
- // @param _value Not used for an RFT
- //
- // Selector: transfer(address,uint256) a9059cbb
- function transfer(address to, uint256 tokenId) public {
+/// @dev the ERC-165 identifier for this interface is 0x5b5e139f
+contract ERC721Metadata is Dummy, ERC165 {
+ /// @notice A descriptive name for a collection of RFTs in this contract
+ /// @dev EVM selector for this function is: 0x06fdde03,
+ /// or in textual repr: name()
+ function name() public view returns (string memory) {
+ require(false, stub_error);
+ dummy;
+ return "";
+ }
+
+ /// @notice An abbreviated name for RFTs in this contract
+ /// @dev EVM selector for this function is: 0x95d89b41,
+ /// or in textual repr: symbol()
+ function symbol() public view returns (string memory) {
require(false, stub_error);
+ dummy;
+ return "";
+ }
+
+ /// @notice A distinct Uniform Resource Identifier (URI) for a given asset.
+ ///
+ /// @dev If the token has a `url` property and it is not empty, it is returned.
+ /// Else If the collection does not have a property with key `schemaName` or its value is not equal to `ERC721Metadata`, it return an error `tokenURI not set`.
+ /// If the collection property `baseURI` is empty or absent, return "" (empty string)
+ /// otherwise, if token property `suffix` present and is non-empty, return concatenation of baseURI and suffix
+ /// otherwise, return concatenation of `baseURI` and stringified token id (decimal stringifying, without paddings).
+ ///
+ /// @return token's const_metadata
+ /// @dev EVM selector for this function is: 0xc87b56dd,
+ /// or in textual repr: tokenURI(uint256)
+ function tokenURI(uint256 tokenId) public view returns (string memory) {
+ require(false, stub_error);
+ tokenId;
+ dummy;
+ return "";
+ }
+}
+
+/// @dev inlined interface
+contract ERC721Events {
+ event Transfer(
+ address indexed from,
+ address indexed to,
+ uint256 indexed tokenId
+ );
+ event Approval(
+ address indexed owner,
+ address indexed approved,
+ uint256 indexed tokenId
+ );
+ event ApprovalForAll(
+ address indexed owner,
+ address indexed operator,
+ bool approved
+ );
+}
+
+/// @title ERC-721 Non-Fungible Token Standard
+/// @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md
+/// @dev the ERC-165 identifier for this interface is 0x58800161
+contract ERC721 is Dummy, ERC165, ERC721Events {
+ /// @notice Count all RFTs assigned to an owner
+ /// @dev RFTs assigned to the zero address are considered invalid, and this
+ /// function throws for queries about the zero address.
+ /// @param owner An address for whom to query the balance
+ /// @return The number of RFTs owned by `owner`, possibly zero
+ /// @dev EVM selector for this function is: 0x70a08231,
+ /// or in textual repr: balanceOf(address)
+ function balanceOf(address owner) public view returns (uint256) {
+ require(false, stub_error);
+ owner;
+ dummy;
+ return 0;
+ }
+
+ /// @notice Find the owner of an RFT
+ /// @dev RFTs assigned to zero address are considered invalid, and queries
+ /// about them do throw.
+ /// Returns special 0xffffffffffffffffffffffffffffffffffffffff address for
+ /// the tokens that are partially owned.
+ /// @param tokenId The identifier for an RFT
+ /// @return The address of the owner of the RFT
+ /// @dev EVM selector for this function is: 0x6352211e,
+ /// or in textual repr: ownerOf(uint256)
+ function ownerOf(uint256 tokenId) public view returns (address) {
+ require(false, stub_error);
+ tokenId;
+ dummy;
+ return 0x0000000000000000000000000000000000000000;
+ }
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x60a11672,
+ /// or in textual repr: safeTransferFromWithData(address,address,uint256,bytes)
+ function safeTransferFromWithData(
+ address from,
+ address to,
+ uint256 tokenId,
+ bytes memory data
+ ) public {
+ require(false, stub_error);
+ from;
to;
tokenId;
+ data;
dummy = 0;
}
- // @notice Burns a specific ERC721 token.
- // @dev Throws unless `msg.sender` is the current owner or an authorized
- // operator for this RFT. Throws if `from` is not the current owner. Throws
- // if `to` is the zero address. Throws if `tokenId` is not a valid RFT.
- // Throws if RFT pieces have multiple owners.
- // @param from The current owner of the RFT
- // @param tokenId The RFT to transfer
- // @param _value Not used for an RFT
- //
- // Selector: burnFrom(address,uint256) 79cc6790
- function burnFrom(address from, uint256 tokenId) public {
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x42842e0e,
+ /// or in textual repr: safeTransferFrom(address,address,uint256)
+ function safeTransferFrom(
+ address from,
+ address to,
+ uint256 tokenId
+ ) public {
require(false, stub_error);
from;
+ to;
tokenId;
dummy = 0;
}
- // @notice Returns next free RFT ID.
- //
- // Selector: nextTokenId() 75794a3c
- function nextTokenId() public view returns (uint256) {
+ /// @notice Transfer ownership of an RFT -- THE CALLER IS RESPONSIBLE
+ /// TO CONFIRM THAT `to` IS CAPABLE OF RECEIVING NFTS OR ELSE
+ /// THEY MAY BE PERMANENTLY LOST
+ /// @dev Throws unless `msg.sender` is the current owner or an authorized
+ /// operator for this RFT. Throws if `from` is not the current owner. Throws
+ /// if `to` is the zero address. Throws if `tokenId` is not a valid RFT.
+ /// Throws if RFT pieces have multiple owners.
+ /// @param from The current owner of the NFT
+ /// @param to The new owner
+ /// @param tokenId The NFT to transfer
+ /// @dev EVM selector for this function is: 0x23b872dd,
+ /// or in textual repr: transferFrom(address,address,uint256)
+ function transferFrom(
+ address from,
+ address to,
+ uint256 tokenId
+ ) public {
require(false, stub_error);
- dummy;
- return 0;
+ from;
+ to;
+ tokenId;
+ dummy = 0;
}
- // @notice Function to mint multiple tokens.
- // @dev `tokenIds` should be an array of consecutive numbers and first number
- // should be obtained with `nextTokenId` method
- // @param to The new owner
- // @param tokenIds IDs of the minted RFTs
- //
- // Selector: mintBulk(address,uint256[]) 44a9945e
- function mintBulk(address to, uint256[] memory tokenIds)
- public
- returns (bool)
- {
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x095ea7b3,
+ /// or in textual repr: approve(address,uint256)
+ function approve(address approved, uint256 tokenId) public {
require(false, stub_error);
- to;
- tokenIds;
+ approved;
+ tokenId;
dummy = 0;
- return false;
}
- // @notice Function to mint multiple tokens with the given tokenUris.
- // @dev `tokenIds` is array of pairs of token ID and token URI. Token IDs should be consecutive
- // numbers and first number should be obtained with `nextTokenId` method
- // @param to The new owner
- // @param tokens array of pairs of token ID and token URI for minted tokens
- //
- // Selector: mintBulkWithTokenURI(address,(uint256,string)[]) 36543006
- function mintBulkWithTokenURI(address to, Tuple0[] memory tokens)
- public
- returns (bool)
- {
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xa22cb465,
+ /// or in textual repr: setApprovalForAll(address,bool)
+ function setApprovalForAll(address operator, bool approved) public {
require(false, stub_error);
- to;
- tokens;
+ operator;
+ approved;
dummy = 0;
- return false;
}
- // Returns EVM address for refungible token
- //
- // @param token ID of the token
- //
- // Selector: tokenContractAddress(uint256) ab76fac6
- function tokenContractAddress(uint256 token) public view returns (address) {
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x081812fc,
+ /// or in textual repr: getApproved(uint256)
+ function getApproved(uint256 tokenId) public view returns (address) {
require(false, stub_error);
- token;
+ tokenId;
+ dummy;
+ return 0x0000000000000000000000000000000000000000;
+ }
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xe985e9c5,
+ /// or in textual repr: isApprovedForAll(address,address)
+ function isApprovedForAll(address owner, address operator)
+ public
+ view
+ returns (address)
+ {
+ require(false, stub_error);
+ owner;
+ operator;
dummy;
return 0x0000000000000000000000000000000000000000;
}
pallets/refungible/src/stubs/UniqueRefungibleToken.rawdiffbeforeafterbothbinary blob β no preview
pallets/refungible/src/stubs/UniqueRefungibleToken.soldiffbeforeafterboth--- a/pallets/refungible/src/stubs/UniqueRefungibleToken.sol
+++ b/pallets/refungible/src/stubs/UniqueRefungibleToken.sol
@@ -3,7 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Common stubs holder
+/// @dev common stubs holder
contract Dummy {
uint8 dummy;
string stub_error = "this contract is implemented in native";
@@ -21,41 +21,18 @@
}
}
-// Inline
-contract ERC20Events {
- event Transfer(address indexed from, address indexed to, uint256 value);
- event Approval(
- address indexed owner,
- address indexed spender,
- uint256 value
- );
-}
-
-// Selector: 042f1106
-contract ERC1633UniqueExtensions is Dummy, ERC165 {
- // Selector: setParentNFT(address,uint256) 042f1106
- function setParentNFT(address collection, uint256 nftId)
- public
- returns (bool)
- {
- require(false, stub_error);
- collection;
- nftId;
- dummy = 0;
- return false;
- }
-}
-
-// Selector: 5755c3f2
+/// @dev the ERC-165 identifier for this interface is 0x5755c3f2
contract ERC1633 is Dummy, ERC165 {
- // Selector: parentToken() 80a54001
+ /// @dev EVM selector for this function is: 0x80a54001,
+ /// or in textual repr: parentToken()
function parentToken() public view returns (address) {
require(false, stub_error);
dummy;
return 0x0000000000000000000000000000000000000000;
}
- // Selector: parentTokenId() d7f083f3
+ /// @dev EVM selector for this function is: 0xd7f083f3,
+ /// or in textual repr: parentTokenId()
function parentTokenId() public view returns (uint256) {
require(false, stub_error);
dummy;
@@ -63,49 +40,92 @@
}
}
-// Selector: 942e8b22
+/// @dev the ERC-165 identifier for this interface is 0xab8deb37
+contract ERC20UniqueExtensions is Dummy, ERC165 {
+ /// @dev Function that burns an amount of the token of a given account,
+ /// deducting from the sender's allowance for said account.
+ /// @param from The account whose tokens will be burnt.
+ /// @param amount The amount that will be burnt.
+ /// @dev EVM selector for this function is: 0x79cc6790,
+ /// or in textual repr: burnFrom(address,uint256)
+ function burnFrom(address from, uint256 amount) public returns (bool) {
+ require(false, stub_error);
+ from;
+ amount;
+ dummy = 0;
+ return false;
+ }
+
+ /// @dev Function that changes total amount of the tokens.
+ /// Throws if `msg.sender` doesn't owns all of the tokens.
+ /// @param amount New total amount of the tokens.
+ /// @dev EVM selector for this function is: 0xd2418ca7,
+ /// or in textual repr: repartition(uint256)
+ function repartition(uint256 amount) public returns (bool) {
+ require(false, stub_error);
+ amount;
+ dummy = 0;
+ return false;
+ }
+}
+
+/// @dev inlined interface
+contract ERC20Events {
+ event Transfer(address indexed from, address indexed to, uint256 value);
+ event Approval(
+ address indexed owner,
+ address indexed spender,
+ uint256 value
+ );
+}
+
+/// @title Standard ERC20 token
+///
+/// @dev Implementation of the basic standard token.
+/// https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md
+/// @dev the ERC-165 identifier for this interface is 0x942e8b22
contract ERC20 is Dummy, ERC165, ERC20Events {
- // @return the name of the token.
- //
- // Selector: name() 06fdde03
+ /// @return the name of the token.
+ /// @dev EVM selector for this function is: 0x06fdde03,
+ /// or in textual repr: name()
function name() public view returns (string memory) {
require(false, stub_error);
dummy;
return "";
}
- // @return the symbol of the token.
- //
- // Selector: symbol() 95d89b41
+ /// @return the symbol of the token.
+ /// @dev EVM selector for this function is: 0x95d89b41,
+ /// or in textual repr: symbol()
function symbol() public view returns (string memory) {
require(false, stub_error);
dummy;
return "";
}
- // @dev Total number of tokens in existence
- //
- // Selector: totalSupply() 18160ddd
+ /// @dev Total number of tokens in existence
+ /// @dev EVM selector for this function is: 0x18160ddd,
+ /// or in textual repr: totalSupply()
function totalSupply() public view returns (uint256) {
require(false, stub_error);
dummy;
return 0;
}
- // @dev Not supported
- //
- // Selector: decimals() 313ce567
+ /// @dev Not supported
+ /// @dev EVM selector for this function is: 0x313ce567,
+ /// or in textual repr: decimals()
function decimals() public view returns (uint8) {
require(false, stub_error);
dummy;
return 0;
}
- // @dev Gets the balance of the specified address.
- // @param owner The address to query the balance of.
- // @return An uint256 representing the amount owned by the passed address.
- //
- // Selector: balanceOf(address) 70a08231
+ /// @dev Gets the balance of the specified address.
+ /// @param owner The address to query the balance of.
+ /// @return An uint256 representing the amount owned by the passed address.
+ /// @dev EVM selector for this function is: 0x70a08231,
+ /// or in textual repr: balanceOf(address)
function balanceOf(address owner) public view returns (uint256) {
require(false, stub_error);
owner;
@@ -113,11 +133,11 @@
return 0;
}
- // @dev Transfer token for a specified address
- // @param to The address to transfer to.
- // @param amount The amount to be transferred.
- //
- // Selector: transfer(address,uint256) a9059cbb
+ /// @dev Transfer token for a specified address
+ /// @param to The address to transfer to.
+ /// @param amount The amount to be transferred.
+ /// @dev EVM selector for this function is: 0xa9059cbb,
+ /// or in textual repr: transfer(address,uint256)
function transfer(address to, uint256 amount) public returns (bool) {
require(false, stub_error);
to;
@@ -126,12 +146,12 @@
return false;
}
- // @dev Transfer tokens from one address to another
- // @param from address The address which you want to send tokens from
- // @param to address The address which you want to transfer to
- // @param amount uint256 the amount of tokens to be transferred
- //
- // Selector: transferFrom(address,address,uint256) 23b872dd
+ /// @dev Transfer tokens from one address to another
+ /// @param from address The address which you want to send tokens from
+ /// @param to address The address which you want to transfer to
+ /// @param amount uint256 the amount of tokens to be transferred
+ /// @dev EVM selector for this function is: 0x23b872dd,
+ /// or in textual repr: transferFrom(address,address,uint256)
function transferFrom(
address from,
address to,
@@ -145,15 +165,15 @@
return false;
}
- // @dev Approve the passed address to spend the specified amount of tokens on behalf of `msg.sender`.
- // Beware that changing an allowance with this method brings the risk that someone may use both the old
- // and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this
- // race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards:
- // https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
- // @param spender The address which will spend the funds.
- // @param amount The amount of tokens to be spent.
- //
- // Selector: approve(address,uint256) 095ea7b3
+ /// @dev Approve the passed address to spend the specified amount of tokens on behalf of `msg.sender`.
+ /// Beware that changing an allowance with this method brings the risk that someone may use both the old
+ /// and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this
+ /// race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards:
+ /// https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
+ /// @param spender The address which will spend the funds.
+ /// @param amount The amount of tokens to be spent.
+ /// @dev EVM selector for this function is: 0x095ea7b3,
+ /// or in textual repr: approve(address,uint256)
function approve(address spender, uint256 amount) public returns (bool) {
require(false, stub_error);
spender;
@@ -162,12 +182,12 @@
return false;
}
- // @dev Function to check the amount of tokens that an owner allowed to a spender.
- // @param owner address The address which owns the funds.
- // @param spender address The address which will spend the funds.
- // @return A uint256 specifying the amount of tokens still available for the spender.
- //
- // Selector: allowance(address,address) dd62ed3e
+ /// @dev Function to check the amount of tokens that an owner allowed to a spender.
+ /// @param owner address The address which owns the funds.
+ /// @param spender address The address which will spend the funds.
+ /// @return A uint256 specifying the amount of tokens still available for the spender.
+ /// @dev EVM selector for this function is: 0xdd62ed3e,
+ /// or in textual repr: allowance(address,address)
function allowance(address owner, address spender)
public
view
@@ -181,40 +201,10 @@
}
}
-// Selector: ab8deb37
-contract ERC20UniqueExtensions is Dummy, ERC165 {
- // @dev Function that burns an amount of the token of a given account,
- // deducting from the sender's allowance for said account.
- // @param from The account whose tokens will be burnt.
- // @param amount The amount that will be burnt.
- //
- // Selector: burnFrom(address,uint256) 79cc6790
- function burnFrom(address from, uint256 amount) public returns (bool) {
- require(false, stub_error);
- from;
- amount;
- dummy = 0;
- return false;
- }
-
- // @dev Function that changes total amount of the tokens.
- // Throws if `msg.sender` doesn't owns all of the tokens.
- // @param amount New total amount of the tokens.
- //
- // Selector: repartition(uint256) d2418ca7
- function repartition(uint256 amount) public returns (bool) {
- require(false, stub_error);
- amount;
- dummy = 0;
- return false;
- }
-}
-
contract UniqueRefungibleToken is
Dummy,
ERC165,
ERC20,
ERC20UniqueExtensions,
- ERC1633,
- ERC1633UniqueExtensions
+ ERC1633
{}
pallets/refungible/src/weights.rsdiffbeforeafterboth--- a/pallets/refungible/src/weights.rs
+++ b/pallets/refungible/src/weights.rs
@@ -53,7 +53,6 @@
fn set_token_properties(b: u32, ) -> Weight;
fn delete_token_properties(b: u32, ) -> Weight;
fn repartition_item() -> Weight;
- fn set_parent_nft_unchecked() -> Weight;
fn token_owner() -> Weight;
}
@@ -254,14 +253,6 @@
(22_356_000 as Weight)
.saturating_add(T::DbWeight::get().reads(2 as Weight))
.saturating_add(T::DbWeight::get().writes(2 as Weight))
- }
- // Storage: Refungible Balance (r:1 w:0)
- // Storage: Refungible TotalSupply (r:1 w:0)
- // Storage: Refungible TokenProperties (r:1 w:1)
- fn set_parent_nft_unchecked() -> Weight {
- (12_015_000 as Weight)
- .saturating_add(T::DbWeight::get().reads(3 as Weight))
- .saturating_add(T::DbWeight::get().writes(1 as Weight))
}
// Storage: Refungible Balance (r:2 w:0)
fn token_owner() -> Weight {
@@ -466,14 +457,6 @@
(22_356_000 as Weight)
.saturating_add(RocksDbWeight::get().reads(2 as Weight))
.saturating_add(RocksDbWeight::get().writes(2 as Weight))
- }
- // Storage: Refungible Balance (r:1 w:0)
- // Storage: Refungible TotalSupply (r:1 w:0)
- // Storage: Refungible TokenProperties (r:1 w:1)
- fn set_parent_nft_unchecked() -> Weight {
- (12_015_000 as Weight)
- .saturating_add(RocksDbWeight::get().reads(3 as Weight))
- .saturating_add(RocksDbWeight::get().writes(1 as Weight))
}
// Storage: Refungible Balance (r:2 w:0)
fn token_owner() -> Weight {
pallets/unique/src/eth/mod.rsdiffbeforeafterboth--- a/pallets/unique/src/eth/mod.rs
+++ b/pallets/unique/src/eth/mod.rs
@@ -154,17 +154,6 @@
Ok(data)
}
-fn parent_nft_property_permissions() -> PropertyKeyPermission {
- PropertyKeyPermission {
- key: key::parent_nft(),
- permission: PropertyPermission {
- mutable: false,
- collection_admin: false,
- token_owner: true,
- },
- }
-}
-
fn create_refungible_collection_internal<
T: Config + pallet_nonfungible::Config + pallet_refungible::Config,
>(
@@ -188,22 +177,12 @@
let collection_id = T::CollectionDispatch::create(caller.clone(), data)
.map_err(pallet_evm_coder_substrate::dispatch_to_evm::<T>)?;
-
- let handle = <CollectionHandle<T>>::try_get(collection_id).map_err(dispatch_to_evm::<T>)?;
- <PalletCommon<T>>::set_scoped_token_property_permissions(
- &handle,
- &caller,
- PropertyScope::Eth,
- vec![parent_nft_property_permissions()],
- )
- .map_err(dispatch_to_evm::<T>)?;
-
let address = pallet_common::eth::collection_id_to_address(collection_id);
Ok(address)
}
/// @title Contract, which allows users to operate with collections
-#[solidity_interface(name = "CollectionHelpers", events(CollectionHelpersEvents))]
+#[solidity_interface(name = CollectionHelpers, events(CollectionHelpersEvents))]
impl<T> EvmCollectionHelpers<T>
where
T: Config + pallet_nonfungible::Config + pallet_refungible::Config,
@@ -211,7 +190,7 @@
/// Create an NFT collection
/// @param name Name of the collection
/// @param description Informative description of the collection
- /// @param token_prefix Token prefix to represent the collection tokens in UI and user applications
+ /// @param tokenPrefix Token prefix to represent the collection tokens in UI and user applications
/// @return address Address of the newly created collection
#[weight(<SelfWeightOf<T>>::create_collection())]
fn create_nonfungible_collection(
@@ -304,7 +283,7 @@
}
/// Check if a collection exists
- /// @param collection_address Address of the collection in question
+ /// @param collectionAddress Address of the collection in question
/// @return bool Does the collection exist?
fn is_collection_exist(&self, _caller: caller, collection_address: address) -> Result<bool> {
if let Some(id) = pallet_common::eth::map_eth_to_id(&collection_address) {
pallets/unique/src/eth/stubs/CollectionHelpers.rawdiffbeforeafterbothbinary blob β no preview
pallets/unique/src/eth/stubs/CollectionHelpers.soldiffbeforeafterboth--- a/pallets/unique/src/eth/stubs/CollectionHelpers.sol
+++ b/pallets/unique/src/eth/stubs/CollectionHelpers.sol
@@ -3,7 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Common stubs holder
+/// @dev common stubs holder
contract Dummy {
uint8 dummy;
string stub_error = "this contract is implemented in native";
@@ -21,7 +21,7 @@
}
}
-// Inline
+/// @dev inlined interface
contract CollectionHelpersEvents {
event CollectionCreated(
address indexed owner,
@@ -29,15 +29,16 @@
);
}
-// Selector: 675f3074
+/// @title Contract, which allows users to operate with collections
+/// @dev the ERC-165 identifier for this interface is 0x675f3074
contract CollectionHelpers is Dummy, ERC165, CollectionHelpersEvents {
- // Create an NFT collection
- // @param name Name of the collection
- // @param description Informative description of the collection
- // @param token_prefix Token prefix to represent the collection tokens in UI and user applications
- // @return address Address of the newly created collection
- //
- // Selector: createNonfungibleCollection(string,string,string) e34a6844
+ /// Create an NFT collection
+ /// @param name Name of the collection
+ /// @param description Informative description of the collection
+ /// @param tokenPrefix Token prefix to represent the collection tokens in UI and user applications
+ /// @return address Address of the newly created collection
+ /// @dev EVM selector for this function is: 0xe34a6844,
+ /// or in textual repr: createNonfungibleCollection(string,string,string)
function createNonfungibleCollection(
string memory name,
string memory description,
@@ -51,7 +52,8 @@
return 0x0000000000000000000000000000000000000000;
}
- // Selector: createERC721MetadataCompatibleCollection(string,string,string,string) a634a5f9
+ /// @dev EVM selector for this function is: 0xa634a5f9,
+ /// or in textual repr: createERC721MetadataCompatibleCollection(string,string,string,string)
function createERC721MetadataCompatibleCollection(
string memory name,
string memory description,
@@ -67,7 +69,8 @@
return 0x0000000000000000000000000000000000000000;
}
- // Selector: createRefungibleCollection(string,string,string) 44a68ad5
+ /// @dev EVM selector for this function is: 0x44a68ad5,
+ /// or in textual repr: createRefungibleCollection(string,string,string)
function createRefungibleCollection(
string memory name,
string memory description,
@@ -81,7 +84,8 @@
return 0x0000000000000000000000000000000000000000;
}
- // Selector: createERC721MetadataCompatibleRFTCollection(string,string,string,string) a5596388
+ /// @dev EVM selector for this function is: 0xa5596388,
+ /// or in textual repr: createERC721MetadataCompatibleRFTCollection(string,string,string,string)
function createERC721MetadataCompatibleRFTCollection(
string memory name,
string memory description,
@@ -97,11 +101,11 @@
return 0x0000000000000000000000000000000000000000;
}
- // Check if a collection exists
- // @param collection_address Address of the collection in question
- // @return bool Does the collection exist?
- //
- // Selector: isCollectionExist(address) c3de1494
+ /// Check if a collection exists
+ /// @param collectionAddress Address of the collection in question
+ /// @return bool Does the collection exist?
+ /// @dev EVM selector for this function is: 0xc3de1494,
+ /// or in textual repr: isCollectionExist(address)
function isCollectionExist(address collectionAddress)
public
view
primitives/data-structs/src/lib.rsdiffbeforeafterboth--- a/primitives/data-structs/src/lib.rs
+++ b/primitives/data-structs/src/lib.rs
@@ -1050,7 +1050,6 @@
pub enum PropertyScope {
None,
Rmrk,
- Eth,
}
impl PropertyScope {
@@ -1059,7 +1058,6 @@
let scope_str: &[u8] = match self {
Self::None => return Ok(key),
Self::Rmrk => b"rmrk",
- Self::Eth => b"eth",
};
[scope_str, b":", key.as_slice()]
runtime/common/config/ethereum.rsdiffbeforeafterboth--- a/runtime/common/config/ethereum.rs
+++ b/runtime/common/config/ethereum.rs
@@ -120,5 +120,4 @@
impl pallet_evm_transaction_payment::Config for Runtime {
type EvmSponsorshipHandler = EvmSponsorshipHandler;
- type Currency = Balances;
}
runtime/common/dispatch.rsdiffbeforeafterboth--- a/runtime/common/dispatch.rs
+++ b/runtime/common/dispatch.rs
@@ -124,7 +124,7 @@
+ pallet_fungible::Config
+ pallet_nonfungible::Config
+ pallet_refungible::Config,
- T::AccountId: From<[u8; 32]>,
+ T::AccountId: From<[u8; 32]> + AsRef<[u8; 32]>,
{
fn is_reserved(target: &H160) -> bool {
map_eth_to_id(target).is_some()
runtime/tests/src/lib.rsdiffbeforeafterboth--- a/runtime/tests/src/lib.rs
+++ b/runtime/tests/src/lib.rs
@@ -167,7 +167,7 @@
}
#[derive(Encode, Decode, Clone, PartialEq, Eq, PartialOrd, Ord, Debug, TypeInfo, MaxEncodedLen)]
-pub struct TestCrossAccountId(u64, sp_core::H160);
+pub struct TestCrossAccountId(u64, sp_core::H160, bool);
impl CrossAccountId<u64> for TestCrossAccountId {
fn as_sub(&self) -> &u64 {
&self.0
@@ -178,17 +178,20 @@
fn from_sub(sub: u64) -> Self {
let mut eth = [0; 20];
eth[12..20].copy_from_slice(&sub.to_be_bytes());
- Self(sub, sp_core::H160(eth))
+ Self(sub, sp_core::H160(eth), true)
}
fn from_eth(eth: sp_core::H160) -> Self {
let mut sub_raw = [0; 8];
sub_raw.copy_from_slice(ð.0[0..8]);
let sub = u64::from_be_bytes(sub_raw);
- Self(sub, eth)
+ Self(sub, eth, false)
}
fn conv_eq(&self, other: &Self) -> bool {
self.as_sub() == other.as_sub()
}
+ fn is_canonical_substrate(&self) -> bool {
+ self.2
+ }
}
impl Default for TestCrossAccountId {
tests/src/addCollectionAdmin.test.tsdiffbeforeafterboth--- a/tests/src/addCollectionAdmin.test.ts
+++ b/tests/src/addCollectionAdmin.test.ts
@@ -14,136 +14,122 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
-import {ApiPromise} from '@polkadot/api';
+import {IKeyringPair} from '@polkadot/types/types';
import chai from 'chai';
import chaiAsPromised from 'chai-as-promised';
-import {default as usingApi, submitTransactionAsync, submitTransactionExpectFailAsync} from './substrate/substrate-api';
-import {addCollectionAdminExpectSuccess, createCollectionExpectSuccess, destroyCollectionExpectSuccess, getAdminList, normalizeAccountId, queryCollectionExpectSuccess} from './util/helpers';
+import {usingPlaygrounds} from './util/playgrounds';
chai.use(chaiAsPromised);
const expect = chai.expect;
+let donor: IKeyringPair;
+
+before(async () => {
+ await usingPlaygrounds(async (_, privateKeyWrapper) => {
+ donor = privateKeyWrapper('//Alice');
+ });
+});
+
describe('Integration Test addCollectionAdmin(collection_id, new_admin_id):', () => {
it('Add collection admin.', async () => {
- await usingApi(async (api, privateKeyWrapper) => {
- const collectionId = await createCollectionExpectSuccess();
- const alice = privateKeyWrapper('//Alice');
- const bob = privateKeyWrapper('//Bob');
+ await usingPlaygrounds(async (helper) => {
+ const [alice, bob] = await helper.arrange.creteAccounts([10n, 10n], donor);
+ const {collectionId} = await helper.nft.mintCollection(alice, {name: 'Collection Name', description: 'Collection Description', tokenPrefix: 'COL'});
- const collection = await queryCollectionExpectSuccess(api, collectionId);
- expect(collection.owner.toString()).to.be.equal(alice.address);
+ const collection = await helper.collection.getData(collectionId);
+ expect(collection!.normalizedOwner!).to.be.equal(alice.address);
- const changeAdminTx = api.tx.unique.addCollectionAdmin(collectionId, normalizeAccountId(bob.address));
- await submitTransactionAsync(alice, changeAdminTx);
+ await helper.nft.addAdmin(alice, collectionId, {Substrate: bob.address});
- const adminListAfterAddAdmin = await getAdminList(api, collectionId);
- expect(adminListAfterAddAdmin).to.be.deep.contains(normalizeAccountId(bob.address));
+ const adminListAfterAddAdmin = await helper.collection.getAdmins(collectionId);
+ expect(adminListAfterAddAdmin).to.be.deep.contains({Substrate: bob.address});
});
});
});
describe('Negative Integration Test addCollectionAdmin(collection_id, new_admin_id):', () => {
it("Not owner can't add collection admin.", async () => {
- await usingApi(async (api, privateKeyWrapper) => {
- const collectionId = await createCollectionExpectSuccess();
- const alice = privateKeyWrapper('//Alice');
- const bob = privateKeyWrapper('//Bob');
- const charlie = privateKeyWrapper('//CHARLIE');
+ await usingPlaygrounds(async (helper) => {
+ const [alice, bob, charlie] = await helper.arrange.creteAccounts([10n, 10n, 10n], donor);
+ const {collectionId} = await helper.nft.mintCollection(alice, {name: 'Collection Name', description: 'Collection Description', tokenPrefix: 'COL'});
- const collection = await queryCollectionExpectSuccess(api, collectionId);
- expect(collection.owner.toString()).to.be.equal(alice.address);
+ const collection = await helper.collection.getData(collectionId);
+ expect(collection?.normalizedOwner).to.be.equal(alice.address);
- const adminListAfterAddAdmin = await getAdminList(api, collectionId);
- expect(adminListAfterAddAdmin).to.be.not.deep.contains(normalizeAccountId(bob.address));
+ const changeAdminTxBob = async () => helper.collection.addAdmin(bob, collectionId, {Substrate: bob.address});
+ const changeAdminTxCharlie = async () => helper.collection.addAdmin(bob, collectionId, {Substrate: charlie.address});
+ await expect(changeAdminTxCharlie()).to.be.rejected;
+ await expect(changeAdminTxBob()).to.be.rejected;
- const changeAdminTxCharlie = api.tx.unique.addCollectionAdmin(collectionId, normalizeAccountId(charlie.address));
- await expect(submitTransactionAsync(bob, changeAdminTxCharlie)).to.be.rejected;
-
- const adminListAfterAddNewAdmin = await getAdminList(api, collectionId);
- expect(adminListAfterAddNewAdmin).to.be.not.deep.contains(normalizeAccountId(bob.address));
- expect(adminListAfterAddNewAdmin).to.be.not.deep.contains(normalizeAccountId(charlie.address));
+ const adminListAfterAddAdmin = await helper.collection.getAdmins(collectionId);
+ expect(adminListAfterAddAdmin).to.be.not.deep.contains({Substrate: charlie.address});
+ expect(adminListAfterAddAdmin).to.be.not.deep.contains({Substrate: bob.address});
});
});
it("Admin can't add collection admin.", async () => {
- await usingApi(async (api, privateKeyWrapper) => {
- const collectionId = await createCollectionExpectSuccess();
- const alice = privateKeyWrapper('//Alice');
- const bob = privateKeyWrapper('//Bob');
- const charlie = privateKeyWrapper('//CHARLIE');
+ await usingPlaygrounds(async (helper) => {
+ const [alice, bob, charlie] = await helper.arrange.creteAccounts([10n, 10n, 10n], donor);
+ const collection = await helper.nft.mintCollection(alice, {name: 'Collection Name', description: 'Collection Description', tokenPrefix: 'COL'});
- const collection = await queryCollectionExpectSuccess(api, collectionId);
- expect(collection.owner.toString()).to.be.equal(alice.address);
+ await collection.addAdmin(alice, {Substrate: bob.address});
- const changeAdminTx = api.tx.unique.addCollectionAdmin(collectionId, normalizeAccountId(bob.address));
- await submitTransactionAsync(alice, changeAdminTx);
+ const adminListAfterAddAdmin = await collection.getAdmins();
+ expect(adminListAfterAddAdmin).to.be.deep.contains({Substrate: bob.address});
- const adminListAfterAddAdmin = await getAdminList(api, collectionId);
- expect(adminListAfterAddAdmin).to.be.deep.contains(normalizeAccountId(bob.address));
+ const changeAdminTxCharlie = async () => collection.addAdmin(bob, {Substrate: charlie.address});
+ await expect(changeAdminTxCharlie()).to.be.rejected;
- const changeAdminTxCharlie = api.tx.unique.addCollectionAdmin(collectionId, normalizeAccountId(charlie.address));
- await expect(submitTransactionAsync(bob, changeAdminTxCharlie)).to.be.rejected;
-
- const adminListAfterAddNewAdmin = await getAdminList(api, collectionId);
- expect(adminListAfterAddNewAdmin).to.be.deep.contains(normalizeAccountId(bob.address));
- expect(adminListAfterAddNewAdmin).to.be.not.deep.contains(normalizeAccountId(charlie.address));
+ const adminListAfterAddNewAdmin = await collection.getAdmins();
+ expect(adminListAfterAddNewAdmin).to.be.deep.contains({Substrate: bob.address});
+ expect(adminListAfterAddNewAdmin).to.be.not.deep.contains({Substrate: charlie.address});
});
});
it("Can't add collection admin of not existing collection.", async () => {
- await usingApi(async (api, privateKeyWrapper) => {
+ await usingPlaygrounds(async (helper) => {
+ const [alice, bob] = await helper.arrange.creteAccounts([10n, 10n, 10n], donor);
// tslint:disable-next-line: no-bitwise
const collectionId = (1 << 32) - 1;
- const alice = privateKeyWrapper('//Alice');
- const bob = privateKeyWrapper('//Bob');
- const changeOwnerTx = api.tx.unique.addCollectionAdmin(collectionId, normalizeAccountId(bob.address));
- await expect(submitTransactionExpectFailAsync(alice, changeOwnerTx)).to.be.rejected;
+ const addAdminTx = async () => helper.collection.addAdmin(alice, collectionId, {Substrate: bob.address});
+ await expect(addAdminTx()).to.be.rejected;
// Verifying that nothing bad happened (network is live, new collections can be created, etc.)
- await createCollectionExpectSuccess();
+ await helper.nft.mintCollection(alice, {name: 'Collection Name', description: 'Collection Description', tokenPrefix: 'COL'});
});
});
it("Can't add an admin to a destroyed collection.", async () => {
- await usingApi(async (api, privateKeyWrapper) => {
- const collectionId = await createCollectionExpectSuccess();
- const alice = privateKeyWrapper('//Alice');
- const bob = privateKeyWrapper('//Bob');
- await destroyCollectionExpectSuccess(collectionId);
- const changeOwnerTx = api.tx.unique.addCollectionAdmin(collectionId, normalizeAccountId(bob.address));
- await expect(submitTransactionExpectFailAsync(alice, changeOwnerTx)).to.be.rejected;
+ await usingPlaygrounds(async (helper) => {
+ const [alice, bob] = await helper.arrange.creteAccounts([10n, 10n, 10n], donor);
+ const collection = await helper.nft.mintCollection(alice, {name: 'Collection Name', description: 'Collection Description', tokenPrefix: 'COL'});
+
+ await collection.burn(alice);
+ const addAdminTx = async () => collection.addAdmin(alice, {Substrate: bob.address});
+ await expect(addAdminTx()).to.be.rejected;
// Verifying that nothing bad happened (network is live, new collections can be created, etc.)
- await createCollectionExpectSuccess();
+ await helper.nft.mintCollection(alice, {name: 'Collection Name', description: 'Collection Description', tokenPrefix: 'COL'});
});
});
it('Add an admin to a collection that has reached the maximum number of admins limit', async () => {
- await usingApi(async (api: ApiPromise, privateKeyWrapper) => {
- const alice = privateKeyWrapper('//Alice');
- const accounts = [
- privateKeyWrapper('//AdminTest/1').address,
- privateKeyWrapper('//AdminTest/2').address,
- privateKeyWrapper('//AdminTest/3').address,
- privateKeyWrapper('//AdminTest/4').address,
- privateKeyWrapper('//AdminTest/5').address,
- privateKeyWrapper('//AdminTest/6').address,
- privateKeyWrapper('//AdminTest/7').address,
- ];
- const collectionId = await createCollectionExpectSuccess();
+ await usingPlaygrounds(async (helper) => {
+ const [alice, ...accounts] = await helper.arrange.creteAccounts([10n, 0n, 0n, 0n, 0n, 0n, 0n, 0n], donor);
+ const collection = await helper.nft.mintCollection(alice, {name: 'Collection Name', description: 'Collection Description', tokenPrefix: 'COL'});
- const chainAdminLimit = (api.consts.common.collectionAdminsLimit as any).toNumber();
+ const chainAdminLimit = (helper.api!.consts.common.collectionAdminsLimit as any).toNumber();
expect(chainAdminLimit).to.be.equal(5);
for (let i = 0; i < chainAdminLimit; i++) {
- await addCollectionAdminExpectSuccess(alice, collectionId, accounts[i]);
- const adminListAfterAddAdmin = await getAdminList(api, collectionId);
- expect(adminListAfterAddAdmin).to.be.deep.contains(normalizeAccountId(accounts[i]));
+ await collection.addAdmin(alice, {Substrate: accounts[i].address});
+ const adminListAfterAddAdmin = await collection.getAdmins();
+ expect(adminListAfterAddAdmin).to.be.deep.contains({Substrate: accounts[i].address});
}
- const tx = api.tx.unique.addCollectionAdmin(collectionId, normalizeAccountId(accounts[chainAdminLimit]));
- await expect(submitTransactionExpectFailAsync(alice, tx)).to.be.rejected;
+ const addExtraAdminTx = async () => collection.addAdmin(alice, {Substrate: accounts[chainAdminLimit].address});
+ await expect(addExtraAdminTx()).to.be.rejected;
});
});
});
tests/src/eth/api/CollectionHelpers.soldiffbeforeafterboth--- a/tests/src/eth/api/CollectionHelpers.sol
+++ b/tests/src/eth/api/CollectionHelpers.sol
@@ -3,7 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Common stubs holder
+/// @dev common stubs holder
interface Dummy {
}
@@ -12,7 +12,7 @@
function supportsInterface(bytes4 interfaceID) external view returns (bool);
}
-// Inline
+/// @dev inlined interface
interface CollectionHelpersEvents {
event CollectionCreated(
address indexed owner,
@@ -20,22 +20,24 @@
);
}
-// Selector: 675f3074
+/// @title Contract, which allows users to operate with collections
+/// @dev the ERC-165 identifier for this interface is 0x675f3074
interface CollectionHelpers is Dummy, ERC165, CollectionHelpersEvents {
- // Create an NFT collection
- // @param name Name of the collection
- // @param description Informative description of the collection
- // @param token_prefix Token prefix to represent the collection tokens in UI and user applications
- // @return address Address of the newly created collection
- //
- // Selector: createNonfungibleCollection(string,string,string) e34a6844
+ /// Create an NFT collection
+ /// @param name Name of the collection
+ /// @param description Informative description of the collection
+ /// @param tokenPrefix Token prefix to represent the collection tokens in UI and user applications
+ /// @return address Address of the newly created collection
+ /// @dev EVM selector for this function is: 0xe34a6844,
+ /// or in textual repr: createNonfungibleCollection(string,string,string)
function createNonfungibleCollection(
string memory name,
string memory description,
string memory tokenPrefix
) external returns (address);
- // Selector: createERC721MetadataCompatibleCollection(string,string,string,string) a634a5f9
+ /// @dev EVM selector for this function is: 0xa634a5f9,
+ /// or in textual repr: createERC721MetadataCompatibleCollection(string,string,string,string)
function createERC721MetadataCompatibleCollection(
string memory name,
string memory description,
@@ -43,14 +45,16 @@
string memory baseUri
) external returns (address);
- // Selector: createRefungibleCollection(string,string,string) 44a68ad5
+ /// @dev EVM selector for this function is: 0x44a68ad5,
+ /// or in textual repr: createRefungibleCollection(string,string,string)
function createRefungibleCollection(
string memory name,
string memory description,
string memory tokenPrefix
) external returns (address);
- // Selector: createERC721MetadataCompatibleRFTCollection(string,string,string,string) a5596388
+ /// @dev EVM selector for this function is: 0xa5596388,
+ /// or in textual repr: createERC721MetadataCompatibleRFTCollection(string,string,string,string)
function createERC721MetadataCompatibleRFTCollection(
string memory name,
string memory description,
@@ -58,11 +62,11 @@
string memory baseUri
) external returns (address);
- // Check if a collection exists
- // @param collection_address Address of the collection in question
- // @return bool Does the collection exist?
- //
- // Selector: isCollectionExist(address) c3de1494
+ /// Check if a collection exists
+ /// @param collectionAddress Address of the collection in question
+ /// @return bool Does the collection exist?
+ /// @dev EVM selector for this function is: 0xc3de1494,
+ /// or in textual repr: isCollectionExist(address)
function isCollectionExist(address collectionAddress)
external
view
tests/src/eth/api/ContractHelpers.soldiffbeforeafterboth--- a/tests/src/eth/api/ContractHelpers.sol
+++ b/tests/src/eth/api/ContractHelpers.sol
@@ -3,7 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Common stubs holder
+/// @dev common stubs holder
interface Dummy {
}
@@ -12,63 +12,164 @@
function supportsInterface(bytes4 interfaceID) external view returns (bool);
}
-// Selector: 7b4866f9
+/// @title Magic contract, which allows users to reconfigure other contracts
+/// @dev the ERC-165 identifier for this interface is 0xd77fab70
interface ContractHelpers is Dummy, ERC165 {
- // Selector: contractOwner(address) 5152b14c
+ /// Get user, which deployed specified contract
+ /// @dev May return zero address in case if contract is deployed
+ /// using uniquenetwork evm-migration pallet, or using other terms not
+ /// intended by pallet-evm
+ /// @dev Returns zero address if contract does not exists
+ /// @param contractAddress Contract to get owner of
+ /// @return address Owner of contract
+ /// @dev EVM selector for this function is: 0x5152b14c,
+ /// or in textual repr: contractOwner(address)
function contractOwner(address contractAddress)
external
view
returns (address);
- // Selector: sponsoringEnabled(address) 6027dc61
- function sponsoringEnabled(address contractAddress)
+ /// Set sponsor.
+ /// @param contractAddress Contract for which a sponsor is being established.
+ /// @param sponsor User address who set as pending sponsor.
+ /// @dev EVM selector for this function is: 0xf01fba93,
+ /// or in textual repr: setSponsor(address,address)
+ function setSponsor(address contractAddress, address sponsor) external;
+
+ /// Set contract as self sponsored.
+ ///
+ /// @param contractAddress Contract for which a self sponsoring is being enabled.
+ /// @dev EVM selector for this function is: 0x89f7d9ae,
+ /// or in textual repr: selfSponsoredEnable(address)
+ function selfSponsoredEnable(address contractAddress) external;
+
+ /// Remove sponsor.
+ ///
+ /// @param contractAddress Contract for which a sponsorship is being removed.
+ /// @dev EVM selector for this function is: 0xef784250,
+ /// or in textual repr: removeSponsor(address)
+ function removeSponsor(address contractAddress) external;
+
+ /// Confirm sponsorship.
+ ///
+ /// @dev Caller must be same that set via [`setSponsor`].
+ ///
+ /// @param contractAddress Π‘ontract for which need to confirm sponsorship.
+ /// @dev EVM selector for this function is: 0xabc00001,
+ /// or in textual repr: confirmSponsorship(address)
+ function confirmSponsorship(address contractAddress) external;
+
+ /// Get current sponsor.
+ ///
+ /// @param contractAddress The contract for which a sponsor is requested.
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ /// @dev EVM selector for this function is: 0x743fc745,
+ /// or in textual repr: getSponsor(address)
+ function getSponsor(address contractAddress)
external
view
- returns (bool);
+ returns (Tuple0 memory);
- // Deprecated
- //
- // Selector: toggleSponsoring(address,bool) fcac6d86
- function toggleSponsoring(address contractAddress, bool enabled) external;
+ /// Check tat contract has confirmed sponsor.
+ ///
+ /// @param contractAddress The contract for which the presence of a confirmed sponsor is checked.
+ /// @return **true** if contract has confirmed sponsor.
+ /// @dev EVM selector for this function is: 0x97418603,
+ /// or in textual repr: hasSponsor(address)
+ function hasSponsor(address contractAddress) external view returns (bool);
- // Selector: setSponsoringMode(address,uint8) fde8a560
- function setSponsoringMode(address contractAddress, uint8 mode) external;
+ /// Check tat contract has pending sponsor.
+ ///
+ /// @param contractAddress The contract for which the presence of a pending sponsor is checked.
+ /// @return **true** if contract has pending sponsor.
+ /// @dev EVM selector for this function is: 0x39b9b242,
+ /// or in textual repr: hasPendingSponsor(address)
+ function hasPendingSponsor(address contractAddress)
+ external
+ view
+ returns (bool);
- // Selector: sponsoringMode(address) b70c7267
- function sponsoringMode(address contractAddress)
+ /// @dev EVM selector for this function is: 0x6027dc61,
+ /// or in textual repr: sponsoringEnabled(address)
+ function sponsoringEnabled(address contractAddress)
external
view
- returns (uint8);
+ returns (bool);
- // Selector: setSponsoringRateLimit(address,uint32) 77b6c908
- function setSponsoringRateLimit(address contractAddress, uint32 rateLimit)
- external;
+ /// @dev EVM selector for this function is: 0xfde8a560,
+ /// or in textual repr: setSponsoringMode(address,uint8)
+ function setSponsoringMode(address contractAddress, uint8 mode) external;
- // Selector: getSponsoringRateLimit(address) 610cfabd
+ /// Get current contract sponsoring rate limit
+ /// @param contractAddress Contract to get sponsoring mode of
+ /// @return uint32 Amount of blocks between two sponsored transactions
+ /// @dev EVM selector for this function is: 0x610cfabd,
+ /// or in textual repr: getSponsoringRateLimit(address)
function getSponsoringRateLimit(address contractAddress)
external
view
returns (uint32);
- // Selector: allowed(address,address) 5c658165
+ /// Set contract sponsoring rate limit
+ /// @dev Sponsoring rate limit - is a minimum amount of blocks that should
+ /// pass between two sponsored transactions
+ /// @param contractAddress Contract to change sponsoring rate limit of
+ /// @param rateLimit Target rate limit
+ /// @dev Only contract owner can change this setting
+ /// @dev EVM selector for this function is: 0x77b6c908,
+ /// or in textual repr: setSponsoringRateLimit(address,uint32)
+ function setSponsoringRateLimit(address contractAddress, uint32 rateLimit)
+ external;
+
+ /// Is specified user present in contract allow list
+ /// @dev Contract owner always implicitly included
+ /// @param contractAddress Contract to check allowlist of
+ /// @param user User to check
+ /// @return bool Is specified users exists in contract allowlist
+ /// @dev EVM selector for this function is: 0x5c658165,
+ /// or in textual repr: allowed(address,address)
function allowed(address contractAddress, address user)
external
view
returns (bool);
- // Selector: allowlistEnabled(address) c772ef6c
+ /// Toggle user presence in contract allowlist
+ /// @param contractAddress Contract to change allowlist of
+ /// @param user Which user presence should be toggled
+ /// @param isAllowed `true` if user should be allowed to be sponsored
+ /// or call this contract, `false` otherwise
+ /// @dev Only contract owner can change this setting
+ /// @dev EVM selector for this function is: 0x4706cc1c,
+ /// or in textual repr: toggleAllowed(address,address,bool)
+ function toggleAllowed(
+ address contractAddress,
+ address user,
+ bool isAllowed
+ ) external;
+
+ /// Is this contract has allowlist access enabled
+ /// @dev Allowlist always can have users, and it is used for two purposes:
+ /// in case of allowlist sponsoring mode, users will be sponsored if they exist in allowlist
+ /// in case of allowlist access enabled, only users from allowlist may call this contract
+ /// @param contractAddress Contract to get allowlist access of
+ /// @return bool Is specified contract has allowlist access enabled
+ /// @dev EVM selector for this function is: 0xc772ef6c,
+ /// or in textual repr: allowlistEnabled(address)
function allowlistEnabled(address contractAddress)
external
view
returns (bool);
- // Selector: toggleAllowlist(address,bool) 36de20f5
+ /// Toggle contract allowlist access
+ /// @param contractAddress Contract to change allowlist access of
+ /// @param enabled Should allowlist access to be enabled?
+ /// @dev EVM selector for this function is: 0x36de20f5,
+ /// or in textual repr: toggleAllowlist(address,bool)
function toggleAllowlist(address contractAddress, bool enabled) external;
+}
- // Selector: toggleAllowed(address,address,bool) 4706cc1c
- function toggleAllowed(
- address contractAddress,
- address user,
- bool allowed
- ) external;
+/// @dev anonymous struct
+struct Tuple0 {
+ address field_0;
+ uint256 field_1;
}
tests/src/eth/api/UniqueFungible.soldiffbeforeafterboth--- a/tests/src/eth/api/UniqueFungible.sol
+++ b/tests/src/eth/api/UniqueFungible.sol
@@ -3,225 +3,312 @@
pragma solidity >=0.8.0 <0.9.0;
-// Common stubs holder
+/// @dev common stubs holder
interface Dummy {
}
interface ERC165 is Dummy {
function supportsInterface(bytes4 interfaceID) external view returns (bool);
-}
-
-// Inline
-interface ERC20Events {
- event Transfer(address indexed from, address indexed to, uint256 value);
- event Approval(
- address indexed owner,
- address indexed spender,
- uint256 value
- );
}
-// Selector: 6cf113cd
+/// @title A contract that allows you to work with collections.
+/// @dev the ERC-165 identifier for this interface is 0xe54be640
interface Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
+ /// Set collection property.
+ ///
+ /// @param key Property key.
+ /// @param value Propery value.
+ /// @dev EVM selector for this function is: 0x2f073f66,
+ /// or in textual repr: setCollectionProperty(string,bytes)
function setCollectionProperty(string memory key, bytes memory value)
external;
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
+ /// Delete collection property.
+ ///
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x7b7debce,
+ /// or in textual repr: deleteCollectionProperty(string)
function deleteCollectionProperty(string memory key) external;
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
+ /// Get collection property.
+ ///
+ /// @dev Throws error if key not found.
+ ///
+ /// @param key Property key.
+ /// @return bytes The property corresponding to the key.
+ /// @dev EVM selector for this function is: 0xcf24fd6d,
+ /// or in textual repr: collectionProperty(string)
function collectionProperty(string memory key)
external
view
returns (bytes memory);
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
+ /// Set the sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0x7623402e,
+ /// or in textual repr: setCollectionSponsor(address)
function setCollectionSponsor(address sponsor) external;
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
+ /// Set the substrate sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Substrate address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0xc74d6751,
+ /// or in textual repr: setCollectionSponsorSubstrate(uint256)
+ function setCollectionSponsorSubstrate(uint256 sponsor) external;
+
+ /// @dev EVM selector for this function is: 0x058ac185,
+ /// or in textual repr: hasCollectionPendingSponsor()
+ function hasCollectionPendingSponsor() external view returns (bool);
+
+ /// Collection sponsorship confirmation.
+ ///
+ /// @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ /// @dev EVM selector for this function is: 0x3c50e97a,
+ /// or in textual repr: confirmCollectionSponsorship()
function confirmCollectionSponsorship() external;
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
+ /// Remove collection sponsor.
+ /// @dev EVM selector for this function is: 0x6e0326a3,
+ /// or in textual repr: removeCollectionSponsor()
+ function removeCollectionSponsor() external;
+
+ /// Get current sponsor.
+ ///
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ /// @dev EVM selector for this function is: 0xb66bbc14,
+ /// or in textual repr: getCollectionSponsor()
+ function getCollectionSponsor() external view returns (Tuple6 memory);
+
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "accountTokenOwnershipLimit",
+ /// "sponsoredDataSize",
+ /// "sponsoredDataRateLimit",
+ /// "tokenLimit",
+ /// "sponsorTransferTimeout",
+ /// "sponsorApproveTimeout"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x6a3841db,
+ /// or in textual repr: setCollectionLimit(string,uint32)
function setCollectionLimit(string memory limit, uint32 value) external;
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "ownerCanTransfer",
+ /// "ownerCanDestroy",
+ /// "transfersEnabled"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x993b7fba,
+ /// or in textual repr: setCollectionLimit(string,bool)
function setCollectionLimit(string memory limit, bool value) external;
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
+ /// Get contract address.
+ /// @dev EVM selector for this function is: 0xf6b4dfb4,
+ /// or in textual repr: contractAddress()
function contractAddress() external view returns (address);
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
+ /// Add collection admin by substrate address.
+ /// @param newAdmin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x5730062b,
+ /// or in textual repr: addCollectionAdminSubstrate(uint256)
function addCollectionAdminSubstrate(uint256 newAdmin) external;
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
+ /// Remove collection admin by substrate address.
+ /// @param admin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x4048fcf9,
+ /// or in textual repr: removeCollectionAdminSubstrate(uint256)
function removeCollectionAdminSubstrate(uint256 admin) external;
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
+ /// Add collection admin.
+ /// @param newAdmin Address of the added administrator.
+ /// @dev EVM selector for this function is: 0x92e462c7,
+ /// or in textual repr: addCollectionAdmin(address)
function addCollectionAdmin(address newAdmin) external;
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
+ /// Remove collection admin.
+ ///
+ /// @param admin Address of the removed administrator.
+ /// @dev EVM selector for this function is: 0xfafd7b42,
+ /// or in textual repr: removeCollectionAdmin(address)
function removeCollectionAdmin(address admin) external;
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ /// @dev EVM selector for this function is: 0x112d4586,
+ /// or in textual repr: setCollectionNesting(bool)
function setCollectionNesting(bool enable) external;
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ /// @param collections Addresses of collections that will be available for nesting.
+ /// @dev EVM selector for this function is: 0x64872396,
+ /// or in textual repr: setCollectionNesting(bool,address[])
function setCollectionNesting(bool enable, address[] memory collections)
external;
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
+ /// Set the collection access method.
+ /// @param mode Access mode
+ /// 0 for Normal
+ /// 1 for AllowList
+ /// @dev EVM selector for this function is: 0x41835d4c,
+ /// or in textual repr: setCollectionAccess(uint8)
function setCollectionAccess(uint8 mode) external;
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
+ /// Add the user to the allowed list.
+ ///
+ /// @param user Address of a trusted user.
+ /// @dev EVM selector for this function is: 0x67844fe6,
+ /// or in textual repr: addToCollectionAllowList(address)
function addToCollectionAllowList(address user) external;
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
+ /// Remove the user from the allowed list.
+ ///
+ /// @param user Address of a removed user.
+ /// @dev EVM selector for this function is: 0x85c51acb,
+ /// or in textual repr: removeFromCollectionAllowList(address)
function removeFromCollectionAllowList(address user) external;
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
+ /// Switch permission for minting.
+ ///
+ /// @param mode Enable if "true".
+ /// @dev EVM selector for this function is: 0x00018e84,
+ /// or in textual repr: setCollectionMintMode(bool)
function setCollectionMintMode(bool mode) external;
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) external view returns (bool);
+ /// Check that account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x9811b0c7,
+ /// or in textual repr: isOwnerOrAdmin(address)
+ function isOwnerOrAdmin(address user) external view returns (bool);
+
+ /// Check that substrate account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x68910e00,
+ /// or in textual repr: isOwnerOrAdminSubstrate(uint256)
+ function isOwnerOrAdminSubstrate(uint256 user) external view returns (bool);
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
+ /// Returns collection type
+ ///
+ /// @return `Fungible` or `NFT` or `ReFungible`
+ /// @dev EVM selector for this function is: 0xd34b55b8,
+ /// or in textual repr: uniqueCollectionType()
function uniqueCollectionType() external returns (string memory);
+
+ /// Changes collection owner to another account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner account
+ /// @dev EVM selector for this function is: 0x13af4035,
+ /// or in textual repr: setOwner(address)
+ function setOwner(address newOwner) external;
+
+ /// Changes collection owner to another substrate account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner substrate account
+ /// @dev EVM selector for this function is: 0xb212138f,
+ /// or in textual repr: setOwnerSubstrate(uint256)
+ function setOwnerSubstrate(uint256 newOwner) external;
}
-// Selector: 79cc6790
+/// @dev the ERC-165 identifier for this interface is 0x63034ac5
interface ERC20UniqueExtensions is Dummy, ERC165 {
- // Selector: burnFrom(address,uint256) 79cc6790
+ /// Burn tokens from account
+ /// @dev Function that burns an `amount` of the tokens of a given account,
+ /// deducting from the sender's allowance for said account.
+ /// @param from The account whose tokens will be burnt.
+ /// @param amount The amount that will be burnt.
+ /// @dev EVM selector for this function is: 0x79cc6790,
+ /// or in textual repr: burnFrom(address,uint256)
function burnFrom(address from, uint256 amount) external returns (bool);
+
+ /// Mint tokens for multiple accounts.
+ /// @param amounts array of pairs of account address and amount
+ /// @dev EVM selector for this function is: 0x1acf2d55,
+ /// or in textual repr: mintBulk((address,uint256)[])
+ function mintBulk(Tuple6[] memory amounts) external returns (bool);
+}
+
+/// @dev anonymous struct
+struct Tuple6 {
+ address field_0;
+ uint256 field_1;
+}
+
+/// @dev the ERC-165 identifier for this interface is 0x40c10f19
+interface ERC20Mintable is Dummy, ERC165 {
+ /// Mint tokens for `to` account.
+ /// @param to account that will receive minted tokens
+ /// @param amount amount of tokens to mint
+ /// @dev EVM selector for this function is: 0x40c10f19,
+ /// or in textual repr: mint(address,uint256)
+ function mint(address to, uint256 amount) external returns (bool);
}
-// Selector: 942e8b22
+/// @dev inlined interface
+interface ERC20Events {
+ event Transfer(address indexed from, address indexed to, uint256 value);
+ event Approval(
+ address indexed owner,
+ address indexed spender,
+ uint256 value
+ );
+}
+
+/// @dev the ERC-165 identifier for this interface is 0x942e8b22
interface ERC20 is Dummy, ERC165, ERC20Events {
- // Selector: name() 06fdde03
+ /// @dev EVM selector for this function is: 0x06fdde03,
+ /// or in textual repr: name()
function name() external view returns (string memory);
- // Selector: symbol() 95d89b41
+ /// @dev EVM selector for this function is: 0x95d89b41,
+ /// or in textual repr: symbol()
function symbol() external view returns (string memory);
- // Selector: totalSupply() 18160ddd
+ /// @dev EVM selector for this function is: 0x18160ddd,
+ /// or in textual repr: totalSupply()
function totalSupply() external view returns (uint256);
- // Selector: decimals() 313ce567
+ /// @dev EVM selector for this function is: 0x313ce567,
+ /// or in textual repr: decimals()
function decimals() external view returns (uint8);
- // Selector: balanceOf(address) 70a08231
+ /// @dev EVM selector for this function is: 0x70a08231,
+ /// or in textual repr: balanceOf(address)
function balanceOf(address owner) external view returns (uint256);
- // Selector: transfer(address,uint256) a9059cbb
+ /// @dev EVM selector for this function is: 0xa9059cbb,
+ /// or in textual repr: transfer(address,uint256)
function transfer(address to, uint256 amount) external returns (bool);
- // Selector: transferFrom(address,address,uint256) 23b872dd
+ /// @dev EVM selector for this function is: 0x23b872dd,
+ /// or in textual repr: transferFrom(address,address,uint256)
function transferFrom(
address from,
address to,
uint256 amount
) external returns (bool);
- // Selector: approve(address,uint256) 095ea7b3
+ /// @dev EVM selector for this function is: 0x095ea7b3,
+ /// or in textual repr: approve(address,uint256)
function approve(address spender, uint256 amount) external returns (bool);
- // Selector: allowance(address,address) dd62ed3e
+ /// @dev EVM selector for this function is: 0xdd62ed3e,
+ /// or in textual repr: allowance(address,address)
function allowance(address owner, address spender)
external
view
@@ -232,6 +319,7 @@
Dummy,
ERC165,
ERC20,
+ ERC20Mintable,
ERC20UniqueExtensions,
Collection
{}
tests/src/eth/api/UniqueNFT.soldiffbeforeafterboth--- a/tests/src/eth/api/UniqueNFT.sol
+++ b/tests/src/eth/api/UniqueNFT.sol
@@ -3,55 +3,26 @@
pragma solidity >=0.8.0 <0.9.0;
-// Anonymous struct
-struct Tuple0 {
- uint256 field_0;
- string field_1;
-}
-
-// Common stubs holder
+/// @dev common stubs holder
interface Dummy {
}
interface ERC165 is Dummy {
function supportsInterface(bytes4 interfaceID) external view returns (bool);
-}
-
-// Inline
-interface ERC721Events {
- event Transfer(
- address indexed from,
- address indexed to,
- uint256 indexed tokenId
- );
- event Approval(
- address indexed owner,
- address indexed approved,
- uint256 indexed tokenId
- );
- event ApprovalForAll(
- address indexed owner,
- address indexed operator,
- bool approved
- );
}
-// Inline
-interface ERC721MintableEvents {
- event MintingFinished();
-}
-
-// Selector: 41369377
+/// @title A contract that allows to set and delete token properties and change token property permissions.
+/// @dev the ERC-165 identifier for this interface is 0x41369377
interface TokenProperties is Dummy, ERC165 {
- // @notice Set permissions for token property.
- // @dev Throws error if `msg.sender` is not admin or owner of the collection.
- // @param key Property key.
- // @param is_mutable Permission to mutate property.
- // @param collection_admin Permission to mutate property by collection admin if property is mutable.
- // @param token_owner Permission to mutate property by token owner if property is mutable.
- //
- // Selector: setTokenPropertyPermission(string,bool,bool,bool) 222d97fa
+ /// @notice Set permissions for token property.
+ /// @dev Throws error if `msg.sender` is not admin or owner of the collection.
+ /// @param key Property key.
+ /// @param isMutable Permission to mutate property.
+ /// @param collectionAdmin Permission to mutate property by collection admin if property is mutable.
+ /// @param tokenOwner Permission to mutate property by token owner if property is mutable.
+ /// @dev EVM selector for this function is: 0x222d97fa,
+ /// or in textual repr: setTokenPropertyPermission(string,bool,bool,bool)
function setTokenPropertyPermission(
string memory key,
bool isMutable,
@@ -59,437 +30,530 @@
bool tokenOwner
) external;
- // @notice Set token property value.
- // @dev Throws error if `msg.sender` has no permission to edit the property.
- // @param tokenId ID of the token.
- // @param key Property key.
- // @param value Property value.
- //
- // Selector: setProperty(uint256,string,bytes) 1752d67b
+ /// @notice Set token property value.
+ /// @dev Throws error if `msg.sender` has no permission to edit the property.
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @param value Property value.
+ /// @dev EVM selector for this function is: 0x1752d67b,
+ /// or in textual repr: setProperty(uint256,string,bytes)
function setProperty(
uint256 tokenId,
string memory key,
bytes memory value
) external;
- // @notice Delete token property value.
- // @dev Throws error if `msg.sender` has no permission to edit the property.
- // @param tokenId ID of the token.
- // @param key Property key.
- //
- // Selector: deleteProperty(uint256,string) 066111d1
+ /// @notice Delete token property value.
+ /// @dev Throws error if `msg.sender` has no permission to edit the property.
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x066111d1,
+ /// or in textual repr: deleteProperty(uint256,string)
function deleteProperty(uint256 tokenId, string memory key) external;
- // @notice Get token property value.
- // @dev Throws error if key not found
- // @param tokenId ID of the token.
- // @param key Property key.
- // @return Property value bytes
- //
- // Selector: property(uint256,string) 7228c327
+ /// @notice Get token property value.
+ /// @dev Throws error if key not found
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @return Property value bytes
+ /// @dev EVM selector for this function is: 0x7228c327,
+ /// or in textual repr: property(uint256,string)
function property(uint256 tokenId, string memory key)
external
view
returns (bytes memory);
}
-// Selector: 42966c68
-interface ERC721Burnable is Dummy, ERC165 {
- // @notice Burns a specific ERC721 token.
- // @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
- // operator of the current owner.
- // @param tokenId The NFT to approve
- //
- // Selector: burn(uint256) 42966c68
- function burn(uint256 tokenId) external;
-}
-
-// Selector: 58800161
-interface ERC721 is Dummy, ERC165, ERC721Events {
- // @notice Count all NFTs assigned to an owner
- // @dev NFTs assigned to the zero address are considered invalid, and this
- // function throws for queries about the zero address.
- // @param owner An address for whom to query the balance
- // @return The number of NFTs owned by `owner`, possibly zero
- //
- // Selector: balanceOf(address) 70a08231
- function balanceOf(address owner) external view returns (uint256);
-
- // @notice Find the owner of an NFT
- // @dev NFTs assigned to zero address are considered invalid, and queries
- // about them do throw.
- // @param tokenId The identifier for an NFT
- // @return The address of the owner of the NFT
- //
- // Selector: ownerOf(uint256) 6352211e
- function ownerOf(uint256 tokenId) external view returns (address);
-
- // @dev Not implemented
- //
- // Selector: safeTransferFromWithData(address,address,uint256,bytes) 60a11672
- function safeTransferFromWithData(
- address from,
- address to,
- uint256 tokenId,
- bytes memory data
- ) external;
-
- // @dev Not implemented
- //
- // Selector: safeTransferFrom(address,address,uint256) 42842e0e
- function safeTransferFrom(
- address from,
- address to,
- uint256 tokenId
- ) external;
-
- // @notice Transfer ownership of an NFT -- THE CALLER IS RESPONSIBLE
- // TO CONFIRM THAT `to` IS CAPABLE OF RECEIVING NFTS OR ELSE
- // THEY MAY BE PERMANENTLY LOST
- // @dev Throws unless `msg.sender` is the current owner or an authorized
- // operator for this NFT. Throws if `from` is not the current owner. Throws
- // if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
- // @param from The current owner of the NFT
- // @param to The new owner
- // @param tokenId The NFT to transfer
- // @param _value Not used for an NFT
- //
- // Selector: transferFrom(address,address,uint256) 23b872dd
- function transferFrom(
- address from,
- address to,
- uint256 tokenId
- ) external;
-
- // @notice Set or reaffirm the approved address for an NFT
- // @dev The zero address indicates there is no approved address.
- // @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
- // operator of the current owner.
- // @param approved The new approved NFT controller
- // @param tokenId The NFT to approve
- //
- // Selector: approve(address,uint256) 095ea7b3
- function approve(address approved, uint256 tokenId) external;
-
- // @dev Not implemented
- //
- // Selector: setApprovalForAll(address,bool) a22cb465
- function setApprovalForAll(address operator, bool approved) external;
-
- // @dev Not implemented
- //
- // Selector: getApproved(uint256) 081812fc
- function getApproved(uint256 tokenId) external view returns (address);
-
- // @dev Not implemented
- //
- // Selector: isApprovedForAll(address,address) e985e9c5
- function isApprovedForAll(address owner, address operator)
- external
- view
- returns (address);
-}
-
-// Selector: 5b5e139f
-interface ERC721Metadata is Dummy, ERC165 {
- // @notice A descriptive name for a collection of NFTs in this contract
- //
- // Selector: name() 06fdde03
- function name() external view returns (string memory);
-
- // @notice An abbreviated name for NFTs in this contract
- //
- // Selector: symbol() 95d89b41
- function symbol() external view returns (string memory);
-
- // @notice A distinct Uniform Resource Identifier (URI) for a given asset.
- //
- // @dev If the token has a `url` property and it is not empty, it is returned.
- // Else If the collection does not have a property with key `schemaName` or its value is not equal to `ERC721Metadata`, it return an error `tokenURI not set`.
- // If the collection property `baseURI` is empty or absent, return "" (empty string)
- // otherwise, if token property `suffix` present and is non-empty, return concatenation of baseURI and suffix
- // otherwise, return concatenation of `baseURI` and stringified token id (decimal stringifying, without paddings).
- //
- // @return token's const_metadata
- //
- // Selector: tokenURI(uint256) c87b56dd
- function tokenURI(uint256 tokenId) external view returns (string memory);
-}
-
-// Selector: 68ccfe89
-interface ERC721Mintable is Dummy, ERC165, ERC721MintableEvents {
- // Selector: mintingFinished() 05d2035b
- function mintingFinished() external view returns (bool);
-
- // @notice Function to mint token.
- // @dev `tokenId` should be obtained with `nextTokenId` method,
- // unlike standard, you can't specify it manually
- // @param to The new owner
- // @param tokenId ID of the minted NFT
- //
- // Selector: mint(address,uint256) 40c10f19
- function mint(address to, uint256 tokenId) external returns (bool);
-
- // @notice Function to mint token with the given tokenUri.
- // @dev `tokenId` should be obtained with `nextTokenId` method,
- // unlike standard, you can't specify it manually
- // @param to The new owner
- // @param tokenId ID of the minted NFT
- // @param tokenUri Token URI that would be stored in the NFT properties
- //
- // Selector: mintWithTokenURI(address,uint256,string) 50bb4e7f
- function mintWithTokenURI(
- address to,
- uint256 tokenId,
- string memory tokenUri
- ) external returns (bool);
-
- // @dev Not implemented
- //
- // Selector: finishMinting() 7d64bcb4
- function finishMinting() external returns (bool);
-}
-
-// Selector: 6cf113cd
+/// @title A contract that allows you to work with collections.
+/// @dev the ERC-165 identifier for this interface is 0xe54be640
interface Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
+ /// Set collection property.
+ ///
+ /// @param key Property key.
+ /// @param value Propery value.
+ /// @dev EVM selector for this function is: 0x2f073f66,
+ /// or in textual repr: setCollectionProperty(string,bytes)
function setCollectionProperty(string memory key, bytes memory value)
external;
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
+ /// Delete collection property.
+ ///
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x7b7debce,
+ /// or in textual repr: deleteCollectionProperty(string)
function deleteCollectionProperty(string memory key) external;
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
+ /// Get collection property.
+ ///
+ /// @dev Throws error if key not found.
+ ///
+ /// @param key Property key.
+ /// @return bytes The property corresponding to the key.
+ /// @dev EVM selector for this function is: 0xcf24fd6d,
+ /// or in textual repr: collectionProperty(string)
function collectionProperty(string memory key)
external
view
returns (bytes memory);
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
+ /// Set the sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0x7623402e,
+ /// or in textual repr: setCollectionSponsor(address)
function setCollectionSponsor(address sponsor) external;
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
+ /// Set the substrate sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Substrate address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0xc74d6751,
+ /// or in textual repr: setCollectionSponsorSubstrate(uint256)
+ function setCollectionSponsorSubstrate(uint256 sponsor) external;
+
+ /// @dev EVM selector for this function is: 0x058ac185,
+ /// or in textual repr: hasCollectionPendingSponsor()
+ function hasCollectionPendingSponsor() external view returns (bool);
+
+ /// Collection sponsorship confirmation.
+ ///
+ /// @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ /// @dev EVM selector for this function is: 0x3c50e97a,
+ /// or in textual repr: confirmCollectionSponsorship()
function confirmCollectionSponsorship() external;
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
+ /// Remove collection sponsor.
+ /// @dev EVM selector for this function is: 0x6e0326a3,
+ /// or in textual repr: removeCollectionSponsor()
+ function removeCollectionSponsor() external;
+
+ /// Get current sponsor.
+ ///
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ /// @dev EVM selector for this function is: 0xb66bbc14,
+ /// or in textual repr: getCollectionSponsor()
+ function getCollectionSponsor() external view returns (Tuple17 memory);
+
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "accountTokenOwnershipLimit",
+ /// "sponsoredDataSize",
+ /// "sponsoredDataRateLimit",
+ /// "tokenLimit",
+ /// "sponsorTransferTimeout",
+ /// "sponsorApproveTimeout"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x6a3841db,
+ /// or in textual repr: setCollectionLimit(string,uint32)
function setCollectionLimit(string memory limit, uint32 value) external;
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "ownerCanTransfer",
+ /// "ownerCanDestroy",
+ /// "transfersEnabled"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x993b7fba,
+ /// or in textual repr: setCollectionLimit(string,bool)
function setCollectionLimit(string memory limit, bool value) external;
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
+ /// Get contract address.
+ /// @dev EVM selector for this function is: 0xf6b4dfb4,
+ /// or in textual repr: contractAddress()
function contractAddress() external view returns (address);
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
+ /// Add collection admin by substrate address.
+ /// @param newAdmin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x5730062b,
+ /// or in textual repr: addCollectionAdminSubstrate(uint256)
function addCollectionAdminSubstrate(uint256 newAdmin) external;
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
+ /// Remove collection admin by substrate address.
+ /// @param admin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x4048fcf9,
+ /// or in textual repr: removeCollectionAdminSubstrate(uint256)
function removeCollectionAdminSubstrate(uint256 admin) external;
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
+ /// Add collection admin.
+ /// @param newAdmin Address of the added administrator.
+ /// @dev EVM selector for this function is: 0x92e462c7,
+ /// or in textual repr: addCollectionAdmin(address)
function addCollectionAdmin(address newAdmin) external;
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
+ /// Remove collection admin.
+ ///
+ /// @param admin Address of the removed administrator.
+ /// @dev EVM selector for this function is: 0xfafd7b42,
+ /// or in textual repr: removeCollectionAdmin(address)
function removeCollectionAdmin(address admin) external;
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ /// @dev EVM selector for this function is: 0x112d4586,
+ /// or in textual repr: setCollectionNesting(bool)
function setCollectionNesting(bool enable) external;
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ /// @param collections Addresses of collections that will be available for nesting.
+ /// @dev EVM selector for this function is: 0x64872396,
+ /// or in textual repr: setCollectionNesting(bool,address[])
function setCollectionNesting(bool enable, address[] memory collections)
external;
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
+ /// Set the collection access method.
+ /// @param mode Access mode
+ /// 0 for Normal
+ /// 1 for AllowList
+ /// @dev EVM selector for this function is: 0x41835d4c,
+ /// or in textual repr: setCollectionAccess(uint8)
function setCollectionAccess(uint8 mode) external;
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
+ /// Add the user to the allowed list.
+ ///
+ /// @param user Address of a trusted user.
+ /// @dev EVM selector for this function is: 0x67844fe6,
+ /// or in textual repr: addToCollectionAllowList(address)
function addToCollectionAllowList(address user) external;
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
+ /// Remove the user from the allowed list.
+ ///
+ /// @param user Address of a removed user.
+ /// @dev EVM selector for this function is: 0x85c51acb,
+ /// or in textual repr: removeFromCollectionAllowList(address)
function removeFromCollectionAllowList(address user) external;
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
+ /// Switch permission for minting.
+ ///
+ /// @param mode Enable if "true".
+ /// @dev EVM selector for this function is: 0x00018e84,
+ /// or in textual repr: setCollectionMintMode(bool)
function setCollectionMintMode(bool mode) external;
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) external view returns (bool);
+ /// Check that account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x9811b0c7,
+ /// or in textual repr: isOwnerOrAdmin(address)
+ function isOwnerOrAdmin(address user) external view returns (bool);
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
+ /// Check that substrate account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x68910e00,
+ /// or in textual repr: isOwnerOrAdminSubstrate(uint256)
+ function isOwnerOrAdminSubstrate(uint256 user) external view returns (bool);
+
+ /// Returns collection type
+ ///
+ /// @return `Fungible` or `NFT` or `ReFungible`
+ /// @dev EVM selector for this function is: 0xd34b55b8,
+ /// or in textual repr: uniqueCollectionType()
function uniqueCollectionType() external returns (string memory);
+
+ /// Changes collection owner to another account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner account
+ /// @dev EVM selector for this function is: 0x13af4035,
+ /// or in textual repr: setOwner(address)
+ function setOwner(address newOwner) external;
+
+ /// Changes collection owner to another substrate account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner substrate account
+ /// @dev EVM selector for this function is: 0xb212138f,
+ /// or in textual repr: setOwnerSubstrate(uint256)
+ function setOwnerSubstrate(uint256 newOwner) external;
}
-// Selector: 780e9d63
-interface ERC721Enumerable is Dummy, ERC165 {
- // @notice Enumerate valid NFTs
- // @param index A counter less than `totalSupply()`
- // @return The token identifier for the `index`th NFT,
- // (sort order not specified)
- //
- // Selector: tokenByIndex(uint256) 4f6ccce7
- function tokenByIndex(uint256 index) external view returns (uint256);
+/// @dev anonymous struct
+struct Tuple17 {
+ address field_0;
+ uint256 field_1;
+}
- // @dev Not implemented
- //
- // Selector: tokenOfOwnerByIndex(address,uint256) 2f745c59
- function tokenOfOwnerByIndex(address owner, uint256 index)
- external
- view
- returns (uint256);
+/// @title ERC721 Token that can be irreversibly burned (destroyed).
+/// @dev the ERC-165 identifier for this interface is 0x42966c68
+interface ERC721Burnable is Dummy, ERC165 {
+ /// @notice Burns a specific ERC721 token.
+ /// @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
+ /// operator of the current owner.
+ /// @param tokenId The NFT to approve
+ /// @dev EVM selector for this function is: 0x42966c68,
+ /// or in textual repr: burn(uint256)
+ function burn(uint256 tokenId) external;
+}
+
+/// @dev inlined interface
+interface ERC721MintableEvents {
+ event MintingFinished();
+}
+
+/// @title ERC721 minting logic.
+/// @dev the ERC-165 identifier for this interface is 0x68ccfe89
+interface ERC721Mintable is Dummy, ERC165, ERC721MintableEvents {
+ /// @dev EVM selector for this function is: 0x05d2035b,
+ /// or in textual repr: mintingFinished()
+ function mintingFinished() external view returns (bool);
+
+ /// @notice Function to mint token.
+ /// @dev `tokenId` should be obtained with `nextTokenId` method,
+ /// unlike standard, you can't specify it manually
+ /// @param to The new owner
+ /// @param tokenId ID of the minted NFT
+ /// @dev EVM selector for this function is: 0x40c10f19,
+ /// or in textual repr: mint(address,uint256)
+ function mint(address to, uint256 tokenId) external returns (bool);
+
+ /// @notice Function to mint token with the given tokenUri.
+ /// @dev `tokenId` should be obtained with `nextTokenId` method,
+ /// unlike standard, you can't specify it manually
+ /// @param to The new owner
+ /// @param tokenId ID of the minted NFT
+ /// @param tokenUri Token URI that would be stored in the NFT properties
+ /// @dev EVM selector for this function is: 0x50bb4e7f,
+ /// or in textual repr: mintWithTokenURI(address,uint256,string)
+ function mintWithTokenURI(
+ address to,
+ uint256 tokenId,
+ string memory tokenUri
+ ) external returns (bool);
- // @notice Count NFTs tracked by this contract
- // @return A count of valid NFTs tracked by this contract, where each one of
- // them has an assigned and queryable owner not equal to the zero address
- //
- // Selector: totalSupply() 18160ddd
- function totalSupply() external view returns (uint256);
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x7d64bcb4,
+ /// or in textual repr: finishMinting()
+ function finishMinting() external returns (bool);
}
-// Selector: d74d154f
+/// @title Unique extensions for ERC721.
+/// @dev the ERC-165 identifier for this interface is 0xd74d154f
interface ERC721UniqueExtensions is Dummy, ERC165 {
- // @notice Transfer ownership of an NFT
- // @dev Throws unless `msg.sender` is the current owner. Throws if `to`
- // is the zero address. Throws if `tokenId` is not a valid NFT.
- // @param to The new owner
- // @param tokenId The NFT to transfer
- // @param _value Not used for an NFT
- //
- // Selector: transfer(address,uint256) a9059cbb
+ /// @notice Transfer ownership of an NFT
+ /// @dev Throws unless `msg.sender` is the current owner. Throws if `to`
+ /// is the zero address. Throws if `tokenId` is not a valid NFT.
+ /// @param to The new owner
+ /// @param tokenId The NFT to transfer
+ /// @dev EVM selector for this function is: 0xa9059cbb,
+ /// or in textual repr: transfer(address,uint256)
function transfer(address to, uint256 tokenId) external;
- // @notice Burns a specific ERC721 token.
- // @dev Throws unless `msg.sender` is the current owner or an authorized
- // operator for this NFT. Throws if `from` is not the current owner. Throws
- // if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
- // @param from The current owner of the NFT
- // @param tokenId The NFT to transfer
- // @param _value Not used for an NFT
- //
- // Selector: burnFrom(address,uint256) 79cc6790
+ /// @notice Burns a specific ERC721 token.
+ /// @dev Throws unless `msg.sender` is the current owner or an authorized
+ /// operator for this NFT. Throws if `from` is not the current owner. Throws
+ /// if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
+ /// @param from The current owner of the NFT
+ /// @param tokenId The NFT to transfer
+ /// @dev EVM selector for this function is: 0x79cc6790,
+ /// or in textual repr: burnFrom(address,uint256)
function burnFrom(address from, uint256 tokenId) external;
- // @notice Returns next free NFT ID.
- //
- // Selector: nextTokenId() 75794a3c
+ /// @notice Returns next free NFT ID.
+ /// @dev EVM selector for this function is: 0x75794a3c,
+ /// or in textual repr: nextTokenId()
function nextTokenId() external view returns (uint256);
- // @notice Function to mint multiple tokens.
- // @dev `tokenIds` should be an array of consecutive numbers and first number
- // should be obtained with `nextTokenId` method
- // @param to The new owner
- // @param tokenIds IDs of the minted NFTs
- //
- // Selector: mintBulk(address,uint256[]) 44a9945e
+ /// @notice Function to mint multiple tokens.
+ /// @dev `tokenIds` should be an array of consecutive numbers and first number
+ /// should be obtained with `nextTokenId` method
+ /// @param to The new owner
+ /// @param tokenIds IDs of the minted NFTs
+ /// @dev EVM selector for this function is: 0x44a9945e,
+ /// or in textual repr: mintBulk(address,uint256[])
function mintBulk(address to, uint256[] memory tokenIds)
external
returns (bool);
- // @notice Function to mint multiple tokens with the given tokenUris.
- // @dev `tokenIds` is array of pairs of token ID and token URI. Token IDs should be consecutive
- // numbers and first number should be obtained with `nextTokenId` method
- // @param to The new owner
- // @param tokens array of pairs of token ID and token URI for minted tokens
- //
- // Selector: mintBulkWithTokenURI(address,(uint256,string)[]) 36543006
- function mintBulkWithTokenURI(address to, Tuple0[] memory tokens)
+ /// @notice Function to mint multiple tokens with the given tokenUris.
+ /// @dev `tokenIds` is array of pairs of token ID and token URI. Token IDs should be consecutive
+ /// numbers and first number should be obtained with `nextTokenId` method
+ /// @param to The new owner
+ /// @param tokens array of pairs of token ID and token URI for minted tokens
+ /// @dev EVM selector for this function is: 0x36543006,
+ /// or in textual repr: mintBulkWithTokenURI(address,(uint256,string)[])
+ function mintBulkWithTokenURI(address to, Tuple8[] memory tokens)
external
returns (bool);
}
+/// @dev anonymous struct
+struct Tuple8 {
+ uint256 field_0;
+ string field_1;
+}
+
+/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
+/// @dev See https://eips.ethereum.org/EIPS/eip-721
+/// @dev the ERC-165 identifier for this interface is 0x780e9d63
+interface ERC721Enumerable is Dummy, ERC165 {
+ /// @notice Enumerate valid NFTs
+ /// @param index A counter less than `totalSupply()`
+ /// @return The token identifier for the `index`th NFT,
+ /// (sort order not specified)
+ /// @dev EVM selector for this function is: 0x4f6ccce7,
+ /// or in textual repr: tokenByIndex(uint256)
+ function tokenByIndex(uint256 index) external view returns (uint256);
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x2f745c59,
+ /// or in textual repr: tokenOfOwnerByIndex(address,uint256)
+ function tokenOfOwnerByIndex(address owner, uint256 index)
+ external
+ view
+ returns (uint256);
+
+ /// @notice Count NFTs tracked by this contract
+ /// @return A count of valid NFTs tracked by this contract, where each one of
+ /// them has an assigned and queryable owner not equal to the zero address
+ /// @dev EVM selector for this function is: 0x18160ddd,
+ /// or in textual repr: totalSupply()
+ function totalSupply() external view returns (uint256);
+}
+
+/// @title ERC-721 Non-Fungible Token Standard, optional metadata extension
+/// @dev See https://eips.ethereum.org/EIPS/eip-721
+/// @dev the ERC-165 identifier for this interface is 0x5b5e139f
+interface ERC721Metadata is Dummy, ERC165 {
+ /// @notice A descriptive name for a collection of NFTs in this contract
+ /// @dev EVM selector for this function is: 0x06fdde03,
+ /// or in textual repr: name()
+ function name() external view returns (string memory);
+
+ /// @notice An abbreviated name for NFTs in this contract
+ /// @dev EVM selector for this function is: 0x95d89b41,
+ /// or in textual repr: symbol()
+ function symbol() external view returns (string memory);
+
+ /// @notice A distinct Uniform Resource Identifier (URI) for a given asset.
+ ///
+ /// @dev If the token has a `url` property and it is not empty, it is returned.
+ /// Else If the collection does not have a property with key `schemaName` or its value is not equal to `ERC721Metadata`, it return an error `tokenURI not set`.
+ /// If the collection property `baseURI` is empty or absent, return "" (empty string)
+ /// otherwise, if token property `suffix` present and is non-empty, return concatenation of baseURI and suffix
+ /// otherwise, return concatenation of `baseURI` and stringified token id (decimal stringifying, without paddings).
+ ///
+ /// @return token's const_metadata
+ /// @dev EVM selector for this function is: 0xc87b56dd,
+ /// or in textual repr: tokenURI(uint256)
+ function tokenURI(uint256 tokenId) external view returns (string memory);
+}
+
+/// @dev inlined interface
+interface ERC721Events {
+ event Transfer(
+ address indexed from,
+ address indexed to,
+ uint256 indexed tokenId
+ );
+ event Approval(
+ address indexed owner,
+ address indexed approved,
+ uint256 indexed tokenId
+ );
+ event ApprovalForAll(
+ address indexed owner,
+ address indexed operator,
+ bool approved
+ );
+}
+
+/// @title ERC-721 Non-Fungible Token Standard
+/// @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md
+/// @dev the ERC-165 identifier for this interface is 0x80ac58cd
+interface ERC721 is Dummy, ERC165, ERC721Events {
+ /// @notice Count all NFTs assigned to an owner
+ /// @dev NFTs assigned to the zero address are considered invalid, and this
+ /// function throws for queries about the zero address.
+ /// @param owner An address for whom to query the balance
+ /// @return The number of NFTs owned by `owner`, possibly zero
+ /// @dev EVM selector for this function is: 0x70a08231,
+ /// or in textual repr: balanceOf(address)
+ function balanceOf(address owner) external view returns (uint256);
+
+ /// @notice Find the owner of an NFT
+ /// @dev NFTs assigned to zero address are considered invalid, and queries
+ /// about them do throw.
+ /// @param tokenId The identifier for an NFT
+ /// @return The address of the owner of the NFT
+ /// @dev EVM selector for this function is: 0x6352211e,
+ /// or in textual repr: ownerOf(uint256)
+ function ownerOf(uint256 tokenId) external view returns (address);
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xb88d4fde,
+ /// or in textual repr: safeTransferFrom(address,address,uint256,bytes)
+ function safeTransferFrom(
+ address from,
+ address to,
+ uint256 tokenId,
+ bytes memory data
+ ) external;
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x42842e0e,
+ /// or in textual repr: safeTransferFrom(address,address,uint256)
+ function safeTransferFrom(
+ address from,
+ address to,
+ uint256 tokenId
+ ) external;
+
+ /// @notice Transfer ownership of an NFT -- THE CALLER IS RESPONSIBLE
+ /// TO CONFIRM THAT `to` IS CAPABLE OF RECEIVING NFTS OR ELSE
+ /// THEY MAY BE PERMANENTLY LOST
+ /// @dev Throws unless `msg.sender` is the current owner or an authorized
+ /// operator for this NFT. Throws if `from` is not the current owner. Throws
+ /// if `to` is the zero address. Throws if `tokenId` is not a valid NFT.
+ /// @param from The current owner of the NFT
+ /// @param to The new owner
+ /// @param tokenId The NFT to transfer
+ /// @dev EVM selector for this function is: 0x23b872dd,
+ /// or in textual repr: transferFrom(address,address,uint256)
+ function transferFrom(
+ address from,
+ address to,
+ uint256 tokenId
+ ) external;
+
+ /// @notice Set or reaffirm the approved address for an NFT
+ /// @dev The zero address indicates there is no approved address.
+ /// @dev Throws unless `msg.sender` is the current NFT owner, or an authorized
+ /// operator of the current owner.
+ /// @param approved The new approved NFT controller
+ /// @param tokenId The NFT to approve
+ /// @dev EVM selector for this function is: 0x095ea7b3,
+ /// or in textual repr: approve(address,uint256)
+ function approve(address approved, uint256 tokenId) external;
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xa22cb465,
+ /// or in textual repr: setApprovalForAll(address,bool)
+ function setApprovalForAll(address operator, bool approved) external;
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x081812fc,
+ /// or in textual repr: getApproved(uint256)
+ function getApproved(uint256 tokenId) external view returns (address);
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xe985e9c5,
+ /// or in textual repr: isApprovedForAll(address,address)
+ function isApprovedForAll(address owner, address operator)
+ external
+ view
+ returns (address);
+}
+
interface UniqueNFT is
Dummy,
ERC165,
tests/src/eth/api/UniqueRefungible.soldiffbeforeafterboth--- a/tests/src/eth/api/UniqueRefungible.sol
+++ b/tests/src/eth/api/UniqueRefungible.sol
@@ -3,13 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Anonymous struct
-struct Tuple0 {
- uint256 field_0;
- string field_1;
-}
-
-// Common stubs holder
+/// @dev common stubs holder
interface Dummy {
}
@@ -18,40 +12,17 @@
function supportsInterface(bytes4 interfaceID) external view returns (bool);
}
-// Inline
-interface ERC721Events {
- event Transfer(
- address indexed from,
- address indexed to,
- uint256 indexed tokenId
- );
- event Approval(
- address indexed owner,
- address indexed approved,
- uint256 indexed tokenId
- );
- event ApprovalForAll(
- address indexed owner,
- address indexed operator,
- bool approved
- );
-}
-
-// Inline
-interface ERC721MintableEvents {
- event MintingFinished();
-}
-
-// Selector: 41369377
+/// @title A contract that allows to set and delete token properties and change token property permissions.
+/// @dev the ERC-165 identifier for this interface is 0x41369377
interface TokenProperties is Dummy, ERC165 {
- // @notice Set permissions for token property.
- // @dev Throws error if `msg.sender` is not admin or owner of the collection.
- // @param key Property key.
- // @param is_mutable Permission to mutate property.
- // @param collection_admin Permission to mutate property by collection admin if property is mutable.
- // @param token_owner Permission to mutate property by token owner if property is mutable.
- //
- // Selector: setTokenPropertyPermission(string,bool,bool,bool) 222d97fa
+ /// @notice Set permissions for token property.
+ /// @dev Throws error if `msg.sender` is not admin or owner of the collection.
+ /// @param key Property key.
+ /// @param isMutable Permission to mutate property.
+ /// @param collectionAdmin Permission to mutate property by collection admin if property is mutable.
+ /// @param tokenOwner Permission to mutate property by token owner if property is mutable.
+ /// @dev EVM selector for this function is: 0x222d97fa,
+ /// or in textual repr: setTokenPropertyPermission(string,bool,bool,bool)
function setTokenPropertyPermission(
string memory key,
bool isMutable,
@@ -59,447 +30,538 @@
bool tokenOwner
) external;
- // @notice Set token property value.
- // @dev Throws error if `msg.sender` has no permission to edit the property.
- // @param tokenId ID of the token.
- // @param key Property key.
- // @param value Property value.
- //
- // Selector: setProperty(uint256,string,bytes) 1752d67b
+ /// @notice Set token property value.
+ /// @dev Throws error if `msg.sender` has no permission to edit the property.
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @param value Property value.
+ /// @dev EVM selector for this function is: 0x1752d67b,
+ /// or in textual repr: setProperty(uint256,string,bytes)
function setProperty(
uint256 tokenId,
string memory key,
bytes memory value
) external;
- // @notice Delete token property value.
- // @dev Throws error if `msg.sender` has no permission to edit the property.
- // @param tokenId ID of the token.
- // @param key Property key.
- //
- // Selector: deleteProperty(uint256,string) 066111d1
+ /// @notice Delete token property value.
+ /// @dev Throws error if `msg.sender` has no permission to edit the property.
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x066111d1,
+ /// or in textual repr: deleteProperty(uint256,string)
function deleteProperty(uint256 tokenId, string memory key) external;
- // @notice Get token property value.
- // @dev Throws error if key not found
- // @param tokenId ID of the token.
- // @param key Property key.
- // @return Property value bytes
- //
- // Selector: property(uint256,string) 7228c327
+ /// @notice Get token property value.
+ /// @dev Throws error if key not found
+ /// @param tokenId ID of the token.
+ /// @param key Property key.
+ /// @return Property value bytes
+ /// @dev EVM selector for this function is: 0x7228c327,
+ /// or in textual repr: property(uint256,string)
function property(uint256 tokenId, string memory key)
external
view
returns (bytes memory);
}
-// Selector: 42966c68
-interface ERC721Burnable is Dummy, ERC165 {
- // @notice Burns a specific ERC721 token.
- // @dev Throws unless `msg.sender` is the current RFT owner, or an authorized
- // operator of the current owner.
- // @param tokenId The RFT to approve
- //
- // Selector: burn(uint256) 42966c68
- function burn(uint256 tokenId) external;
-}
-
-// Selector: 58800161
-interface ERC721 is Dummy, ERC165, ERC721Events {
- // @notice Count all RFTs assigned to an owner
- // @dev RFTs assigned to the zero address are considered invalid, and this
- // function throws for queries about the zero address.
- // @param owner An address for whom to query the balance
- // @return The number of RFTs owned by `owner`, possibly zero
- //
- // Selector: balanceOf(address) 70a08231
- function balanceOf(address owner) external view returns (uint256);
-
- // @notice Find the owner of an RFT
- // @dev RFTs assigned to zero address are considered invalid, and queries
- // about them do throw.
- // Returns special 0xffffffffffffffffffffffffffffffffffffffff address for
- // the tokens that are partially owned.
- // @param tokenId The identifier for an RFT
- // @return The address of the owner of the RFT
- //
- // Selector: ownerOf(uint256) 6352211e
- function ownerOf(uint256 tokenId) external view returns (address);
-
- // @dev Not implemented
- //
- // Selector: safeTransferFromWithData(address,address,uint256,bytes) 60a11672
- function safeTransferFromWithData(
- address from,
- address to,
- uint256 tokenId,
- bytes memory data
- ) external;
-
- // @dev Not implemented
- //
- // Selector: safeTransferFrom(address,address,uint256) 42842e0e
- function safeTransferFrom(
- address from,
- address to,
- uint256 tokenId
- ) external;
-
- // @notice Transfer ownership of an RFT -- THE CALLER IS RESPONSIBLE
- // TO CONFIRM THAT `to` IS CAPABLE OF RECEIVING NFTS OR ELSE
- // THEY MAY BE PERMANENTLY LOST
- // @dev Throws unless `msg.sender` is the current owner or an authorized
- // operator for this RFT. Throws if `from` is not the current owner. Throws
- // if `to` is the zero address. Throws if `tokenId` is not a valid RFT.
- // Throws if RFT pieces have multiple owners.
- // @param from The current owner of the NFT
- // @param to The new owner
- // @param tokenId The NFT to transfer
- // @param _value Not used for an NFT
- //
- // Selector: transferFrom(address,address,uint256) 23b872dd
- function transferFrom(
- address from,
- address to,
- uint256 tokenId
- ) external;
-
- // @dev Not implemented
- //
- // Selector: approve(address,uint256) 095ea7b3
- function approve(address approved, uint256 tokenId) external;
-
- // @dev Not implemented
- //
- // Selector: setApprovalForAll(address,bool) a22cb465
- function setApprovalForAll(address operator, bool approved) external;
-
- // @dev Not implemented
- //
- // Selector: getApproved(uint256) 081812fc
- function getApproved(uint256 tokenId) external view returns (address);
-
- // @dev Not implemented
- //
- // Selector: isApprovedForAll(address,address) e985e9c5
- function isApprovedForAll(address owner, address operator)
- external
- view
- returns (address);
-}
-
-// Selector: 5b5e139f
-interface ERC721Metadata is Dummy, ERC165 {
- // @notice A descriptive name for a collection of RFTs in this contract
- //
- // Selector: name() 06fdde03
- function name() external view returns (string memory);
-
- // @notice An abbreviated name for RFTs in this contract
- //
- // Selector: symbol() 95d89b41
- function symbol() external view returns (string memory);
-
- // @notice A distinct Uniform Resource Identifier (URI) for a given asset.
- //
- // @dev If the token has a `url` property and it is not empty, it is returned.
- // Else If the collection does not have a property with key `schemaName` or its value is not equal to `ERC721Metadata`, it return an error `tokenURI not set`.
- // If the collection property `baseURI` is empty or absent, return "" (empty string)
- // otherwise, if token property `suffix` present and is non-empty, return concatenation of baseURI and suffix
- // otherwise, return concatenation of `baseURI` and stringified token id (decimal stringifying, without paddings).
- //
- // @return token's const_metadata
- //
- // Selector: tokenURI(uint256) c87b56dd
- function tokenURI(uint256 tokenId) external view returns (string memory);
-}
-
-// Selector: 68ccfe89
-interface ERC721Mintable is Dummy, ERC165, ERC721MintableEvents {
- // Selector: mintingFinished() 05d2035b
- function mintingFinished() external view returns (bool);
-
- // @notice Function to mint token.
- // @dev `tokenId` should be obtained with `nextTokenId` method,
- // unlike standard, you can't specify it manually
- // @param to The new owner
- // @param tokenId ID of the minted RFT
- //
- // Selector: mint(address,uint256) 40c10f19
- function mint(address to, uint256 tokenId) external returns (bool);
-
- // @notice Function to mint token with the given tokenUri.
- // @dev `tokenId` should be obtained with `nextTokenId` method,
- // unlike standard, you can't specify it manually
- // @param to The new owner
- // @param tokenId ID of the minted RFT
- // @param tokenUri Token URI that would be stored in the RFT properties
- //
- // Selector: mintWithTokenURI(address,uint256,string) 50bb4e7f
- function mintWithTokenURI(
- address to,
- uint256 tokenId,
- string memory tokenUri
- ) external returns (bool);
-
- // @dev Not implemented
- //
- // Selector: finishMinting() 7d64bcb4
- function finishMinting() external returns (bool);
-}
-
-// Selector: 6cf113cd
+/// @title A contract that allows you to work with collections.
+/// @dev the ERC-165 identifier for this interface is 0xe54be640
interface Collection is Dummy, ERC165 {
- // Set collection property.
- //
- // @param key Property key.
- // @param value Propery value.
- //
- // Selector: setCollectionProperty(string,bytes) 2f073f66
+ /// Set collection property.
+ ///
+ /// @param key Property key.
+ /// @param value Propery value.
+ /// @dev EVM selector for this function is: 0x2f073f66,
+ /// or in textual repr: setCollectionProperty(string,bytes)
function setCollectionProperty(string memory key, bytes memory value)
external;
- // Delete collection property.
- //
- // @param key Property key.
- //
- // Selector: deleteCollectionProperty(string) 7b7debce
+ /// Delete collection property.
+ ///
+ /// @param key Property key.
+ /// @dev EVM selector for this function is: 0x7b7debce,
+ /// or in textual repr: deleteCollectionProperty(string)
function deleteCollectionProperty(string memory key) external;
- // Get collection property.
- //
- // @dev Throws error if key not found.
- //
- // @param key Property key.
- // @return bytes The property corresponding to the key.
- //
- // Selector: collectionProperty(string) cf24fd6d
+ /// Get collection property.
+ ///
+ /// @dev Throws error if key not found.
+ ///
+ /// @param key Property key.
+ /// @return bytes The property corresponding to the key.
+ /// @dev EVM selector for this function is: 0xcf24fd6d,
+ /// or in textual repr: collectionProperty(string)
function collectionProperty(string memory key)
external
view
returns (bytes memory);
- // Set the sponsor of the collection.
- //
- // @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
- //
- // @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
- //
- // Selector: setCollectionSponsor(address) 7623402e
+ /// Set the sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0x7623402e,
+ /// or in textual repr: setCollectionSponsor(address)
function setCollectionSponsor(address sponsor) external;
- // Collection sponsorship confirmation.
- //
- // @dev After setting the sponsor for the collection, it must be confirmed with this function.
- //
- // Selector: confirmCollectionSponsorship() 3c50e97a
+ /// Set the substrate sponsor of the collection.
+ ///
+ /// @dev In order for sponsorship to work, it must be confirmed on behalf of the sponsor.
+ ///
+ /// @param sponsor Substrate address of the sponsor from whose account funds will be debited for operations with the contract.
+ /// @dev EVM selector for this function is: 0xc74d6751,
+ /// or in textual repr: setCollectionSponsorSubstrate(uint256)
+ function setCollectionSponsorSubstrate(uint256 sponsor) external;
+
+ /// @dev EVM selector for this function is: 0x058ac185,
+ /// or in textual repr: hasCollectionPendingSponsor()
+ function hasCollectionPendingSponsor() external view returns (bool);
+
+ /// Collection sponsorship confirmation.
+ ///
+ /// @dev After setting the sponsor for the collection, it must be confirmed with this function.
+ /// @dev EVM selector for this function is: 0x3c50e97a,
+ /// or in textual repr: confirmCollectionSponsorship()
function confirmCollectionSponsorship() external;
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "accountTokenOwnershipLimit",
- // "sponsoredDataSize",
- // "sponsoredDataRateLimit",
- // "tokenLimit",
- // "sponsorTransferTimeout",
- // "sponsorApproveTimeout"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,uint32) 6a3841db
+ /// Remove collection sponsor.
+ /// @dev EVM selector for this function is: 0x6e0326a3,
+ /// or in textual repr: removeCollectionSponsor()
+ function removeCollectionSponsor() external;
+
+ /// Get current sponsor.
+ ///
+ /// @return Tuble with sponsor address and his substrate mirror. If there is no confirmed sponsor error "Contract has no sponsor" throw.
+ /// @dev EVM selector for this function is: 0xb66bbc14,
+ /// or in textual repr: getCollectionSponsor()
+ function getCollectionSponsor() external view returns (Tuple17 memory);
+
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "accountTokenOwnershipLimit",
+ /// "sponsoredDataSize",
+ /// "sponsoredDataRateLimit",
+ /// "tokenLimit",
+ /// "sponsorTransferTimeout",
+ /// "sponsorApproveTimeout"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x6a3841db,
+ /// or in textual repr: setCollectionLimit(string,uint32)
function setCollectionLimit(string memory limit, uint32 value) external;
- // Set limits for the collection.
- // @dev Throws error if limit not found.
- // @param limit Name of the limit. Valid names:
- // "ownerCanTransfer",
- // "ownerCanDestroy",
- // "transfersEnabled"
- // @param value Value of the limit.
- //
- // Selector: setCollectionLimit(string,bool) 993b7fba
+ /// Set limits for the collection.
+ /// @dev Throws error if limit not found.
+ /// @param limit Name of the limit. Valid names:
+ /// "ownerCanTransfer",
+ /// "ownerCanDestroy",
+ /// "transfersEnabled"
+ /// @param value Value of the limit.
+ /// @dev EVM selector for this function is: 0x993b7fba,
+ /// or in textual repr: setCollectionLimit(string,bool)
function setCollectionLimit(string memory limit, bool value) external;
- // Get contract address.
- //
- // Selector: contractAddress() f6b4dfb4
+ /// Get contract address.
+ /// @dev EVM selector for this function is: 0xf6b4dfb4,
+ /// or in textual repr: contractAddress()
function contractAddress() external view returns (address);
- // Add collection admin by substrate address.
- // @param new_admin Substrate administrator address.
- //
- // Selector: addCollectionAdminSubstrate(uint256) 5730062b
+ /// Add collection admin by substrate address.
+ /// @param newAdmin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x5730062b,
+ /// or in textual repr: addCollectionAdminSubstrate(uint256)
function addCollectionAdminSubstrate(uint256 newAdmin) external;
- // Remove collection admin by substrate address.
- // @param admin Substrate administrator address.
- //
- // Selector: removeCollectionAdminSubstrate(uint256) 4048fcf9
+ /// Remove collection admin by substrate address.
+ /// @param admin Substrate administrator address.
+ /// @dev EVM selector for this function is: 0x4048fcf9,
+ /// or in textual repr: removeCollectionAdminSubstrate(uint256)
function removeCollectionAdminSubstrate(uint256 admin) external;
- // Add collection admin.
- // @param new_admin Address of the added administrator.
- //
- // Selector: addCollectionAdmin(address) 92e462c7
+ /// Add collection admin.
+ /// @param newAdmin Address of the added administrator.
+ /// @dev EVM selector for this function is: 0x92e462c7,
+ /// or in textual repr: addCollectionAdmin(address)
function addCollectionAdmin(address newAdmin) external;
- // Remove collection admin.
- //
- // @param new_admin Address of the removed administrator.
- //
- // Selector: removeCollectionAdmin(address) fafd7b42
+ /// Remove collection admin.
+ ///
+ /// @param admin Address of the removed administrator.
+ /// @dev EVM selector for this function is: 0xfafd7b42,
+ /// or in textual repr: removeCollectionAdmin(address)
function removeCollectionAdmin(address admin) external;
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
- //
- // Selector: setCollectionNesting(bool) 112d4586
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: 'Owner' else to nesting: 'Disabled'
+ /// @dev EVM selector for this function is: 0x112d4586,
+ /// or in textual repr: setCollectionNesting(bool)
function setCollectionNesting(bool enable) external;
- // Toggle accessibility of collection nesting.
- //
- // @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
- // @param collections Addresses of collections that will be available for nesting.
- //
- // Selector: setCollectionNesting(bool,address[]) 64872396
+ /// Toggle accessibility of collection nesting.
+ ///
+ /// @param enable If "true" degenerates to nesting: {OwnerRestricted: [1, 2, 3]} else to nesting: 'Disabled'
+ /// @param collections Addresses of collections that will be available for nesting.
+ /// @dev EVM selector for this function is: 0x64872396,
+ /// or in textual repr: setCollectionNesting(bool,address[])
function setCollectionNesting(bool enable, address[] memory collections)
external;
- // Set the collection access method.
- // @param mode Access mode
- // 0 for Normal
- // 1 for AllowList
- //
- // Selector: setCollectionAccess(uint8) 41835d4c
+ /// Set the collection access method.
+ /// @param mode Access mode
+ /// 0 for Normal
+ /// 1 for AllowList
+ /// @dev EVM selector for this function is: 0x41835d4c,
+ /// or in textual repr: setCollectionAccess(uint8)
function setCollectionAccess(uint8 mode) external;
- // Add the user to the allowed list.
- //
- // @param user Address of a trusted user.
- //
- // Selector: addToCollectionAllowList(address) 67844fe6
+ /// Add the user to the allowed list.
+ ///
+ /// @param user Address of a trusted user.
+ /// @dev EVM selector for this function is: 0x67844fe6,
+ /// or in textual repr: addToCollectionAllowList(address)
function addToCollectionAllowList(address user) external;
- // Remove the user from the allowed list.
- //
- // @param user Address of a removed user.
- //
- // Selector: removeFromCollectionAllowList(address) 85c51acb
+ /// Remove the user from the allowed list.
+ ///
+ /// @param user Address of a removed user.
+ /// @dev EVM selector for this function is: 0x85c51acb,
+ /// or in textual repr: removeFromCollectionAllowList(address)
function removeFromCollectionAllowList(address user) external;
- // Switch permission for minting.
- //
- // @param mode Enable if "true".
- //
- // Selector: setCollectionMintMode(bool) 00018e84
+ /// Switch permission for minting.
+ ///
+ /// @param mode Enable if "true".
+ /// @dev EVM selector for this function is: 0x00018e84,
+ /// or in textual repr: setCollectionMintMode(bool)
function setCollectionMintMode(bool mode) external;
- // Check that account is the owner or admin of the collection
- //
- // @param user account to verify
- // @return "true" if account is the owner or admin
- //
- // Selector: verifyOwnerOrAdmin(address) c2282493
- function verifyOwnerOrAdmin(address user) external view returns (bool);
+ /// Check that account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x9811b0c7,
+ /// or in textual repr: isOwnerOrAdmin(address)
+ function isOwnerOrAdmin(address user) external view returns (bool);
- // Returns collection type
- //
- // @return `Fungible` or `NFT` or `ReFungible`
- //
- // Selector: uniqueCollectionType() d34b55b8
+ /// Check that substrate account is the owner or admin of the collection
+ ///
+ /// @param user account to verify
+ /// @return "true" if account is the owner or admin
+ /// @dev EVM selector for this function is: 0x68910e00,
+ /// or in textual repr: isOwnerOrAdminSubstrate(uint256)
+ function isOwnerOrAdminSubstrate(uint256 user) external view returns (bool);
+
+ /// Returns collection type
+ ///
+ /// @return `Fungible` or `NFT` or `ReFungible`
+ /// @dev EVM selector for this function is: 0xd34b55b8,
+ /// or in textual repr: uniqueCollectionType()
function uniqueCollectionType() external returns (string memory);
+
+ /// Changes collection owner to another account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner account
+ /// @dev EVM selector for this function is: 0x13af4035,
+ /// or in textual repr: setOwner(address)
+ function setOwner(address newOwner) external;
+
+ /// Changes collection owner to another substrate account
+ ///
+ /// @dev Owner can be changed only by current owner
+ /// @param newOwner new owner substrate account
+ /// @dev EVM selector for this function is: 0xb212138f,
+ /// or in textual repr: setOwnerSubstrate(uint256)
+ function setOwnerSubstrate(uint256 newOwner) external;
+}
+
+/// @dev anonymous struct
+struct Tuple17 {
+ address field_0;
+ uint256 field_1;
}
-// Selector: 780e9d63
-interface ERC721Enumerable is Dummy, ERC165 {
- // @notice Enumerate valid RFTs
- // @param index A counter less than `totalSupply()`
- // @return The token identifier for the `index`th NFT,
- // (sort order not specified)
- //
- // Selector: tokenByIndex(uint256) 4f6ccce7
- function tokenByIndex(uint256 index) external view returns (uint256);
+/// @title ERC721 Token that can be irreversibly burned (destroyed).
+/// @dev the ERC-165 identifier for this interface is 0x42966c68
+interface ERC721Burnable is Dummy, ERC165 {
+ /// @notice Burns a specific ERC721 token.
+ /// @dev Throws unless `msg.sender` is the current RFT owner, or an authorized
+ /// operator of the current owner.
+ /// @param tokenId The RFT to approve
+ /// @dev EVM selector for this function is: 0x42966c68,
+ /// or in textual repr: burn(uint256)
+ function burn(uint256 tokenId) external;
+}
+
+/// @dev inlined interface
+interface ERC721MintableEvents {
+ event MintingFinished();
+}
+
+/// @title ERC721 minting logic.
+/// @dev the ERC-165 identifier for this interface is 0x68ccfe89
+interface ERC721Mintable is Dummy, ERC165, ERC721MintableEvents {
+ /// @dev EVM selector for this function is: 0x05d2035b,
+ /// or in textual repr: mintingFinished()
+ function mintingFinished() external view returns (bool);
- // Not implemented
- //
- // Selector: tokenOfOwnerByIndex(address,uint256) 2f745c59
- function tokenOfOwnerByIndex(address owner, uint256 index)
- external
- view
- returns (uint256);
+ /// @notice Function to mint token.
+ /// @dev `tokenId` should be obtained with `nextTokenId` method,
+ /// unlike standard, you can't specify it manually
+ /// @param to The new owner
+ /// @param tokenId ID of the minted RFT
+ /// @dev EVM selector for this function is: 0x40c10f19,
+ /// or in textual repr: mint(address,uint256)
+ function mint(address to, uint256 tokenId) external returns (bool);
+
+ /// @notice Function to mint token with the given tokenUri.
+ /// @dev `tokenId` should be obtained with `nextTokenId` method,
+ /// unlike standard, you can't specify it manually
+ /// @param to The new owner
+ /// @param tokenId ID of the minted RFT
+ /// @param tokenUri Token URI that would be stored in the RFT properties
+ /// @dev EVM selector for this function is: 0x50bb4e7f,
+ /// or in textual repr: mintWithTokenURI(address,uint256,string)
+ function mintWithTokenURI(
+ address to,
+ uint256 tokenId,
+ string memory tokenUri
+ ) external returns (bool);
- // @notice Count RFTs tracked by this contract
- // @return A count of valid RFTs tracked by this contract, where each one of
- // them has an assigned and queryable owner not equal to the zero address
- //
- // Selector: totalSupply() 18160ddd
- function totalSupply() external view returns (uint256);
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x7d64bcb4,
+ /// or in textual repr: finishMinting()
+ function finishMinting() external returns (bool);
}
-// Selector: 7c3bef89
+/// @title Unique extensions for ERC721.
+/// @dev the ERC-165 identifier for this interface is 0x7c3bef89
interface ERC721UniqueExtensions is Dummy, ERC165 {
- // @notice Transfer ownership of an RFT
- // @dev Throws unless `msg.sender` is the current owner. Throws if `to`
- // is the zero address. Throws if `tokenId` is not a valid RFT.
- // Throws if RFT pieces have multiple owners.
- // @param to The new owner
- // @param tokenId The RFT to transfer
- // @param _value Not used for an RFT
- //
- // Selector: transfer(address,uint256) a9059cbb
+ /// @notice Transfer ownership of an RFT
+ /// @dev Throws unless `msg.sender` is the current owner. Throws if `to`
+ /// is the zero address. Throws if `tokenId` is not a valid RFT.
+ /// Throws if RFT pieces have multiple owners.
+ /// @param to The new owner
+ /// @param tokenId The RFT to transfer
+ /// @dev EVM selector for this function is: 0xa9059cbb,
+ /// or in textual repr: transfer(address,uint256)
function transfer(address to, uint256 tokenId) external;
- // @notice Burns a specific ERC721 token.
- // @dev Throws unless `msg.sender` is the current owner or an authorized
- // operator for this RFT. Throws if `from` is not the current owner. Throws
- // if `to` is the zero address. Throws if `tokenId` is not a valid RFT.
- // Throws if RFT pieces have multiple owners.
- // @param from The current owner of the RFT
- // @param tokenId The RFT to transfer
- // @param _value Not used for an RFT
- //
- // Selector: burnFrom(address,uint256) 79cc6790
+ /// @notice Burns a specific ERC721 token.
+ /// @dev Throws unless `msg.sender` is the current owner or an authorized
+ /// operator for this RFT. Throws if `from` is not the current owner. Throws
+ /// if `to` is the zero address. Throws if `tokenId` is not a valid RFT.
+ /// Throws if RFT pieces have multiple owners.
+ /// @param from The current owner of the RFT
+ /// @param tokenId The RFT to transfer
+ /// @dev EVM selector for this function is: 0x79cc6790,
+ /// or in textual repr: burnFrom(address,uint256)
function burnFrom(address from, uint256 tokenId) external;
- // @notice Returns next free RFT ID.
- //
- // Selector: nextTokenId() 75794a3c
+ /// @notice Returns next free RFT ID.
+ /// @dev EVM selector for this function is: 0x75794a3c,
+ /// or in textual repr: nextTokenId()
function nextTokenId() external view returns (uint256);
- // @notice Function to mint multiple tokens.
- // @dev `tokenIds` should be an array of consecutive numbers and first number
- // should be obtained with `nextTokenId` method
- // @param to The new owner
- // @param tokenIds IDs of the minted RFTs
- //
- // Selector: mintBulk(address,uint256[]) 44a9945e
+ /// @notice Function to mint multiple tokens.
+ /// @dev `tokenIds` should be an array of consecutive numbers and first number
+ /// should be obtained with `nextTokenId` method
+ /// @param to The new owner
+ /// @param tokenIds IDs of the minted RFTs
+ /// @dev EVM selector for this function is: 0x44a9945e,
+ /// or in textual repr: mintBulk(address,uint256[])
function mintBulk(address to, uint256[] memory tokenIds)
external
returns (bool);
- // @notice Function to mint multiple tokens with the given tokenUris.
- // @dev `tokenIds` is array of pairs of token ID and token URI. Token IDs should be consecutive
- // numbers and first number should be obtained with `nextTokenId` method
- // @param to The new owner
- // @param tokens array of pairs of token ID and token URI for minted tokens
- //
- // Selector: mintBulkWithTokenURI(address,(uint256,string)[]) 36543006
- function mintBulkWithTokenURI(address to, Tuple0[] memory tokens)
+ /// @notice Function to mint multiple tokens with the given tokenUris.
+ /// @dev `tokenIds` is array of pairs of token ID and token URI. Token IDs should be consecutive
+ /// numbers and first number should be obtained with `nextTokenId` method
+ /// @param to The new owner
+ /// @param tokens array of pairs of token ID and token URI for minted tokens
+ /// @dev EVM selector for this function is: 0x36543006,
+ /// or in textual repr: mintBulkWithTokenURI(address,(uint256,string)[])
+ function mintBulkWithTokenURI(address to, Tuple8[] memory tokens)
external
returns (bool);
- // Returns EVM address for refungible token
- //
- // @param token ID of the token
- //
- // Selector: tokenContractAddress(uint256) ab76fac6
+ /// Returns EVM address for refungible token
+ ///
+ /// @param token ID of the token
+ /// @dev EVM selector for this function is: 0xab76fac6,
+ /// or in textual repr: tokenContractAddress(uint256)
function tokenContractAddress(uint256 token)
external
view
returns (address);
}
+/// @dev anonymous struct
+struct Tuple8 {
+ uint256 field_0;
+ string field_1;
+}
+
+/// @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
+/// @dev See https://eips.ethereum.org/EIPS/eip-721
+/// @dev the ERC-165 identifier for this interface is 0x780e9d63
+interface ERC721Enumerable is Dummy, ERC165 {
+ /// @notice Enumerate valid RFTs
+ /// @param index A counter less than `totalSupply()`
+ /// @return The token identifier for the `index`th NFT,
+ /// (sort order not specified)
+ /// @dev EVM selector for this function is: 0x4f6ccce7,
+ /// or in textual repr: tokenByIndex(uint256)
+ function tokenByIndex(uint256 index) external view returns (uint256);
+
+ /// Not implemented
+ /// @dev EVM selector for this function is: 0x2f745c59,
+ /// or in textual repr: tokenOfOwnerByIndex(address,uint256)
+ function tokenOfOwnerByIndex(address owner, uint256 index)
+ external
+ view
+ returns (uint256);
+
+ /// @notice Count RFTs tracked by this contract
+ /// @return A count of valid RFTs tracked by this contract, where each one of
+ /// them has an assigned and queryable owner not equal to the zero address
+ /// @dev EVM selector for this function is: 0x18160ddd,
+ /// or in textual repr: totalSupply()
+ function totalSupply() external view returns (uint256);
+}
+
+/// @dev the ERC-165 identifier for this interface is 0x5b5e139f
+interface ERC721Metadata is Dummy, ERC165 {
+ /// @notice A descriptive name for a collection of RFTs in this contract
+ /// @dev EVM selector for this function is: 0x06fdde03,
+ /// or in textual repr: name()
+ function name() external view returns (string memory);
+
+ /// @notice An abbreviated name for RFTs in this contract
+ /// @dev EVM selector for this function is: 0x95d89b41,
+ /// or in textual repr: symbol()
+ function symbol() external view returns (string memory);
+
+ /// @notice A distinct Uniform Resource Identifier (URI) for a given asset.
+ ///
+ /// @dev If the token has a `url` property and it is not empty, it is returned.
+ /// Else If the collection does not have a property with key `schemaName` or its value is not equal to `ERC721Metadata`, it return an error `tokenURI not set`.
+ /// If the collection property `baseURI` is empty or absent, return "" (empty string)
+ /// otherwise, if token property `suffix` present and is non-empty, return concatenation of baseURI and suffix
+ /// otherwise, return concatenation of `baseURI` and stringified token id (decimal stringifying, without paddings).
+ ///
+ /// @return token's const_metadata
+ /// @dev EVM selector for this function is: 0xc87b56dd,
+ /// or in textual repr: tokenURI(uint256)
+ function tokenURI(uint256 tokenId) external view returns (string memory);
+}
+
+/// @dev inlined interface
+interface ERC721Events {
+ event Transfer(
+ address indexed from,
+ address indexed to,
+ uint256 indexed tokenId
+ );
+ event Approval(
+ address indexed owner,
+ address indexed approved,
+ uint256 indexed tokenId
+ );
+ event ApprovalForAll(
+ address indexed owner,
+ address indexed operator,
+ bool approved
+ );
+}
+
+/// @title ERC-721 Non-Fungible Token Standard
+/// @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-721.md
+/// @dev the ERC-165 identifier for this interface is 0x58800161
+interface ERC721 is Dummy, ERC165, ERC721Events {
+ /// @notice Count all RFTs assigned to an owner
+ /// @dev RFTs assigned to the zero address are considered invalid, and this
+ /// function throws for queries about the zero address.
+ /// @param owner An address for whom to query the balance
+ /// @return The number of RFTs owned by `owner`, possibly zero
+ /// @dev EVM selector for this function is: 0x70a08231,
+ /// or in textual repr: balanceOf(address)
+ function balanceOf(address owner) external view returns (uint256);
+
+ /// @notice Find the owner of an RFT
+ /// @dev RFTs assigned to zero address are considered invalid, and queries
+ /// about them do throw.
+ /// Returns special 0xffffffffffffffffffffffffffffffffffffffff address for
+ /// the tokens that are partially owned.
+ /// @param tokenId The identifier for an RFT
+ /// @return The address of the owner of the RFT
+ /// @dev EVM selector for this function is: 0x6352211e,
+ /// or in textual repr: ownerOf(uint256)
+ function ownerOf(uint256 tokenId) external view returns (address);
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x60a11672,
+ /// or in textual repr: safeTransferFromWithData(address,address,uint256,bytes)
+ function safeTransferFromWithData(
+ address from,
+ address to,
+ uint256 tokenId,
+ bytes memory data
+ ) external;
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x42842e0e,
+ /// or in textual repr: safeTransferFrom(address,address,uint256)
+ function safeTransferFrom(
+ address from,
+ address to,
+ uint256 tokenId
+ ) external;
+
+ /// @notice Transfer ownership of an RFT -- THE CALLER IS RESPONSIBLE
+ /// TO CONFIRM THAT `to` IS CAPABLE OF RECEIVING NFTS OR ELSE
+ /// THEY MAY BE PERMANENTLY LOST
+ /// @dev Throws unless `msg.sender` is the current owner or an authorized
+ /// operator for this RFT. Throws if `from` is not the current owner. Throws
+ /// if `to` is the zero address. Throws if `tokenId` is not a valid RFT.
+ /// Throws if RFT pieces have multiple owners.
+ /// @param from The current owner of the NFT
+ /// @param to The new owner
+ /// @param tokenId The NFT to transfer
+ /// @dev EVM selector for this function is: 0x23b872dd,
+ /// or in textual repr: transferFrom(address,address,uint256)
+ function transferFrom(
+ address from,
+ address to,
+ uint256 tokenId
+ ) external;
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x095ea7b3,
+ /// or in textual repr: approve(address,uint256)
+ function approve(address approved, uint256 tokenId) external;
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xa22cb465,
+ /// or in textual repr: setApprovalForAll(address,bool)
+ function setApprovalForAll(address operator, bool approved) external;
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0x081812fc,
+ /// or in textual repr: getApproved(uint256)
+ function getApproved(uint256 tokenId) external view returns (address);
+
+ /// @dev Not implemented
+ /// @dev EVM selector for this function is: 0xe985e9c5,
+ /// or in textual repr: isApprovedForAll(address,address)
+ function isApprovedForAll(address owner, address operator)
+ external
+ view
+ returns (address);
+}
+
interface UniqueRefungible is
Dummy,
ERC165,
tests/src/eth/api/UniqueRefungibleToken.soldiffbeforeafterboth--- a/tests/src/eth/api/UniqueRefungibleToken.sol
+++ b/tests/src/eth/api/UniqueRefungibleToken.sol
@@ -3,7 +3,7 @@
pragma solidity >=0.8.0 <0.9.0;
-// Common stubs holder
+/// @dev common stubs holder
interface Dummy {
}
@@ -12,7 +12,36 @@
function supportsInterface(bytes4 interfaceID) external view returns (bool);
}
-// Inline
+/// @dev the ERC-165 identifier for this interface is 0x5755c3f2
+interface ERC1633 is Dummy, ERC165 {
+ /// @dev EVM selector for this function is: 0x80a54001,
+ /// or in textual repr: parentToken()
+ function parentToken() external view returns (address);
+
+ /// @dev EVM selector for this function is: 0xd7f083f3,
+ /// or in textual repr: parentTokenId()
+ function parentTokenId() external view returns (uint256);
+}
+
+/// @dev the ERC-165 identifier for this interface is 0xab8deb37
+interface ERC20UniqueExtensions is Dummy, ERC165 {
+ /// @dev Function that burns an amount of the token of a given account,
+ /// deducting from the sender's allowance for said account.
+ /// @param from The account whose tokens will be burnt.
+ /// @param amount The amount that will be burnt.
+ /// @dev EVM selector for this function is: 0x79cc6790,
+ /// or in textual repr: burnFrom(address,uint256)
+ function burnFrom(address from, uint256 amount) external returns (bool);
+
+ /// @dev Function that changes total amount of the tokens.
+ /// Throws if `msg.sender` doesn't owns all of the tokens.
+ /// @param amount New total amount of the tokens.
+ /// @dev EVM selector for this function is: 0xd2418ca7,
+ /// or in textual repr: repartition(uint256)
+ function repartition(uint256 amount) external returns (bool);
+}
+
+/// @dev inlined interface
interface ERC20Events {
event Transfer(address indexed from, address indexed to, uint256 value);
event Approval(
@@ -22,110 +51,79 @@
);
}
-// Selector: 042f1106
-interface ERC1633UniqueExtensions is Dummy, ERC165 {
- // Selector: setParentNFT(address,uint256) 042f1106
- function setParentNFT(address collection, uint256 nftId)
- external
- returns (bool);
-}
-
-// Selector: 5755c3f2
-interface ERC1633 is Dummy, ERC165 {
- // Selector: parentToken() 80a54001
- function parentToken() external view returns (address);
-
- // Selector: parentTokenId() d7f083f3
- function parentTokenId() external view returns (uint256);
-}
-
-// Selector: 942e8b22
+/// @title Standard ERC20 token
+///
+/// @dev Implementation of the basic standard token.
+/// https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md
+/// @dev the ERC-165 identifier for this interface is 0x942e8b22
interface ERC20 is Dummy, ERC165, ERC20Events {
- // @return the name of the token.
- //
- // Selector: name() 06fdde03
+ /// @return the name of the token.
+ /// @dev EVM selector for this function is: 0x06fdde03,
+ /// or in textual repr: name()
function name() external view returns (string memory);
- // @return the symbol of the token.
- //
- // Selector: symbol() 95d89b41
+ /// @return the symbol of the token.
+ /// @dev EVM selector for this function is: 0x95d89b41,
+ /// or in textual repr: symbol()
function symbol() external view returns (string memory);
- // @dev Total number of tokens in existence
- //
- // Selector: totalSupply() 18160ddd
+ /// @dev Total number of tokens in existence
+ /// @dev EVM selector for this function is: 0x18160ddd,
+ /// or in textual repr: totalSupply()
function totalSupply() external view returns (uint256);
- // @dev Not supported
- //
- // Selector: decimals() 313ce567
+ /// @dev Not supported
+ /// @dev EVM selector for this function is: 0x313ce567,
+ /// or in textual repr: decimals()
function decimals() external view returns (uint8);
- // @dev Gets the balance of the specified address.
- // @param owner The address to query the balance of.
- // @return An uint256 representing the amount owned by the passed address.
- //
- // Selector: balanceOf(address) 70a08231
+ /// @dev Gets the balance of the specified address.
+ /// @param owner The address to query the balance of.
+ /// @return An uint256 representing the amount owned by the passed address.
+ /// @dev EVM selector for this function is: 0x70a08231,
+ /// or in textual repr: balanceOf(address)
function balanceOf(address owner) external view returns (uint256);
- // @dev Transfer token for a specified address
- // @param to The address to transfer to.
- // @param amount The amount to be transferred.
- //
- // Selector: transfer(address,uint256) a9059cbb
+ /// @dev Transfer token for a specified address
+ /// @param to The address to transfer to.
+ /// @param amount The amount to be transferred.
+ /// @dev EVM selector for this function is: 0xa9059cbb,
+ /// or in textual repr: transfer(address,uint256)
function transfer(address to, uint256 amount) external returns (bool);
- // @dev Transfer tokens from one address to another
- // @param from address The address which you want to send tokens from
- // @param to address The address which you want to transfer to
- // @param amount uint256 the amount of tokens to be transferred
- //
- // Selector: transferFrom(address,address,uint256) 23b872dd
+ /// @dev Transfer tokens from one address to another
+ /// @param from address The address which you want to send tokens from
+ /// @param to address The address which you want to transfer to
+ /// @param amount uint256 the amount of tokens to be transferred
+ /// @dev EVM selector for this function is: 0x23b872dd,
+ /// or in textual repr: transferFrom(address,address,uint256)
function transferFrom(
address from,
address to,
uint256 amount
) external returns (bool);
- // @dev Approve the passed address to spend the specified amount of tokens on behalf of `msg.sender`.
- // Beware that changing an allowance with this method brings the risk that someone may use both the old
- // and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this
- // race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards:
- // https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
- // @param spender The address which will spend the funds.
- // @param amount The amount of tokens to be spent.
- //
- // Selector: approve(address,uint256) 095ea7b3
+ /// @dev Approve the passed address to spend the specified amount of tokens on behalf of `msg.sender`.
+ /// Beware that changing an allowance with this method brings the risk that someone may use both the old
+ /// and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this
+ /// race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards:
+ /// https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
+ /// @param spender The address which will spend the funds.
+ /// @param amount The amount of tokens to be spent.
+ /// @dev EVM selector for this function is: 0x095ea7b3,
+ /// or in textual repr: approve(address,uint256)
function approve(address spender, uint256 amount) external returns (bool);
- // @dev Function to check the amount of tokens that an owner allowed to a spender.
- // @param owner address The address which owns the funds.
- // @param spender address The address which will spend the funds.
- // @return A uint256 specifying the amount of tokens still available for the spender.
- //
- // Selector: allowance(address,address) dd62ed3e
+ /// @dev Function to check the amount of tokens that an owner allowed to a spender.
+ /// @param owner address The address which owns the funds.
+ /// @param spender address The address which will spend the funds.
+ /// @return A uint256 specifying the amount of tokens still available for the spender.
+ /// @dev EVM selector for this function is: 0xdd62ed3e,
+ /// or in textual repr: allowance(address,address)
function allowance(address owner, address spender)
external
view
returns (uint256);
-}
-
-// Selector: ab8deb37
-interface ERC20UniqueExtensions is Dummy, ERC165 {
- // @dev Function that burns an amount of the token of a given account,
- // deducting from the sender's allowance for said account.
- // @param from The account whose tokens will be burnt.
- // @param amount The amount that will be burnt.
- //
- // Selector: burnFrom(address,uint256) 79cc6790
- function burnFrom(address from, uint256 amount) external returns (bool);
-
- // @dev Function that changes total amount of the tokens.
- // Throws if `msg.sender` doesn't owns all of the tokens.
- // @param amount New total amount of the tokens.
- //
- // Selector: repartition(uint256) d2418ca7
- function repartition(uint256 amount) external returns (bool);
}
interface UniqueRefungibleToken is
@@ -133,6 +131,5 @@
ERC165,
ERC20,
ERC20UniqueExtensions,
- ERC1633,
- ERC1633UniqueExtensions
+ ERC1633
{}
tests/src/eth/base.test.tsdiffbeforeafterboth--- a/tests/src/eth/base.test.ts
+++ b/tests/src/eth/base.test.ts
@@ -94,7 +94,7 @@
});
itWeb3('ERC721 support', async ({web3}) => {
- expect(await contract(web3).methods.supportsInterface('0x58800161').call()).to.be.true;
+ expect(await contract(web3).methods.supportsInterface('0x780e9d63').call()).to.be.true;
});
itWeb3('ERC721Metadata support', async ({web3}) => {
tests/src/eth/collectionAdmin.test.tsdiffbeforeafterboth--- a/tests/src/eth/collectionAdmin.test.ts
+++ b/tests/src/eth/collectionAdmin.test.ts
@@ -15,6 +15,7 @@
import {expect} from 'chai';
import privateKey from '../substrate/privateKey';
+import { UNIQUE } from '../util/helpers';
import {
createEthAccount,
createEthAccountWithBalance,
@@ -22,6 +23,8 @@
evmCollectionHelpers,
getCollectionAddressFromResult,
itWeb3,
+ recordEthFee,
+ subToEth,
} from './util/helpers';
describe('Add collection admins', () => {
@@ -71,9 +74,9 @@
const newAdmin = createEthAccount(web3);
const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
- expect(await collectionEvm.methods.verifyOwnerOrAdmin(newAdmin).call()).to.be.false;
+ expect(await collectionEvm.methods.isOwnerOrAdmin(newAdmin).call()).to.be.false;
await collectionEvm.methods.addCollectionAdmin(newAdmin).send();
- expect(await collectionEvm.methods.verifyOwnerOrAdmin(newAdmin).call()).to.be.true;
+ expect(await collectionEvm.methods.isOwnerOrAdmin(newAdmin).call()).to.be.true;
});
itWeb3('(!negative tests!) Add admin by ADMIN is not allowed', async ({api, web3, privateKeyWrapper}) => {
@@ -309,4 +312,102 @@
expect(adminList[0].asSubstrate.toString().toLocaleLowerCase())
.to.be.eq(adminSub.address.toLocaleLowerCase());
});
+});
+
+describe('Change owner tests', () => {
+ itWeb3('Change owner', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const newOwner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionHelper = evmCollectionHelpers(web3, owner);
+ const result = await collectionHelper.methods
+ .createNonfungibleCollection('A', 'B', 'C')
+ .send();
+ const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ await collectionEvm.methods.setOwner(newOwner).send();
+
+ expect(await collectionEvm.methods.isOwnerOrAdmin(owner).call()).to.be.false;
+ expect(await collectionEvm.methods.isOwnerOrAdmin(newOwner).call()).to.be.true;
+ });
+
+ itWeb3('change owner call fee', async ({web3, api, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const newOwner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionHelper = evmCollectionHelpers(web3, owner);
+ const result = await collectionHelper.methods
+ .createNonfungibleCollection('A', 'B', 'C')
+ .send();
+ const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ const cost = await recordEthFee(api, owner, () => collectionEvm.methods.setOwner(newOwner).send());
+ expect(cost < BigInt(0.2 * Number(UNIQUE)));
+ expect(cost > 0);
+ });
+
+ itWeb3('(!negative tests!) call setOwner by non owner', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const newOwner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionHelper = evmCollectionHelpers(web3, owner);
+ const result = await collectionHelper.methods
+ .createNonfungibleCollection('A', 'B', 'C')
+ .send();
+ const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ await expect(collectionEvm.methods.setOwner(newOwner).send({from: newOwner})).to.be.rejected;
+ expect(await collectionEvm.methods.isOwnerOrAdmin(newOwner).call()).to.be.false;
+ });
+});
+
+describe('Change substrate owner tests', () => {
+ itWeb3('Change owner', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const newOwner = privateKeyWrapper('//Alice');
+ const collectionHelper = evmCollectionHelpers(web3, owner);
+ const result = await collectionHelper.methods
+ .createNonfungibleCollection('A', 'B', 'C')
+ .send();
+ const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ expect(await collectionEvm.methods.isOwnerOrAdmin(owner).call()).to.be.true;
+ expect(await collectionEvm.methods.isOwnerOrAdminSubstrate(newOwner.addressRaw).call()).to.be.false;
+
+ await collectionEvm.methods.setOwnerSubstrate(newOwner.addressRaw).send();
+
+ expect(await collectionEvm.methods.isOwnerOrAdmin(owner).call()).to.be.false;
+ expect(await collectionEvm.methods.isOwnerOrAdminSubstrate(newOwner.addressRaw).call()).to.be.true;
+ });
+
+ itWeb3('change owner call fee', async ({web3, api, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const newOwner = privateKeyWrapper('//Alice');
+ const collectionHelper = evmCollectionHelpers(web3, owner);
+ const result = await collectionHelper.methods
+ .createNonfungibleCollection('A', 'B', 'C')
+ .send();
+ const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ const cost = await recordEthFee(api, owner, () => collectionEvm.methods.setOwnerSubstrate(newOwner.addressRaw).send());
+ expect(cost < BigInt(0.2 * Number(UNIQUE)));
+ expect(cost > 0);
+ });
+
+ itWeb3('(!negative tests!) call setOwner by non owner', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const otherReceiver = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const newOwner = privateKeyWrapper('//Alice');
+ const collectionHelper = evmCollectionHelpers(web3, owner);
+ const result = await collectionHelper.methods
+ .createNonfungibleCollection('A', 'B', 'C')
+ .send();
+ const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ await expect(collectionEvm.methods.setOwnerSubstrate(newOwner.addressRaw).send({from: otherReceiver})).to.be.rejected;
+ expect(await collectionEvm.methods.isOwnerOrAdminSubstrate(newOwner.addressRaw).call()).to.be.false;
+ });
});
\ No newline at end of file
tests/src/eth/collectionSponsoring.test.tsdiffbeforeafterboth--- a/tests/src/eth/collectionSponsoring.test.ts
+++ b/tests/src/eth/collectionSponsoring.test.ts
@@ -1,7 +1,10 @@
-import {addToAllowListExpectSuccess, confirmSponsorshipExpectSuccess, createCollectionExpectSuccess, enablePublicMintingExpectSuccess, setCollectionSponsorExpectSuccess} from '../util/helpers';
-import {itWeb3, createEthAccount, collectionIdToAddress, GAS_ARGS, normalizeEvents} from './util/helpers';
+import {addToAllowListExpectSuccess, bigIntToSub, confirmSponsorshipExpectSuccess, createCollectionExpectSuccess, enablePublicMintingExpectSuccess, getDetailedCollectionInfo, setCollectionSponsorExpectSuccess} from '../util/helpers';
+import {itWeb3, createEthAccount, collectionIdToAddress, GAS_ARGS, normalizeEvents, createEthAccountWithBalance, evmCollectionHelpers, getCollectionAddressFromResult, evmCollection, ethBalanceViaSub, subToEth} from './util/helpers';
import nonFungibleAbi from './nonFungibleAbi.json';
import {expect} from 'chai';
+import {evmToAddress} from '@polkadot/util-crypto';
+import {submitTransactionAsync} from '../substrate/substrate-api';
+import getBalance from '../substrate/get-balance';
describe('evm collection sponsoring', () => {
itWeb3('sponsors mint transactions', async ({web3, privateKeyWrapper}) => {
@@ -36,4 +39,226 @@
},
]);
});
+
+ itWeb3('Set substrate sponsor', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionHelpers = evmCollectionHelpers(web3, owner);
+ let result = await collectionHelpers.methods.createNonfungibleCollection('Sponsor collection', '1', '1').send();
+ const {collectionIdAddress, collectionId} = await getCollectionAddressFromResult(api, result);
+ const sponsor = privateKeyWrapper('//Alice');
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ expect(await collectionEvm.methods.hasCollectionPendingSponsor().call({from: owner})).to.be.false;
+ result = await collectionEvm.methods.setCollectionSponsorSubstrate(sponsor.addressRaw).send({from: owner});
+ expect(await collectionEvm.methods.hasCollectionPendingSponsor().call({from: owner})).to.be.true;
+
+ const confirmTx = await api.tx.unique.confirmSponsorship(collectionId);
+ await submitTransactionAsync(sponsor, confirmTx);
+ expect(await collectionEvm.methods.hasCollectionPendingSponsor().call({from: owner})).to.be.false;
+
+ const sponsorTuple = await collectionEvm.methods.getCollectionSponsor().call({from: owner});
+ expect(bigIntToSub(api, BigInt(sponsorTuple[1]))).to.be.eq(sponsor.address);
+ });
+
+ itWeb3('Remove sponsor', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionHelpers = evmCollectionHelpers(web3, owner);
+ let result = await collectionHelpers.methods.createNonfungibleCollection('Sponsor collection', '1', '1').send();
+ const {collectionIdAddress} = await getCollectionAddressFromResult(api, result);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ expect(await collectionEvm.methods.hasCollectionPendingSponsor().call({from: owner})).to.be.false;
+ result = await collectionEvm.methods.setCollectionSponsor(sponsor).send({from: owner});
+ expect(await collectionEvm.methods.hasCollectionPendingSponsor().call({from: owner})).to.be.true;
+
+ await collectionEvm.methods.confirmCollectionSponsorship().send({from: sponsor});
+ expect(await collectionEvm.methods.hasCollectionPendingSponsor().call({from: owner})).to.be.false;
+
+ await collectionEvm.methods.removeCollectionSponsor().send({from: owner});
+
+ const sponsorTuple = await collectionEvm.methods.getCollectionSponsor().call({from: owner});
+ expect(sponsorTuple.field_0).to.be.eq('0x0000000000000000000000000000000000000000');
+ });
+
+ itWeb3('Sponsoring collection from evm address via access list', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionHelpers = evmCollectionHelpers(web3, owner);
+ let result = await collectionHelpers.methods.createNonfungibleCollection('Sponsor collection', '1', '1').send();
+ const {collectionIdAddress, collectionId} = await getCollectionAddressFromResult(api, result);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+ result = await collectionEvm.methods.setCollectionSponsor(sponsor).send({from: owner});
+ let collectionSub = (await getDetailedCollectionInfo(api, collectionId))!;
+ const ss58Format = (api.registry.getChainProperties())!.toJSON().ss58Format;
+ expect(collectionSub.sponsorship.isUnconfirmed).to.be.true;
+ expect(collectionSub.sponsorship.asUnconfirmed.toHuman()).to.be.eq(evmToAddress(sponsor, Number(ss58Format)));
+ await expect(collectionEvm.methods.confirmCollectionSponsorship().call()).to.be.rejectedWith('caller is not set as sponsor');
+
+ await collectionEvm.methods.confirmCollectionSponsorship().send({from: sponsor});
+ collectionSub = (await getDetailedCollectionInfo(api, collectionId))!;
+ expect(collectionSub.sponsorship.isConfirmed).to.be.true;
+ expect(collectionSub.sponsorship.asConfirmed.toHuman()).to.be.eq(evmToAddress(sponsor, Number(ss58Format)));
+
+ const user = createEthAccount(web3);
+ const nextTokenId = await collectionEvm.methods.nextTokenId().call();
+ expect(nextTokenId).to.be.equal('1');
+
+ const oldPermissions = (await getDetailedCollectionInfo(api, collectionId))!.permissions.toHuman();
+ expect(oldPermissions.mintMode).to.be.false;
+ expect(oldPermissions.access).to.be.equal('Normal');
+
+ await collectionEvm.methods.setCollectionAccess(1 /*'AllowList'*/).send({from: owner});
+ await collectionEvm.methods.addToCollectionAllowList(user).send({from: owner});
+ await collectionEvm.methods.setCollectionMintMode(true).send({from: owner});
+
+ const newPermissions = (await getDetailedCollectionInfo(api, collectionId))!.permissions.toHuman();
+ expect(newPermissions.mintMode).to.be.true;
+ expect(newPermissions.access).to.be.equal('AllowList');
+
+ const ownerBalanceBefore = await ethBalanceViaSub(api, owner);
+ const sponsorBalanceBefore = await ethBalanceViaSub(api, sponsor);
+
+ {
+ const nextTokenId = await collectionEvm.methods.nextTokenId().call();
+ expect(nextTokenId).to.be.equal('1');
+ const result = await collectionEvm.methods.mintWithTokenURI(
+ user,
+ nextTokenId,
+ 'Test URI',
+ ).send({from: user});
+ const events = normalizeEvents(result.events);
+
+ expect(events).to.be.deep.equal([
+ {
+ address: collectionIdAddress,
+ event: 'Transfer',
+ args: {
+ from: '0x0000000000000000000000000000000000000000',
+ to: user,
+ tokenId: nextTokenId,
+ },
+ },
+ ]);
+
+ const ownerBalanceAfter = await ethBalanceViaSub(api, owner);
+ const sponsorBalanceAfter = await ethBalanceViaSub(api, sponsor);
+
+ expect(await collectionEvm.methods.tokenURI(nextTokenId).call()).to.be.equal('Test URI');
+ expect(ownerBalanceBefore).to.be.eq(ownerBalanceAfter);
+ expect(sponsorBalanceBefore > sponsorBalanceAfter).to.be.true;
+ }
+ });
+
+ itWeb3('Sponsoring collection from substrate address via access list', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionHelpers = evmCollectionHelpers(web3, owner);
+ const result = await collectionHelpers.methods.createNonfungibleCollection('Sponsor collection', '1', '1').send();
+ const {collectionIdAddress, collectionId} = await getCollectionAddressFromResult(api, result);
+ const sponsor = privateKeyWrapper('//Alice');
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+
+ await collectionEvm.methods.setCollectionSponsorSubstrate(sponsor.addressRaw).send({from: owner});
+
+ const confirmTx = await api.tx.unique.confirmSponsorship(collectionId);
+ await submitTransactionAsync(sponsor, confirmTx);
+
+ const user = createEthAccount(web3);
+ const nextTokenId = await collectionEvm.methods.nextTokenId().call();
+ expect(nextTokenId).to.be.equal('1');
+
+ await collectionEvm.methods.setCollectionAccess(1 /*'AllowList'*/).send({from: owner});
+ await collectionEvm.methods.addToCollectionAllowList(user).send({from: owner});
+ await collectionEvm.methods.setCollectionMintMode(true).send({from: owner});
+
+ const ownerBalanceBefore = await ethBalanceViaSub(api, owner);
+ const sponsorBalanceBefore = (await getBalance(api, [sponsor.address]))[0];
+
+ {
+ const nextTokenId = await collectionEvm.methods.nextTokenId().call();
+ expect(nextTokenId).to.be.equal('1');
+ const result = await collectionEvm.methods.mintWithTokenURI(
+ user,
+ nextTokenId,
+ 'Test URI',
+ ).send({from: user});
+ const events = normalizeEvents(result.events);
+
+ expect(events).to.be.deep.equal([
+ {
+ address: collectionIdAddress,
+ event: 'Transfer',
+ args: {
+ from: '0x0000000000000000000000000000000000000000',
+ to: user,
+ tokenId: nextTokenId,
+ },
+ },
+ ]);
+
+ const ownerBalanceAfter = await ethBalanceViaSub(api, owner);
+ const sponsorBalanceAfter = (await getBalance(api, [sponsor.address]))[0];
+
+ expect(await collectionEvm.methods.tokenURI(nextTokenId).call()).to.be.equal('Test URI');
+ expect(ownerBalanceBefore).to.be.eq(ownerBalanceAfter);
+ expect(sponsorBalanceBefore > sponsorBalanceAfter).to.be.true;
+ }
+ });
+
+ itWeb3('Check that transaction via EVM spend money from sponsor address', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionHelpers = evmCollectionHelpers(web3, owner);
+ let result = await collectionHelpers.methods.createNonfungibleCollection('Sponsor collection', '1', '1').send();
+ const {collectionIdAddress, collectionId} = await getCollectionAddressFromResult(api, result);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
+ result = await collectionEvm.methods.setCollectionSponsor(sponsor).send();
+ let collectionSub = (await getDetailedCollectionInfo(api, collectionId))!;
+ const ss58Format = (api.registry.getChainProperties())!.toJSON().ss58Format;
+ expect(collectionSub.sponsorship.isUnconfirmed).to.be.true;
+ expect(collectionSub.sponsorship.asUnconfirmed.toHuman()).to.be.eq(evmToAddress(sponsor, Number(ss58Format)));
+ await expect(collectionEvm.methods.confirmCollectionSponsorship().call()).to.be.rejectedWith('caller is not set as sponsor');
+ const sponsorCollection = evmCollection(web3, sponsor, collectionIdAddress);
+ await sponsorCollection.methods.confirmCollectionSponsorship().send();
+ collectionSub = (await getDetailedCollectionInfo(api, collectionId))!;
+ expect(collectionSub.sponsorship.isConfirmed).to.be.true;
+ expect(collectionSub.sponsorship.asConfirmed.toHuman()).to.be.eq(evmToAddress(sponsor, Number(ss58Format)));
+
+ const user = createEthAccount(web3);
+ await collectionEvm.methods.addCollectionAdmin(user).send();
+
+ const ownerBalanceBefore = await ethBalanceViaSub(api, owner);
+ const sponsorBalanceBefore = await ethBalanceViaSub(api, sponsor);
+
+
+ const userCollectionEvm = evmCollection(web3, user, collectionIdAddress);
+ const nextTokenId = await userCollectionEvm.methods.nextTokenId().call();
+ expect(nextTokenId).to.be.equal('1');
+ result = await userCollectionEvm.methods.mintWithTokenURI(
+ user,
+ nextTokenId,
+ 'Test URI',
+ ).send();
+
+ const events = normalizeEvents(result.events);
+ const address = collectionIdToAddress(collectionId);
+
+ expect(events).to.be.deep.equal([
+ {
+ address,
+ event: 'Transfer',
+ args: {
+ from: '0x0000000000000000000000000000000000000000',
+ to: user,
+ tokenId: nextTokenId,
+ },
+ },
+ ]);
+ expect(await userCollectionEvm.methods.tokenURI(nextTokenId).call()).to.be.equal('Test URI');
+
+ const ownerBalanceAfter = await ethBalanceViaSub(api, owner);
+ expect(ownerBalanceAfter).to.be.eq(ownerBalanceBefore);
+ const sponsorBalanceAfter = await ethBalanceViaSub(api, sponsor);
+ expect(sponsorBalanceAfter < sponsorBalanceBefore).to.be.true;
+ });
});
tests/src/eth/contractSponsoring.test.tsdiffbeforeafterboth--- a/tests/src/eth/contractSponsoring.test.ts
+++ b/tests/src/eth/contractSponsoring.test.ts
@@ -23,33 +23,35 @@
itWeb3,
SponsoringMode,
createEthAccount,
- collectionIdToAddress,
- GAS_ARGS,
- normalizeEvents,
- subToEth,
- executeEthTxOnSub,
- evmCollectionHelpers,
- getCollectionAddressFromResult,
- evmCollection,
ethBalanceViaSub,
} from './util/helpers';
-import {
- addCollectionAdminExpectSuccess,
- createCollectionExpectSuccess,
- getDetailedCollectionInfo,
- transferBalanceTo,
-} from '../util/helpers';
-import nonFungibleAbi from './nonFungibleAbi.json';
-import getBalance from '../substrate/get-balance';
-import {evmToAddress} from '@polkadot/util-crypto';
describe('Sponsoring EVM contracts', () => {
+ itWeb3('Self sponsored can be set by the address that deployed the contract', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ await expect(helpers.methods.selfSponsoredEnable(flipper.options.address).send()).to.be.not.rejected;
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.true;
+ });
+
+ itWeb3('Self sponsored can not be set by the address that did not deployed the contract', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const notOwner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ await expect(helpers.methods.selfSponsoredEnable(flipper.options.address).call({from: notOwner})).to.be.rejectedWith('NoPermission');
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ });
+
itWeb3('Sponsoring can be set by the address that has deployed the contract', async ({api, web3, privateKeyWrapper}) => {
const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const flipper = await deployFlipper(web3, owner);
const helpers = contractHelpers(web3, owner);
expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
- await helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Allowlisted).send({from: owner});
+ await expect(helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Allowlisted).send({from: owner})).to.be.not.rejected;
expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.true;
});
@@ -59,11 +61,150 @@
const flipper = await deployFlipper(web3, owner);
const helpers = contractHelpers(web3, owner);
expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
- await expect(helpers.methods.setSponsoringMode(notOwner, SponsoringMode.Allowlisted).send({from: notOwner})).to.rejected;
+ await expect(helpers.methods.setSponsoringMode(notOwner, SponsoringMode.Allowlisted).call({from: notOwner})).to.be.rejectedWith('NoPermission');
expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
});
+
+ itWeb3('Sponsor can be set by the address that deployed the contract', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ expect(await helpers.methods.hasPendingSponsor(flipper.options.address).call()).to.be.false;
+ await expect(helpers.methods.setSponsor(flipper.options.address, sponsor).send()).to.be.not.rejected;
+ expect(await helpers.methods.hasPendingSponsor(flipper.options.address).call()).to.be.true;
+ });
+
+ itWeb3('Sponsor can not be set by the address that did not deployed the contract', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const notOwner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ expect(await helpers.methods.hasPendingSponsor(flipper.options.address).call()).to.be.false;
+ await expect(helpers.methods.setSponsor(flipper.options.address, sponsor).call({from: notOwner})).to.be.rejectedWith('NoPermission');
+ expect(await helpers.methods.hasPendingSponsor(flipper.options.address).call()).to.be.false;
+ });
+
+ itWeb3('Sponsorship can be confirmed by the address that pending as sponsor', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ await expect(helpers.methods.setSponsor(flipper.options.address, sponsor).send()).to.be.not.rejected;
+ await expect(helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor})).to.be.not.rejected;
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.true;
+ });
+
+ itWeb3('Sponsorship can not be confirmed by the address that not pending as sponsor', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const notSponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ await expect(helpers.methods.setSponsor(flipper.options.address, sponsor).send()).to.be.not.rejected;
+ await expect(helpers.methods.confirmSponsorship(flipper.options.address).call({from: notSponsor})).to.be.rejectedWith('NoPermission');
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ });
+
+ itWeb3('Sponsorship can not be confirmed by the address that not set as sponsor', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const notSponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ await expect(helpers.methods.confirmSponsorship(flipper.options.address).call({from: notSponsor})).to.be.rejectedWith('NoPendingSponsor');
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ });
+
+ itWeb3('Get self sponsored sponsor', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ await helpers.methods.selfSponsoredEnable(flipper.options.address).send();
+
+ const result = await helpers.methods.getSponsor(flipper.options.address).call();
+
+ expect(result[0]).to.be.eq(flipper.options.address);
+ expect(result[1]).to.be.eq('0');
+ });
+
+ itWeb3('Get confirmed sponsor', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+ await helpers.methods.setSponsor(flipper.options.address, sponsor).send();
+ await helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor});
+
+ const result = await helpers.methods.getSponsor(flipper.options.address).call();
+ expect(result[0]).to.be.eq(sponsor);
+ expect(result[1]).to.be.eq('0');
+ });
+
+ itWeb3('Sponsor can be removed by the address that deployed the contract', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ await helpers.methods.setSponsor(flipper.options.address, sponsor).send();
+ await helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor});
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.true;
+
+ await helpers.methods.removeSponsor(flipper.options.address).send();
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ });
+
+ itWeb3('Sponsor can not be removed by the address that did not deployed the contract', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const notOwner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const flipper = await deployFlipper(web3, owner);
+ const helpers = contractHelpers(web3, owner);
+
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.false;
+ await helpers.methods.setSponsor(flipper.options.address, sponsor).send();
+ await helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor});
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.true;
+
+ await expect(helpers.methods.removeSponsor(flipper.options.address).call({from: notOwner})).to.be.rejectedWith('NoPermission');
+ expect(await helpers.methods.hasSponsor(flipper.options.address).call()).to.be.true;
+ });
+
itWeb3('In generous mode, non-allowlisted user transaction will be sponsored', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const caller = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+
+ const flipper = await deployFlipper(web3, owner);
+
+ const helpers = contractHelpers(web3, owner);
+
+ await helpers.methods.setSponsor(flipper.options.address, sponsor).send();
+ await helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor});
+
+ await helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Generous).send({from: owner});
+ await helpers.methods.setSponsoringRateLimit(flipper.options.address, 0).send({from: owner});
+
+ const sponsorBalanceBefore = await ethBalanceViaSub(api, sponsor);
+ const callerBalanceBefore = await ethBalanceViaSub(api, caller);
+
+ await flipper.methods.flip().send({from: caller});
+ expect(await flipper.methods.getValue().call()).to.be.true;
+
+ // Balance should be taken from sponsor instead of caller
+ const sponsorBalanceAfter = await ethBalanceViaSub(api, sponsor);
+ const callerBalanceAfter = await ethBalanceViaSub(api, caller);
+ expect(sponsorBalanceAfter < sponsorBalanceBefore).to.be.true;
+ expect(callerBalanceAfter).to.be.eq(callerBalanceBefore);
+ });
+
+ itWeb3('In generous mode, non-allowlisted user transaction will be self sponsored', async ({api, web3, privateKeyWrapper}) => {
const alice = privateKeyWrapper('//Alice');
const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
@@ -73,28 +214,29 @@
const helpers = contractHelpers(web3, owner);
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
+ await helpers.methods.selfSponsoredEnable(flipper.options.address).send();
+
await helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Generous).send({from: owner});
await helpers.methods.setSponsoringRateLimit(flipper.options.address, 0).send({from: owner});
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.true;
await transferBalanceToEth(api, alice, flipper.options.address);
- const originalFlipperBalance = await web3.eth.getBalance(flipper.options.address);
- expect(originalFlipperBalance).to.be.not.equal('0');
+ const contractBalanceBefore = await ethBalanceViaSub(api, flipper.options.address);
+ const callerBalanceBefore = await ethBalanceViaSub(api, caller);
await flipper.methods.flip().send({from: caller});
expect(await flipper.methods.getValue().call()).to.be.true;
- // Balance should be taken from flipper instead of caller
- const balanceAfter = await web3.eth.getBalance(flipper.options.address);
- expect(+balanceAfter).to.be.lessThan(+originalFlipperBalance);
+ // Balance should be taken from sponsor instead of caller
+ const contractBalanceAfter = await ethBalanceViaSub(api, flipper.options.address);
+ const callerBalanceAfter = await ethBalanceViaSub(api, caller);
+ expect(contractBalanceAfter < contractBalanceBefore).to.be.true;
+ expect(callerBalanceAfter).to.be.eq(callerBalanceBefore);
});
itWeb3('Sponsoring is set, an address that has no UNQ can send a transaction and it works. Sponsor balance should decrease (allowlisted)', async ({api, web3, privateKeyWrapper}) => {
- const alice = privateKeyWrapper('//Alice');
-
const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const caller = createEthAccount(web3);
const flipper = await deployFlipper(web3, owner);
@@ -103,22 +245,21 @@
await helpers.methods.toggleAllowlist(flipper.options.address, true).send({from: owner});
await helpers.methods.toggleAllowed(flipper.options.address, caller, true).send({from: owner});
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
await helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Allowlisted).send({from: owner});
await helpers.methods.setSponsoringRateLimit(flipper.options.address, 0).send({from: owner});
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.true;
- await transferBalanceToEth(api, alice, flipper.options.address);
+ await helpers.methods.setSponsor(flipper.options.address, sponsor).send();
+ await helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor});
- const originalFlipperBalance = await web3.eth.getBalance(flipper.options.address);
- expect(originalFlipperBalance).to.be.not.equal('0');
+ const sponsorBalanceBefore = await ethBalanceViaSub(api, sponsor);
+ expect(sponsorBalanceBefore).to.be.not.equal('0');
await flipper.methods.flip().send({from: caller});
expect(await flipper.methods.getValue().call()).to.be.true;
// Balance should be taken from flipper instead of caller
- const balanceAfter = await web3.eth.getBalance(flipper.options.address);
- expect(+balanceAfter).to.be.lessThan(+originalFlipperBalance);
+ const sponsorBalanceAfter = await ethBalanceViaSub(api, sponsor);
+ expect(sponsorBalanceAfter < sponsorBalanceBefore).to.be.true;
});
itWeb3('Sponsoring is set, an address that has no UNQ can send a transaction and it works. Sponsor balance should not decrease (non-allowlisted)', async ({api, web3, privateKeyWrapper}) => {
@@ -131,10 +272,8 @@
const helpers = contractHelpers(web3, owner);
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
await helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Allowlisted).send({from: owner});
await helpers.methods.setSponsoringRateLimit(flipper.options.address, 0).send({from: owner});
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.true;
await transferBalanceToEth(api, alice, flipper.options.address);
@@ -150,11 +289,9 @@
});
itWeb3('Sponsoring is set, an address that has UNQ can send a transaction and it works. User balance should not change', async ({api, web3, privateKeyWrapper}) => {
- const alice = privateKeyWrapper('//Alice');
-
const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const caller = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
- const originalCallerBalance = await web3.eth.getBalance(caller);
const flipper = await deployFlipper(web3, owner);
@@ -162,26 +299,27 @@
await helpers.methods.toggleAllowlist(flipper.options.address, true).send({from: owner});
await helpers.methods.toggleAllowed(flipper.options.address, caller, true).send({from: owner});
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
await helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Allowlisted).send({from: owner});
await helpers.methods.setSponsoringRateLimit(flipper.options.address, 0).send({from: owner});
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.true;
- await transferBalanceToEth(api, alice, flipper.options.address);
+ await helpers.methods.setSponsor(flipper.options.address, sponsor).send();
+ await helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor});
- const originalFlipperBalance = await web3.eth.getBalance(flipper.options.address);
- expect(originalFlipperBalance).to.be.not.equal('0');
+ const sponsorBalanceBefore = await ethBalanceViaSub(api, sponsor);
+ const callerBalanceBefore = await ethBalanceViaSub(api, caller);
await flipper.methods.flip().send({from: caller});
expect(await flipper.methods.getValue().call()).to.be.true;
- expect(await web3.eth.getBalance(caller)).to.be.equals(originalCallerBalance);
+ const sponsorBalanceAfter = await ethBalanceViaSub(api, sponsor);
+ const callerBalanceAfter = await ethBalanceViaSub(api, caller);
+ expect(sponsorBalanceAfter < sponsorBalanceBefore).to.be.true;
+ expect(callerBalanceAfter).to.be.equals(callerBalanceBefore);
});
itWeb3('Sponsoring is limited, with setContractRateLimit. The limitation is working if transactions are sent more often, the sender pays the commission.', async ({api, web3, privateKeyWrapper}) => {
- const alice = privateKeyWrapper('//Alice');
-
const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const caller = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const originalCallerBalance = await web3.eth.getBalance(caller);
@@ -191,25 +329,24 @@
await helpers.methods.toggleAllowlist(flipper.options.address, true).send({from: owner});
await helpers.methods.toggleAllowed(flipper.options.address, caller, true).send({from: owner});
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
await helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Allowlisted).send({from: owner});
await helpers.methods.setSponsoringRateLimit(flipper.options.address, 10).send({from: owner});
- expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.true;
- await transferBalanceToEth(api, alice, flipper.options.address);
+ await helpers.methods.setSponsor(flipper.options.address, sponsor).send();
+ await helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor});
- const originalFlipperBalance = await web3.eth.getBalance(flipper.options.address);
+ const originalFlipperBalance = await web3.eth.getBalance(sponsor);
expect(originalFlipperBalance).to.be.not.equal('0');
await flipper.methods.flip().send({from: caller});
expect(await flipper.methods.getValue().call()).to.be.true;
expect(await web3.eth.getBalance(caller)).to.be.equals(originalCallerBalance);
- const newFlipperBalance = await web3.eth.getBalance(flipper.options.address);
+ const newFlipperBalance = await web3.eth.getBalance(sponsor);
expect(newFlipperBalance).to.be.not.equals(originalFlipperBalance);
await flipper.methods.flip().send({from: caller});
- expect(await web3.eth.getBalance(flipper.options.address)).to.be.equal(newFlipperBalance);
+ expect(await web3.eth.getBalance(sponsor)).to.be.equal(newFlipperBalance);
expect(await web3.eth.getBalance(caller)).to.be.not.equals(originalCallerBalance);
});
@@ -219,131 +356,5 @@
const flipper = await deployFlipper(web3, owner);
const helpers = contractHelpers(web3, owner);
expect(await helpers.methods.getSponsoringRateLimit(flipper.options.address).call()).to.be.equals('7200');
- });
-
- itWeb3('Sponsoring collection from evm address via access list', async ({api, web3, privateKeyWrapper}) => {
- const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
- const collectionHelpers = evmCollectionHelpers(web3, owner);
- let result = await collectionHelpers.methods.createNonfungibleCollection('Sponsor collection', '1', '1').send();
- const {collectionIdAddress, collectionId} = await getCollectionAddressFromResult(api, result);
- const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
- const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
- result = await collectionEvm.methods.setCollectionSponsor(sponsor).send({from: owner});
- let collectionSub = (await getDetailedCollectionInfo(api, collectionId))!;
- const ss58Format = (api.registry.getChainProperties())!.toJSON().ss58Format;
- expect(collectionSub.sponsorship.isUnconfirmed).to.be.true;
- expect(collectionSub.sponsorship.asUnconfirmed.toHuman()).to.be.eq(evmToAddress(sponsor, Number(ss58Format)));
- await expect(collectionEvm.methods.confirmCollectionSponsorship().call()).to.be.rejectedWith('caller is not set as sponsor');
-
- await collectionEvm.methods.confirmCollectionSponsorship().send({from: sponsor});
- collectionSub = (await getDetailedCollectionInfo(api, collectionId))!;
- expect(collectionSub.sponsorship.isConfirmed).to.be.true;
- expect(collectionSub.sponsorship.asConfirmed.toHuman()).to.be.eq(evmToAddress(sponsor, Number(ss58Format)));
-
- const user = createEthAccount(web3);
- const nextTokenId = await collectionEvm.methods.nextTokenId().call();
- expect(nextTokenId).to.be.equal('1');
-
- const oldPermissions = (await getDetailedCollectionInfo(api, collectionId))!.permissions.toHuman();
- expect(oldPermissions.mintMode).to.be.false;
- expect(oldPermissions.access).to.be.equal('Normal');
-
- await collectionEvm.methods.setCollectionAccess(1 /*'AllowList'*/).send({from: owner});
- await collectionEvm.methods.addToCollectionAllowList(user).send({from: owner});
- await collectionEvm.methods.setCollectionMintMode(true).send({from: owner});
-
- const newPermissions = (await getDetailedCollectionInfo(api, collectionId))!.permissions.toHuman();
- expect(newPermissions.mintMode).to.be.true;
- expect(newPermissions.access).to.be.equal('AllowList');
-
- const ownerBalanceBefore = await ethBalanceViaSub(api, owner);
- const sponsorBalanceBefore = await ethBalanceViaSub(api, sponsor);
-
- {
- const nextTokenId = await collectionEvm.methods.nextTokenId().call();
- expect(nextTokenId).to.be.equal('1');
- const result = await collectionEvm.methods.mintWithTokenURI(
- user,
- nextTokenId,
- 'Test URI',
- ).send({from: user});
- const events = normalizeEvents(result.events);
-
- expect(events).to.be.deep.equal([
- {
- address: collectionIdAddress,
- event: 'Transfer',
- args: {
- from: '0x0000000000000000000000000000000000000000',
- to: user,
- tokenId: nextTokenId,
- },
- },
- ]);
-
- const ownerBalanceAfter = await ethBalanceViaSub(api, owner);
- const sponsorBalanceAfter = await ethBalanceViaSub(api, sponsor);
-
- expect(await collectionEvm.methods.tokenURI(nextTokenId).call()).to.be.equal('Test URI');
- expect(ownerBalanceBefore).to.be.eq(ownerBalanceAfter);
- expect(sponsorBalanceBefore > sponsorBalanceAfter).to.be.true;
- }
- });
-
- itWeb3('Check that transaction via EVM spend money from sponsor address', async ({api, web3, privateKeyWrapper}) => {
- const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
- const collectionHelpers = evmCollectionHelpers(web3, owner);
- let result = await collectionHelpers.methods.createNonfungibleCollection('Sponsor collection', '1', '1').send();
- const {collectionIdAddress, collectionId} = await getCollectionAddressFromResult(api, result);
- const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
- const collectionEvm = evmCollection(web3, owner, collectionIdAddress);
- result = await collectionEvm.methods.setCollectionSponsor(sponsor).send();
- let collectionSub = (await getDetailedCollectionInfo(api, collectionId))!;
- const ss58Format = (api.registry.getChainProperties())!.toJSON().ss58Format;
- expect(collectionSub.sponsorship.isUnconfirmed).to.be.true;
- expect(collectionSub.sponsorship.asUnconfirmed.toHuman()).to.be.eq(evmToAddress(sponsor, Number(ss58Format)));
- await expect(collectionEvm.methods.confirmCollectionSponsorship().call()).to.be.rejectedWith('caller is not set as sponsor');
- const sponsorCollection = evmCollection(web3, sponsor, collectionIdAddress);
- await sponsorCollection.methods.confirmCollectionSponsorship().send();
- collectionSub = (await getDetailedCollectionInfo(api, collectionId))!;
- expect(collectionSub.sponsorship.isConfirmed).to.be.true;
- expect(collectionSub.sponsorship.asConfirmed.toHuman()).to.be.eq(evmToAddress(sponsor, Number(ss58Format)));
-
- const user = createEthAccount(web3);
- await collectionEvm.methods.addCollectionAdmin(user).send();
-
- const ownerBalanceBefore = await ethBalanceViaSub(api, owner);
- const sponsorBalanceBefore = await ethBalanceViaSub(api, sponsor);
-
-
- const userCollectionEvm = evmCollection(web3, user, collectionIdAddress);
- const nextTokenId = await userCollectionEvm.methods.nextTokenId().call();
- expect(nextTokenId).to.be.equal('1');
- result = await userCollectionEvm.methods.mintWithTokenURI(
- user,
- nextTokenId,
- 'Test URI',
- ).send();
-
- const events = normalizeEvents(result.events);
- const address = collectionIdToAddress(collectionId);
-
- expect(events).to.be.deep.equal([
- {
- address,
- event: 'Transfer',
- args: {
- from: '0x0000000000000000000000000000000000000000',
- to: user,
- tokenId: nextTokenId,
- },
- },
- ]);
- expect(await userCollectionEvm.methods.tokenURI(nextTokenId).call()).to.be.equal('Test URI');
-
- const ownerBalanceAfter = await ethBalanceViaSub(api, owner);
- expect(ownerBalanceAfter).to.be.eq(ownerBalanceBefore);
- const sponsorBalanceAfter = await ethBalanceViaSub(api, sponsor);
- expect(sponsorBalanceAfter < sponsorBalanceBefore).to.be.true;
});
});
tests/src/eth/fractionalizer/Fractionalizer.bindiffbeforeafterboth--- a/tests/src/eth/fractionalizer/Fractionalizer.bin
+++ /dev/null
@@ -1 +0,0 @@
-60c0604052600a60805269526546756e6769626c6560b01b60a0527fcdb72fd4e1d0d6d4eebd7ab142113ec2b4b06ddb24324db5c287ef01ab484d6b60055534801561004a57600080fd5b50600480546001600160a01b0319163317905561137a8061006c6000396000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c8063115091401461005c5780631b191ea214610071578063d470e60f14610084578063dbc38ad214610097578063eb292412146100aa575b600080fd5b61006f61006a366004610f85565b6100bd565b005b61006f61007f366004610ff2565b61035b565b61006f61009236600461108c565b6104c0565b61006f6100a53660046110b8565b61089d565b61006f6100b8366004611114565b610ee0565b6004546001600160a01b031633146100f05760405162461bcd60e51b81526004016100e79061114d565b60405180910390fd5b6000546001600160a01b0316156101495760405162461bcd60e51b815260206004820152601d60248201527f52465420636f6c6c656374696f6e20697320616c72656164792073657400000060448201526064016100e7565b60008190506000816001600160a01b031663d34b55b86040518163ffffffff1660e01b81526004016000604051808303816000875af1158015610190573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526101b8919081019061118b565b905060055481805190602001201461022f5760405162461bcd60e51b815260206004820152603460248201527f57726f6e6720636f6c6c656374696f6e20747970652e20436f6c6c656374696f604482015273371034b9903737ba103932b33ab733b4b136329760611b60648201526084016100e7565b816001600160a01b03166304a460536040518163ffffffff1660e01b81526004016020604051808303816000875af115801561026f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610293919061125b565b6103055760405162461bcd60e51b815260206004820152603c60248201527f4672616374696f6e616c697a657220636f6e74726163742073686f756c64206260448201527f6520616e2061646d696e206f662074686520636f6c6c656374696f6e0000000060648201526084016100e7565b600080546001600160a01b0319166001600160a01b0385169081179091556040519081527f7186a599bf2297b1f4c8957d30b0965291eee0021a5f9a0aeb54dcbd1ffdceef9060200160405180910390a1505050565b6004546001600160a01b031633146103855760405162461bcd60e51b81526004016100e79061114d565b6000546001600160a01b0316156103de5760405162461bcd60e51b815260206004820152601d60248201527f52465420636f6c6c656374696f6e20697320616c72656164792073657400000060448201526064016100e7565b6040516344a68ad560e01b8152736c4e9fe1ae37a41e93cee429e8e1881abdcbb54f9081906344a68ad590610421908a908a908a908a908a908a906004016112a1565b6020604051808303816000875af1158015610440573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061046491906112ea565b600080546001600160a01b0319166001600160a01b039290921691821790556040519081527f7186a599bf2297b1f4c8957d30b0965291eee0021a5f9a0aeb54dcbd1ffdceef906020015b60405180910390a150505050505050565b6000546001600160a01b03166105145760405162461bcd60e51b81526020600482015260196024820152781491950818dbdb1b1958dd1a5bdb881a5cc81b9bdd081cd95d603a1b60448201526064016100e7565b6000546001600160a01b038381169116146105685760405162461bcd60e51b81526020600482015260146024820152732bb937b7339029232a1031b7b63632b1ba34b7b760611b60448201526064016100e7565b600080546040516355bb7d6360e11b8152600481018490526001600160a01b039091169190829063ab76fac690602401602060405180830381865afa1580156105b5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105d991906112ea565b6001600160a01b03808216600090815260036020908152604091829020825180840190935280549093168083526001909301549082015291925061065f5760405162461bcd60e51b815260206004820181905260248201527f4e6f20636f72726573706f6e64696e67204e465420746f6b656e20666f756e6460448201526064016100e7565b6000829050806001600160a01b03166318160ddd6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156106a2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106c69190611307565b6040516370a0823160e01b81523360048201526001600160a01b038316906370a0823190602401602060405180830381865afa15801561070a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061072e9190611307565b1461078a5760405162461bcd60e51b815260206004820152602660248201527f4e6f7420616c6c2070696563657320617265206f776e6564206279207468652060448201526531b0b63632b960d11b60648201526084016100e7565b6040516323b872dd60e01b81526001600160a01b038516906323b872dd906107ba90339030908a90600401611320565b600060405180830381600087803b1580156107d457600080fd5b505af11580156107e8573d6000803e3d6000fd5b5050835160208501516040516323b872dd60e01b81526001600160a01b0390921693506323b872dd92506108229130913391600401611320565b600060405180830381600087803b15801561083c57600080fd5b505af1158015610850573d6000803e3d6000fd5b5050835160208501516040517fe9e9808d24ff79ccc3b1ecf48be7b2d11591adccc452150d0d7947cb48eb0d53945061088d935087929190611320565b60405180910390a1505050505050565b6000546001600160a01b03166108f15760405162461bcd60e51b81526020600482015260196024820152781491950818dbdb1b1958dd1a5bdb881a5cc81b9bdd081cd95d603a1b60448201526064016100e7565b600080546001600160a01b0385811683526001602081905260409093205491169160ff90911615151461098c5760405162461bcd60e51b815260206004820152603c60248201527f4672616374696f6e616c697a6174696f6e206f66207468697320636f6c6c656360448201527f74696f6e206973206e6f7420616c6c6f7765642062792061646d696e0000000060648201526084016100e7565b6040516331a9108f60e11b81526004810184905233906001600160a01b03861690636352211e90602401602060405180830381865afa1580156109d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109f791906112ea565b6001600160a01b031614610a5d5760405162461bcd60e51b815260206004820152602760248201527f4f6e6c7920746f6b656e206f776e657220636f756c64206672616374696f6e616044820152661b1a5e99481a5d60ca1b60648201526084016100e7565b6040516323b872dd60e01b81526001600160a01b038516906323b872dd90610a8d90339030908890600401611320565b600060405180830381600087803b158015610aa757600080fd5b505af1158015610abb573d6000803e3d6000fd5b505050506001600160a01b0384166000908152600260209081526040808320868452909152812054819081908103610d0757836001600160a01b03166375794a3c6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610b2b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b4f9190611307565b6040516340c10f1960e01b8152306004820152602481018290529093506001600160a01b038516906340c10f19906044016020604051808303816000875af1158015610b9f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bc3919061125b565b506040516355bb7d6360e11b8152600481018490526001600160a01b0385169063ab76fac690602401602060405180830381865afa158015610c09573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c2d91906112ea565b6001600160a01b0388811660008181526002602090815260408083208c84528252808320899055805180820182528481528083018d8152878716808652600390945293829020905181546001600160a01b0319169616959095178555915160019094019390935551630217888360e11b81526004810191909152602481018990529193508392509063042f1106906044016020604051808303816000875af1158015610cdd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d01919061125b565b50610d98565b6001600160a01b0387811660009081526002602090815260408083208a8452909152908190205490516355bb7d6360e11b8152600481018290529094509085169063ab76fac690602401602060405180830381865afa158015610d6e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d9291906112ea565b91508190505b60405163d2418ca760e01b81526001600160801b03861660048201526001600160a01b0382169063d2418ca7906024016020604051808303816000875af1158015610de7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e0b919061125b565b5060405163a9059cbb60e01b81523360048201526001600160801b03861660248201526001600160a01b0382169063a9059cbb906044016020604051808303816000875af1158015610e61573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e85919061125b565b50604080516001600160a01b03808a168252602082018990528416918101919091526001600160801b03861660608201527f29f372538523984f33874da1b50e596ce0f180a6eb04d7ff22bb2ce80e1576b6906080016104af565b6004546001600160a01b03163314610f0a5760405162461bcd60e51b81526004016100e79061114d565b6001600160a01b038216600081815260016020908152604091829020805460ff19168515159081179091558251938452908301527f6dad0aed33f4b7f07095619b668698e17943fd9f4c83e7cfcc7f6dd880a11588910160405180910390a15050565b6001600160a01b0381168114610f8257600080fd5b50565b600060208284031215610f9757600080fd5b8135610fa281610f6d565b9392505050565b60008083601f840112610fbb57600080fd5b50813567ffffffffffffffff811115610fd357600080fd5b602083019150836020828501011115610feb57600080fd5b9250929050565b6000806000806000806060878903121561100b57600080fd5b863567ffffffffffffffff8082111561102357600080fd5b61102f8a838b01610fa9565b9098509650602089013591508082111561104857600080fd5b6110548a838b01610fa9565b9096509450604089013591508082111561106d57600080fd5b5061107a89828a01610fa9565b979a9699509497509295939492505050565b6000806040838503121561109f57600080fd5b82356110aa81610f6d565b946020939093013593505050565b6000806000606084860312156110cd57600080fd5b83356110d881610f6d565b92506020840135915060408401356001600160801b03811681146110fb57600080fd5b809150509250925092565b8015158114610f8257600080fd5b6000806040838503121561112757600080fd5b823561113281610f6d565b9150602083013561114281611106565b809150509250929050565b6020808252600e908201526d27b7363c9037bbb732b91031b0b760911b604082015260600190565b634e487b7160e01b600052604160045260246000fd5b6000602080838503121561119e57600080fd5b825167ffffffffffffffff808211156111b657600080fd5b818501915085601f8301126111ca57600080fd5b8151818111156111dc576111dc611175565b604051601f8201601f19908116603f0116810190838211818310171561120457611204611175565b81604052828152888684870101111561121c57600080fd5b600093505b8284101561123e5784840186015181850187015292850192611221565b8284111561124f5760008684830101525b98975050505050505050565b60006020828403121561126d57600080fd5b8151610fa281611106565b81835281816020850137506000828201602090810191909152601f909101601f19169091010190565b6060815260006112b560608301888a611278565b82810360208401526112c8818789611278565b905082810360408401526112dd818587611278565b9998505050505050505050565b6000602082840312156112fc57600080fd5b8151610fa281610f6d565b60006020828403121561131957600080fd5b5051919050565b6001600160a01b03938416815291909216602082015260408101919091526060019056fea2646970667358221220a118fe8c3b83b3933baa7bfe084ed165a014ec509367252e5c99e1a3332d000364736f6c634300080f0033
\ No newline at end of file
tests/src/eth/fractionalizer/Fractionalizer.soldiffbeforeafterboth--- a/tests/src/eth/fractionalizer/Fractionalizer.sol
+++ b/tests/src/eth/fractionalizer/Fractionalizer.sol
@@ -16,8 +16,8 @@
}
address rftCollection;
mapping(address => bool) nftCollectionAllowList;
- mapping(address => mapping(uint256 => uint256)) nft2rftMapping;
- mapping(address => Token) rft2nftMapping;
+ mapping(address => mapping(uint256 => uint256)) public nft2rftMapping;
+ mapping(address => Token) public rft2nftMapping;
bytes32 refungibleCollectionType = keccak256(bytes("ReFungible"));
receive() external payable onlyOwner {}
@@ -64,7 +64,7 @@
"Wrong collection type. Collection is not refungible."
);
require(
- refungibleContract.verifyOwnerOrAdmin(address(this)),
+ refungibleContract.isOwnerOrAdmin(address(this)),
"Fractionalizer contract should be an admin of the collection"
);
rftCollection = _collection;
@@ -137,7 +137,6 @@
rft2nftMapping[rftTokenAddress] = Token(_collection, _token);
rftTokenContract = UniqueRefungibleToken(rftTokenAddress);
- rftTokenContract.setParentNFT(_collection, _token);
} else {
rftTokenId = nft2rftMapping[_collection][_token];
rftTokenAddress = rftCollectionContract.tokenContractAddress(rftTokenId);
tests/src/eth/fractionalizer/FractionalizerAbi.jsondiffbeforeafterboth--- a/tests/src/eth/fractionalizer/FractionalizerAbi.json
+++ /dev/null
@@ -1,142 +0,0 @@
-[
- { "inputs": [], "stateMutability": "nonpayable", "type": "constructor" },
- {
- "anonymous": false,
- "inputs": [
- {
- "indexed": false,
- "internalType": "address",
- "name": "_collection",
- "type": "address"
- },
- {
- "indexed": false,
- "internalType": "bool",
- "name": "_status",
- "type": "bool"
- }
- ],
- "name": "AllowListSet",
- "type": "event"
- },
- {
- "anonymous": false,
- "inputs": [
- {
- "indexed": false,
- "internalType": "address",
- "name": "_rftToken",
- "type": "address"
- },
- {
- "indexed": false,
- "internalType": "address",
- "name": "_nftCollection",
- "type": "address"
- },
- {
- "indexed": false,
- "internalType": "uint256",
- "name": "_nftTokenId",
- "type": "uint256"
- }
- ],
- "name": "Defractionalized",
- "type": "event"
- },
- {
- "anonymous": false,
- "inputs": [
- {
- "indexed": false,
- "internalType": "address",
- "name": "_collection",
- "type": "address"
- },
- {
- "indexed": false,
- "internalType": "uint256",
- "name": "_tokenId",
- "type": "uint256"
- },
- {
- "indexed": false,
- "internalType": "address",
- "name": "_rftToken",
- "type": "address"
- },
- {
- "indexed": false,
- "internalType": "uint128",
- "name": "_amount",
- "type": "uint128"
- }
- ],
- "name": "Fractionalized",
- "type": "event"
- },
- {
- "anonymous": false,
- "inputs": [
- {
- "indexed": false,
- "internalType": "address",
- "name": "_collection",
- "type": "address"
- }
- ],
- "name": "RFTCollectionSet",
- "type": "event"
- },
- {
- "inputs": [
- { "internalType": "string", "name": "_name", "type": "string" },
- { "internalType": "string", "name": "_description", "type": "string" },
- { "internalType": "string", "name": "_tokenPrefix", "type": "string" }
- ],
- "name": "createAndSetRFTCollection",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "_collection", "type": "address" },
- { "internalType": "uint256", "name": "_token", "type": "uint256" },
- { "internalType": "uint128", "name": "_pieces", "type": "uint128" }
- ],
- "name": "nft2rft",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "_collection", "type": "address" },
- { "internalType": "uint256", "name": "_token", "type": "uint256" }
- ],
- "name": "rft2nft",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "collection", "type": "address" },
- { "internalType": "bool", "name": "status", "type": "bool" }
- ],
- "name": "setNftCollectionIsAllowed",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "_collection", "type": "address" }
- ],
- "name": "setRFTCollection",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- }
-]
tests/src/eth/fractionalizer/fractionalizer.test.tsdiffbeforeafterboth--- a/tests/src/eth/fractionalizer/fractionalizer.test.ts
+++ b/tests/src/eth/fractionalizer/fractionalizer.test.ts
@@ -223,6 +223,28 @@
},
});
});
+
+ itWeb3('Test fractionalizer NFT <-> RFT mapping ', async ({api, web3, privateKeyWrapper}) => {
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+
+ const {fractionalizer, rftCollectionAddress} = await initFractionalizer(api, web3, privateKeyWrapper, owner);
+ const {rftTokenAddress, nftCollectionAddress, nftTokenId} = await createRFTToken(api, web3, owner, fractionalizer, 100n);
+
+ const {collectionId, tokenId} = tokenIdFromAddress(rftTokenAddress);
+ const refungibleAddress = collectionIdToAddress(collectionId);
+ expect(rftCollectionAddress).to.be.equal(refungibleAddress);
+ const refungibleTokenContract = uniqueRefungibleToken(web3, rftTokenAddress, owner);
+ await refungibleTokenContract.methods.approve(fractionalizer.options.address, 100).send();
+
+ const rft2nft = await fractionalizer.methods.rft2nftMapping(rftTokenAddress).call();
+ expect(rft2nft).to.be.like({
+ _collection: nftCollectionAddress,
+ _tokenId: nftTokenId,
+ });
+
+ const nft2rft = await fractionalizer.methods.nft2rftMapping(nftCollectionAddress, nftTokenId).call();
+ expect(nft2rft).to.be.eq(tokenId.toString());
+ });
});
tests/src/eth/fungible.test.tsdiffbeforeafterboth--- a/tests/src/eth/fungible.test.ts
+++ b/tests/src/eth/fungible.test.ts
@@ -14,10 +14,11 @@
// You should have received a copy of the GNU General Public License
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
-import {approveExpectSuccess, createCollectionExpectSuccess, createFungibleItemExpectSuccess, transferExpectSuccess, transferFromExpectSuccess, UNIQUE} from '../util/helpers';
-import {collectionIdToAddress, createEthAccount, createEthAccountWithBalance, GAS_ARGS, itWeb3, normalizeEvents, recordEthFee, recordEvents, subToEth, transferBalanceToEth} from './util/helpers';
+import {approveExpectSuccess, createCollection, createCollectionExpectSuccess, createFungibleItemExpectSuccess, transferExpectSuccess, transferFromExpectSuccess, UNIQUE} from '../util/helpers';
+import {collectionIdToAddress, createEthAccount, createEthAccountWithBalance, evmCollection, GAS_ARGS, itWeb3, normalizeEvents, recordEthFee, recordEvents, subToEth, transferBalanceToEth} from './util/helpers';
import fungibleAbi from './fungibleAbi.json';
import {expect} from 'chai';
+import {submitTransactionAsync} from '../substrate/substrate-api';
describe('Fungible: Information getting', () => {
itWeb3('totalSupply', async ({api, web3, privateKeyWrapper}) => {
@@ -58,6 +59,128 @@
});
describe('Fungible: Plain calls', () => {
+ itWeb3('Can perform mint()', async ({web3, api, privateKeyWrapper}) => {
+ const alice = privateKeyWrapper('//Alice');
+ const collection = await createCollection(api, alice, {
+ name: 'token name',
+ mode: {type: 'Fungible', decimalPoints: 0},
+ });
+
+ const receiver = createEthAccount(web3);
+
+ const collectionIdAddress = collectionIdToAddress(collection.collectionId);
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const changeAdminTx = api.tx.unique.addCollectionAdmin(collection.collectionId, {Ethereum: owner});
+ await submitTransactionAsync(alice, changeAdminTx);
+
+ const collectionContract = evmCollection(web3, owner, collectionIdAddress, {type: 'Fungible', decimalPoints: 0});
+ const result = await collectionContract.methods.mint(receiver, 100).send();
+ const events = normalizeEvents(result.events);
+
+ expect(events).to.be.deep.equal([
+ {
+ address: collectionIdAddress,
+ event: 'Transfer',
+ args: {
+ from: '0x0000000000000000000000000000000000000000',
+ to: receiver,
+ value: '100',
+ },
+ },
+ ]);
+ });
+
+ itWeb3('Can perform mintBulk()', async ({web3, api, privateKeyWrapper}) => {
+ const alice = privateKeyWrapper('//Alice');
+ const collection = await createCollection(api, alice, {
+ name: 'token name',
+ mode: {type: 'Fungible', decimalPoints: 0},
+ });
+
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const receiver1 = createEthAccount(web3);
+ const receiver2 = createEthAccount(web3);
+ const receiver3 = createEthAccount(web3);
+
+ const collectionIdAddress = collectionIdToAddress(collection.collectionId);
+ const changeAdminTx = api.tx.unique.addCollectionAdmin(collection.collectionId, {Ethereum: owner});
+ await submitTransactionAsync(alice, changeAdminTx);
+
+ const collectionContract = evmCollection(web3, owner, collectionIdAddress, {type: 'Fungible', decimalPoints: 0});
+ const result = await collectionContract.methods.mintBulk([
+ [receiver1, 10],
+ [receiver2, 20],
+ [receiver3, 30],
+ ]).send();
+ const events = normalizeEvents(result.events);
+
+ expect(events).to.be.deep.contain({
+ address:collectionIdAddress,
+ event: 'Transfer',
+ args: {
+ from: '0x0000000000000000000000000000000000000000',
+ to: receiver1,
+ value: '10',
+ },
+ });
+
+ expect(events).to.be.deep.contain({
+ address:collectionIdAddress,
+ event: 'Transfer',
+ args: {
+ from: '0x0000000000000000000000000000000000000000',
+ to: receiver2,
+ value: '20',
+ },
+ });
+
+ expect(events).to.be.deep.contain({
+ address:collectionIdAddress,
+ event: 'Transfer',
+ args: {
+ from: '0x0000000000000000000000000000000000000000',
+ to: receiver3,
+ value: '30',
+ },
+ });
+ });
+
+ itWeb3('Can perform burn()', async ({web3, api, privateKeyWrapper}) => {
+ const alice = privateKeyWrapper('//Alice');
+ const collection = await createCollection(api, alice, {
+ name: 'token name',
+ mode: {type: 'Fungible', decimalPoints: 0},
+ });
+
+ const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const changeAdminTx = api.tx.unique.addCollectionAdmin(collection.collectionId, {Ethereum: owner});
+ await submitTransactionAsync(alice, changeAdminTx);
+ const receiver = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+
+ const collectionIdAddress = collectionIdToAddress(collection.collectionId);
+ const collectionContract = evmCollection(web3, owner, collectionIdAddress, {type: 'Fungible', decimalPoints: 0});
+ await collectionContract.methods.mint(receiver, 100).send();
+
+ const result = await collectionContract.methods.burnFrom(receiver, 49).send({from: receiver});
+
+ const events = normalizeEvents(result.events);
+
+ expect(events).to.be.deep.equal([
+ {
+ address: collectionIdAddress,
+ event: 'Transfer',
+ args: {
+ from: receiver,
+ to: '0x0000000000000000000000000000000000000000',
+ value: '49',
+ },
+ },
+ ]);
+
+ const balance = await collectionContract.methods.balanceOf(receiver).call();
+ expect(balance).to.equal('51');
+ });
+
itWeb3('Can perform approve()', async ({web3, api, privateKeyWrapper}) => {
const collection = await createCollectionExpectSuccess({
name: 'token name',
tests/src/eth/fungibleAbi.jsondiffbeforeafterboth--- a/tests/src/eth/fungibleAbi.json
+++ b/tests/src/eth/fungibleAbi.json
@@ -152,6 +152,75 @@
},
{
"inputs": [],
+ "name": "getCollectionSponsor",
+ "outputs": [
+ {
+ "components": [
+ { "internalType": "address", "name": "field_0", "type": "address" },
+ { "internalType": "uint256", "name": "field_1", "type": "uint256" }
+ ],
+ "internalType": "struct Tuple6",
+ "name": "",
+ "type": "tuple"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "hasCollectionPendingSponsor",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "address", "name": "user", "type": "address" }
+ ],
+ "name": "isOwnerOrAdmin",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "uint256", "name": "user", "type": "uint256" }
+ ],
+ "name": "isOwnerOrAdminSubstrate",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "address", "name": "to", "type": "address" },
+ { "internalType": "uint256", "name": "amount", "type": "uint256" }
+ ],
+ "name": "mint",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "components": [
+ { "internalType": "address", "name": "field_0", "type": "address" },
+ { "internalType": "uint256", "name": "field_1", "type": "uint256" }
+ ],
+ "internalType": "struct Tuple6[]",
+ "name": "amounts",
+ "type": "tuple[]"
+ }
+ ],
+ "name": "mintBulk",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [],
"name": "name",
"outputs": [{ "internalType": "string", "name": "", "type": "string" }],
"stateMutability": "view",
@@ -176,6 +245,13 @@
"type": "function"
},
{
+ "inputs": [],
+ "name": "removeCollectionSponsor",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
"inputs": [
{ "internalType": "address", "name": "user", "type": "address" }
],
@@ -260,6 +336,33 @@
},
{
"inputs": [
+ { "internalType": "uint256", "name": "sponsor", "type": "uint256" }
+ ],
+ "name": "setCollectionSponsorSubstrate",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "address", "name": "newOwner", "type": "address" }
+ ],
+ "name": "setOwner",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "uint256", "name": "newOwner", "type": "uint256" }
+ ],
+ "name": "setOwnerSubstrate",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
{ "internalType": "bytes4", "name": "interfaceID", "type": "bytes4" }
],
"name": "supportsInterface",
@@ -307,15 +410,6 @@
"name": "uniqueCollectionType",
"outputs": [{ "internalType": "string", "name": "", "type": "string" }],
"stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "user", "type": "address" }
- ],
- "name": "verifyOwnerOrAdmin",
- "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
- "stateMutability": "view",
"type": "function"
}
]
tests/src/eth/marketplace/marketplace.test.tsdiffbeforeafterboth--- a/tests/src/eth/marketplace/marketplace.test.ts
+++ b/tests/src/eth/marketplace/marketplace.test.ts
@@ -39,6 +39,7 @@
describe('Matcher contract usage', () => {
itWeb3('With UNQ', async ({api, web3, privateKeyWrapper}) => {
const alice = privateKeyWrapper('//Alice');
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const matcherOwner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const matcherContract = new web3.eth.Contract(JSON.parse((await readFile(`${__dirname}/MarketPlace.abi`)).toString()), undefined, {
from: matcherOwner,
@@ -48,7 +49,9 @@
const helpers = contractHelpers(web3, matcherOwner);
await helpers.methods.setSponsoringMode(matcher.options.address, SponsoringMode.Allowlisted).send({from: matcherOwner});
await helpers.methods.setSponsoringRateLimit(matcher.options.address, 1).send({from: matcherOwner});
- await transferBalanceToEth(api, alice, matcher.options.address);
+
+ await helpers.methods.setSponsor(matcher.options.address, sponsor).send({from: matcherOwner});
+ await helpers.methods.confirmSponsorship(matcher.options.address).send({from: sponsor});
const collectionId = await createCollectionExpectSuccess({mode: {type: 'NFT'}});
await setCollectionLimitsExpectSuccess(alice, collectionId, {sponsorApproveTimeout: 1});
@@ -100,6 +103,7 @@
itWeb3('With escrow', async ({api, web3, privateKeyWrapper}) => {
const alice = privateKeyWrapper('//Alice');
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const matcherOwner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const escrow = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const matcherContract = new web3.eth.Contract(JSON.parse((await readFile(`${__dirname}/MarketPlace.abi`)).toString()), undefined, {
@@ -111,7 +115,9 @@
const helpers = contractHelpers(web3, matcherOwner);
await helpers.methods.setSponsoringMode(matcher.options.address, SponsoringMode.Allowlisted).send({from: matcherOwner});
await helpers.methods.setSponsoringRateLimit(matcher.options.address, 1).send({from: matcherOwner});
- await transferBalanceToEth(api, alice, matcher.options.address);
+
+ await helpers.methods.setSponsor(matcher.options.address, sponsor).send({from: matcherOwner});
+ await helpers.methods.confirmSponsorship(matcher.options.address).send({from: sponsor});
const collectionId = await createCollectionExpectSuccess({mode: {type: 'NFT'}});
await setCollectionLimitsExpectSuccess(alice, collectionId, {sponsorApproveTimeout: 1});
tests/src/eth/nonFungibleAbi.jsondiffbeforeafterboth--- a/tests/src/eth/nonFungibleAbi.json
+++ b/tests/src/eth/nonFungibleAbi.json
@@ -200,6 +200,30 @@
"type": "function"
},
{
+ "inputs": [],
+ "name": "getCollectionSponsor",
+ "outputs": [
+ {
+ "components": [
+ { "internalType": "address", "name": "field_0", "type": "address" },
+ { "internalType": "uint256", "name": "field_1", "type": "uint256" }
+ ],
+ "internalType": "struct Tuple17",
+ "name": "",
+ "type": "tuple"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "hasCollectionPendingSponsor",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
"inputs": [
{ "internalType": "address", "name": "owner", "type": "address" },
{ "internalType": "address", "name": "operator", "type": "address" }
@@ -211,6 +235,24 @@
},
{
"inputs": [
+ { "internalType": "address", "name": "user", "type": "address" }
+ ],
+ "name": "isOwnerOrAdmin",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "uint256", "name": "user", "type": "uint256" }
+ ],
+ "name": "isOwnerOrAdminSubstrate",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
{ "internalType": "address", "name": "to", "type": "address" },
{ "internalType": "uint256", "name": "tokenId", "type": "uint256" }
],
@@ -237,7 +279,7 @@
{ "internalType": "uint256", "name": "field_0", "type": "uint256" },
{ "internalType": "string", "name": "field_1", "type": "string" }
],
- "internalType": "struct Tuple0[]",
+ "internalType": "struct Tuple8[]",
"name": "tokens",
"type": "tuple[]"
}
@@ -317,6 +359,13 @@
"type": "function"
},
{
+ "inputs": [],
+ "name": "removeCollectionSponsor",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
"inputs": [
{ "internalType": "address", "name": "user", "type": "address" }
],
@@ -343,7 +392,7 @@
{ "internalType": "uint256", "name": "tokenId", "type": "uint256" },
{ "internalType": "bytes", "name": "data", "type": "bytes" }
],
- "name": "safeTransferFromWithData",
+ "name": "safeTransferFrom",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
@@ -434,6 +483,33 @@
},
{
"inputs": [
+ { "internalType": "uint256", "name": "sponsor", "type": "uint256" }
+ ],
+ "name": "setCollectionSponsorSubstrate",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "address", "name": "newOwner", "type": "address" }
+ ],
+ "name": "setOwner",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "uint256", "name": "newOwner", "type": "uint256" }
+ ],
+ "name": "setOwnerSubstrate",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
{ "internalType": "uint256", "name": "tokenId", "type": "uint256" },
{ "internalType": "string", "name": "key", "type": "string" },
{ "internalType": "bytes", "name": "value", "type": "bytes" }
@@ -532,15 +608,6 @@
"name": "uniqueCollectionType",
"outputs": [{ "internalType": "string", "name": "", "type": "string" }],
"stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "user", "type": "address" }
- ],
- "name": "verifyOwnerOrAdmin",
- "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
- "stateMutability": "view",
"type": "function"
}
]
tests/src/eth/reFungibleAbi.jsondiffbeforeafterboth--- a/tests/src/eth/reFungibleAbi.json
+++ b/tests/src/eth/reFungibleAbi.json
@@ -200,6 +200,30 @@
"type": "function"
},
{
+ "inputs": [],
+ "name": "getCollectionSponsor",
+ "outputs": [
+ {
+ "components": [
+ { "internalType": "address", "name": "field_0", "type": "address" },
+ { "internalType": "uint256", "name": "field_1", "type": "uint256" }
+ ],
+ "internalType": "struct Tuple17",
+ "name": "",
+ "type": "tuple"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [],
+ "name": "hasCollectionPendingSponsor",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
"inputs": [
{ "internalType": "address", "name": "owner", "type": "address" },
{ "internalType": "address", "name": "operator", "type": "address" }
@@ -211,6 +235,24 @@
},
{
"inputs": [
+ { "internalType": "address", "name": "user", "type": "address" }
+ ],
+ "name": "isOwnerOrAdmin",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "uint256", "name": "user", "type": "uint256" }
+ ],
+ "name": "isOwnerOrAdminSubstrate",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
{ "internalType": "address", "name": "to", "type": "address" },
{ "internalType": "uint256", "name": "tokenId", "type": "uint256" }
],
@@ -237,7 +279,7 @@
{ "internalType": "uint256", "name": "field_0", "type": "uint256" },
{ "internalType": "string", "name": "field_1", "type": "string" }
],
- "internalType": "struct Tuple0[]",
+ "internalType": "struct Tuple8[]",
"name": "tokens",
"type": "tuple[]"
}
@@ -317,6 +359,13 @@
"type": "function"
},
{
+ "inputs": [],
+ "name": "removeCollectionSponsor",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
"inputs": [
{ "internalType": "address", "name": "user", "type": "address" }
],
@@ -434,6 +483,33 @@
},
{
"inputs": [
+ { "internalType": "uint256", "name": "sponsor", "type": "uint256" }
+ ],
+ "name": "setCollectionSponsorSubstrate",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "address", "name": "newOwner", "type": "address" }
+ ],
+ "name": "setOwner",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "uint256", "name": "newOwner", "type": "uint256" }
+ ],
+ "name": "setOwnerSubstrate",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
{ "internalType": "uint256", "name": "tokenId", "type": "uint256" },
{ "internalType": "string", "name": "key", "type": "string" },
{ "internalType": "bytes", "name": "value", "type": "bytes" }
@@ -541,15 +617,6 @@
"name": "uniqueCollectionType",
"outputs": [{ "internalType": "string", "name": "", "type": "string" }],
"stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "user", "type": "address" }
- ],
- "name": "verifyOwnerOrAdmin",
- "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
- "stateMutability": "view",
"type": "function"
}
]
tests/src/eth/reFungibleToken.test.tsdiffbeforeafterboth--- a/tests/src/eth/reFungibleToken.test.ts
+++ b/tests/src/eth/reFungibleToken.test.ts
@@ -655,31 +655,6 @@
await requirePallets(this, [Pallets.ReFungible]);
});
- itWeb3('Parent NFT token address and id', async ({api, web3, privateKeyWrapper}) => {
- const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
-
- const {collectionIdAddress: nftCollectionAddress} = await createNonfungibleCollection(api, web3, owner);
- const nftContract = uniqueNFT(web3, nftCollectionAddress, owner);
- const nftTokenId = await nftContract.methods.nextTokenId().call();
- await nftContract.methods.mint(owner, nftTokenId).send();
- const nftCollectionId = collectionIdFromAddress(nftCollectionAddress);
-
- const {collectionIdAddress, collectionId} = await createRefungibleCollection(api, web3, owner);
- const refungibleContract = uniqueRefungible(web3, collectionIdAddress, owner);
- const refungibleTokenId = await refungibleContract.methods.nextTokenId().call();
- await refungibleContract.methods.mint(owner, refungibleTokenId).send();
-
- const rftTokenAddress = tokenIdToAddress(collectionId, refungibleTokenId);
- const refungibleTokenContract = uniqueRefungibleToken(web3, rftTokenAddress, owner);
- await refungibleTokenContract.methods.setParentNFT(nftCollectionAddress, nftTokenId).send();
-
- const tokenAddress = await refungibleTokenContract.methods.parentToken().call();
- const tokenId = await refungibleTokenContract.methods.parentTokenId().call();
- const nftTokenAddress = tokenIdToAddress(nftCollectionId, nftTokenId);
- expect(tokenAddress).to.be.equal(nftTokenAddress);
- expect(tokenId).to.be.equal(nftTokenId);
- });
-
itWeb3('Default parent token address and id', async ({api, web3, privateKeyWrapper}) => {
const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
@@ -693,7 +668,7 @@
const tokenAddress = await refungibleTokenContract.methods.parentToken().call();
const tokenId = await refungibleTokenContract.methods.parentTokenId().call();
- expect(tokenAddress).to.be.equal(rftTokenAddress);
+ expect(tokenAddress).to.be.equal(collectionIdAddress);
expect(tokenId).to.be.equal(refungibleTokenId);
});
});
tests/src/eth/reFungibleTokenAbi.jsondiffbeforeafterboth--- a/tests/src/eth/reFungibleTokenAbi.json
+++ b/tests/src/eth/reFungibleTokenAbi.json
@@ -127,16 +127,6 @@
},
{
"inputs": [
- { "internalType": "address", "name": "collection", "type": "address" },
- { "internalType": "uint256", "name": "nftId", "type": "uint256" }
- ],
- "name": "setParentNFT",
- "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
{ "internalType": "bytes4", "name": "interfaceID", "type": "bytes4" }
],
"name": "supportsInterface",
tests/src/eth/refungibleAbi.jsondiffbeforeafterboth--- a/tests/src/eth/refungibleAbi.json
+++ /dev/null
@@ -1,167 +0,0 @@
-[
- {
- "inputs": [
- { "internalType": "address", "name": "newAdmin", "type": "address" }
- ],
- "name": "addCollectionAdmin",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "uint256", "name": "newAdmin", "type": "uint256" }
- ],
- "name": "addCollectionAdminSubstrate",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "user", "type": "address" }
- ],
- "name": "addToCollectionAllowList",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [{ "internalType": "string", "name": "key", "type": "string" }],
- "name": "collectionProperty",
- "outputs": [{ "internalType": "bytes", "name": "", "type": "bytes" }],
- "stateMutability": "view",
- "type": "function"
- },
- {
- "inputs": [],
- "name": "confirmCollectionSponsorship",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [],
- "name": "contractAddress",
- "outputs": [{ "internalType": "address", "name": "", "type": "address" }],
- "stateMutability": "view",
- "type": "function"
- },
- {
- "inputs": [{ "internalType": "string", "name": "key", "type": "string" }],
- "name": "deleteCollectionProperty",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "admin", "type": "address" }
- ],
- "name": "removeCollectionAdmin",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "uint256", "name": "admin", "type": "uint256" }
- ],
- "name": "removeCollectionAdminSubstrate",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "user", "type": "address" }
- ],
- "name": "removeFromCollectionAllowList",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [{ "internalType": "uint8", "name": "mode", "type": "uint8" }],
- "name": "setCollectionAccess",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "string", "name": "limit", "type": "string" },
- { "internalType": "uint32", "name": "value", "type": "uint32" }
- ],
- "name": "setCollectionLimit",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "string", "name": "limit", "type": "string" },
- { "internalType": "bool", "name": "value", "type": "bool" }
- ],
- "name": "setCollectionLimit",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [{ "internalType": "bool", "name": "mode", "type": "bool" }],
- "name": "setCollectionMintMode",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [{ "internalType": "bool", "name": "enable", "type": "bool" }],
- "name": "setCollectionNesting",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "bool", "name": "enable", "type": "bool" },
- {
- "internalType": "address[]",
- "name": "collections",
- "type": "address[]"
- }
- ],
- "name": "setCollectionNesting",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "string", "name": "key", "type": "string" },
- { "internalType": "bytes", "name": "value", "type": "bytes" }
- ],
- "name": "setCollectionProperty",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "address", "name": "sponsor", "type": "address" }
- ],
- "name": "setCollectionSponsor",
- "outputs": [],
- "stateMutability": "nonpayable",
- "type": "function"
- },
- {
- "inputs": [
- { "internalType": "bytes4", "name": "interfaceID", "type": "bytes4" }
- ],
- "name": "supportsInterface",
- "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
- "stateMutability": "view",
- "type": "function"
- }
-]
tests/src/eth/sponsoring.test.tsdiffbeforeafterboth--- a/tests/src/eth/sponsoring.test.ts
+++ b/tests/src/eth/sponsoring.test.ts
@@ -15,13 +15,12 @@
// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
import {expect} from 'chai';
-import {contractHelpers, createEthAccount, createEthAccountWithBalance, deployCollector, deployFlipper, itWeb3, SponsoringMode, transferBalanceToEth} from './util/helpers';
+import {contractHelpers, createEthAccount, createEthAccountWithBalance, deployCollector, deployFlipper, itWeb3, SponsoringMode} from './util/helpers';
describe('EVM sponsoring', () => {
itWeb3('Fee is deducted from contract if sponsoring is enabled', async ({api, web3, privateKeyWrapper}) => {
- const alice = privateKeyWrapper('//Alice');
-
const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const caller = createEthAccount(web3);
const originalCallerBalance = await web3.eth.getBalance(caller);
expect(originalCallerBalance).to.be.equal('0');
@@ -31,28 +30,29 @@
const helpers = contractHelpers(web3, owner);
await helpers.methods.toggleAllowlist(flipper.options.address, true).send({from: owner});
await helpers.methods.toggleAllowed(flipper.options.address, caller, true).send({from: owner});
+
+ await helpers.methods.setSponsor(flipper.options.address, sponsor).send({from: owner});
+ await helpers.methods.confirmSponsorship(flipper.options.address).send({from: sponsor});
expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.false;
await helpers.methods.setSponsoringMode(flipper.options.address, SponsoringMode.Allowlisted).send({from: owner});
await helpers.methods.setSponsoringRateLimit(flipper.options.address, 0).send({from: owner});
expect(await helpers.methods.sponsoringEnabled(flipper.options.address).call()).to.be.true;
- await transferBalanceToEth(api, alice, flipper.options.address);
-
- const originalFlipperBalance = await web3.eth.getBalance(flipper.options.address);
- expect(originalFlipperBalance).to.be.not.equal('0');
+ const originalSponsorBalance = await web3.eth.getBalance(sponsor);
+ expect(originalSponsorBalance).to.be.not.equal('0');
await flipper.methods.flip().send({from: caller});
expect(await flipper.methods.getValue().call()).to.be.true;
// Balance should be taken from flipper instead of caller
expect(await web3.eth.getBalance(caller)).to.be.equals(originalCallerBalance);
- expect(await web3.eth.getBalance(flipper.options.address)).to.be.not.equals(originalFlipperBalance);
+ expect(await web3.eth.getBalance(sponsor)).to.be.not.equals(originalSponsorBalance);
});
+
itWeb3('...but this doesn\'t applies to payable value', async ({api, web3, privateKeyWrapper}) => {
- const alice = privateKeyWrapper('//Alice');
-
const owner = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
+ const sponsor = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const caller = await createEthAccountWithBalance(api, web3, privateKeyWrapper);
const originalCallerBalance = await web3.eth.getBalance(caller);
expect(originalCallerBalance).to.be.not.equal('0');
@@ -68,16 +68,17 @@
await helpers.methods.setSponsoringRateLimit(collector.options.address, 0).send({from: owner});
expect(await helpers.methods.sponsoringEnabled(collector.options.address).call()).to.be.true;
- await transferBalanceToEth(api, alice, collector.options.address);
+ await helpers.methods.setSponsor(collector.options.address, sponsor).send({from: owner});
+ await helpers.methods.confirmSponsorship(collector.options.address).send({from: sponsor});
- const originalCollectorBalance = await web3.eth.getBalance(collector.options.address);
- expect(originalCollectorBalance).to.be.not.equal('0');
+ const originalSponsorBalance = await web3.eth.getBalance(sponsor);
+ expect(originalSponsorBalance).to.be.not.equal('0');
await collector.methods.giveMoney().send({from: caller, value: '10000'});
// Balance will be taken from both caller (value) and from collector (fee)
expect(await web3.eth.getBalance(caller)).to.be.equals((BigInt(originalCallerBalance) - 10000n).toString());
- expect(await web3.eth.getBalance(collector.options.address)).to.be.not.equals(originalCollectorBalance);
+ expect(await web3.eth.getBalance(sponsor)).to.be.not.equals(originalSponsorBalance);
expect(await collector.methods.getCollected().call()).to.be.equal('10000');
});
});
tests/src/eth/util/contractHelpersAbi.jsondiffbeforeafterboth--- a/tests/src/eth/util/contractHelpersAbi.json
+++ b/tests/src/eth/util/contractHelpersAbi.json
@@ -34,6 +34,19 @@
"type": "address"
}
],
+ "name": "confirmSponsorship",
+ "outputs": [],
+ "stateMutability": "nonpayable",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address",
+ "name": "contractAddress",
+ "type": "address"
+ }
+ ],
"name": "contractOwner",
"outputs": [{ "internalType": "address", "name": "", "type": "address" }],
"stateMutability": "view",
@@ -47,6 +60,29 @@
"type": "address"
}
],
+ "name": "getSponsor",
+ "outputs": [
+ {
+ "components": [
+ { "internalType": "address", "name": "field_0", "type": "address" },
+ { "internalType": "uint256", "name": "field_1", "type": "uint256" }
+ ],
+ "internalType": "struct Tuple0",
+ "name": "",
+ "type": "tuple"
+ }
+ ],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address",
+ "name": "contractAddress",
+ "type": "address"
+ }
+ ],
"name": "getSponsoringRateLimit",
"outputs": [{ "internalType": "uint32", "name": "", "type": "uint32" }],
"stateMutability": "view",
@@ -58,12 +94,11 @@
"internalType": "address",
"name": "contractAddress",
"type": "address"
- },
- { "internalType": "uint8", "name": "mode", "type": "uint8" }
+ }
],
- "name": "setSponsoringMode",
- "outputs": [],
- "stateMutability": "nonpayable",
+ "name": "hasPendingSponsor",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
"type": "function"
},
{
@@ -72,10 +107,22 @@
"internalType": "address",
"name": "contractAddress",
"type": "address"
- },
- { "internalType": "uint32", "name": "rateLimit", "type": "uint32" }
+ }
],
- "name": "setSponsoringRateLimit",
+ "name": "hasSponsor",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address",
+ "name": "contractAddress",
+ "type": "address"
+ }
+ ],
+ "name": "removeSponsor",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
@@ -88,9 +135,9 @@
"type": "address"
}
],
- "name": "sponsoringEnabled",
- "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
- "stateMutability": "view",
+ "name": "selfSponsoredEnable",
+ "outputs": [],
+ "stateMutability": "nonpayable",
"type": "function"
},
{
@@ -99,20 +146,26 @@
"internalType": "address",
"name": "contractAddress",
"type": "address"
- }
+ },
+ { "internalType": "address", "name": "sponsor", "type": "address" }
],
- "name": "sponsoringMode",
- "outputs": [{ "internalType": "uint8", "name": "", "type": "uint8" }],
- "stateMutability": "view",
+ "name": "setSponsor",
+ "outputs": [],
+ "stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
- { "internalType": "bytes4", "name": "interfaceID", "type": "bytes4" }
+ {
+ "internalType": "address",
+ "name": "contractAddress",
+ "type": "address"
+ },
+ { "internalType": "uint8", "name": "mode", "type": "uint8" }
],
- "name": "supportsInterface",
- "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
- "stateMutability": "view",
+ "name": "setSponsoringMode",
+ "outputs": [],
+ "stateMutability": "nonpayable",
"type": "function"
},
{
@@ -122,10 +175,9 @@
"name": "contractAddress",
"type": "address"
},
- { "internalType": "address", "name": "user", "type": "address" },
- { "internalType": "bool", "name": "allowed", "type": "bool" }
+ { "internalType": "uint32", "name": "rateLimit", "type": "uint32" }
],
- "name": "toggleAllowed",
+ "name": "setSponsoringRateLimit",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
@@ -136,10 +188,33 @@
"internalType": "address",
"name": "contractAddress",
"type": "address"
+ }
+ ],
+ "name": "sponsoringEnabled",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ { "internalType": "bytes4", "name": "interfaceID", "type": "bytes4" }
+ ],
+ "name": "supportsInterface",
+ "outputs": [{ "internalType": "bool", "name": "", "type": "bool" }],
+ "stateMutability": "view",
+ "type": "function"
+ },
+ {
+ "inputs": [
+ {
+ "internalType": "address",
+ "name": "contractAddress",
+ "type": "address"
},
- { "internalType": "bool", "name": "enabled", "type": "bool" }
+ { "internalType": "address", "name": "user", "type": "address" },
+ { "internalType": "bool", "name": "isAllowed", "type": "bool" }
],
- "name": "toggleAllowlist",
+ "name": "toggleAllowed",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
@@ -153,7 +228,7 @@
},
{ "internalType": "bool", "name": "enabled", "type": "bool" }
],
- "name": "toggleSponsoring",
+ "name": "toggleAllowlist",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
tests/src/util/helpers.tsdiffbeforeafterboth--- a/tests/src/util/helpers.ts
+++ b/tests/src/util/helpers.ts
@@ -99,6 +99,10 @@
}
}
+export function bigIntToSub(api: ApiPromise, number: bigint) {
+ return api.registry.createType('AccountId', '0x' + number.toString(16).padStart(64, '0')).toJSON();
+}
+
export function normalizeAccountId(input: string | AccountId | CrossAccountId | IKeyringPair): CrossAccountId {
if (typeof input === 'string') {
if (input.length >= 47) {
tests/src/util/playgrounds/index.tsdiffbeforeafterboth--- a/tests/src/util/playgrounds/index.ts
+++ b/tests/src/util/playgrounds/index.ts
@@ -2,15 +2,12 @@
// SPDX-License-Identifier: Apache-2.0
import {IKeyringPair} from '@polkadot/types/types';
-import {UniqueHelper} from './unique';
import config from '../../config';
import '../../interfaces/augment-api-events';
-import * as defs from '../../interfaces/definitions';
-import {ApiPromise, WsProvider} from '@polkadot/api';
-
+import {DevUniqueHelper} from './unique.dev';
class SilentLogger {
- log(msg: any, level: any): void {}
+ log(msg: any, level: any): void { }
level = {
ERROR: 'ERROR' as const,
WARNING: 'WARNING' as const,
@@ -18,45 +15,7 @@
};
}
-
-class DevUniqueHelper extends UniqueHelper {
- async connect(wsEndpoint: string, listeners?: any): Promise<void> {
- const wsProvider = new WsProvider(wsEndpoint);
- this.api = new ApiPromise({
- provider: wsProvider,
- signedExtensions: {
- ContractHelpers: {
- extrinsic: {},
- payload: {},
- },
- FakeTransactionFinalizer: {
- extrinsic: {},
- payload: {},
- },
- },
- rpc: {
- unique: defs.unique.rpc,
- rmrk: defs.rmrk.rpc,
- eth: {
- feeHistory: {
- description: 'Dummy',
- params: [],
- type: 'u8',
- },
- maxPriorityFeePerGas: {
- description: 'Dummy',
- params: [],
- type: 'u8',
- },
- },
- },
- });
- await this.api.isReadyOrError;
- this.network = await UniqueHelper.detectNetwork(this.api);
- }
-}
-
-export const usingPlaygrounds = async (code: (helper: UniqueHelper, privateKey: (seed: string) => IKeyringPair) => Promise<void>) => {
+export const usingPlaygrounds = async (code: (helper: DevUniqueHelper, privateKey: (seed: string) => IKeyringPair) => Promise<void>) => {
// TODO: Remove, this is temporary: Filter unneeded API output
// (Jaco promised it will be removed in the next version)
const consoleErr = console.error;
@@ -83,7 +42,7 @@
const ss58Format = helper.chain.getChainProperties().ss58Format;
const privateKey = (seed: string) => helper.util.fromSeed(seed, ss58Format);
await code(helper, privateKey);
- }
+ }
finally {
await helper.disconnect();
console.error = consoleErr;
tests/src/util/playgrounds/types.tsdiffbeforeafterboth--- /dev/null
+++ b/tests/src/util/playgrounds/types.ts
@@ -0,0 +1,130 @@
+// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+import {IKeyringPair} from '@polkadot/types/types';
+
+export interface IChainEvent {
+ data: any;
+ method: string;
+ section: string;
+}
+
+export interface ITransactionResult {
+ status: 'Fail' | 'Success';
+ result: {
+ events: {
+ event: IChainEvent
+ }[];
+ },
+ moduleError?: string;
+}
+
+export interface ILogger {
+ log: (msg: any, level?: string) => void;
+ level: {
+ ERROR: 'ERROR';
+ WARNING: 'WARNING';
+ INFO: 'INFO';
+ [key: string]: string;
+ }
+}
+
+export interface IUniqueHelperLog {
+ executedAt: number;
+ executionTime: number;
+ type: 'extrinsic' | 'rpc';
+ status: 'Fail' | 'Success';
+ call: string;
+ params: any[];
+ moduleError?: string;
+ events?: any;
+}
+
+export interface IApiListeners {
+ connected?: (...args: any[]) => any;
+ disconnected?: (...args: any[]) => any;
+ error?: (...args: any[]) => any;
+ ready?: (...args: any[]) => any;
+ decorated?: (...args: any[]) => any;
+}
+
+export interface ICrossAccountId {
+ Substrate?: TSubstrateAccount;
+ Ethereum?: TEthereumAccount;
+}
+
+export interface ICrossAccountIdLower {
+ substrate?: TSubstrateAccount;
+ ethereum?: TEthereumAccount;
+}
+
+export interface ICollectionLimits {
+ accountTokenOwnershipLimit?: number | null;
+ sponsoredDataSize?: number | null;
+ sponsoredDataRateLimit?: {blocks: number} | {sponsoringDisabled: null} | null;
+ tokenLimit?: number | null;
+ sponsorTransferTimeout?: number | null;
+ sponsorApproveTimeout?: number | null;
+ ownerCanTransfer?: boolean | null;
+ ownerCanDestroy?: boolean | null;
+ transfersEnabled?: boolean | null;
+}
+
+export interface INestingPermissions {
+ tokenOwner?: boolean;
+ collectionAdmin?: boolean;
+ restricted?: number[] | null;
+}
+
+export interface ICollectionPermissions {
+ access?: 'Normal' | 'AllowList';
+ mintMode?: boolean;
+ nesting?: INestingPermissions;
+}
+
+export interface IProperty {
+ key: string;
+ value: string;
+}
+
+export interface ITokenPropertyPermission {
+ key: string;
+ permission: {
+ mutable: boolean;
+ tokenOwner: boolean;
+ collectionAdmin: boolean;
+ }
+}
+
+export interface IToken {
+ collectionId: number;
+ tokenId: number;
+}
+
+export interface ICollectionCreationOptions {
+ name: string | number[];
+ description: string | number[];
+ tokenPrefix: string | number[];
+ mode?: {
+ nft?: null;
+ refungible?: null;
+ fungible?: number;
+ }
+ permissions?: ICollectionPermissions;
+ properties?: IProperty[];
+ tokenPropertyPermissions?: ITokenPropertyPermission[];
+ limits?: ICollectionLimits;
+ pendingSponsor?: TSubstrateAccount;
+}
+
+export interface IChainProperties {
+ ss58Format: number;
+ tokenDecimals: number[];
+ tokenSymbol: string[]
+}
+
+export type TSubstrateAccount = string;
+export type TEthereumAccount = string;
+export type TApiAllowedListeners = 'connected' | 'disconnected' | 'error' | 'ready' | 'decorated';
+export type TUniqueNetworks = 'opal' | 'quartz' | 'unique';
+export type TSigner = IKeyringPair; // | 'string'
\ No newline at end of file
tests/src/util/playgrounds/unique.dev.tsdiffbeforeafterboth--- /dev/null
+++ b/tests/src/util/playgrounds/unique.dev.ts
@@ -0,0 +1,136 @@
+// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
+// SPDX-License-Identifier: Apache-2.0
+
+import {mnemonicGenerate} from '@polkadot/util-crypto';
+import {UniqueHelper} from './unique';
+import {ApiPromise, WsProvider} from '@polkadot/api';
+import * as defs from '../../interfaces/definitions';
+import {TSigner} from './types';
+import {IKeyringPair} from '@polkadot/types/types';
+
+
+export class DevUniqueHelper extends UniqueHelper {
+ /**
+ * Arrange methods for tests
+ */
+ arrange: ArrangeGroup;
+
+ constructor(logger: { log: (msg: any, level: any) => void, level: any }) {
+ super(logger);
+ this.arrange = new ArrangeGroup(this);
+ }
+
+ async connect(wsEndpoint: string, listeners?: any): Promise<void> {
+ const wsProvider = new WsProvider(wsEndpoint);
+ this.api = new ApiPromise({
+ provider: wsProvider,
+ signedExtensions: {
+ ContractHelpers: {
+ extrinsic: {},
+ payload: {},
+ },
+ FakeTransactionFinalizer: {
+ extrinsic: {},
+ payload: {},
+ },
+ },
+ rpc: {
+ unique: defs.unique.rpc,
+ rmrk: defs.rmrk.rpc,
+ eth: {
+ feeHistory: {
+ description: 'Dummy',
+ params: [],
+ type: 'u8',
+ },
+ maxPriorityFeePerGas: {
+ description: 'Dummy',
+ params: [],
+ type: 'u8',
+ },
+ },
+ },
+ });
+ await this.api.isReadyOrError;
+ this.network = await UniqueHelper.detectNetwork(this.api);
+ }
+}
+
+class ArrangeGroup {
+ helper: UniqueHelper;
+
+ constructor(helper: UniqueHelper) {
+ this.helper = helper;
+ }
+
+ /**
+ * Generates accounts with the specified UNQ token balance
+ * @param balances balances for generated accounts. Each balance will be multiplied by the token nominal.
+ * @param donor donor account for balances
+ * @returns array of newly created accounts
+ * @example const [acc1, acc2, acc3] = await createAccounts([0n, 10n, 20n], donor);
+ */
+ creteAccounts = async (balances: bigint[], donor: IKeyringPair): Promise<IKeyringPair[]> => {
+ let nonce = await this.helper.chain.getNonce(donor.address);
+ const tokenNominal = this.helper.balance.getOneTokenNominal();
+ const transactions = [];
+ const accounts: IKeyringPair[] = [];
+ for (const balance of balances) {
+ const recepient = this.helper.util.fromSeed(mnemonicGenerate());
+ accounts.push(recepient);
+ if (balance !== 0n) {
+ const tx = this.helper.constructApiCall('api.tx.balances.transfer', [{Id: recepient.address}, balance * tokenNominal]);
+ transactions.push(this.helper.signTransaction(donor, tx, 'account generation', {nonce}));
+ nonce++;
+ }
+ }
+
+ await Promise.all(transactions).catch(e => {});
+
+ //#region TODO remove this region, when nonce problem will be solved
+ const checkBalances = async () => {
+ let isSuccess = true;
+ for (let i = 0; i < balances.length; i++) {
+ const balance = await this.helper.balance.getSubstrate(accounts[i].address);
+ if (balance !== balances[i] * tokenNominal) {
+ isSuccess = false;
+ break;
+ }
+ }
+ return isSuccess;
+ };
+
+ let accountsCreated = false;
+ // checkBalances retry up to 5 blocks
+ for (let index = 0; index < 5; index++) {
+ console.log(await this.helper.chain.getLatestBlockNumber());
+ accountsCreated = await checkBalances();
+ if(accountsCreated) break;
+ await this.waitNewBlocks(1);
+ }
+
+ if (!accountsCreated) throw Error('Accounts generation failed');
+ //#endregion
+
+ return accounts;
+ };
+
+ /**
+ * Wait for specified bnumber of blocks
+ * @param blocksCount number of blocks to wait
+ * @returns
+ */
+ async waitNewBlocks(blocksCount = 1): Promise<void> {
+ const promise = new Promise<void>(async (resolve) => {
+ const unsubscribe = await this.helper.api!.rpc.chain.subscribeNewHeads(() => {
+ if (blocksCount > 0) {
+ blocksCount--;
+ } else {
+ unsubscribe();
+ resolve();
+ }
+ });
+ });
+ return promise;
+ }
+}
\ No newline at end of file
tests/src/util/playgrounds/unique.tsdiffbeforeafterboth--- a/tests/src/util/playgrounds/unique.ts
+++ b/tests/src/util/playgrounds/unique.ts
@@ -7,10 +7,10 @@
import {ApiPromise, WsProvider, Keyring} from '@polkadot/api';
import {ApiInterfaceEvents} from '@polkadot/api/types';
+import {encodeAddress, decodeAddress, keccakAsHex, evmToAddress, addressToEvm} from '@polkadot/util-crypto';
import {IKeyringPair} from '@polkadot/types/types';
-import {encodeAddress, decodeAddress, keccakAsHex, evmToAddress, addressToEvm} from '@polkadot/util-crypto';
+import {IApiListeners, IChainEvent, IChainProperties, ICollectionCreationOptions, ICollectionLimits, ICollectionPermissions, ICrossAccountId, ICrossAccountIdLower, ILogger, INestingPermissions, IProperty, IToken, ITokenPropertyPermission, ITransactionResult, IUniqueHelperLog, TApiAllowedListeners, TEthereumAccount, TSigner, TSubstrateAccount, TUniqueNetworks} from './types';
-
const crossAccountIdFromLower = (lowerAddress: ICrossAccountIdLower): ICrossAccountId => {
const address = {} as ICrossAccountId;
if(lowerAddress.substrate) address.Substrate = lowerAddress.substrate;
@@ -43,134 +43,7 @@
return this.toChecksumAddress(`0xf8238ccfff8ed887463fd5e0${collectionId.toString(16).padStart(8, '0')}${tokenId.toString(16).padStart(8, '0')}`);
},
};
-
-
-interface IChainEvent {
- data: any;
- method: string;
- section: string;
-}
-
-interface ITransactionResult {
- status: 'Fail' | 'Success';
- result: {
- events: {
- event: IChainEvent
- }[];
- },
- moduleError?: string;
-}
-
-interface ILogger {
- log: (msg: any, level?: string) => void;
- level: {
- ERROR: 'ERROR';
- WARNING: 'WARNING';
- INFO: 'INFO';
- [key: string]: string;
- }
-}
-
-interface IUniqueHelperLog {
- executedAt: number;
- executionTime: number;
- type: 'extrinsic' | 'rpc';
- status: 'Fail' | 'Success';
- call: string;
- params: any[];
- moduleError?: string;
- events?: any;
-}
-
-interface IApiListeners {
- connected?: (...args: any[]) => any;
- disconnected?: (...args: any[]) => any;
- error?: (...args: any[]) => any;
- ready?: (...args: any[]) => any;
- decorated?: (...args: any[]) => any;
-}
-
-interface ICrossAccountId {
- Substrate?: TSubstrateAccount;
- Ethereum?: TEthereumAccount;
-}
-
-interface ICrossAccountIdLower {
- substrate?: TSubstrateAccount;
- ethereum?: TEthereumAccount;
-}
-
-interface ICollectionLimits {
- accountTokenOwnershipLimit?: number | null;
- sponsoredDataSize?: number | null;
- sponsoredDataRateLimit?: {blocks: number} | {sponsoringDisabled: null} | null;
- tokenLimit?: number | null;
- sponsorTransferTimeout?: number | null;
- sponsorApproveTimeout?: number | null;
- ownerCanTransfer?: boolean | null;
- ownerCanDestroy?: boolean | null;
- transfersEnabled?: boolean | null;
-}
-
-interface INestingPermissions {
- tokenOwner?: boolean;
- collectionAdmin?: boolean;
- restricted?: number[] | null;
-}
-
-interface ICollectionPermissions {
- access?: 'Normal' | 'AllowList';
- mintMode?: boolean;
- nesting?: INestingPermissions;
-}
-
-interface IProperty {
- key: string;
- value: string;
-}
-
-interface ITokenPropertyPermission {
- key: string;
- permission: {
- mutable: boolean;
- tokenOwner: boolean;
- collectionAdmin: boolean;
- }
-}
-
-interface IToken {
- collectionId: number;
- tokenId: number;
-}
-
-interface ICollectionCreationOptions {
- name: string | number[];
- description: string | number[];
- tokenPrefix: string | number[];
- mode?: {
- nft?: null;
- refungible?: null;
- fungible?: number;
- }
- permissions?: ICollectionPermissions;
- properties?: IProperty[];
- tokenPropertyPermissions?: ITokenPropertyPermission[];
- limits?: ICollectionLimits;
- pendingSponsor?: TSubstrateAccount;
-}
-
-interface IChainProperties {
- ss58Format: number;
- tokenDecimals: number[];
- tokenSymbol: string[]
-}
-type TSubstrateAccount = string;
-type TEthereumAccount = string;
-type TApiAllowedListeners = 'connected' | 'disconnected' | 'error' | 'ready' | 'decorated';
-type TUniqueNetworks = 'opal' | 'quartz' | 'unique';
-type TSigner = IKeyringPair; // | 'string'
-
class UniqueUtil {
static transactionStatus = {
NOT_READY: 'NotReady',
@@ -439,7 +312,7 @@
return this.transactionStatus.FAIL;
}
- signTransaction(sender: TSigner, transaction: any, label = 'transaction', options = null) {
+ signTransaction(sender: TSigner, transaction: any, label = 'transaction', options: any = null) {
const sign = (callback: any) => {
if(options !== null) return transaction.signAndSend(sender, options, callback);
return transaction.signAndSend(sender, callback);
@@ -652,6 +525,22 @@
}
/**
+ * Get the normalized addresses added to the collection allow-list.
+ * @param collectionId ID of collection
+ * @example await getAllowList(1)
+ * @returns array of allow-listed addresses
+ */
+ async getAllowList(collectionId: number): Promise<ICrossAccountId[]> {
+ const normalized = [];
+ const allowListed = (await this.helper.callRpc('api.rpc.unique.allowlist', [collectionId])).toHuman();
+ for (const address of allowListed) {
+ if (address.Substrate) normalized.push({Substrate: this.helper.address.normalizeSubstrate(address.Substrate)});
+ else normalized.push(address);
+ }
+ return normalized;
+ }
+
+ /**
* Get the effective limits of the collection instead of null for default values
*
* @param collectionId ID of collection
@@ -795,6 +684,25 @@
}
/**
+ * Adds an address to allow list
+ * @param signer keyring of signer
+ * @param collectionId ID of collection
+ * @param addressObj address to add to the allow list
+ * @param label extra label for log
+ * @returns ```true``` if extrinsic success, otherwise ```false```
+ */
+ async addToAllowList(signer: TSigner, collectionId: number, addressObj: ICrossAccountId, label?: string): Promise<boolean> {
+ if(typeof label === 'undefined') label = `collection #${collectionId}`;
+ const result = await this.helper.executeExtrinsic(
+ signer,
+ 'api.tx.unique.addToAllowList', [collectionId, addressObj],
+ true, `Unable to add address to allow list for ${label}`,
+ );
+
+ return this.helper.util.findCollectionInEvents(result.result.events, collectionId, 'unique', 'AllowListAddressAdded');
+ }
+
+ /**
* Removes a collection administrator.
*
* @param signer keyring of signer
@@ -2119,6 +2027,10 @@
return await this.helper.collection.getAdmins(this.collectionId);
}
+ async getAllowList() {
+ return await this.helper.collection.getAllowList(this.collectionId);
+ }
+
async getEffectiveLimits() {
return await this.helper.collection.getEffectiveLimits(this.collectionId);
}
@@ -2143,6 +2055,10 @@
return await this.helper.collection.addAdmin(signer, this.collectionId, adminAddressObj, label);
}
+ async addToAllowList(signer: TSigner, addressObj: ICrossAccountId, label?: string) {
+ return await this.helper.collection.addToAllowList(signer, this.collectionId, addressObj, label);
+ }
+
async removeAdmin(signer: TSigner, adminAddressObj: ICrossAccountId, label?: string) {
return await this.helper.collection.removeAdmin(signer, this.collectionId, adminAddressObj, label);
}