difftreelog
Parachain compatible with polkadot v0.9.3
in: master
16 files changed
.gitignorediffbeforeafterboth--- a/.gitignore
+++ b/.gitignore
@@ -12,4 +12,8 @@
/.idea/
-tests/.vscode
\ No newline at end of file
+tests/.vscode
+cumulus-parachain/
+*genesis
+*wasm
+tmp/
\ No newline at end of file
Cargo.lockdiffbeforeafterboth--- a/Cargo.lock
+++ b/Cargo.lock
@@ -464,7 +464,7 @@
[[package]]
name = "beefy-gadget"
version = "0.1.0"
-source = "git+https://github.com/paritytech/grandpa-bridge-gadget?branch=rococo-v1#b0e5f2da52cc9bc9804a23e111d003413b268faf"
+source = "git+https://github.com/paritytech/grandpa-bridge-gadget?branch=polkadot-v0.9.3#063e18a1f82945d5a304906db92bfbb571bac459"
dependencies = [
"beefy-primitives",
"futures 0.3.14",
@@ -478,6 +478,7 @@
"sc-network-gossip",
"sp-api",
"sp-application-crypto",
+ "sp-arithmetic",
"sp-blockchain",
"sp-consensus",
"sp-core",
@@ -491,7 +492,7 @@
[[package]]
name = "beefy-gadget-rpc"
version = "0.1.0"
-source = "git+https://github.com/paritytech/grandpa-bridge-gadget?branch=rococo-v1#b0e5f2da52cc9bc9804a23e111d003413b268faf"
+source = "git+https://github.com/paritytech/grandpa-bridge-gadget?branch=polkadot-v0.9.3#063e18a1f82945d5a304906db92bfbb571bac459"
dependencies = [
"beefy-gadget",
"beefy-primitives",
@@ -512,7 +513,7 @@
[[package]]
name = "beefy-primitives"
version = "0.1.0"
-source = "git+https://github.com/paritytech/grandpa-bridge-gadget?branch=rococo-v1#b0e5f2da52cc9bc9804a23e111d003413b268faf"
+source = "git+https://github.com/paritytech/grandpa-bridge-gadget?branch=polkadot-v0.9.3#063e18a1f82945d5a304906db92bfbb571bac459"
dependencies = [
"parity-scale-codec",
"sp-api",
@@ -692,6 +693,114 @@
]
[[package]]
+name = "bp-header-chain"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "finality-grandpa",
+ "frame-support",
+ "parity-scale-codec",
+ "serde",
+ "sp-core",
+ "sp-finality-grandpa",
+ "sp-runtime",
+ "sp-std",
+]
+
+[[package]]
+name = "bp-messages"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "bp-runtime",
+ "frame-support",
+ "frame-system",
+ "parity-scale-codec",
+ "sp-std",
+]
+
+[[package]]
+name = "bp-polkadot-core"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "bp-messages",
+ "bp-runtime",
+ "frame-support",
+ "frame-system",
+ "parity-scale-codec",
+ "sp-api",
+ "sp-core",
+ "sp-runtime",
+ "sp-std",
+ "sp-version",
+]
+
+[[package]]
+name = "bp-rococo"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "bp-header-chain",
+ "bp-messages",
+ "bp-polkadot-core",
+ "bp-runtime",
+ "parity-scale-codec",
+ "sp-api",
+ "sp-runtime",
+ "sp-std",
+ "sp-version",
+]
+
+[[package]]
+name = "bp-runtime"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "frame-support",
+ "hash-db",
+ "num-traits",
+ "parity-scale-codec",
+ "sp-core",
+ "sp-io",
+ "sp-runtime",
+ "sp-state-machine",
+ "sp-std",
+ "sp-trie",
+]
+
+[[package]]
+name = "bp-test-utils"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "bp-header-chain",
+ "ed25519-dalek",
+ "finality-grandpa",
+ "parity-scale-codec",
+ "sp-application-crypto",
+ "sp-finality-grandpa",
+ "sp-runtime",
+ "sp-std",
+]
+
+[[package]]
+name = "bp-wococo"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "bp-header-chain",
+ "bp-messages",
+ "bp-polkadot-core",
+ "bp-runtime",
+ "parity-scale-codec",
+ "sp-api",
+ "sp-runtime",
+ "sp-std",
+ "sp-version",
+]
+
+[[package]]
name = "bs58"
version = "0.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -1242,7 +1351,7 @@
[[package]]
name = "cumulus-client-cli"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"sc-cli",
"sc-service",
@@ -1252,65 +1361,68 @@
[[package]]
name = "cumulus-client-collator"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"cumulus-client-consensus-common",
"cumulus-client-network",
"cumulus-primitives-core",
"futures 0.3.14",
"parity-scale-codec",
- "parking_lot 0.9.0",
+ "parking_lot 0.10.2",
"polkadot-node-primitives",
"polkadot-node-subsystem",
"polkadot-overseer",
"polkadot-primitives",
"sc-client-api",
+ "sp-api",
"sp-consensus",
"sp-core",
"sp-io",
"sp-runtime",
- "sp-state-machine",
"tracing",
]
[[package]]
-name = "cumulus-client-consensus-common"
+name = "cumulus-client-consensus-aura"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"async-trait",
- "dyn-clone",
+ "cumulus-client-consensus-common",
+ "cumulus-primitives-core",
"futures 0.3.14",
"parity-scale-codec",
- "polkadot-primitives",
- "polkadot-runtime",
+ "parking_lot 0.10.2",
+ "polkadot-service",
"sc-client-api",
+ "sc-consensus-aura",
+ "sc-consensus-slots",
+ "sc-telemetry",
"sp-api",
+ "sp-application-crypto",
"sp-block-builder",
"sp-blockchain",
"sp-consensus",
+ "sp-consensus-aura",
"sp-core",
"sp-inherents",
+ "sp-keystore",
"sp-runtime",
- "sp-trie",
"substrate-prometheus-endpoint",
- "tokio 0.1.22",
"tracing",
]
[[package]]
-name = "cumulus-client-consensus-relay-chain"
+name = "cumulus-client-consensus-common"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"async-trait",
- "cumulus-client-consensus-common",
- "cumulus-primitives-core",
- "cumulus-primitives-parachain-inherent",
+ "dyn-clone",
"futures 0.3.14",
"parity-scale-codec",
- "parking_lot 0.9.0",
- "polkadot-service",
+ "polkadot-primitives",
+ "polkadot-runtime",
"sc-client-api",
"sp-api",
"sp-block-builder",
@@ -1319,6 +1431,7 @@
"sp-core",
"sp-inherents",
"sp-runtime",
+ "sp-trie",
"substrate-prometheus-endpoint",
"tracing",
]
@@ -1326,7 +1439,7 @@
[[package]]
name = "cumulus-client-network"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"derive_more",
"futures 0.3.14",
@@ -1348,19 +1461,48 @@
]
[[package]]
+name = "cumulus-client-pov-recovery"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
+dependencies = [
+ "cumulus-primitives-core",
+ "futures 0.3.14",
+ "futures-timer 3.0.2",
+ "parity-scale-codec",
+ "polkadot-node-primitives",
+ "polkadot-node-subsystem",
+ "polkadot-overseer",
+ "polkadot-parachain",
+ "polkadot-primitives",
+ "polkadot-service",
+ "polkadot-statement-table",
+ "rand 0.8.3",
+ "sc-client-api",
+ "sp-api",
+ "sp-consensus",
+ "sp-core",
+ "sp-maybe-compressed-blob",
+ "sp-runtime",
+ "tracing",
+]
+
+[[package]]
name = "cumulus-client-service"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"cumulus-client-collator",
"cumulus-client-consensus-common",
+ "cumulus-client-pov-recovery",
"cumulus-primitives-core",
- "futures 0.3.14",
"parity-scale-codec",
+ "parking_lot 0.10.2",
+ "polkadot-overseer",
"polkadot-primitives",
"polkadot-service",
"sc-chain-spec",
"sc-client-api",
+ "sc-consensus-babe",
"sc-service",
"sc-telemetry",
"sc-tracing",
@@ -1373,9 +1515,45 @@
]
[[package]]
+name = "cumulus-pallet-aura-ext"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
+dependencies = [
+ "frame-executive",
+ "frame-support",
+ "frame-system",
+ "pallet-aura",
+ "parity-scale-codec",
+ "serde",
+ "sp-application-crypto",
+ "sp-consensus-aura",
+ "sp-runtime",
+ "sp-std",
+]
+
+[[package]]
+name = "cumulus-pallet-dmp-queue"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
+dependencies = [
+ "cumulus-primitives-core",
+ "frame-support",
+ "frame-system",
+ "log",
+ "parity-scale-codec",
+ "rand 0.8.3",
+ "rand_chacha 0.3.0",
+ "sp-io",
+ "sp-runtime",
+ "sp-std",
+ "xcm",
+ "xcm-executor",
+]
+
+[[package]]
name = "cumulus-pallet-parachain-system"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"cumulus-primitives-core",
"cumulus-primitives-parachain-inherent",
@@ -1405,13 +1583,14 @@
[[package]]
name = "cumulus-pallet-xcm"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"cumulus-primitives-core",
"frame-support",
"frame-system",
"parity-scale-codec",
"serde",
+ "sp-io",
"sp-runtime",
"sp-std",
"xcm",
@@ -1420,7 +1599,7 @@
[[package]]
name = "cumulus-pallet-xcmp-queue"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"cumulus-primitives-core",
"frame-support",
@@ -1438,7 +1617,7 @@
[[package]]
name = "cumulus-primitives-core"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"frame-support",
"impl-trait-for-tuples",
@@ -1446,6 +1625,7 @@
"polkadot-core-primitives",
"polkadot-parachain",
"polkadot-primitives",
+ "sp-api",
"sp-runtime",
"sp-std",
"sp-trie",
@@ -1455,10 +1635,12 @@
[[package]]
name = "cumulus-primitives-parachain-inherent"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
+ "async-trait",
"cumulus-primitives-core",
"parity-scale-codec",
+ "polkadot-service",
"sc-client-api",
"sp-api",
"sp-core",
@@ -1473,7 +1655,7 @@
[[package]]
name = "cumulus-primitives-utility"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"cumulus-primitives-core",
"frame-support",
@@ -1759,9 +1941,9 @@
[[package]]
name = "environmental"
-version = "1.1.2"
+version = "1.1.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6576a1755ddffd988788025e75bce9e74b018f7cc226198fe931d077911c6d7e"
+checksum = "68b91989ae21441195d7d9b9993a2f9295c7e1a8c96255d8b729accddc124797"
[[package]]
name = "erased-serde"
@@ -1968,7 +2150,7 @@
[[package]]
name = "fork-tree"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
]
@@ -1986,7 +2168,7 @@
[[package]]
name = "frame-benchmarking"
version = "3.1.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -2005,7 +2187,7 @@
[[package]]
name = "frame-benchmarking-cli"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"Inflector",
"chrono",
@@ -2028,7 +2210,7 @@
[[package]]
name = "frame-election-provider-support"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -2041,7 +2223,7 @@
[[package]]
name = "frame-executive"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -2056,7 +2238,7 @@
[[package]]
name = "frame-metadata"
version = "13.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"serde",
@@ -2067,7 +2249,7 @@
[[package]]
name = "frame-support"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"bitflags",
"frame-metadata",
@@ -2093,7 +2275,7 @@
[[package]]
name = "frame-support-procedural"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"Inflector",
"frame-support-procedural-tools",
@@ -2105,7 +2287,7 @@
[[package]]
name = "frame-support-procedural-tools"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support-procedural-tools-derive",
"proc-macro-crate 1.0.0",
@@ -2117,7 +2299,7 @@
[[package]]
name = "frame-support-procedural-tools-derive"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"proc-macro2",
"quote",
@@ -2127,7 +2309,7 @@
[[package]]
name = "frame-system"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"impl-trait-for-tuples",
@@ -2144,7 +2326,7 @@
[[package]]
name = "frame-system-benchmarking"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-benchmarking",
"frame-support",
@@ -2158,7 +2340,7 @@
[[package]]
name = "frame-system-rpc-runtime-api"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"sp-api",
@@ -2167,7 +2349,7 @@
[[package]]
name = "frame-try-runtime"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"parity-scale-codec",
@@ -2545,14 +2727,14 @@
[[package]]
name = "handlebars"
-version = "3.5.4"
+version = "3.5.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "580b6f551b29a3a02436318aed09ba1c58eea177dc49e39beac627ad356730a5"
+checksum = "4498fc115fa7d34de968184e473529abb40eeb6be8bc5f7faba3d08c316cb3e3"
dependencies = [
"log",
"pest",
"pest_derive",
- "quick-error 2.0.0",
+ "quick-error 2.0.1",
"serde",
"serde_json",
]
@@ -3143,9 +3325,9 @@
[[package]]
name = "jsonrpsee-http-client"
-version = "0.2.0-alpha.5"
+version = "0.2.0-alpha.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7e3a49473ea266be8e9f23e20a7bfa4349109b42319d72cc0b8a101e18fa6466"
+checksum = "2737440f37efa10e5ef7beeec43d059d29dc92640978be21fcdcef481a2edb0d"
dependencies = [
"async-trait",
"fnv",
@@ -3162,9 +3344,9 @@
[[package]]
name = "jsonrpsee-proc-macros"
-version = "0.2.0-alpha.5"
+version = "0.2.0-alpha.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b0cbaee9ca6440e191545a68c7bf28db0ff918359a904e37a6e7cf7edd132f5a"
+checksum = "5784ee8bb31988fa2c7a755fe31b0e21aa51894a67e5c99b6d4470f0253bf31a"
dependencies = [
"Inflector",
"proc-macro-crate 1.0.0",
@@ -3218,8 +3400,8 @@
[[package]]
name = "kusama-runtime"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"beefy-primitives",
"bitvec",
@@ -3238,6 +3420,7 @@
"pallet-democracy",
"pallet-election-provider-multi-phase",
"pallet-elections-phragmen",
+ "pallet-gilt",
"pallet-grandpa",
"pallet-identity",
"pallet-im-online",
@@ -3254,7 +3437,7 @@
"pallet-session",
"pallet-society",
"pallet-staking",
- "pallet-staking-reward-curve",
+ "pallet-staking-reward-fn",
"pallet-timestamp",
"pallet-tips",
"pallet-transaction-payment",
@@ -3262,14 +3445,17 @@
"pallet-treasury",
"pallet-utility",
"pallet-vesting",
+ "pallet-xcm",
"parity-scale-codec",
"polkadot-primitives",
"polkadot-runtime-common",
+ "polkadot-runtime-parachains",
"rustc-hex",
"serde",
"serde_derive",
"smallvec 1.6.1",
"sp-api",
+ "sp-arithmetic",
"sp-authority-discovery",
"sp-block-builder",
"sp-consensus-babe",
@@ -3286,6 +3472,9 @@
"sp-version",
"static_assertions",
"substrate-wasm-builder 3.0.0",
+ "xcm",
+ "xcm-builder",
+ "xcm-executor",
]
[[package]]
@@ -4054,7 +4243,7 @@
[[package]]
name = "metered-channel"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"derive_more",
"futures 0.3.14",
@@ -4316,10 +4505,12 @@
dependencies = [
"cumulus-client-cli",
"cumulus-client-collator",
- "cumulus-client-consensus-relay-chain",
+ "cumulus-client-consensus-aura",
+ "cumulus-client-consensus-common",
"cumulus-client-network",
"cumulus-client-service",
"cumulus-primitives-core",
+ "cumulus-primitives-parachain-inherent",
"flexi_logger",
"frame-benchmarking",
"frame-benchmarking-cli",
@@ -4330,6 +4521,7 @@
"pallet-contracts",
"pallet-contracts-rpc",
"pallet-transaction-payment-rpc",
+ "parity-scale-codec",
"parking_lot 0.10.2",
"polkadot-cli",
"polkadot-parachain",
@@ -4362,19 +4554,25 @@
"sp-core",
"sp-finality-grandpa",
"sp-inherents",
+ "sp-keystore",
+ "sp-offchain",
"sp-runtime",
+ "sp-session",
"sp-timestamp",
"sp-transaction-pool",
"sp-trie",
"structopt",
"substrate-build-script-utils",
"substrate-frame-rpc-system",
+ "substrate-prometheus-endpoint",
]
[[package]]
name = "nft-runtime"
version = "3.0.0"
dependencies = [
+ "cumulus-pallet-aura-ext",
+ "cumulus-pallet-dmp-queue",
"cumulus-pallet-parachain-system",
"cumulus-pallet-xcm",
"cumulus-pallet-xcmp-queue",
@@ -4387,6 +4585,7 @@
"frame-system-benchmarking",
"frame-system-rpc-runtime-api",
"hex-literal",
+ "pallet-aura",
"pallet-balances",
"pallet-contracts",
"pallet-contracts-primitives",
@@ -4409,6 +4608,7 @@
"sp-api",
"sp-arithmetic",
"sp-block-builder",
+ "sp-consensus-aura",
"sp-core",
"sp-inherents",
"sp-io",
@@ -4585,9 +4785,25 @@
]
[[package]]
+name = "pallet-aura"
+version = "3.0.0"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
+dependencies = [
+ "frame-support",
+ "frame-system",
+ "pallet-session",
+ "pallet-timestamp",
+ "parity-scale-codec",
+ "sp-application-crypto",
+ "sp-consensus-aura",
+ "sp-runtime",
+ "sp-std",
+]
+
+[[package]]
name = "pallet-authority-discovery"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -4602,14 +4818,13 @@
[[package]]
name = "pallet-authorship"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
"impl-trait-for-tuples",
"parity-scale-codec",
"sp-authorship",
- "sp-inherents",
"sp-runtime",
"sp-std",
]
@@ -4617,7 +4832,7 @@
[[package]]
name = "pallet-babe"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-benchmarking",
"frame-support",
@@ -4640,7 +4855,7 @@
[[package]]
name = "pallet-balances"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-benchmarking",
"frame-support",
@@ -4654,7 +4869,7 @@
[[package]]
name = "pallet-beefy"
version = "0.1.0"
-source = "git+https://github.com/paritytech/grandpa-bridge-gadget?branch=rococo-v1#b0e5f2da52cc9bc9804a23e111d003413b268faf"
+source = "git+https://github.com/paritytech/grandpa-bridge-gadget?branch=polkadot-v0.9.3#063e18a1f82945d5a304906db92bfbb571bac459"
dependencies = [
"beefy-primitives",
"frame-support",
@@ -4669,7 +4884,7 @@
[[package]]
name = "pallet-bounties"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -4680,9 +4895,30 @@
]
[[package]]
+name = "pallet-bridge-grandpa"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "bp-header-chain",
+ "bp-runtime",
+ "bp-test-utils",
+ "finality-grandpa",
+ "frame-support",
+ "frame-system",
+ "log",
+ "num-traits",
+ "parity-scale-codec",
+ "serde",
+ "sp-finality-grandpa",
+ "sp-runtime",
+ "sp-std",
+ "sp-trie",
+]
+
+[[package]]
name = "pallet-collective"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -4697,7 +4933,7 @@
[[package]]
name = "pallet-contracts"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -4708,6 +4944,7 @@
"parity-wasm 0.42.2",
"pwasm-utils 0.17.1",
"serde",
+ "smallvec 1.6.1",
"sp-core",
"sp-io",
"sp-runtime",
@@ -4719,7 +4956,7 @@
[[package]]
name = "pallet-contracts-primitives"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"bitflags",
"parity-scale-codec",
@@ -4732,7 +4969,7 @@
[[package]]
name = "pallet-contracts-proc-macro"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"proc-macro2",
"quote",
@@ -4742,7 +4979,7 @@
[[package]]
name = "pallet-contracts-rpc"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"jsonrpc-core",
"jsonrpc-core-client",
@@ -4761,7 +4998,7 @@
[[package]]
name = "pallet-contracts-rpc-runtime-api"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"pallet-contracts-primitives",
"parity-scale-codec",
@@ -4773,7 +5010,7 @@
[[package]]
name = "pallet-democracy"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-benchmarking",
"frame-support",
@@ -4788,7 +5025,7 @@
[[package]]
name = "pallet-election-provider-multi-phase"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-election-provider-support",
"frame-support",
@@ -4796,6 +5033,7 @@
"log",
"parity-scale-codec",
"sp-arithmetic",
+ "sp-core",
"sp-io",
"sp-npos-elections",
"sp-runtime",
@@ -4806,7 +5044,7 @@
[[package]]
name = "pallet-elections-phragmen"
version = "4.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -4820,9 +5058,23 @@
]
[[package]]
+name = "pallet-gilt"
+version = "3.0.0"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
+dependencies = [
+ "frame-benchmarking",
+ "frame-support",
+ "frame-system",
+ "parity-scale-codec",
+ "sp-arithmetic",
+ "sp-runtime",
+ "sp-std",
+]
+
+[[package]]
name = "pallet-grandpa"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-benchmarking",
"frame-support",
@@ -4843,7 +5095,7 @@
[[package]]
name = "pallet-identity"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"enumflags2",
"frame-benchmarking",
@@ -4858,7 +5110,7 @@
[[package]]
name = "pallet-im-online"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -4876,7 +5128,7 @@
[[package]]
name = "pallet-indices"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -4909,7 +5161,7 @@
[[package]]
name = "pallet-membership"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-benchmarking",
"frame-support",
@@ -4924,7 +5176,7 @@
[[package]]
name = "pallet-mmr"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"ckb-merkle-mountain-range",
"frame-benchmarking",
@@ -4941,7 +5193,7 @@
[[package]]
name = "pallet-mmr-primitives"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -4957,7 +5209,7 @@
[[package]]
name = "pallet-mmr-rpc"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"jsonrpc-core",
"jsonrpc-core-client",
@@ -4975,7 +5227,7 @@
[[package]]
name = "pallet-multisig"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5009,7 +5261,7 @@
[[package]]
name = "pallet-nicks"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5022,7 +5274,7 @@
[[package]]
name = "pallet-offences"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5038,7 +5290,7 @@
[[package]]
name = "pallet-proxy"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5052,7 +5304,7 @@
[[package]]
name = "pallet-randomness-collective-flip"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5065,7 +5317,7 @@
[[package]]
name = "pallet-recovery"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"enumflags2",
"frame-support",
@@ -5079,7 +5331,7 @@
[[package]]
name = "pallet-scheduler"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-benchmarking",
"frame-support",
@@ -5094,7 +5346,7 @@
[[package]]
name = "pallet-session"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5113,7 +5365,7 @@
[[package]]
name = "pallet-society"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5126,7 +5378,7 @@
[[package]]
name = "pallet-staking"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-election-provider-support",
"frame-support",
@@ -5148,7 +5400,7 @@
[[package]]
name = "pallet-staking-reward-curve"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"proc-macro-crate 1.0.0",
"proc-macro2",
@@ -5157,9 +5409,18 @@
]
[[package]]
+name = "pallet-staking-reward-fn"
+version = "3.0.0"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
+dependencies = [
+ "log",
+ "sp-arithmetic",
+]
+
+[[package]]
name = "pallet-sudo"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5172,7 +5433,7 @@
[[package]]
name = "pallet-timestamp"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-benchmarking",
"frame-support",
@@ -5190,7 +5451,7 @@
[[package]]
name = "pallet-tips"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5204,7 +5465,7 @@
[[package]]
name = "pallet-transaction-payment"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5220,7 +5481,7 @@
[[package]]
name = "pallet-transaction-payment-rpc"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"jsonrpc-core",
"jsonrpc-core-client",
@@ -5237,7 +5498,7 @@
[[package]]
name = "pallet-transaction-payment-rpc-runtime-api"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"pallet-transaction-payment",
"parity-scale-codec",
@@ -5248,7 +5509,7 @@
[[package]]
name = "pallet-treasury"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5263,7 +5524,7 @@
[[package]]
name = "pallet-utility"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-support",
"frame-system",
@@ -5277,7 +5538,7 @@
[[package]]
name = "pallet-vesting"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"enumflags2",
"frame-support",
@@ -5290,7 +5551,7 @@
[[package]]
name = "pallet-xcm"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"frame-support",
"frame-system",
@@ -5299,17 +5560,19 @@
"sp-runtime",
"sp-std",
"xcm",
+ "xcm-executor",
]
[[package]]
name = "parachain-info"
version = "0.1.0"
-source = "git+https://github.com/paritytech/cumulus.git?branch=rococo-v1#da4c3bac6e9584e65740ef5db4dbd2c31c1a91db"
+source = "git+https://github.com/paritytech/cumulus.git?branch=polkadot-v0.9.3#78b31b21122995b49f3c2cfe2791f188e33e5917"
dependencies = [
"cumulus-primitives-core",
"frame-support",
"frame-system",
"parity-scale-codec",
+ "serde",
]
[[package]]
@@ -5721,7 +5984,7 @@
[[package]]
name = "polkadot-approval-distribution"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"polkadot-node-network-protocol",
@@ -5735,10 +5998,9 @@
[[package]]
name = "polkadot-availability-bitfield-distribution"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
- "parity-scale-codec",
"polkadot-node-network-protocol",
"polkadot-node-subsystem",
"polkadot-node-subsystem-util",
@@ -5749,7 +6011,7 @@
[[package]]
name = "polkadot-availability-distribution"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"lru",
@@ -5772,7 +6034,7 @@
[[package]]
name = "polkadot-availability-recovery"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"lru",
@@ -5790,8 +6052,8 @@
[[package]]
name = "polkadot-cli"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"frame-benchmarking-cli",
"futures 0.3.14",
@@ -5811,7 +6073,7 @@
[[package]]
name = "polkadot-collator-protocol"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"always-assert",
"futures 0.3.14",
@@ -5830,8 +6092,8 @@
[[package]]
name = "polkadot-core-primitives"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"parity-scale-codec",
"parity-util-mem",
@@ -5842,8 +6104,8 @@
[[package]]
name = "polkadot-erasure-coding"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"parity-scale-codec",
"polkadot-node-primitives",
@@ -5857,7 +6119,7 @@
[[package]]
name = "polkadot-gossip-support"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"polkadot-node-network-protocol",
@@ -5872,7 +6134,7 @@
[[package]]
name = "polkadot-network-bridge"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"async-trait",
"futures 0.3.14",
@@ -5892,7 +6154,7 @@
[[package]]
name = "polkadot-node-collation-generation"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"parity-scale-codec",
@@ -5910,7 +6172,7 @@
[[package]]
name = "polkadot-node-core-approval-voting"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"bitvec",
"derive_more",
@@ -5939,7 +6201,7 @@
[[package]]
name = "polkadot-node-core-av-store"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"bitvec",
"futures 0.3.14",
@@ -5959,7 +6221,7 @@
[[package]]
name = "polkadot-node-core-backing"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"bitvec",
"futures 0.3.14",
@@ -5977,7 +6239,7 @@
[[package]]
name = "polkadot-node-core-bitfield-signing"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"polkadot-node-subsystem",
@@ -5992,7 +6254,7 @@
[[package]]
name = "polkadot-node-core-candidate-selection"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"polkadot-node-primitives",
@@ -6007,7 +6269,7 @@
[[package]]
name = "polkadot-node-core-candidate-validation"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"async-trait",
"futures 0.3.14",
@@ -6025,7 +6287,7 @@
[[package]]
name = "polkadot-node-core-chain-api"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"polkadot-node-subsystem",
@@ -6036,34 +6298,27 @@
]
[[package]]
-name = "polkadot-node-core-proposer"
+name = "polkadot-node-core-parachains-inherent"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
+ "async-trait",
"futures 0.3.14",
"futures-timer 3.0.2",
"polkadot-node-subsystem",
"polkadot-overseer",
"polkadot-primitives",
- "sc-basic-authorship",
- "sc-block-builder",
- "sc-client-api",
- "sc-telemetry",
- "sp-api",
"sp-blockchain",
- "sp-consensus",
- "sp-core",
"sp-inherents",
"sp-runtime",
- "sp-transaction-pool",
- "substrate-prometheus-endpoint",
+ "thiserror",
"tracing",
]
[[package]]
name = "polkadot-node-core-provisioner"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"bitvec",
"futures 0.3.14",
@@ -6078,7 +6333,7 @@
[[package]]
name = "polkadot-node-core-pvf"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"always-assert",
"assert_matches",
@@ -6106,7 +6361,7 @@
[[package]]
name = "polkadot-node-core-runtime-api"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"memory-lru",
@@ -6124,7 +6379,7 @@
[[package]]
name = "polkadot-node-jaeger"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"async-std",
"lazy_static",
@@ -6142,7 +6397,7 @@
[[package]]
name = "polkadot-node-network-protocol"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"parity-scale-codec",
@@ -6157,7 +6412,7 @@
[[package]]
name = "polkadot-node-primitives"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"futures 0.3.14",
"parity-scale-codec",
@@ -6179,7 +6434,7 @@
[[package]]
name = "polkadot-node-subsystem"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"async-std",
"async-trait",
@@ -6209,7 +6464,7 @@
[[package]]
name = "polkadot-node-subsystem-util"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"async-trait",
"futures 0.3.14",
@@ -6237,7 +6492,7 @@
[[package]]
name = "polkadot-overseer"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"async-trait",
"futures 0.3.14",
@@ -6246,6 +6501,7 @@
"polkadot-node-subsystem",
"polkadot-node-subsystem-util",
"polkadot-primitives",
+ "polkadot-procmacro-overseer-subsystems-gen",
"sc-client-api",
"sp-api",
"tracing",
@@ -6253,8 +6509,8 @@
[[package]]
name = "polkadot-parachain"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"derive_more",
"parity-scale-codec",
@@ -6268,8 +6524,8 @@
[[package]]
name = "polkadot-primitives"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"bitvec",
"frame-system",
@@ -6296,9 +6552,20 @@
]
[[package]]
+name = "polkadot-procmacro-overseer-subsystems-gen"
+version = "0.1.0"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
+dependencies = [
+ "assert_matches",
+ "proc-macro2",
+ "quote",
+ "syn",
+]
+
+[[package]]
name = "polkadot-procmacro-subsystem-dispatch-gen"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"assert_matches",
"proc-macro2",
@@ -6308,8 +6575,8 @@
[[package]]
name = "polkadot-rpc"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"beefy-gadget",
"beefy-gadget-rpc",
@@ -6341,8 +6608,8 @@
[[package]]
name = "polkadot-runtime"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"beefy-primitives",
"bitvec",
@@ -6411,8 +6678,8 @@
[[package]]
name = "polkadot-runtime-common"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"beefy-primitives",
"bitvec",
@@ -6453,8 +6720,8 @@
[[package]]
name = "polkadot-runtime-parachains"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"bitvec",
"derive_more",
@@ -6490,8 +6757,8 @@
[[package]]
name = "polkadot-service"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"beefy-gadget",
"beefy-primitives",
@@ -6522,7 +6789,7 @@
"polkadot-node-core-candidate-selection",
"polkadot-node-core-candidate-validation",
"polkadot-node-core-chain-api",
- "polkadot-node-core-proposer",
+ "polkadot-node-core-parachains-inherent",
"polkadot-node-core-provisioner",
"polkadot-node-core-runtime-api",
"polkadot-node-primitives",
@@ -6537,6 +6804,7 @@
"polkadot-statement-distribution",
"rococo-runtime",
"sc-authority-discovery",
+ "sc-basic-authorship",
"sc-block-builder",
"sc-chain-spec",
"sc-client-api",
@@ -6544,6 +6812,7 @@
"sc-consensus",
"sc-consensus-babe",
"sc-consensus-slots",
+ "sc-consensus-uncles",
"sc-executor",
"sc-finality-grandpa",
"sc-finality-grandpa-warp-sync",
@@ -6569,6 +6838,7 @@
"sp-session",
"sp-state-machine",
"sp-storage",
+ "sp-timestamp",
"sp-transaction-pool",
"sp-trie",
"substrate-prometheus-endpoint",
@@ -6580,7 +6850,7 @@
[[package]]
name = "polkadot-statement-distribution"
version = "0.1.0"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"arrayvec 0.5.2",
"futures 0.3.14",
@@ -6592,14 +6862,16 @@
"polkadot-node-subsystem-util",
"polkadot-primitives",
"sc-network",
+ "sp-keystore",
"sp-staking",
+ "thiserror",
"tracing",
]
[[package]]
name = "polkadot-statement-table"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"parity-scale-codec",
"polkadot-primitives",
@@ -6608,8 +6880,8 @@
[[package]]
name = "polkadot-test-runtime"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"beefy-primitives",
"bitvec",
@@ -6665,8 +6937,8 @@
[[package]]
name = "polkadot-test-service"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#943038a888bfaf736142642e2610b248f7af486c"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"frame-benchmarking",
"frame-system",
@@ -6936,9 +7208,9 @@
[[package]]
name = "quick-error"
-version = "2.0.0"
+version = "2.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3ac73b1112776fc109b2e61909bc46c7e1bf0d7f690ffb1676553acce16d5cda"
+checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3"
[[package]]
name = "quicksink"
@@ -7267,7 +7539,7 @@
[[package]]
name = "remote-externalities"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"env_logger 0.8.3",
"hex-literal",
@@ -7342,10 +7614,12 @@
[[package]]
name = "rococo-runtime"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"beefy-primitives",
+ "bp-rococo",
+ "bp-wococo",
"frame-executive",
"frame-support",
"frame-system",
@@ -7357,6 +7631,7 @@
"pallet-babe",
"pallet-balances",
"pallet-beefy",
+ "pallet-bridge-grandpa",
"pallet-collective",
"pallet-grandpa",
"pallet-im-online",
@@ -7547,7 +7822,7 @@
[[package]]
name = "sc-authority-discovery"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"derive_more",
@@ -7576,7 +7851,7 @@
[[package]]
name = "sc-basic-authorship"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.3.14",
"futures-timer 3.0.2",
@@ -7599,7 +7874,7 @@
[[package]]
name = "sc-block-builder"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"sc-client-api",
@@ -7615,7 +7890,7 @@
[[package]]
name = "sc-chain-spec"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"impl-trait-for-tuples",
"parity-scale-codec",
@@ -7636,7 +7911,7 @@
[[package]]
name = "sc-chain-spec-derive"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"proc-macro-crate 1.0.0",
"proc-macro2",
@@ -7647,7 +7922,7 @@
[[package]]
name = "sc-cli"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"chrono",
"fdlimit",
@@ -7685,7 +7960,7 @@
[[package]]
name = "sc-client-api"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"fnv",
@@ -7719,7 +7994,7 @@
[[package]]
name = "sc-client-db"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"blake2-rfc",
"hash-db",
@@ -7749,7 +8024,7 @@
[[package]]
name = "sc-consensus"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parking_lot 0.11.1",
"sc-client-api",
@@ -7761,7 +8036,7 @@
[[package]]
name = "sc-consensus-aura"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"derive_more",
@@ -7785,7 +8060,6 @@
"sp-io",
"sp-keystore",
"sp-runtime",
- "sp-timestamp",
"sp-version",
"substrate-prometheus-endpoint",
]
@@ -7793,7 +8067,7 @@
[[package]]
name = "sc-consensus-babe"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"derive_more",
@@ -7831,7 +8105,6 @@
"sp-io",
"sp-keystore",
"sp-runtime",
- "sp-timestamp",
"sp-utils",
"sp-version",
"substrate-prometheus-endpoint",
@@ -7840,7 +8113,7 @@
[[package]]
name = "sc-consensus-babe-rpc"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"futures 0.3.14",
@@ -7864,7 +8137,7 @@
[[package]]
name = "sc-consensus-epochs"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"fork-tree",
"parity-scale-codec",
@@ -7877,11 +8150,12 @@
[[package]]
name = "sc-consensus-slots"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"futures 0.3.14",
"futures-timer 3.0.2",
+ "impl-trait-for-tuples",
"log",
"parity-scale-codec",
"sc-client-api",
@@ -7904,21 +8178,18 @@
[[package]]
name = "sc-consensus-uncles"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
- "log",
"sc-client-api",
"sp-authorship",
- "sp-consensus",
- "sp-core",
- "sp-inherents",
"sp-runtime",
+ "thiserror",
]
[[package]]
name = "sc-executor"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"lazy_static",
@@ -7934,7 +8205,6 @@
"sp-core",
"sp-externalities",
"sp-io",
- "sp-maybe-compressed-blob",
"sp-panic-handler",
"sp-runtime-interface",
"sp-serializer",
@@ -7948,7 +8218,7 @@
[[package]]
name = "sc-executor-common"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"parity-scale-codec",
@@ -7956,6 +8226,7 @@
"pwasm-utils 0.14.0",
"sp-allocator",
"sp-core",
+ "sp-maybe-compressed-blob",
"sp-serializer",
"sp-wasm-interface",
"thiserror",
@@ -7965,7 +8236,7 @@
[[package]]
name = "sc-executor-wasmi"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"log",
"parity-scale-codec",
@@ -7980,7 +8251,7 @@
[[package]]
name = "sc-executor-wasmtime"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"log",
"parity-scale-codec",
@@ -7998,7 +8269,7 @@
[[package]]
name = "sc-finality-grandpa"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"derive_more",
@@ -8038,7 +8309,7 @@
[[package]]
name = "sc-finality-grandpa-rpc"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"finality-grandpa",
@@ -8062,7 +8333,7 @@
[[package]]
name = "sc-finality-grandpa-warp-sync"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"futures 0.3.14",
@@ -8083,7 +8354,7 @@
[[package]]
name = "sc-informant"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"ansi_term 0.12.1",
"futures 0.3.14",
@@ -8101,7 +8372,7 @@
[[package]]
name = "sc-keystore"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"derive_more",
@@ -8121,7 +8392,7 @@
[[package]]
name = "sc-light"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"hash-db",
"lazy_static",
@@ -8140,7 +8411,7 @@
[[package]]
name = "sc-network"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-std",
"async-trait",
@@ -8193,7 +8464,7 @@
[[package]]
name = "sc-network-gossip"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.3.14",
"futures-timer 3.0.2",
@@ -8210,7 +8481,7 @@
[[package]]
name = "sc-offchain"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"bytes 0.5.6",
"fnv",
@@ -8238,7 +8509,7 @@
[[package]]
name = "sc-peerset"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.3.14",
"libp2p",
@@ -8251,7 +8522,7 @@
[[package]]
name = "sc-proposer-metrics"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"log",
"substrate-prometheus-endpoint",
@@ -8260,7 +8531,7 @@
[[package]]
name = "sc-rpc"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.3.14",
"hash-db",
@@ -8286,6 +8557,7 @@
"sp-runtime",
"sp-session",
"sp-state-machine",
+ "sp-tracing",
"sp-transaction-pool",
"sp-utils",
"sp-version",
@@ -8294,7 +8566,7 @@
[[package]]
name = "sc-rpc-api"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"futures 0.3.14",
@@ -8311,6 +8583,7 @@
"sp-core",
"sp-rpc",
"sp-runtime",
+ "sp-tracing",
"sp-transaction-pool",
"sp-version",
]
@@ -8318,7 +8591,7 @@
[[package]]
name = "sc-rpc-server"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.1.31",
"jsonrpc-core",
@@ -8336,7 +8609,7 @@
[[package]]
name = "sc-service"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"directories",
@@ -8400,7 +8673,7 @@
[[package]]
name = "sc-state-db"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"log",
"parity-scale-codec",
@@ -8415,7 +8688,7 @@
[[package]]
name = "sc-sync-state-rpc"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"jsonrpc-core",
"jsonrpc-core-client",
@@ -8435,7 +8708,7 @@
[[package]]
name = "sc-telemetry"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"chrono",
"futures 0.3.14",
@@ -8455,7 +8728,7 @@
[[package]]
name = "sc-tracing"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"ansi_term 0.12.1",
"atty",
@@ -8466,23 +8739,33 @@
"parking_lot 0.11.1",
"regex",
"rustc-hash",
+ "sc-client-api",
+ "sc-rpc-server",
+ "sc-telemetry",
"sc-tracing-proc-macro",
"serde",
"serde_json",
+ "sp-api",
+ "sp-block-builder",
+ "sp-blockchain",
+ "sp-core",
+ "sp-rpc",
+ "sp-runtime",
+ "sp-storage",
"sp-tracing",
"thiserror",
"tracing",
- "tracing-core",
"tracing-log",
"tracing-subscriber",
"wasm-bindgen",
+ "wasm-timer",
"web-sys",
]
[[package]]
name = "sc-tracing-proc-macro"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"proc-macro-crate 1.0.0",
"proc-macro2",
@@ -8493,7 +8776,7 @@
[[package]]
name = "sc-transaction-graph"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"futures 0.3.14",
@@ -8515,7 +8798,7 @@
[[package]]
name = "sc-transaction-pool"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.3.14",
"futures-diagnose",
@@ -8836,9 +9119,18 @@
checksum = "c111b5bd5695e56cffe5129854aa230b39c93a305372fdbb2668ca2394eea9f8"
[[package]]
+name = "slog"
+version = "2.7.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8347046d4ebd943127157b94d63abb990fcf729dc4e9978927fdf4ac3c998d06"
+dependencies = [
+ "erased-serde",
+]
+
+[[package]]
name = "slot-range-helper"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"enumn",
"parity-scale-codec",
@@ -8929,7 +9221,7 @@
[[package]]
name = "sp-allocator"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"log",
"sp-core",
@@ -8941,7 +9233,7 @@
[[package]]
name = "sp-api"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"hash-db",
"log",
@@ -8958,7 +9250,7 @@
[[package]]
name = "sp-api-proc-macro"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"blake2-rfc",
"proc-macro-crate 1.0.0",
@@ -8970,7 +9262,7 @@
[[package]]
name = "sp-application-crypto"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"serde",
@@ -8982,7 +9274,7 @@
[[package]]
name = "sp-arithmetic"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"integer-sqrt",
"num-traits",
@@ -8996,7 +9288,7 @@
[[package]]
name = "sp-authority-discovery"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"sp-api",
@@ -9008,8 +9300,9 @@
[[package]]
name = "sp-authorship"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
+ "async-trait",
"parity-scale-codec",
"sp-inherents",
"sp-runtime",
@@ -9019,7 +9312,7 @@
[[package]]
name = "sp-block-builder"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"sp-api",
@@ -9031,7 +9324,7 @@
[[package]]
name = "sp-blockchain"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.3.14",
"log",
@@ -9049,7 +9342,7 @@
[[package]]
name = "sp-chain-spec"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"serde",
"serde_json",
@@ -9058,7 +9351,7 @@
[[package]]
name = "sp-consensus"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"futures 0.3.14",
@@ -9085,8 +9378,9 @@
[[package]]
name = "sp-consensus-aura"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
+ "async-trait",
"parity-scale-codec",
"sp-api",
"sp-application-crypto",
@@ -9101,8 +9395,9 @@
[[package]]
name = "sp-consensus-babe"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
+ "async-trait",
"merlin",
"parity-scale-codec",
"serde",
@@ -9122,7 +9417,7 @@
[[package]]
name = "sp-consensus-slots"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"sp-arithmetic",
@@ -9132,7 +9427,7 @@
[[package]]
name = "sp-consensus-vrf"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"schnorrkel",
@@ -9144,7 +9439,7 @@
[[package]]
name = "sp-core"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"base58",
"blake2-rfc",
@@ -9188,7 +9483,7 @@
[[package]]
name = "sp-database"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"kvdb",
"parking_lot 0.11.1",
@@ -9197,7 +9492,7 @@
[[package]]
name = "sp-debug-derive"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"proc-macro2",
"quote",
@@ -9207,7 +9502,7 @@
[[package]]
name = "sp-externalities"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"environmental",
"parity-scale-codec",
@@ -9218,7 +9513,7 @@
[[package]]
name = "sp-finality-grandpa"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"finality-grandpa",
"log",
@@ -9235,11 +9530,13 @@
[[package]]
name = "sp-inherents"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
+ "async-trait",
+ "impl-trait-for-tuples",
"parity-scale-codec",
- "parking_lot 0.11.1",
"sp-core",
+ "sp-runtime",
"sp-std",
"thiserror",
]
@@ -9247,7 +9544,7 @@
[[package]]
name = "sp-io"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.3.14",
"hash-db",
@@ -9258,6 +9555,7 @@
"sp-core",
"sp-externalities",
"sp-keystore",
+ "sp-maybe-compressed-blob",
"sp-runtime-interface",
"sp-state-machine",
"sp-std",
@@ -9271,7 +9569,7 @@
[[package]]
name = "sp-keyring"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"lazy_static",
"sp-core",
@@ -9282,7 +9580,7 @@
[[package]]
name = "sp-keystore"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"derive_more",
@@ -9299,7 +9597,7 @@
[[package]]
name = "sp-maybe-compressed-blob"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"ruzstd",
"zstd",
@@ -9308,7 +9606,7 @@
[[package]]
name = "sp-npos-elections"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"serde",
@@ -9321,7 +9619,7 @@
[[package]]
name = "sp-npos-elections-compact"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"proc-macro-crate 1.0.0",
"proc-macro2",
@@ -9332,7 +9630,7 @@
[[package]]
name = "sp-offchain"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"sp-api",
"sp-core",
@@ -9342,7 +9640,7 @@
[[package]]
name = "sp-panic-handler"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"backtrace",
]
@@ -9350,16 +9648,18 @@
[[package]]
name = "sp-rpc"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
+ "rustc-hash",
"serde",
"sp-core",
+ "tracing-core",
]
[[package]]
name = "sp-runtime"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"either",
"hash256-std-hasher",
@@ -9380,7 +9680,7 @@
[[package]]
name = "sp-runtime-interface"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"impl-trait-for-tuples",
"parity-scale-codec",
@@ -9397,7 +9697,7 @@
[[package]]
name = "sp-runtime-interface-proc-macro"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"Inflector",
"proc-macro-crate 1.0.0",
@@ -9409,7 +9709,7 @@
[[package]]
name = "sp-sandbox"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"sp-core",
@@ -9422,7 +9722,7 @@
[[package]]
name = "sp-serializer"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"serde",
"serde_json",
@@ -9431,7 +9731,7 @@
[[package]]
name = "sp-session"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"sp-api",
@@ -9444,7 +9744,7 @@
[[package]]
name = "sp-staking"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"parity-scale-codec",
"sp-runtime",
@@ -9454,7 +9754,7 @@
[[package]]
name = "sp-state-machine"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"hash-db",
"log",
@@ -9469,6 +9769,7 @@
"sp-std",
"sp-trie",
"thiserror",
+ "tracing",
"trie-db",
"trie-root",
]
@@ -9476,12 +9777,12 @@
[[package]]
name = "sp-std"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
[[package]]
name = "sp-storage"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"impl-serde",
"parity-scale-codec",
@@ -9494,7 +9795,7 @@
[[package]]
name = "sp-tasks"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"log",
"sp-core",
@@ -9507,23 +9808,32 @@
[[package]]
name = "sp-timestamp"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
+ "async-trait",
+ "futures-timer 3.0.2",
+ "log",
"parity-scale-codec",
"sp-api",
"sp-inherents",
"sp-runtime",
"sp-std",
+ "thiserror",
"wasm-timer",
]
[[package]]
name = "sp-tracing"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
+ "erased-serde",
"log",
"parity-scale-codec",
+ "parking_lot 0.10.2",
+ "serde",
+ "serde_json",
+ "slog",
"sp-std",
"tracing",
"tracing-core",
@@ -9533,7 +9843,7 @@
[[package]]
name = "sp-transaction-pool"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"derive_more",
"futures 0.3.14",
@@ -9549,7 +9859,7 @@
[[package]]
name = "sp-trie"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"hash-db",
"memory-db",
@@ -9563,7 +9873,7 @@
[[package]]
name = "sp-utils"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"futures 0.3.14",
"futures-core",
@@ -9575,19 +9885,32 @@
[[package]]
name = "sp-version"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"impl-serde",
"parity-scale-codec",
"serde",
"sp-runtime",
"sp-std",
+ "sp-version-proc-macro",
+]
+
+[[package]]
+name = "sp-version-proc-macro"
+version = "3.0.0"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
+dependencies = [
+ "parity-scale-codec",
+ "proc-macro-crate 1.0.0",
+ "proc-macro2",
+ "quote",
+ "syn",
]
[[package]]
name = "sp-wasm-interface"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"impl-trait-for-tuples",
"parity-scale-codec",
@@ -9746,7 +10069,7 @@
[[package]]
name = "substrate-build-script-utils"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"platforms",
]
@@ -9754,7 +10077,7 @@
[[package]]
name = "substrate-frame-rpc-system"
version = "3.0.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-system-rpc-runtime-api",
"futures 0.3.14",
@@ -9777,7 +10100,7 @@
[[package]]
name = "substrate-prometheus-endpoint"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-std",
"derive_more",
@@ -9791,7 +10114,7 @@
[[package]]
name = "substrate-test-client"
version = "2.0.1"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"async-trait",
"futures 0.1.31",
@@ -10476,7 +10799,7 @@
[[package]]
name = "try-runtime-cli"
version = "0.9.0"
-source = "git+https://github.com/paritytech/substrate.git?branch=rococo-v1#2be8fcc4236d32786c62f6f27a98e7fe7e550807"
+source = "git+https://github.com/paritytech/substrate.git?branch=polkadot-v0.9.3#c94e0cdfe5556680dca1996004751eeb114755d7"
dependencies = [
"frame-try-runtime",
"log",
@@ -11122,8 +11445,8 @@
[[package]]
name = "westend-runtime"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"beefy-primitives",
"bitvec",
@@ -11165,6 +11488,7 @@
"pallet-treasury",
"pallet-utility",
"pallet-vesting",
+ "pallet-xcm",
"parity-scale-codec",
"polkadot-parachain",
"polkadot-primitives",
@@ -11191,6 +11515,9 @@
"sp-version",
"static_assertions",
"substrate-wasm-builder 3.0.0",
+ "xcm",
+ "xcm-builder",
+ "xcm-executor",
]
[[package]]
@@ -11299,8 +11626,8 @@
[[package]]
name = "xcm"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"derivative",
"impl-trait-for-tuples",
@@ -11309,12 +11636,13 @@
[[package]]
name = "xcm-builder"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"frame-support",
"frame-system",
"impl-trait-for-tuples",
+ "pallet-transaction-payment",
"parity-scale-codec",
"polkadot-parachain",
"sp-arithmetic",
@@ -11327,8 +11655,8 @@
[[package]]
name = "xcm-executor"
-version = "0.8.30"
-source = "git+https://github.com/paritytech/polkadot?branch=rococo-v1#127eb17a25bbe2a9f2731ff11a65d7f8170f2373"
+version = "0.9.3"
+source = "git+https://github.com/paritytech/polkadot?branch=release-v0.9.3#aa386760948574af4078c59decf558d16efe15e2"
dependencies = [
"frame-support",
"impl-trait-for-tuples",
node/Cargo.tomldiffbeforeafterboth--- a/node/Cargo.toml
+++ b/node/Cargo.toml
@@ -3,189 +3,214 @@
[build-dependencies.substrate-build-script-utils]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
################################################################################
# Substrate Dependecies
+[dependencies.codec]
+default-features = false
+features = ['derive']
+package = 'parity-scale-codec'
+version = '2.0.0'
+
[dependencies.frame-benchmarking]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-benchmarking-cli]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-transaction-payment-rpc]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
+[dependencies.substrate-prometheus-endpoint]
+git = 'https://github.com/paritytech/substrate.git'
+branch = 'polkadot-v0.9.3'
+version = '0.9.0'
+
[dependencies.sc-basic-authorship]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sc-chain-spec]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sc-cli]
features = ['wasmtime']
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sc-client-api]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sc-consensus]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sc-consensus-aura]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sc-executor]
features = ['wasmtime']
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sc-finality-grandpa]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sc-keystore]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sc-rpc]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sc-rpc-api]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sc-service]
features = ['wasmtime']
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sc-telemetry]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sc-transaction-pool]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sc-tracing]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-block-builder]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-api]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-blockchain]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-consensus]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sp-consensus-aura]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.sp-core]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-finality-grandpa]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-inherents]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
+[dependencies.sp-keystore]
+git = 'https://github.com/paritytech/substrate.git'
+branch = 'polkadot-v0.9.3'
+version = '0.9.0'
+
+[dependencies.sp-offchain]
+git = 'https://github.com/paritytech/substrate.git'
+branch = 'polkadot-v0.9.3'
+version = '3.0.0'
+
[dependencies.sp-runtime]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
+version = '3.0.0'
+
+[dependencies.sp-session]
+git = 'https://github.com/paritytech/substrate.git'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-timestamp]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-transaction-pool]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-trie]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.substrate-frame-rpc-system]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-contracts]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-contracts-rpc]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sc-network]
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.9.0'
[dependencies.serde]
features = ['derive']
-optional = true
version = '1.0.119'
[dependencies.serde_json]
@@ -195,52 +220,60 @@
################################################################################
# Cumulus dependencies
-[dependencies.cumulus-client-consensus-relay-chain]
+[dependencies.cumulus-client-consensus-aura]
+git = 'https://github.com/paritytech/cumulus.git'
+branch = 'polkadot-v0.9.3'
+
+[dependencies.cumulus-client-consensus-common]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
[dependencies.cumulus-client-collator]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
[dependencies.cumulus-client-cli]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
[dependencies.cumulus-client-network]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
[dependencies.cumulus-primitives-core]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
+
+[dependencies.cumulus-primitives-parachain-inherent]
+git = 'https://github.com/paritytech/cumulus.git'
+branch = 'polkadot-v0.9.3'
[dependencies.cumulus-client-service]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
################################################################################
# Polkadot dependencies
[dependencies.polkadot-primitives]
git = "https://github.com/paritytech/polkadot"
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
[dependencies.polkadot-service]
git = "https://github.com/paritytech/polkadot"
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
[dependencies.polkadot-cli]
git = "https://github.com/paritytech/polkadot"
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
[dependencies.polkadot-test-service]
git = "https://github.com/paritytech/polkadot"
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
[dependencies.polkadot-parachain]
git = "https://github.com/paritytech/polkadot"
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
################################################################################
node/src/chain_spec.rsdiffbeforeafterboth--- a/node/src/chain_spec.rs
+++ b/node/src/chain_spec.rs
@@ -3,21 +3,18 @@
// file 'LICENSE', which is part of this source code package.
//
+use cumulus_primitives_core::ParaId;
use nft_runtime::*;
-
-use cumulus_primitives_core::ParaId;
-use parachain_runtime::{AccountId, Signature};
use sc_chain_spec::{ChainSpecExtension, ChainSpecGroup};
use sc_service::ChainType;
use sp_core::{sr25519, Pair, Public};
-use sp_finality_grandpa::AuthorityId as GrandpaId;
use sp_runtime::traits::{IdentifyAccount, Verify};
use serde::{Deserialize, Serialize};
use serde_json::map::Map;
/// Specialized `ChainSpec`. This is a specialization of the general Substrate ChainSpec type.
-pub type ChainSpec = sc_service::GenericChainSpec<GenesisConfig>;
+pub type ChainSpec = sc_service::GenericChainSpec<nft_runtime::GenesisConfig, Extensions>;
/// Helper function to generate a crypto pair from seed
pub fn get_from_seed<TPublic: Public>(seed: &str) -> <TPublic::Pair as Pair>::Public {
@@ -26,6 +23,23 @@
.public()
}
+/// The extensions for the [`ChainSpec`].
+#[derive(Debug, Clone, PartialEq, Serialize, Deserialize, ChainSpecGroup, ChainSpecExtension)]
+#[serde(deny_unknown_fields)]
+pub struct Extensions {
+ /// The relay chain of the Parachain.
+ pub relay_chain: String,
+ /// The id of the Parachain.
+ pub para_id: u32,
+}
+
+impl Extensions {
+ /// Try to get the extension from the given `ChainSpec`.
+ pub fn try_get(chain_spec: &dyn sc_service::ChainSpec) -> Option<&Self> {
+ sc_chain_spec::get_extension(chain_spec.extensions())
+ }
+}
+
type AccountPublic = <Signature as Verify>::Signer;
/// Helper function to generate an account ID from seed
@@ -34,18 +48,11 @@
AccountPublic: From<<TPublic::Pair as Pair>::Public>,
{
AccountPublic::from(get_from_seed::<TPublic>(seed)).into_account()
-}
-
-/// Helper function to generate an authority key for Aura
-pub fn authority_keys_from_seed(s: &str) -> (AuraId, GrandpaId) {
- (get_from_seed::<AuraId>(s), get_from_seed::<GrandpaId>(s))
}
pub fn development_config(id: ParaId) -> ChainSpec {
- let wasm_binary = WASM_BINARY.ok_or("Development wasm binary not available".to_string())?;
-
let mut properties = Map::new();
- properties.insert("tokenSymbol".into(), "UniqueTest".into());
+ properties.insert("tokenSymbol".into(), "testUNQ".into());
properties.insert("tokenDecimals".into(), 15.into());
properties.insert("ss58Format".into(), 42.into()); // Generic Substrate wildcard (SS58 checksum preimage)
@@ -56,21 +63,18 @@
"dev",
ChainType::Local,
move || testnet_genesis(
- wasm_binary,
- // Initial PoA authorities
- vec![
- authority_keys_from_seed("Alice"),
- ],
// Sudo account
get_account_id_from_seed::<sr25519::Public>("Alice"),
+ vec![
+ get_from_seed::<AuraId>("Alice"),
+ get_from_seed::<AuraId>("Bob"),
+ ],
// Pre-funded accounts
vec![
get_account_id_from_seed::<sr25519::Public>("Alice"),
get_account_id_from_seed::<sr25519::Public>("Bob"),
- get_account_id_from_seed::<sr25519::Public>("Alice//stash"),
- get_account_id_from_seed::<sr25519::Public>("Bob//stash"),
],
- true,
+ id,
),
// Bootnodes
vec![],
@@ -89,23 +93,19 @@
}
pub fn local_testnet_config(id: ParaId) -> ChainSpec {
- let wasm_binary = WASM_BINARY.ok_or("Development wasm binary not available".to_string())?;
-
- Ok(ChainSpec::from_genesis(
+ ChainSpec::from_genesis(
// Name
"Local Testnet",
// ID
"local_testnet",
ChainType::Local,
move || testnet_genesis(
- wasm_binary,
- // Initial PoA authorities
- vec![
- authority_keys_from_seed("Alice"),
- authority_keys_from_seed("Bob"),
- ],
// Sudo account
get_account_id_from_seed::<sr25519::Public>("Alice"),
+ vec![
+ get_from_seed::<AuraId>("Alice"),
+ get_from_seed::<AuraId>("Bob"),
+ ],
// Pre-funded accounts
vec![
get_account_id_from_seed::<sr25519::Public>("Alice"),
@@ -121,7 +121,7 @@
get_account_id_from_seed::<sr25519::Public>("Eve//stash"),
get_account_id_from_seed::<sr25519::Public>("Ferdie//stash"),
],
- true,
+ id,
),
// Bootnodes
vec![],
@@ -136,15 +136,14 @@
relay_chain: "rococo-local".into(),
para_id: id.into(),
},
- ))
+ )
}
fn testnet_genesis(
- wasm_binary: &[u8],
- initial_authorities: Vec<(AuraId, GrandpaId)>,
root_key: AccountId,
+ initial_authorities: Vec<AuraId>,
endowed_accounts: Vec<AccountId>,
- enable_println: bool,
+ id: ParaId,
) -> GenesisConfig {
let vested_accounts = vec![
@@ -152,27 +151,29 @@
];
GenesisConfig {
- system: Some(SystemConfig {
- code: wasm_binary.to_vec(),
- changes_trie_config: Default::default(),
- }),
- pallet_balances: Some(BalancesConfig {
+ system: nft_runtime::SystemConfig {
+ code: nft_runtime::WASM_BINARY
+ .expect("WASM binary was not build, please build it!")
+ .to_vec(),
+ changes_trie_config: Default::default(),
+ },
+ pallet_balances: BalancesConfig {
balances: endowed_accounts
.iter()
.cloned()
.map(|k| (k, 1 << 100))
.collect(),
- }),
- pallet_treasury: Some(Default::default()),
- pallet_sudo: Some(SudoConfig { key: root_key }),
- pallet_vesting: Some(VestingConfig {
+ },
+ pallet_treasury: Default::default(),
+ pallet_sudo: SudoConfig { key: root_key },
+ pallet_vesting: VestingConfig {
vesting: vested_accounts
.iter()
.cloned()
.map(|k| (k, 1000, 100, 1 << 98))
.collect(),
- }),
- pallet_nft: Some(NftConfig {
+ },
+ pallet_nft: NftConfig {
collection_id: vec![(
1,
Collection {
@@ -207,13 +208,11 @@
variable_on_chain_schema_limit: 1024,
const_on_chain_schema_limit: 1024,
},
- }),
- pallet_contracts: Some(ContractsConfig {
- current_schedule: ContractsSchedule {
- enable_println,
- ..Default::default()
- },
- }),
- parachain_info: parachain_runtime::ParachainInfoConfig { parachain_id: id },
+ },
+ parachain_info: nft_runtime::ParachainInfoConfig { parachain_id: id },
+ pallet_aura: nft_runtime::AuraConfig {
+ authorities: initial_authorities,
+ },
+ cumulus_pallet_aura_ext: Default::default(),
}
}
node/src/cli.rsdiffbeforeafterboth--- a/node/src/cli.rs
+++ b/node/src/cli.rs
@@ -1,4 +1,5 @@
use crate::chain_spec;
+use cumulus_client_cli;
use sc_cli;
use std::path::PathBuf;
use structopt::StructOpt;
@@ -34,6 +35,10 @@
/// Revert the chain to a previous state.
Revert(sc_cli::RevertCmd),
+
+ /// The custom benchmark subcommmand benchmarking runtime pallets.
+ #[structopt(name = "benchmark", about = "Benchmark runtime pallets.")]
+ Benchmark(frame_benchmarking_cli::BenchmarkCmd),
}
/// Command for exporting the genesis state of the parachain
@@ -75,24 +80,6 @@
}
#[derive(Debug, StructOpt)]
-pub struct RunCmd {
- #[structopt(flatten)]
- pub base: sc_cli::RunCmd,
-
- /// Id of the parachain this collator collates for.
- #[structopt(long)]
- pub parachain_id: Option<u32>,
-}
-
-impl std::ops::Deref for RunCmd {
- type Target = sc_cli::RunCmd;
-
- fn deref(&self) -> &Self::Target {
- &self.base
- }
-}
-
-#[derive(Debug, StructOpt)]
#[structopt(settings = &[
structopt::clap::AppSettings::GlobalVersion,
structopt::clap::AppSettings::ArgsNegateSubcommands,
@@ -103,14 +90,8 @@
pub subcommand: Option<Subcommand>,
#[structopt(flatten)]
- pub run: RunCmd,
+ pub run: cumulus_client_cli::RunCmd,
- /// Run node as collator.
- ///
- /// Note that this is the same as running with `--validator`.
- #[structopt(long, conflicts_with = "validator")]
- pub collator: bool,
-
/// Relaychain arguments
#[structopt(raw = true)]
pub relaychain_args: Vec<String>,
@@ -146,4 +127,4 @@
base: polkadot_cli::RunCmd::from_iter(relay_chain_args),
}
}
-}
\ No newline at end of file
+}
node/src/command.rsdiffbeforeafterboth--- a/node/src/command.rs
+++ b/node/src/command.rs
@@ -18,20 +18,20 @@
use crate::{
chain_spec,
cli::{Cli, RelayChainCli, Subcommand},
+ service::{new_partial, ParachainRuntimeExecutor}
};
use codec::Encode;
use cumulus_primitives_core::ParaId;
use cumulus_client_service::genesis::generate_genesis_block;
use log::info;
-use parachain_runtime::Block;
+use nft_runtime::{RuntimeApi, Block};
use polkadot_parachain::primitives::AccountIdConversion;
use sc_cli::{
ChainSpec, CliConfiguration, DefaultConfigurationValues, ImportParams, KeystoreParams,
NetworkParams, Result, RuntimeVersion, SharedParams, SubstrateCli,
};
use sc_service::{
- config::{BasePath, PrometheusConfig},
- PartialComponents,
+ config::{BasePath, PrometheusConfig}
};
use sp_core::hexdisplay::HexDisplay;
use sp_runtime::traits::Block as BlockT;
@@ -52,7 +52,7 @@
impl SubstrateCli for Cli {
fn impl_name() -> String {
- "Unique Node".into()
+ "Parachain Collator Template".into()
}
fn impl_version() -> String {
@@ -86,7 +86,7 @@
}
fn native_runtime_version(_: &Box<dyn ChainSpec>) -> &'static RuntimeVersion {
- ¶chain_runtime::VERSION
+ &nft_runtime::VERSION
}
}
@@ -103,7 +103,7 @@
"Parachain Collator Template\n\nThe command-line arguments provided first will be \
passed to the parachain node, while the arguments provided after -- will be passed \
to the relaychain node.\n\n\
- rococo-collator [parachain-args] -- [relaychain-args]"
+ parachain-collator [parachain-args] -- [relaychain-args]"
.into()
}
@@ -138,6 +138,24 @@
.ok_or_else(|| "Could not find wasm file in genesis state!".into())
}
+macro_rules! construct_async_run {
+ (|$components:ident, $cli:ident, $cmd:ident, $config:ident| $( $code:tt )* ) => {{
+ let runner = $cli.create_runner($cmd)?;
+ runner.async_run(|$config| {
+ let $components = new_partial::<
+ RuntimeApi,
+ ParachainRuntimeExecutor,
+ _
+ >(
+ &$config,
+ crate::service::parachain_build_import_queue,
+ )?;
+ let task_manager = $components.task_manager;
+ { $( $code )* }.map(|v| (v, task_manager))
+ })
+ }}
+}
+
/// Parse command line arguments into service configuration.
pub fn run() -> Result<()> {
let cli = Cli::from_args();
@@ -148,49 +166,23 @@
runner.sync_run(|config| cmd.run(config.chain_spec, config.network))
}
Some(Subcommand::CheckBlock(cmd)) => {
- let runner = cli.create_runner(cmd)?;
- runner.async_run(|config| {
- let PartialComponents {
- client,
- task_manager,
- import_queue,
- ..
- } = crate::service::new_partial(&config)?;
- Ok((cmd.run(client, import_queue), task_manager))
+ construct_async_run!(|components, cli, cmd, config| {
+ Ok(cmd.run(components.client, components.import_queue))
})
}
Some(Subcommand::ExportBlocks(cmd)) => {
- let runner = cli.create_runner(cmd)?;
- runner.async_run(|config| {
- let PartialComponents {
- client,
- task_manager,
- ..
- } = crate::service::new_partial(&config)?;
- Ok((cmd.run(client, config.database), task_manager))
+ construct_async_run!(|components, cli, cmd, config| {
+ Ok(cmd.run(components.client, config.database))
})
}
Some(Subcommand::ExportState(cmd)) => {
- let runner = cli.create_runner(cmd)?;
- runner.async_run(|config| {
- let PartialComponents {
- client,
- task_manager,
- ..
- } = crate::service::new_partial(&config)?;
- Ok((cmd.run(client, config.chain_spec), task_manager))
+ construct_async_run!(|components, cli, cmd, config| {
+ Ok(cmd.run(components.client, config.chain_spec))
})
}
Some(Subcommand::ImportBlocks(cmd)) => {
- let runner = cli.create_runner(cmd)?;
- runner.async_run(|config| {
- let PartialComponents {
- client,
- task_manager,
- import_queue,
- ..
- } = crate::service::new_partial(&config)?;
- Ok((cmd.run(client, import_queue), task_manager))
+ construct_async_run!(|components, cli, cmd, config| {
+ Ok(cmd.run(components.client, components.import_queue))
})
}
Some(Subcommand::PurgeChain(cmd)) => {
@@ -214,18 +206,9 @@
cmd.run(config, polkadot_config)
})
}
- Some(Subcommand::Revert(cmd)) => {
- let runner = cli.create_runner(cmd)?;
- runner.async_run(|config| {
- let PartialComponents {
- client,
- task_manager,
- backend,
- ..
- } = crate::service::new_partial(&config)?;
- Ok((cmd.run(client, backend), task_manager))
- })
- }
+ Some(Subcommand::Revert(cmd)) => construct_async_run!(|components, cli, cmd, config| {
+ Ok(cmd.run(components.client, components.backend))
+ }),
Some(Subcommand::ExportGenesisState(params)) => {
let mut builder = sc_cli::LoggerBuilder::new("");
builder.with_profiling(sc_tracing::TracingReceiver::Log, "");
@@ -270,9 +253,19 @@
}
Ok(())
- }
+ },
+ Some(Subcommand::Benchmark(cmd)) => {
+ if cfg!(feature = "runtime-benchmarks") {
+ let runner = cli.create_runner(cmd)?;
+
+ runner.sync_run(|config| cmd.run::<Block, ParachainRuntimeExecutor>(config))
+ } else {
+ Err("Benchmarking wasn't enabled when building the node. \
+ You can enable it with `--features runtime-benchmarks`.".into())
+ }
+ },
None => {
- let runner = cli.create_runner(&*cli.run)?;
+ let runner = cli.create_runner(&cli.run.normalize())?;
runner.run_node_until_exit(|config| async move {
// TODO
@@ -304,14 +297,20 @@
task_executor,
)
.map_err(|err| format!("Relay chain argument error: {}", err))?;
- let collator = cli.run.base.validator || cli.collator;
info!("Parachain id: {:?}", id);
info!("Parachain Account: {}", parachain_account);
info!("Parachain genesis state: {}", genesis_state);
- info!("Is collating: {}", if collator { "yes" } else { "no" });
+ info!(
+ "Is collating: {}",
+ if config.role.is_authority() {
+ "yes"
+ } else {
+ "no"
+ }
+ );
- crate::service::start_node(config, key, polkadot_config, id, collator)
+ crate::service::start_node(config, key, polkadot_config, id)
.await
.map(|r| r.0)
.map_err(Into::into)
@@ -446,4 +445,4 @@
) -> Result<Option<sc_telemetry::TelemetryEndpoints>> {
self.base.base.telemetry_endpoints(chain_spec)
}
-}
+}
\ No newline at end of file
node/src/lib.rsdiffbeforeafterboth--- a/node/src/lib.rs
+++ b/node/src/lib.rs
@@ -1,3 +1,2 @@
pub mod chain_spec;
pub mod service;
-pub mod rpc;
node/src/main.rsdiffbeforeafterboth--- a/node/src/main.rs
+++ b/node/src/main.rs
@@ -8,7 +8,6 @@
mod service;
mod cli;
mod command;
-mod rpc;
fn main() -> sc_cli::Result<()> {
command::run()
node/src/rpc.rsdiffbeforeafterboth--- a/node/src/rpc.rs
+++ /dev/null
@@ -1,65 +0,0 @@
-//! A collection of node-specific RPC methods.
-//! Substrate provides the `sc-rpc` crate, which defines the core RPC layer
-//! used by Substrate nodes. This file extends those RPC definitions with
-//! capabilities that are specific to this project's runtime configuration.
-
-#![warn(missing_docs)]
-
-use std::sync::Arc;
-
-use nft_runtime::{opaque::Block, AccountId, Balance, Index, BlockNumber, Hash};
-use sp_api::ProvideRuntimeApi;
-use sp_blockchain::{Error as BlockChainError, HeaderMetadata, HeaderBackend};
-use sp_block_builder::BlockBuilder;
-pub use sc_rpc_api::DenyUnsafe;
-use sp_transaction_pool::TransactionPool;
-use pallet_contracts_rpc::{Contracts, ContractsApi};
-
-/// Full client dependencies.
-pub struct FullDeps<C, P> {
- /// The client instance to use.
- pub client: Arc<C>,
- /// Transaction pool instance.
- pub pool: Arc<P>,
- /// Whether to deny unsafe calls
- pub deny_unsafe: DenyUnsafe,
-}
-
-/// Instantiate all full RPC extensions.
-pub fn create_full<C, P>(
- deps: FullDeps<C, P>,
-) -> jsonrpc_core::IoHandler<sc_rpc::Metadata> where
- C: ProvideRuntimeApi<Block>,
- C: HeaderBackend<Block> + HeaderMetadata<Block, Error=BlockChainError> + 'static,
- C: Send + Sync + 'static,
- C::Api: substrate_frame_rpc_system::AccountNonceApi<Block, AccountId, Index>,
- C::Api: pallet_transaction_payment_rpc::TransactionPaymentRuntimeApi<Block, Balance>,
- C::Api: BlockBuilder<Block>,
- C::Api: pallet_contracts_rpc::ContractsRuntimeApi<Block, AccountId, Balance, BlockNumber, Hash>,
- P: TransactionPool + 'static,
-{
- use substrate_frame_rpc_system::{FullSystem, SystemApi};
- use pallet_transaction_payment_rpc::{TransactionPayment, TransactionPaymentApi};
-
- let mut io = jsonrpc_core::IoHandler::default();
- let FullDeps {
- client,
- pool,
- deny_unsafe,
- } = deps;
-
- io.extend_with(
- SystemApi::to_delegate(FullSystem::new(client.clone(), pool, deny_unsafe))
- );
-
- io.extend_with(
- TransactionPaymentApi::to_delegate(TransactionPayment::new(client.clone()))
- );
-
- // Contracts RPC API extension
- io.extend_with(
- ContractsApi::to_delegate(Contracts::new(client.clone()))
- );
-
- io
-}
node/src/service.rsdiffbeforeafterboth--- a/node/src/service.rs
+++ b/node/src/service.rs
@@ -5,50 +5,96 @@
// file 'LICENSE', which is part of this source code package.
//
-use cumulus_client_consensus_relay_chain::{
- build_relay_chain_consensus, BuildRelayChainConsensusParams,
+// std
+use std::sync::Arc;
+
+// Local Runtime Types
+use nft_runtime::RuntimeApi;
+
+// Cumulus Imports
+use cumulus_client_consensus_aura::{
+ build_aura_consensus, BuildAuraConsensusParams, SlotProportion,
};
+use cumulus_client_consensus_common::ParachainConsensus;
use cumulus_client_network::build_block_announce_validator;
use cumulus_client_service::{
prepare_node_config, start_collator, start_full_node, StartCollatorParams, StartFullNodeParams,
};
use cumulus_primitives_core::ParaId;
-use polkadot_primitives::v0::CollatorPair;
-use parachain_runtime::{RuntimeApi, opaque::Block};
+
+// Polkadot Imports
+use polkadot_primitives::v1::CollatorPair;
+
+// Substrate Imports
+use sc_client_api::ExecutorProvider;
+pub use sc_executor::NativeExecutor;
use sc_executor::native_executor_instance;
-pub use sc_executor::NativeExecutor;
+use sc_network::NetworkService;
use sc_service::{Configuration, PartialComponents, Role, TFullBackend, TFullClient, TaskManager};
-use sc_telemetry::{Telemetry, TelemetryWorker, TelemetryWorkerHandle};
+use sc_telemetry::{Telemetry, TelemetryHandle, TelemetryWorker, TelemetryWorkerHandle};
+use sp_api::ConstructRuntimeApi;
+use sp_consensus::SlotData;
+use sp_keystore::SyncCryptoStorePtr;
use sp_runtime::traits::BlakeTwo256;
-use sp_trie::PrefixedMemoryDB;
-use std::sync::Arc;
+use substrate_prometheus_endpoint::Registry;
+
+// Runtime type overrides
+type BlockNumber = u32;
+type Header = sp_runtime::generic::Header<BlockNumber, sp_runtime::traits::BlakeTwo256>;
+pub type Block = sp_runtime::generic::Block<Header, sp_runtime::OpaqueExtrinsic>;
+type Hash = sp_core::H256;
// Native executor instance.
native_executor_instance!(
- pub Executor,
- parachain_runtime::api::dispatch,
- parachain_runtime::native_version,
+ pub ParachainRuntimeExecutor,
+ nft_runtime::api::dispatch,
+ nft_runtime::native_version,
+ frame_benchmarking::benchmarking::HostFunctions,
);
/// Starts a `ServiceBuilder` for a full service.
///
/// Use this macro if you don't actually need the full service, but just the builder in order to
/// be able to perform chain operations.
-pub fn new_partial(
+pub fn new_partial<RuntimeApi, Executor, BIQ>(
config: &Configuration,
+ build_import_queue: BIQ,
) -> Result<
PartialComponents<
TFullClient<Block, RuntimeApi, Executor>,
TFullBackend<Block>,
(),
- sp_consensus::import_queue::BasicQueue<Block, PrefixedMemoryDB<BlakeTwo256>>,
+ sp_consensus::DefaultImportQueue<Block, TFullClient<Block, RuntimeApi, Executor>>,
sc_transaction_pool::FullPool<Block, TFullClient<Block, RuntimeApi, Executor>>,
(Option<Telemetry>, Option<TelemetryWorkerHandle>),
>,
sc_service::Error,
-> {
- let inherent_data_providers = sp_inherents::InherentDataProviders::new();
-
+>
+where
+ RuntimeApi: ConstructRuntimeApi<Block, TFullClient<Block, RuntimeApi, Executor>>
+ + Send
+ + Sync
+ + 'static,
+ RuntimeApi::RuntimeApi: sp_transaction_pool::runtime_api::TaggedTransactionQueue<Block>
+ + sp_api::Metadata<Block>
+ + sp_session::SessionKeys<Block>
+ + sp_api::ApiExt<
+ Block,
+ StateBackend = sc_client_api::StateBackendFor<TFullBackend<Block>, Block>,
+ > + sp_offchain::OffchainWorkerApi<Block>
+ + sp_block_builder::BlockBuilder<Block>,
+ sc_client_api::StateBackendFor<TFullBackend<Block>, Block>: sp_api::StateBackend<BlakeTwo256>,
+ Executor: sc_executor::NativeExecutionDispatch + 'static,
+ BIQ: FnOnce(
+ Arc<TFullClient<Block, RuntimeApi, Executor>>,
+ &Configuration,
+ Option<TelemetryHandle>,
+ &TaskManager,
+ ) -> Result<
+ sp_consensus::DefaultImportQueue<Block, TFullClient<Block, RuntimeApi, Executor>>,
+ sc_service::Error,
+ >,
+{
let telemetry = config
.telemetry_endpoints
.clone()
@@ -66,18 +112,13 @@
telemetry.as_ref().map(|(_, telemetry)| telemetry.handle()),
)?;
let client = Arc::new(client);
-
- let telemetry_worker_handle = telemetry
- .as_ref()
- .map(|(worker, _)| worker.handle());
- let telemetry = telemetry
- .map(|(worker, telemetry)| {
- task_manager.spawn_handle().spawn("telemetry", worker.run());
- telemetry
- });
+ let telemetry_worker_handle = telemetry.as_ref().map(|(worker, _)| worker.handle());
- let registry = config.prometheus_registry();
+ let telemetry = telemetry.map(|(worker, telemetry)| {
+ task_manager.spawn_handle().spawn("telemetry", worker.run());
+ telemetry
+ });
let transaction_pool = sc_transaction_pool::BasicPool::new_full(
config.transaction_pool.clone(),
@@ -87,12 +128,11 @@
client.clone(),
);
- let import_queue = cumulus_client_consensus_relay_chain::import_queue(
+ let import_queue = build_import_queue(
client.clone(),
- client.clone(),
- inherent_data_providers.clone(),
- &task_manager.spawn_essential_handle(),
- registry.clone(),
+ config,
+ telemetry.as_ref().map(|telemetry| telemetry.handle()),
+ &task_manager,
)?;
let params = PartialComponents {
@@ -102,7 +142,6 @@
keystore_container,
task_manager,
transaction_pool,
- inherent_data_providers,
select_chain: (),
other: (telemetry, telemetry_worker_handle),
};
@@ -114,20 +153,56 @@
///
/// This is the actual implementation that is abstract over the executor and the runtime api.
#[sc_tracing::logging::prefix_logs_with("Parachain")]
-async fn start_node_impl<RB>(
+async fn start_node_impl<RuntimeApi, Executor, RB, BIQ, BIC>(
parachain_config: Configuration,
collator_key: CollatorPair,
polkadot_config: Configuration,
id: ParaId,
- validator: bool,
rpc_ext_builder: RB,
+ build_import_queue: BIQ,
+ build_consensus: BIC,
) -> sc_service::error::Result<(TaskManager, Arc<TFullClient<Block, RuntimeApi, Executor>>)>
where
+ RuntimeApi: ConstructRuntimeApi<Block, TFullClient<Block, RuntimeApi, Executor>>
+ + Send
+ + Sync
+ + 'static,
+ RuntimeApi::RuntimeApi: sp_transaction_pool::runtime_api::TaggedTransactionQueue<Block>
+ + sp_api::Metadata<Block>
+ + sp_session::SessionKeys<Block>
+ + sp_api::ApiExt<
+ Block,
+ StateBackend = sc_client_api::StateBackendFor<TFullBackend<Block>, Block>,
+ > + sp_offchain::OffchainWorkerApi<Block>
+ + sp_block_builder::BlockBuilder<Block>
+ + cumulus_primitives_core::CollectCollationInfo<Block>,
+ sc_client_api::StateBackendFor<TFullBackend<Block>, Block>: sp_api::StateBackend<BlakeTwo256>,
+ Executor: sc_executor::NativeExecutionDispatch + 'static,
RB: Fn(
Arc<TFullClient<Block, RuntimeApi, Executor>>,
) -> jsonrpc_core::IoHandler<sc_rpc::Metadata>
+ Send
+ 'static,
+ BIQ: FnOnce(
+ Arc<TFullClient<Block, RuntimeApi, Executor>>,
+ &Configuration,
+ Option<TelemetryHandle>,
+ &TaskManager,
+ ) -> Result<
+ sp_consensus::DefaultImportQueue<Block, TFullClient<Block, RuntimeApi, Executor>>,
+ sc_service::Error,
+ >,
+ BIC: FnOnce(
+ Arc<TFullClient<Block, RuntimeApi, Executor>>,
+ Option<&Registry>,
+ Option<TelemetryHandle>,
+ &TaskManager,
+ &polkadot_service::NewFull<polkadot_service::Client>,
+ Arc<sc_transaction_pool::FullPool<Block, TFullClient<Block, RuntimeApi, Executor>>>,
+ Arc<NetworkService<Block, Hash>>,
+ SyncCryptoStorePtr,
+ bool,
+ ) -> Result<Box<dyn ParachainConsensus<Block>>, sc_service::Error>,
{
if matches!(parachain_config.role, Role::Light) {
return Err("Light client not supported!".into());
@@ -135,56 +210,44 @@
let parachain_config = prepare_node_config(parachain_config);
- let params = new_partial(¶chain_config)?;
- params
- .inherent_data_providers
- .register_provider(sp_timestamp::InherentDataProvider)
- .unwrap();
+ let params = new_partial::<RuntimeApi, Executor, BIQ>(¶chain_config, build_import_queue)?;
let (mut telemetry, telemetry_worker_handle) = params.other;
- let polkadot_full_node =
- cumulus_client_service::build_polkadot_full_node(
- polkadot_config,
- collator_key.clone(),
- telemetry_worker_handle,
- )
- .map_err(|e| match e {
- polkadot_service::Error::Sub(x) => x,
- s => format!("{}", s).into(),
- })?;
+ let relay_chain_full_node = cumulus_client_service::build_polkadot_full_node(
+ polkadot_config,
+ collator_key.clone(),
+ telemetry_worker_handle,
+ )
+ .map_err(|e| match e {
+ polkadot_service::Error::Sub(x) => x,
+ s => format!("{}", s).into(),
+ })?;
let client = params.client.clone();
let backend = params.backend.clone();
let block_announce_validator = build_block_announce_validator(
- polkadot_full_node.client.clone(),
+ relay_chain_full_node.client.clone(),
id,
- Box::new(polkadot_full_node.network.clone()),
- polkadot_full_node.backend.clone(),
+ Box::new(relay_chain_full_node.network.clone()),
+ relay_chain_full_node.backend.clone(),
);
+ let force_authoring = parachain_config.force_authoring;
+ let validator = parachain_config.role.is_authority();
let prometheus_registry = parachain_config.prometheus_registry().cloned();
let transaction_pool = params.transaction_pool.clone();
let mut task_manager = params.task_manager;
- let import_queue = params.import_queue;
+ let import_queue = cumulus_client_service::SharedImportQueue::new(params.import_queue);
let (network, network_status_sinks, system_rpc_tx, start_network) =
sc_service::build_network(sc_service::BuildNetworkParams {
config: ¶chain_config,
client: client.clone(),
transaction_pool: transaction_pool.clone(),
spawn_handle: task_manager.spawn_handle(),
- import_queue,
+ import_queue: import_queue.clone(),
on_demand: None,
block_announce_validator_builder: Some(Box::new(|_| block_announce_validator)),
})?;
-
- if parachain_config.offchain_worker.enabled {
- sc_service::build_offchain_workers(
- ¶chain_config,
- task_manager.spawn_handle(),
- client.clone(),
- network.clone(),
- );
- }
let rpc_client = client.clone();
let rpc_extensions_builder = Box::new(move |_, _| rpc_ext_builder(rpc_client.clone()));
@@ -211,23 +274,19 @@
};
if validator {
- let proposer_factory = sc_basic_authorship::ProposerFactory::with_proof_recording(
- task_manager.spawn_handle(),
+ let parachain_consensus = build_consensus(
client.clone(),
+ prometheus_registry.as_ref(),
+ telemetry.as_ref().map(|t| t.handle()),
+ &task_manager,
+ &relay_chain_full_node,
transaction_pool,
- prometheus_registry.as_ref(),
- telemetry.as_ref().map(|x| x.handle()),
- );
- let spawner = task_manager.spawn_handle();
+ network,
+ params.keystore_container.sync_keystore(),
+ force_authoring,
+ )?;
- let parachain_consensus = build_relay_chain_consensus(BuildRelayChainConsensusParams {
- para_id: id,
- proposer_factory,
- inherent_data_providers: params.inherent_data_providers,
- block_import: client.clone(),
- relay_chain_client: polkadot_full_node.client.clone(),
- relay_chain_backend: polkadot_full_node.backend.clone(),
- });
+ let spawner = task_manager.spawn_handle();
let params = StartCollatorParams {
para_id: id,
@@ -236,10 +295,10 @@
client: client.clone(),
task_manager: &mut task_manager,
collator_key,
- relay_chain_full_node: polkadot_full_node,
+ relay_chain_full_node,
spawner,
- backend,
parachain_consensus,
+ import_queue,
};
start_collator(params).await?;
@@ -249,7 +308,7 @@
announce_block,
task_manager: &mut task_manager,
para_id: id,
- polkadot_full_node,
+ relay_chain_full_node,
};
start_full_node(params)?;
@@ -260,21 +319,140 @@
Ok((task_manager, client))
}
+/// Build the import queue for the the parachain runtime.
+pub fn parachain_build_import_queue(
+ client: Arc<TFullClient<Block, RuntimeApi, ParachainRuntimeExecutor>>,
+ config: &Configuration,
+ telemetry: Option<TelemetryHandle>,
+ task_manager: &TaskManager,
+) -> Result<
+ sp_consensus::DefaultImportQueue<
+ Block,
+ TFullClient<Block, RuntimeApi, ParachainRuntimeExecutor>,
+ >,
+ sc_service::Error,
+> {
+ let slot_duration = cumulus_client_consensus_aura::slot_duration(&*client)?;
+
+
+ cumulus_client_consensus_aura::import_queue::<
+ sp_consensus_aura::sr25519::AuthorityPair,
+ _,
+ _,
+ _,
+ _,
+ _,
+ _,
+ >(cumulus_client_consensus_aura::ImportQueueParams {
+ block_import: client.clone(),
+ client: client.clone(),
+ create_inherent_data_providers: move |_, _| async move {
+ let time = sp_timestamp::InherentDataProvider::from_system_time();
+
+ let slot =
+ sp_consensus_aura::inherents::InherentDataProvider::from_timestamp_and_duration(
+ *time,
+ slot_duration.slot_duration(),
+ );
+
+ Ok((time, slot))
+ },
+ registry: config.prometheus_registry().clone(),
+ can_author_with: sp_consensus::CanAuthorWithNativeVersion::new(client.executor().clone()),
+ spawner: &task_manager.spawn_essential_handle(),
+ telemetry,
+ })
+ .map_err(Into::into)
+}
+
/// Start a normal parachain node.
pub async fn start_node(
parachain_config: Configuration,
collator_key: CollatorPair,
polkadot_config: Configuration,
id: ParaId,
- validator: bool,
-) -> sc_service::error::Result<(TaskManager, Arc<TFullClient<Block, RuntimeApi, Executor>>)> {
- start_node_impl(
+) -> sc_service::error::Result<(TaskManager, Arc<TFullClient<Block, RuntimeApi, ParachainRuntimeExecutor>>)> {
+ start_node_impl::<RuntimeApi, ParachainRuntimeExecutor, _, _, _>(
parachain_config,
collator_key,
polkadot_config,
id,
- validator,
|_| Default::default(),
+ parachain_build_import_queue,
+ |client,
+ prometheus_registry,
+ telemetry,
+ task_manager,
+ relay_chain_node,
+ transaction_pool,
+ sync_oracle,
+ keystore,
+ force_authoring| {
+ let slot_duration = cumulus_client_consensus_aura::slot_duration(&*client)?;
+
+ let proposer_factory = sc_basic_authorship::ProposerFactory::with_proof_recording(
+ task_manager.spawn_handle(),
+ client.clone(),
+ transaction_pool,
+ prometheus_registry.clone(),
+ telemetry.clone(),
+ );
+
+ let relay_chain_backend = relay_chain_node.backend.clone();
+ let relay_chain_client = relay_chain_node.client.clone();
+ Ok(build_aura_consensus::<
+ sp_consensus_aura::sr25519::AuthorityPair,
+ _,
+ _,
+ _,
+ _,
+ _,
+ _,
+ _,
+ _,
+ _,
+ >(BuildAuraConsensusParams {
+ proposer_factory,
+ create_inherent_data_providers: move |_, (relay_parent, validation_data)| {
+ let parachain_inherent =
+ cumulus_primitives_parachain_inherent::ParachainInherentData::create_at_with_client(
+ relay_parent,
+ &relay_chain_client,
+ &*relay_chain_backend,
+ &validation_data,
+ id,
+ );
+ async move {
+ let time = sp_timestamp::InherentDataProvider::from_system_time();
+
+ let slot =
+ sp_consensus_aura::inherents::InherentDataProvider::from_timestamp_and_duration(
+ *time,
+ slot_duration.slot_duration(),
+ );
+
+ let parachain_inherent = parachain_inherent.ok_or_else(|| {
+ Box::<dyn std::error::Error + Send + Sync>::from(
+ "Failed to create parachain inherent",
+ )
+ })?;
+ Ok((time, slot, parachain_inherent))
+ }
+ },
+ block_import: client.clone(),
+ relay_chain_client: relay_chain_node.client.clone(),
+ relay_chain_backend: relay_chain_node.backend.clone(),
+ para_client: client.clone(),
+ backoff_authoring_blocks: Option::<()>::None,
+ sync_oracle,
+ keystore,
+ force_authoring,
+ slot_duration,
+ // We got around 500ms for proposing
+ block_proposal_slot_portion: SlotProportion::new(1f32 / 24f32),
+ telemetry,
+ }))
+ },
)
.await
}
\ No newline at end of file
pallets/inflation/Cargo.tomldiffbeforeafterboth--- a/pallets/inflation/Cargo.toml
+++ b/pallets/inflation/Cargo.toml
@@ -43,43 +43,43 @@
default-features = false
optional = true
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-support]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-system]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-balances]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-timestamp]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-randomness-collective-flip]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-std]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.serde]
@@ -89,18 +89,18 @@
[dependencies.sp-runtime]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-core]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-io]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
pallets/nft/Cargo.tomldiffbeforeafterboth--- a/pallets/nft/Cargo.toml
+++ b/pallets/nft/Cargo.toml
@@ -45,55 +45,55 @@
default-features = false
optional = true
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-support]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-system]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-balances]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-timestamp]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-randomness-collective-flip]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-std]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-contracts]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-transaction-payment]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.serde]
@@ -103,18 +103,18 @@
[dependencies.sp-runtime]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-core]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-io]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
pallets/nft/src/lib.rsdiffbeforeafterboth--- a/pallets/nft/src/lib.rs
+++ b/pallets/nft/src/lib.rs
@@ -2328,6 +2328,7 @@
Ok(())
}
+ #[allow(dead_code)]
fn init_collection(item: &Collection<T>) {
// check params
assert!(
@@ -2355,6 +2356,7 @@
CreatedCollectionCount::put(next_id);
}
+ #[allow(dead_code)]
fn init_nft_token(collection_id: CollectionId, item: &NftItemType<T::AccountId>) {
let current_index = <ItemListIndex>::get(collection_id)
.checked_add(1)
@@ -2372,6 +2374,7 @@
<Balance<T>>::insert(collection_id, item_owner.clone(), new_balance);
}
+ #[allow(dead_code)]
fn init_fungible_token(collection_id: CollectionId, owner: &T::AccountId, item: &FungibleItemType) {
let current_index = <ItemListIndex>::get(collection_id)
.checked_add(1)
@@ -2388,6 +2391,7 @@
<Balance<T>>::insert(collection_id, (*owner).clone(), new_balance);
}
+ #[allow(dead_code)]
fn init_refungible_token(collection_id: CollectionId, item: &ReFungibleItemType<T::AccountId>) {
let current_index = <ItemListIndex>::get(collection_id)
.checked_add(1)
runtime/Cargo.tomldiffbeforeafterboth--- a/runtime/Cargo.toml
+++ b/runtime/Cargo.toml
@@ -31,6 +31,7 @@
]
std = [
'codec/std',
+ 'cumulus-pallet-aura-ext/std',
'cumulus-pallet-parachain-system/std',
'cumulus-pallet-xcm/std',
'cumulus-pallet-xcmp-queue/std',
@@ -40,6 +41,7 @@
'frame-support/std',
'frame-system/std',
'frame-system-rpc-runtime-api/std',
+ 'pallet-aura/std',
'pallet-balances/std',
'pallet-contracts/std',
'pallet-contracts-primitives/std',
@@ -51,9 +53,11 @@
'pallet-transaction-payment-rpc-runtime-api/std',
'pallet-treasury/std',
'pallet-vesting/std',
+ 'parachain-info/std',
'serde',
'sp-api/std',
'sp-block-builder/std',
+ "sp-consensus-aura/std",
'sp-core/std',
'sp-inherents/std',
'sp-io/std',
@@ -84,38 +88,38 @@
default-features = false
git = 'https://github.com/paritytech/substrate.git'
optional = true
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-executive]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-support]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-system]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-system-benchmarking]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
optional = true
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.frame-system-rpc-runtime-api]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.hex-literal]
@@ -127,143 +131,155 @@
optional = true
version = '1.0.119'
+[dependencies.pallet-aura]
+default-features = false
+git = 'https://github.com/paritytech/substrate.git'
+branch = 'polkadot-v0.9.3'
+version = '3.0.0'
+
[dependencies.pallet-balances]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
# Contracts specific packages
[dependencies.pallet-contracts]
git = 'https://github.com/paritytech/substrate.git'
default-features = false
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-contracts-primitives]
git = 'https://github.com/paritytech/substrate.git'
default-features = false
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-contracts-rpc-runtime-api]
git = 'https://github.com/paritytech/substrate.git'
default-features = false
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-randomness-collective-flip]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-sudo]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-timestamp]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-transaction-payment]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-transaction-payment-rpc-runtime-api]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-treasury]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.pallet-vesting]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-arithmetic]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-api]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-block-builder]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-core]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
+[dependencies.sp-consensus-aura]
+default-features = false
+git = 'https://github.com/paritytech/substrate.git'
+branch = 'polkadot-v0.9.3'
+version = '0.9.0'
+
[dependencies.sp-inherents]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-io]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-offchain]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-runtime]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-session]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-std]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-transaction-pool]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.sp-version]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '3.0.0'
[dependencies.smallvec]
@@ -275,32 +291,42 @@
[dependencies.parachain-info]
default-features = false
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
version = '0.1.0'
+[dependencies.cumulus-pallet-aura-ext]
+git = 'https://github.com/paritytech/cumulus.git'
+branch = 'polkadot-v0.9.3'
+default-features = false
+
[dependencies.cumulus-pallet-parachain-system]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
default-features = false
[dependencies.cumulus-primitives-core]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
default-features = false
[dependencies.cumulus-pallet-xcm]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
default-features = false
+[dependencies.cumulus-pallet-dmp-queue]
+git = 'https://github.com/paritytech/cumulus.git'
+branch = 'polkadot-v0.9.3'
+default-features = false
+
[dependencies.cumulus-pallet-xcmp-queue]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
default-features = false
[dependencies.cumulus-primitives-utility]
git = 'https://github.com/paritytech/cumulus.git'
-branch = 'rococo-v1'
+branch = 'polkadot-v0.9.3'
default-features = false
################################################################################
@@ -308,40 +334,41 @@
[dependencies.polkadot-parachain]
git = 'https://github.com/paritytech/polkadot'
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
default-features = false
[dependencies.xcm]
git = 'https://github.com/paritytech/polkadot'
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
default-features = false
[dependencies.xcm-builder]
git = 'https://github.com/paritytech/polkadot'
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
default-features = false
[dependencies.xcm-executor]
git = 'https://github.com/paritytech/polkadot'
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
default-features = false
[dependencies.pallet-xcm]
git = 'https://github.com/paritytech/polkadot'
-branch = 'rococo-v1'
+branch = 'release-v0.9.3'
default-features = false
-
-################################################################################
-# Build Dependencies
-
-[build-dependencies]
-substrate-wasm-builder = '4.0.0'
################################################################################
# local dependencies
+[dependencies]
pallet-nft = { path = '../pallets/nft', default-features = false, version = '3.0.0' }
pallet-inflation = { path = '../pallets/inflation', default-features = false, version = '3.0.0' }
+################################################################################
+# Build Dependencies
+
+[build-dependencies]
+substrate-wasm-builder = '4.0.0'
+
runtime/src/chain_extension.rsdiffbeforeafterboth--- a/runtime/src/chain_extension.rs
+++ b/runtime/src/chain_extension.rs
@@ -17,9 +17,6 @@
extern crate pallet_nft;
pub use pallet_nft::*;
-use crate::Runtime;
-use sp_runtime::AccountId32;
-use crate::Vec;
/// Create item parameters
#[derive(Debug, PartialEq, Encode, Decode)]
runtime/src/lib.rsdiffbeforeafterboth1//2// This file is subject to the terms and conditions defined in3// file 'LICENSE', which is part of this source code package.4//56//! The Substrate Node Template runtime. This can be compiled with `#[no_std]`, ready for Wasm.78#![cfg_attr(not(feature = "std"), no_std)]9// `construct_runtime!` does a lot of recursion and requires us to increase the limit to 256.10#![recursion_limit = "256"]1112// Make the WASM binary available.13#[cfg(feature = "std")]14include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));1516use sp_api::impl_runtime_apis;17use sp_core::{ crypto::KeyTypeId, crypto::Public, OpaqueMetadata };18use sp_runtime::{19 BuildStorage,20 Permill, Perbill, Percent,21 ModuleId,22 create_runtime_str, generic, impl_opaque_keys,23 traits::{24 AccountIdLookup, BlakeTwo256, Block as BlockT, Convert, ConvertInto, IdentifyAccount, 25 IdentityLookup, NumberFor, Verify, AccountIdConversion,26 },27 transaction_validity::{TransactionSource, TransactionValidity},28 ApplyExtrinsicResult, MultiSignature,29};3031use sp_std::prelude::*;3233#[cfg(feature = "std")]34use sp_version::NativeVersion;35use sp_version::RuntimeVersion;36pub use pallet_transaction_payment::{Multiplier, TargetedFeeAdjustment, CurrencyAdapter, FeeDetails, RuntimeDispatchInfo};37// A few exports that help ease life for downstream crates.38pub use pallet_balances::Call as BalancesCall;39pub use pallet_contracts::{Schedule as ContractsSchedule };40pub use frame_support::{41 construct_runtime,42 dispatch::DispatchResult,43 parameter_types,44 StorageValue,45 traits::{46 All, Currency, ExistenceRequirement, Get, IsInVec, KeyOwnerProofSystem, LockIdentifier, OnUnbalanced, Randomness47 },48 weights::{49 constants::{BlockExecutionWeight, ExtrinsicBaseWeight, RocksDbWeight, WEIGHT_PER_SECOND},50 DispatchClass, DispatchInfo, GetDispatchInfo, IdentityFee, Pays, PostDispatchInfo, Weight,51 WeightToFeePolynomial, WeightToFeeCoefficient, WeightToFeeCoefficients52 },53};54use pallet_contracts::weights::WeightInfo;55// #[cfg(any(feature = "std", test))]56use frame_system::{57 self as system,58 EnsureRoot, 59 limits::{BlockWeights, BlockLength},60};61use sp_std::{prelude::*, marker::PhantomData};62use sp_arithmetic::{traits::{BaseArithmetic, Unsigned}};63use smallvec::smallvec;6465pub use pallet_timestamp::Call as TimestampCall;6667// Polkadot imports68use polkadot_parachain::primitives::Sibling;69use xcm::v0::{Junction, MultiLocation, NetworkId};70use xcm_builder::{71 AccountId32Aliases, CurrencyAdapter, LocationInverter, ParentIsDefault, RelayChainAsNative,72 SiblingParachainAsNative, SiblingParachainConvertsVia, SignedAccountId32AsNative,73 SovereignSignedViaLocation, FixedRateOfConcreteFungible, EnsureXcmOrigin,74 AllowTopLevelPaidExecutionFrom, TakeWeightCredit, FixedWeightBounds, IsConcrete, NativeAsset,75 AllowUnpaidExecutionFrom, ParentAsSuperuser,76};77use xcm_executor::{Config, XcmExecutor};787980mod chain_extension;81use crate::chain_extension::{ NFTExtension, Imbalance };8283/// Struct that handles the conversion of Balance -> `u64`. This is used for84/// staking's election calculation.85pub struct CurrencyToVoteHandler;8687impl CurrencyToVoteHandler {88 fn factor() -> Balance {89 (Balances::total_issuance() / u64::max_value() as Balance).max(1)90 }91}9293impl Convert<Balance, u64> for CurrencyToVoteHandler {94 fn convert(x: Balance) -> u64 {95 (x / Self::factor()) as u6496 }97}9899impl Convert<u128, Balance> for CurrencyToVoteHandler {100 fn convert(x: u128) -> Balance {101 x * Self::factor()102 }103}104105/// Re-export a nft pallet106/// TODO: Check this re-export. Is this safe and good style?107extern crate pallet_nft;108pub use pallet_nft::*;109110/// An index to a block.111pub type BlockNumber = u32;112113/// Alias to 512-bit hash when used in the context of a transaction signature on the chain.114pub type Signature = MultiSignature;115116/// Some way of identifying an account on the chain. We intentionally make it equivalent117/// to the public key of our transaction signing scheme.118pub type AccountId = <<Signature as Verify>::Signer as IdentifyAccount>::AccountId;119120/// The type for looking up accounts. We don't expect more than 4 billion of them, but you121/// never know...122pub type AccountIndex = u32;123124/// Balance of an account.125pub type Balance = u128;126127/// Index of a transaction in the chain.128pub type Index = u32;129130/// A hash of some data used by the chain.131pub type Hash = sp_core::H256;132133/// Digest item type.134pub type DigestItem = generic::DigestItem<Hash>;135136mod nft_weights;137138/// Opaque types. These are used by the CLI to instantiate machinery that don't need to know139/// the specifics of the runtime. They can then be made to be agnostic over specific formats140/// of data like extrinsics, allowing for them to continue syncing the network through upgrades141/// to even the core data structures.142pub mod opaque {143 use super::*;144145 pub use sp_runtime::OpaqueExtrinsic as UncheckedExtrinsic;146147 /// Opaque block header type.148 pub type Header = generic::Header<BlockNumber, BlakeTwo256>;149 /// Opaque block type.150 pub type Block = generic::Block<Header, UncheckedExtrinsic>;151 /// Opaque block identifier type.152 pub type BlockId = generic::BlockId<Block>;153154 impl_opaque_keys! {155 pub struct SessionKeys {}156 }157}158159/// This runtime version.160pub const VERSION: RuntimeVersion = RuntimeVersion {161 spec_name: create_runtime_str!("nft"),162 impl_name: create_runtime_str!("nft"),163 authoring_version: 1,164 spec_version: 3,165 impl_version: 1,166 apis: RUNTIME_API_VERSIONS,167 transaction_version: 1,168};169170pub const MILLISECS_PER_BLOCK: u64 = 6000;171172pub const SLOT_DURATION: u64 = MILLISECS_PER_BLOCK;173174// These time units are defined in number of blocks.175pub const MINUTES: BlockNumber = 60_000 / (MILLISECS_PER_BLOCK as BlockNumber);176pub const HOURS: BlockNumber = MINUTES * 60;177pub const DAYS: BlockNumber = HOURS * 24;178179#[derive(codec::Encode, codec::Decode)]180pub enum XCMPMessage<XAccountId, XBalance> {181 /// Transfer tokens to the given account from the Parachain account.182 TransferToken(XAccountId, XBalance),183}184185/// The version information used to identify this runtime when compiled natively.186#[cfg(feature = "std")]187pub fn native_version() -> NativeVersion {188 NativeVersion {189 runtime_version: VERSION,190 can_author_with: Default::default(),191 }192}193194type NegativeImbalance = <Balances as Currency<AccountId>>::NegativeImbalance;195196pub struct DealWithFees;197impl OnUnbalanced<NegativeImbalance> for DealWithFees {198 fn on_unbalanceds<B>(mut fees_then_tips: impl Iterator<Item=NegativeImbalance>) {199 if let Some(fees) = fees_then_tips.next() {200 // for fees, 100% to treasury201 let mut split = fees.ration(100, 0);202 if let Some(tips) = fees_then_tips.next() {203 // for tips, if any, 100% to treasury204 tips.ration_merge_into(100, 0, &mut split);205 }206 Treasury::on_unbalanced(split.0);207 // Author::on_unbalanced(split.1);208 }209 }210}211212// impl OnUnbalanced<NegativeImbalance> for DealWithFees {213// fn on_unbalanceds<B>(mut fees_then_tips: impl Iterator<Item=NegativeImbalance>) {214// if let Some(fees) = fees_then_tips.next() {215// // for fees, 100% to treasury216// let mut split = fees.ration(100, 0);217// if let Some(tips) = fees_then_tips.next() {218// // for tips, if any, 100% to treasury219// tips.ration_merge_into(100, 0, &mut split);220// }221// Treasury::on_unbalanced(split.0);222// // Author::on_unbalanced(split.1);223// }224// }225// }226227/// We assume that ~10% of the block weight is consumed by `on_initalize` handlers.228/// This is used to limit the maximal weight of a single extrinsic.229const AVERAGE_ON_INITIALIZE_RATIO: Perbill = Perbill::from_percent(10);230/// We allow `Normal` extrinsics to fill up the block up to 75%, the rest can be used231/// by Operational extrinsics.232const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75);233/// We allow for 2 seconds of compute with a 6 second average block time.234const MAXIMUM_BLOCK_WEIGHT: Weight = 2 * WEIGHT_PER_SECOND;235236parameter_types! {237 pub const BlockHashCount: BlockNumber = 2400;238 pub RuntimeBlockLength: BlockLength =239 BlockLength::max_with_normal_ratio(5 * 1024 * 1024, NORMAL_DISPATCH_RATIO);240 pub const AvailableBlockRatio: Perbill = Perbill::from_percent(75);241 pub const MaximumBlockLength: u32 = 5 * 1024 * 1024;242 pub RuntimeBlockWeights: BlockWeights = BlockWeights::builder()243 .base_block(BlockExecutionWeight::get())244 .for_class(DispatchClass::all(), |weights| {245 weights.base_extrinsic = ExtrinsicBaseWeight::get();246 })247 .for_class(DispatchClass::Normal, |weights| {248 weights.max_total = Some(NORMAL_DISPATCH_RATIO * MAXIMUM_BLOCK_WEIGHT);249 })250 .for_class(DispatchClass::Operational, |weights| {251 weights.max_total = Some(MAXIMUM_BLOCK_WEIGHT);252 // Operational transactions have some extra reserved space, so that they253 // are included even if block reached `MAXIMUM_BLOCK_WEIGHT`.254 weights.reserved = Some(255 MAXIMUM_BLOCK_WEIGHT - NORMAL_DISPATCH_RATIO * MAXIMUM_BLOCK_WEIGHT256 );257 })258 .avg_block_initialization(AVERAGE_ON_INITIALIZE_RATIO)259 .build_or_panic();260 pub const Version: RuntimeVersion = VERSION;261 pub const SS58Prefix: u8 = 42;262}263264impl system::Config for Runtime {265 /// The data to be stored in an account.266 type AccountData = pallet_balances::AccountData<Balance>;267 /// The identifier used to distinguish between accounts.268 type AccountId = AccountId;269 /// The basic call filter to use in dispatchable.270 type BaseCallFilter = ();271 /// Maximum number of block number to block hash mappings to keep (oldest pruned first).272 type BlockHashCount = BlockHashCount;273 /// The maximum length of a block (in bytes).274 type BlockLength = RuntimeBlockLength;275 /// The index type for blocks.276 type BlockNumber = BlockNumber;277 /// The weight of the overhead invoked on the block import process, independent of the278 /// extrinsics included in that block.279 type BlockWeights = RuntimeBlockWeights;280 /// The aggregated dispatch type that is available for extrinsics.281 type Call = Call;282 /// The weight of database operations that the runtime can invoke.283 type DbWeight = RocksDbWeight;284 /// The ubiquitous event type.285 type Event = Event;286 /// The type for hashing blocks and tries.287 type Hash = Hash;288 /// The hashing algorithm used.289 type Hashing = BlakeTwo256;290 /// The header type.291 type Header = generic::Header<BlockNumber, BlakeTwo256>;292 /// The index type for storing how many extrinsics an account has signed.293 type Index = Index;294 /// The lookup mechanism to get account ID from whatever is passed in dispatchers.295 type Lookup = IdentityLookup<AccountId>;296 /// What to do if an account is fully reaped from the system.297 type OnKilledAccount = ();298 /// What to do if a new account is created.299 type OnNewAccount = ();300 type OnSetCode = cumulus_pallet_parachain_system::ParachainSetCode<Self>;301 /// The ubiquitous origin type.302 type Origin = Origin;303 /// This type is being generated by `construct_runtime!`.304 type PalletInfo = PalletInfo;305 /// This is used as an identifier of the chain. 42 is the generic substrate prefix.306 type SS58Prefix = SS58Prefix;307 /// Weight information for the extrinsics of this pallet.308 type SystemWeightInfo = system::weights::SubstrateWeight<Runtime>;309 /// Version of the runtime.310 type Version = Version;311}312313parameter_types! {314 pub const MinimumPeriod: u64 = SLOT_DURATION / 2;315}316317impl pallet_timestamp::Config for Runtime {318 /// A timestamp: milliseconds since the unix epoch.319 type Moment = u64;320 type OnTimestampSet = Aura;321 type MinimumPeriod = MinimumPeriod;322 type WeightInfo = ();323}324325parameter_types! {326 // pub const ExistentialDeposit: u128 = 500;327 pub const ExistentialDeposit: u128 = 0;328 pub const MaxLocks: u32 = 50;329}330331impl pallet_balances::Config for Runtime {332 type MaxLocks = MaxLocks;333 /// The type for recording an account's balance.334 type Balance = Balance;335 /// The ubiquitous event type.336 type Event = Event;337 type DustRemoval = Treasury;338 type ExistentialDeposit = ExistentialDeposit;339 type AccountStore = System;340 type WeightInfo = pallet_balances::weights::SubstrateWeight<Runtime>;341}342343pub const MICROUNIQUE: Balance = 1_000_000_000;344pub const MILLIUNIQUE: Balance = 1_000 * MICROUNIQUE;345pub const CENTIUNIQUE: Balance = 10 * MILLIUNIQUE;346pub const UNIQUE: Balance = 100 * CENTIUNIQUE;347348pub const fn deposit(items: u32, bytes: u32) -> Balance {349 items as Balance * 15 * CENTIUNIQUE + (bytes as Balance) * 6 * CENTIUNIQUE350}351352parameter_types! {353 pub const TombstoneDeposit: Balance = deposit(354 0,355 sp_std::mem::size_of::<pallet_contracts::ContractInfo<Runtime>>() as u32356 );357 pub const DepositPerContract: Balance = TombstoneDeposit::get();358 pub const DepositPerStorageByte: Balance = deposit(0, 1);359 pub const DepositPerStorageItem: Balance = deposit(1, 0);360 pub RentFraction: Perbill = Perbill::from_rational_approximation(1u32, 30 * DAYS);361 pub const SurchargeReward: Balance = 150 * MILLIUNIQUE;362 pub const SignedClaimHandicap: u32 = 2;363 pub const MaxDepth: u32 = 32;364 pub const MaxValueSize: u32 = 16 * 1024;365 pub const MaxCodeSize: u32 = 1024 * 1024 * 25; // 25 Mb 366 // The lazy deletion runs inside on_initialize.367 pub DeletionWeightLimit: Weight = AVERAGE_ON_INITIALIZE_RATIO *368 RuntimeBlockWeights::get().max_block;369 // The weight needed for decoding the queue should be less or equal than a fifth370 // of the overall weight dedicated to the lazy deletion.371 pub DeletionQueueDepth: u32 = ((DeletionWeightLimit::get() / (372 <Runtime as pallet_contracts::Config>::WeightInfo::on_initialize_per_queue_item(1) -373 <Runtime as pallet_contracts::Config>::WeightInfo::on_initialize_per_queue_item(0)374 )) / 5) as u32;375}376377378impl pallet_contracts::Config for Runtime {379 type Time = Timestamp;380 type Randomness = RandomnessCollectiveFlip;381 type Currency = Balances;382 type Event = Event;383 type RentPayment = ();384 type SignedClaimHandicap = SignedClaimHandicap;385 type TombstoneDeposit = TombstoneDeposit;386 type DepositPerContract = DepositPerContract;387 type DepositPerStorageByte = DepositPerStorageByte;388 type DepositPerStorageItem = DepositPerStorageItem;389 type RentFraction = RentFraction;390 type SurchargeReward = SurchargeReward;391 type MaxDepth = MaxDepth;392 type MaxValueSize = MaxValueSize;393 type WeightPrice = pallet_transaction_payment::Module<Self>;394 type WeightInfo = pallet_contracts::weights::SubstrateWeight<Self>;395 type ChainExtension = NFTExtension;396 type DeletionQueueDepth = DeletionQueueDepth;397 type DeletionWeightLimit = DeletionWeightLimit;398 type MaxCodeSize = MaxCodeSize;399}400401parame ter_types! {402 pub const TransactionByteFee: Balance = 501 * MICROUNIQUE; // Targeting 0.1 Unique per NFT transfer 403}404405/// Linear implementor of `WeightToFeePolynomial` 406pub struct LinearFee<T>(sp_std::marker::PhantomData<T>);407408impl<T> WeightToFeePolynomial for LinearFee<T> where409 T: BaseArithmetic + From<u32> + Copy + Unsigned410{411 type Balance = T;412413 fn polynomial() -> WeightToFeeCoefficients<Self::Balance> {414 smallvec!(WeightToFeeCoefficient {415 coeff_integer: 146_700u32.into(), // Targeting 0.1 Unique per NFT transfer416 coeff_frac: Perbill::zero(),417 negative: false,418 degree: 1,419 })420 }421}422423impl pallet_transaction_payment::Config for Runtime {424 type OnChargeTransaction = CurrencyAdapter<Balances, DealWithFees>;425 type TransactionByteFee = TransactionByteFee;426 type WeightToFee = LinearFee<Balance>;427 type FeeMultiplierUpdate = ();428}429430parameter_types! {431 pub const ProposalBond: Permill = Permill::from_percent(5);432 pub const ProposalBondMinimum: Balance = 1 * UNIQUE;433 pub const SpendPeriod: BlockNumber = 5 * MINUTES;434 pub const Burn: Permill = Permill::from_percent(0);435 pub const TipCountdown: BlockNumber = 1 * DAYS;436 pub const TipFindersFee: Percent = Percent::from_percent(20);437 pub const TipReportDepositBase: Balance = 1 * UNIQUE;438 pub const DataDepositPerByte: Balance = 1 * CENTIUNIQUE;439 pub const BountyDepositBase: Balance = 1 * UNIQUE;440 pub const BountyDepositPayoutDelay: BlockNumber = 1 * DAYS;441 pub const TreasuryModuleId: ModuleId = ModuleId(*b"py/trsry");442 pub const BountyUpdatePeriod: BlockNumber = 14 * DAYS;443 pub const MaximumReasonLength: u32 = 16384;444 pub const BountyCuratorDeposit: Permill = Permill::from_percent(50);445 pub const BountyValueMinimum: Balance = 5 * UNIQUE;446}447448impl pallet_treasury::Config for Runtime {449 type ModuleId = TreasuryModuleId;450 type Currency = Balances;451 type ApproveOrigin = EnsureRoot<AccountId>;452 type RejectOrigin = EnsureRoot<AccountId>;453 type Event = Event;454 type OnSlash = ();455 type ProposalBond = ProposalBond;456 type ProposalBondMinimum = ProposalBondMinimum;457 type SpendPeriod = SpendPeriod;458 type Burn = Burn;459 type BurnDestination = ();460 type SpendFunds = ();461 type WeightInfo = pallet_treasury::weights::SubstrateWeight<Runtime>;462}463464impl pallet_sudo::Config for Runtime {465 type Event = Event;466 type Call = Call;467}468469parameter_types! {470 pub const MinVestedTransfer: Balance = 10 * UNIQUE;471}472473impl pallet_vesting::Config for Runtime {474 type Event = Event;475 type Currency = Balances;476 type BlockNumberToBalance = ConvertInto;477 type MinVestedTransfer = MinVestedTransfer;478 type WeightInfo = ();479}480481parameter_types! {482 pub const ReservedXcmpWeight: Weight = MAXIMUM_BLOCK_WEIGHT / 4;483}484485impl cumulus_pallet_parachain_system::Config for Runtime {486 type Event = Event;487 type OnValidationData = ();488 type SelfParaId = parachain_info::Module<Runtime>;489 type DownwardMessageHandlers = cumulus_primitives_utility::UnqueuedDmpAsParent<490 MaxDownwardMessageWeight,491 XcmExecutor<XcmConfig>,492 Call,493 >;494 type OutboundXcmpMessageSource = XcmpQueue;495 type XcmpMessageHandler = XcmpQueue;496 type ReservedXcmpWeight = ReservedXcmpWeight;497}498499impl parachain_info::Config for Runtime {}500501parameter_types! {502 pub const RococoLocation: MultiLocation = MultiLocation::X1(Junction::Parent);503 pub const RococoNetwork: NetworkId = NetworkId::Polkadot;504 pub RelayChainOrigin: Origin = cumulus_pallet_xcm::Origin::Relay.into();505 pub Ancestry: MultiLocation = Junction::Parachain {506 id: ParachainInfo::parachain_id().into()507 }.into();508}509510/// Type for specifying how a `MultiLocation` can be converted into an `AccountId`. This is used511/// when determining ownership of accounts for asset transacting and when attempting to use XCM512/// `Transact` in order to determine the dispatch Origin.513pub type LocationToAccountId = (514 // The parent (Relay-chain) origin converts to the default `AccountId`.515 ParentIsDefault<AccountId>,516 // Sibling parachain origins convert to AccountId via the `ParaId::into`.517 SiblingParachainConvertsVia<Sibling, AccountId>,518 // Straight up local `AccountId32` origins just alias directly to `AccountId`.519 AccountId32Aliases<RococoNetwork, AccountId>,520);521522/// Means for transacting assets on this chain.523pub type LocalAssetTransactor = CurrencyAdapter<524 // Use this currency:525 Balances,526 // Use this currency when it is a fungible asset matching the given location or name:527 IsConcrete<RococoLocation>,528 // Do a simple punn to convert an AccountId32 MultiLocation into a native chain account ID:529 LocationToAccountId,530 // Our chain's account ID type (we can't get away without mentioning it explicitly):531 AccountId,532>;533534/// This is the type we use to convert an (incoming) XCM origin into a local `Origin` instance,535/// ready for dispatching a transaction with Xcm's `Transact`. There is an `OriginKind` which can536/// biases the kind of local `Origin` it will become.537pub type XcmOriginToTransactDispatchOrigin = (538 // Sovereign account converter; this attempts to derive an `AccountId` from the origin location539 // using `LocationToAccountId` and then turn that into the usual `Signed` origin. Useful for540 // foreign chains who want to have a local sovereign account on this chain which they control.541 SovereignSignedViaLocation<LocationToAccountId, Origin>,542 // Native converter for Relay-chain (Parent) location; will converts to a `Relay` origin when543 // recognised.544 RelayChainAsNative<RelayChainOrigin, Origin>,545 // Native converter for sibling Parachains; will convert to a `SiblingPara` origin when546 // recognised.547 SiblingParachainAsNative<cumulus_pallet_xcm::Origin, Origin>,548 // Superuser converter for the Relay-chain (Parent) location. This will allow it to issue a549 // transaction from the Root origin.550 ParentAsSuperuser<Origin>,551 // Native signed account converter; this just converts an `AccountId32` origin into a normal552 // `Origin::Signed` origin of the same 32-byte value.553 SignedAccountId32AsNative<RococoNetwork, Origin>,554);555556parameter_types! {557 pub UnitWeightCost: Weight = 1_000;558}559560parameter_types! {561 // 1_000_000_000_000 => 1 unit of asset for 1 unit of Weight.562 // TODO: Should take the actual weight price. This is just 1_000 ROC per second of weight.563 pub const WeightPrice: (MultiLocation, u128) = (MultiLocation::X1(Junction::Parent), 1_000);564 pub AllowUnpaidFrom: Vec<MultiLocation> = vec![ MultiLocation::X1(Junction::Parent) ];565}566567pub type Barrier = (568 TakeWeightCredit,569 AllowTopLevelPaidExecutionFrom<All<MultiLocation>>,570 AllowUnpaidExecutionFrom<IsInVec<AllowUnpaidFrom>>, // <- Parent gets free execution571);572573574pub struct XcmConfig;575impl Config for XcmConfig {576 type Call = Call;577 type XcmSender = XcmRouter;578 // How to withdraw and deposit an asset.579 type AssetTransactor = LocalAssetTransactor;580 type OriginConverter = XcmOriginToTransactDispatchOrigin;581 type IsReserve = NativeAsset;582 type IsTeleporter = NativeAsset; // <- should be enough to allow teleportation of ROC583 type LocationInverter = LocationInverter<Ancestry>;584 type Barrier = Barrier;585 type Weigher = FixedWeightBounds<UnitWeightCost, Call>;586 type Trader = FixedRateOfConcreteFungible<WeightPrice>;587 type ResponseHandler = (); // Don't handle responses for now.588}589590parameter_types! {591 pub const MaxDownwardMessageWeight: Weight = MAXIMUM_BLOCK_WEIGHT / 10;592}593594/// No local origins on this chain are allowed to dispatch XCM sends/executions.595pub type LocalOriginToLocation = ();596597/// The means for routing XCM messages which are not for local execution into the right message598/// queues.599pub type XcmRouter = (600 // Two routers - use UMP to communicate with the relay chain:601 cumulus_primitives_utility::ParentAsUmp<ParachainSystem>,602 // ..and XCMP to communicate with the sibling chains.603 XcmpQueue,604);605606impl pallet_xcm::Config for Runtime {607 type Event = Event;608 type SendXcmOrigin = EnsureXcmOrigin<Origin, LocalOriginToLocation>;609 type XcmRouter = XcmRouter;610 type ExecuteXcmOrigin = EnsureXcmOrigin<Origin, LocalOriginToLocation>;611 type XcmExecutor = XcmExecutor<XcmConfig>;612}613614impl cumulus_pallet_xcm::Config for Runtime {}615616impl cumulus_pallet_xcmp_queue::Config for Runtime {617 type Event = Event;618 type XcmExecutor = XcmExecutor<XcmConfig>;619 type ChannelInfo = ParachainSystem;620}621622parameter_types! {623 pub TreasuryAccountId: AccountId = TreasuryModuleId::get().into_account();624 pub const CollectionCreationPrice: Balance = 100 * UNIQUE;625}626627/// Used for the pallet nft in `./nft.rs`628impl pallet_nft::Config for Runtime {629 type Event = Event;630 type WeightInfo = nft_weights::WeightInfo;631 type Currency = Balances;632 type CollectionCreationPrice = CollectionCreationPrice;633 type TreasuryAccountId = TreasuryAccountId;634}635636/// Reimport pallet inflation637extern crate pallet_inflation;638pub use pallet_inflation::*;639640parameter_types! {641 pub const InflationBlockInterval: BlockNumber = 100; // every time per how many blocks inflation is applied642}643644/// Used for the pallet inflation645impl pallet_inflation::Config for Runtime {646 type Currency = Balances;647 type TreasuryAccountId = TreasuryAccountId;648 type InflationBlockInterval = InflationBlockInterval;649}650651construct_runtime!(652 pub enum Runtime where653 Block = Block,654 NodeBlock = opaque::Block,655 UncheckedExtrinsic = UncheckedExtrinsic656 {657 Balances: pallet_balances::{Module, Call, Storage, Config<T>, Event<T>},658 Contracts: pallet_contracts::{Module, Call, Config<T>, Storage, Event<T>},659 CumulusXcm: cumulus_pallet_xcm::{Pallet, Origin},660 ParachainInfo: parachain_info::{Pallet, Storage, Config},661 ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Storage, Inherent, Event<T>},662 PolkadotXcm: pallet_xcm::{Pallet, Call, Event<T>, Origin},663 RandomnessCollectiveFlip: pallet_randomness_collective_flip::{Module, Call, Storage},664 Sudo: pallet_sudo::{Module, Call, Config<T>, Storage, Event<T>},665 System: system::{Module, Call, Config, Storage, Event<T>},666 Timestamp: pallet_timestamp::{Module, Call, Storage, Inherent},667 TransactionPayment: pallet_transaction_payment::{Module, Storage},668 Treasury: pallet_treasury::{Module, Call, Storage, Config, Event<T>},669 Vesting: pallet_vesting::{Module, Call, Config<T>, Storage, Event<T>},670 XcmpQueue: cumulus_pallet_xcmp_queue::{Pallet, Call, Storage, Event<T>},671672 Inflation: pallet_inflation::{Module, Call, Storage},673 Nft: pallet_nft::{Module, Call, Config<T>, Storage, Event<T>},674 }675);676677/// The address format for describing accounts.678pub type Address = AccountId;679/// Block header type as expected by this runtime.680pub type Header = generic::Header<BlockNumber, BlakeTwo256>;681/// Block type as expected by this runtime.682pub type Block = generic::Block<Header, UncheckedExtrinsic>;683/// A Block signed with a Justification684pub type SignedBlock = generic::SignedBlock<Block>;685/// BlockId type as expected by this runtime.686pub type BlockId = generic::BlockId<Block>;687/// The SignedExtension to the basic transaction logic.688pub type SignedExtra = (689 system::CheckSpecVersion<Runtime>,690 system::CheckTxVersion<Runtime>,691 system::CheckGenesis<Runtime>,692 system::CheckEra<Runtime>,693 system::CheckNonce<Runtime>,694 system::CheckWeight<Runtime>,695 pallet_nft::ChargeTransactionPayment<Runtime>,696);697/// Unchecked extrinsic type as expected by this runtime.698pub type UncheckedExtrinsic = generic::UncheckedExtrinsic<Address, Call, Signature, SignedExtra>;699/// Extrinsic type that has already been checked.700pub type CheckedExtrinsic = generic::CheckedExtrinsic<AccountId, Call, SignedExtra>;701/// Executive: handles dispatch to the various modules.702pub type Executive =703 frame_executive::Executive<Runtime, Block, system::ChainContext<Runtime>, Runtime, AllModules>;704705impl_runtime_apis! {706 impl sp_api::Core<Block> for Runtime {707 fn version() -> RuntimeVersion {708 VERSION709 }710711 fn execute_block(block: Block) {712 Executive::execute_block(block)713 }714715 fn initialize_block(header: &<Block as BlockT>::Header) {716 Executive::initialize_block(header)717 }718 }719720 impl sp_api::Metadata<Block> for Runtime {721 fn metadata() -> OpaqueMetadata {722 Runtime::metadata().into()723 }724 }725726 impl sp_block_builder::BlockBuilder<Block> for Runtime {727 fn apply_extrinsic(extrinsic: <Block as BlockT>::Extrinsic) -> ApplyExtrinsicResult {728 Executive::apply_extrinsic(extrinsic)729 }730731 fn finalize_block() -> <Block as BlockT>::Header {732 Executive::finalize_block()733 }734735 fn inherent_extrinsics(data: sp_inherents::InherentData) -> Vec<<Block as BlockT>::Extrinsic> {736 data.create_extrinsics()737 }738739 fn check_inherents(740 block: Block,741 data: sp_inherents::InherentData,742 ) -> sp_inherents::CheckInherentsResult {743 data.check_extrinsics(&block)744 }745746 fn random_seed() -> <Block as BlockT>::Hash {747 RandomnessCollectiveFlip::random_seed()748 }749 }750751 impl sp_transaction_pool::runtime_api::TaggedTransactionQueue<Block> for Runtime {752 fn validate_transaction(753 source: TransactionSource,754 tx: <Block as BlockT>::Extrinsic,755 ) -> TransactionValidity {756 Executive::validate_transaction(source, tx)757 }758 }759760 impl sp_offchain::OffchainWorkerApi<Block> for Runtime {761 fn offchain_worker(header: &<Block as BlockT>::Header) {762 Executive::offchain_worker(header)763 }764 }765766 impl sp_session::SessionKeys<Block> for Runtime {767 fn generate_session_keys(seed: Option<Vec<u8>>) -> Vec<u8> {768 opaque::SessionKeys::generate(seed)769 }770771 fn decode_session_keys(772 encoded: Vec<u8>,773 ) -> Option<Vec<(Vec<u8>, KeyTypeId)>> {774 opaque::SessionKeys::decode_into_raw_public_keys(&encoded)775 }776 }777778 impl frame_system_rpc_runtime_api::AccountNonceApi<Block, AccountId, Index> for Runtime {779 fn account_nonce(account: AccountId) -> Index {780 System::account_nonce(account)781 }782 }783784 impl pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi<Block, Balance> for Runtime {785 fn query_info(uxt: <Block as BlockT>::Extrinsic, len: u32) -> RuntimeDispatchInfo<Balance> {786 TransactionPayment::query_info(uxt, len)787 }788 fn query_fee_details(uxt: <Block as BlockT>::Extrinsic, len: u32) -> FeeDetails<Balance> {789 TransactionPayment::query_fee_details(uxt, len)790 }791 }792793 impl pallet_contracts_rpc_runtime_api::ContractsApi<Block, AccountId, Balance, BlockNumber>794 for Runtime795 {796 fn call(797 origin: AccountId,798 dest: AccountId,799 value: Balance,800 gas_limit: u64,801 input_data: Vec<u8>,802 ) -> pallet_contracts_primitives::ContractExecResult {803 Contracts::bare_call(origin, dest, value, gas_limit, input_data)804 }805806 fn get_storage(807 address: AccountId,808 key: [u8; 32],809 ) -> pallet_contracts_primitives::GetStorageResult {810 Contracts::get_storage(address, key)811 }812813 fn rent_projection(814 address: AccountId,815 ) -> pallet_contracts_primitives::RentProjectionResult<BlockNumber> {816 Contracts::rent_projection(address)817 }818 }819820 #[cfg(feature = "runtime-benchmarks")]821 impl frame_benchmarking::Benchmark<Block> for Runtime {822 fn dispatch_benchmark(823 config: frame_benchmarking::BenchmarkConfig824 ) -> Result<Vec<frame_benchmarking::BenchmarkBatch>, sp_runtime::RuntimeString> {825 use frame_benchmarking::{Benchmarking, BenchmarkBatch, add_benchmark, TrackedStorageKey};826827 let whitelist: Vec<TrackedStorageKey> = vec![828 // Alice account829 hex_literal::hex!("d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d").to_vec().into(),830 // // Total Issuance831 // hex_literal::hex!("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80").to_vec().into(),832 // // Execution Phase833 // hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(),834 // // Event Count835 // hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(),836 // // System Events837 // hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(),838 ];839840 let mut batches = Vec::<BenchmarkBatch>::new();841 let params = (&config, &whitelist);842843 add_benchmark!(params, batches, pallet_nft, Nft);844 add_benchmark!(params, batches, pallet_inflation, Inflation);845846 if batches.is_empty() { return Err("Benchmark not found for this pallet.".into()) }847 Ok(batches)848 }849 }850}1//2// This file is subject to the terms and conditions defined in3// file 'LICENSE', which is part of this source code package.4//56//! The Substrate Node Template runtime. This can be compiled with `#[no_std]`, ready for Wasm.78#![cfg_attr(not(feature = "std"), no_std)]9// `construct_runtime!` does a lot of recursion and requires us to increase the limit to 256.10#![recursion_limit = "256"]1112// Make the WASM binary available.13#[cfg(feature = "std")]14include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));1516use sp_api::impl_runtime_apis;17use sp_core::{ crypto::KeyTypeId, OpaqueMetadata };18// #[cfg(any(feature = "std", test))]19// pub use sp_runtime::BuildStorage;20use sp_runtime::traits::{21 AccountIdLookup, AccountIdConversion, BlakeTwo256, Block as BlockT, ConvertInto, IdentifyAccount, Verify,22};23use sp_runtime::{24 Permill, Perbill, Percent,25 create_runtime_str, generic, impl_opaque_keys,26 transaction_validity::{TransactionSource, TransactionValidity},27 ApplyExtrinsicResult, MultiSignature,28};2930use sp_std::prelude::*;3132#[cfg(feature = "std")]33use sp_version::NativeVersion;34use sp_version::RuntimeVersion;35pub use pallet_transaction_payment::{Multiplier, TargetedFeeAdjustment, FeeDetails, RuntimeDispatchInfo};36// A few exports that help ease life for downstream crates.37pub use pallet_balances::Call as BalancesCall;38pub use frame_support::{39 construct_runtime,40 match_type,41 dispatch::DispatchResult,42 PalletId,43 parameter_types,44 StorageValue,45 traits::{46 All, Currency, ExistenceRequirement, Get, IsInVec, KeyOwnerProofSystem, LockIdentifier, OnUnbalanced, Randomness47 },48 weights::{49 constants::{BlockExecutionWeight, ExtrinsicBaseWeight, RocksDbWeight, WEIGHT_PER_SECOND},50 DispatchClass, DispatchInfo, GetDispatchInfo, IdentityFee, Pays, PostDispatchInfo, Weight,51 WeightToFeePolynomial, WeightToFeeCoefficient, WeightToFeeCoefficients52 },53};54use pallet_contracts::weights::WeightInfo;55// #[cfg(any(feature = "std", test))]56use frame_system::{57 self as system,58 EnsureRoot, 59 limits::{BlockWeights, BlockLength},60};61use sp_arithmetic::{traits::{BaseArithmetic, Unsigned}};62use smallvec::smallvec;6364pub use pallet_timestamp::Call as TimestampCall;65pub use sp_consensus_aura::sr25519::AuthorityId as AuraId;6667// Polkadot imports68use pallet_xcm::XcmPassthrough;69use polkadot_parachain::primitives::Sibling;70use xcm::v0::Xcm;71use xcm::v0::{BodyId, Junction::*, MultiAsset, MultiLocation, MultiLocation::*, NetworkId};72use xcm_builder::{73 AccountId32Aliases, AllowTopLevelPaidExecutionFrom, AllowUnpaidExecutionFrom, CurrencyAdapter,74 EnsureXcmOrigin, FixedWeightBounds, IsConcrete, LocationInverter, NativeAsset,75 ParentAsSuperuser, ParentIsDefault, RelayChainAsNative, SiblingParachainAsNative,76 SiblingParachainConvertsVia, SignedAccountId32AsNative, SignedToAccountId32,77 SovereignSignedViaLocation, TakeWeightCredit, UsingComponents,78};79use xcm_executor::{Config, XcmExecutor};808182mod chain_extension;83use crate::chain_extension::{ NFTExtension, Imbalance };8485/// Re-export a nft pallet86/// TODO: Check this re-export. Is this safe and good style?87extern crate pallet_nft;88pub use pallet_nft::*;8990/// An index to a block.91pub type BlockNumber = u32;9293/// Alias to 512-bit hash when used in the context of a transaction signature on the chain.94pub type Signature = MultiSignature;9596/// Some way of identifying an account on the chain. We intentionally make it equivalent97/// to the public key of our transaction signing scheme.98pub type AccountId = <<Signature as Verify>::Signer as IdentifyAccount>::AccountId;99100/// The type for looking up accounts. We don't expect more than 4 billion of them, but you101/// never know...102pub type AccountIndex = u32;103104/// Balance of an account.105pub type Balance = u128;106107/// Index of a transaction in the chain.108pub type Index = u32;109110/// A hash of some data used by the chain.111pub type Hash = sp_core::H256;112113/// Digest item type.114pub type DigestItem = generic::DigestItem<Hash>;115116mod nft_weights;117118/// Opaque types. These are used by the CLI to instantiate machinery that don't need to know119/// the specifics of the runtime. They can then be made to be agnostic over specific formats120/// of data like extrinsics, allowing for them to continue syncing the network through upgrades121/// to even the core data structures.122pub mod opaque {123 use super::*;124125 pub use sp_runtime::OpaqueExtrinsic as UncheckedExtrinsic;126127 /// Opaque block type.128 pub type Block = generic::Block<Header, UncheckedExtrinsic>;129130 pub type SessionHandlers = ();131132 impl_opaque_keys! {133 pub struct SessionKeys {}134 }135}136137/// This runtime version.138pub const VERSION: RuntimeVersion = RuntimeVersion {139 spec_name: create_runtime_str!("nft"),140 impl_name: create_runtime_str!("nft"),141 authoring_version: 1,142 spec_version: 3,143 impl_version: 1,144 apis: RUNTIME_API_VERSIONS,145 transaction_version: 1,146};147148pub const MILLISECS_PER_BLOCK: u64 = 12000;149150pub const SLOT_DURATION: u64 = MILLISECS_PER_BLOCK;151152// These time units are defined in number of blocks.153pub const MINUTES: BlockNumber = 60_000 / (MILLISECS_PER_BLOCK as BlockNumber);154pub const HOURS: BlockNumber = MINUTES * 60;155pub const DAYS: BlockNumber = HOURS * 24;156157#[derive(codec::Encode, codec::Decode)]158pub enum XCMPMessage<XAccountId, XBalance> {159 /// Transfer tokens to the given account from the Parachain account.160 TransferToken(XAccountId, XBalance),161}162163/// The version information used to identify this runtime when compiled natively.164#[cfg(feature = "std")]165pub fn native_version() -> NativeVersion {166 NativeVersion {167 runtime_version: VERSION,168 can_author_with: Default::default(),169 }170}171172type NegativeImbalance = <Balances as Currency<AccountId>>::NegativeImbalance;173174pub struct DealWithFees;175impl OnUnbalanced<NegativeImbalance> for DealWithFees {176 fn on_unbalanceds<B>(mut fees_then_tips: impl Iterator<Item=NegativeImbalance>) {177 if let Some(fees) = fees_then_tips.next() {178 // for fees, 100% to treasury179 let mut split = fees.ration(100, 0);180 if let Some(tips) = fees_then_tips.next() {181 // for tips, if any, 100% to treasury182 tips.ration_merge_into(100, 0, &mut split);183 }184 Treasury::on_unbalanced(split.0);185 // Author::on_unbalanced(split.1);186 }187 }188}189190// impl OnUnbalanced<NegativeImbalance> for DealWithFees {191// fn on_unbalanceds<B>(mut fees_then_tips: impl Iterator<Item=NegativeImbalance>) {192// if let Some(fees) = fees_then_tips.next() {193// // for fees, 100% to treasury194// let mut split = fees.ration(100, 0);195// if let Some(tips) = fees_then_tips.next() {196// // for tips, if any, 100% to treasury197// tips.ration_merge_into(100, 0, &mut split);198// }199// Treasury::on_unbalanced(split.0);200// // Author::on_unbalanced(split.1);201// }202// }203// }204205/// We assume that ~10% of the block weight is consumed by `on_initalize` handlers.206/// This is used to limit the maximal weight of a single extrinsic.207const AVERAGE_ON_INITIALIZE_RATIO: Perbill = Perbill::from_percent(10);208/// We allow `Normal` extrinsics to fill up the block up to 75%, the rest can be used209/// by Operational extrinsics.210const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75);211/// We allow for 2 seconds of compute with a 6 second average block time.212const MAXIMUM_BLOCK_WEIGHT: Weight = 2 * WEIGHT_PER_SECOND;213214parameter_types! {215 pub const BlockHashCount: BlockNumber = 2400;216 pub RuntimeBlockLength: BlockLength =217 BlockLength::max_with_normal_ratio(5 * 1024 * 1024, NORMAL_DISPATCH_RATIO);218 pub const AvailableBlockRatio: Perbill = Perbill::from_percent(75);219 pub const MaximumBlockLength: u32 = 5 * 1024 * 1024;220 pub RuntimeBlockWeights: BlockWeights = BlockWeights::builder()221 .base_block(BlockExecutionWeight::get())222 .for_class(DispatchClass::all(), |weights| {223 weights.base_extrinsic = ExtrinsicBaseWeight::get();224 })225 .for_class(DispatchClass::Normal, |weights| {226 weights.max_total = Some(NORMAL_DISPATCH_RATIO * MAXIMUM_BLOCK_WEIGHT);227 })228 .for_class(DispatchClass::Operational, |weights| {229 weights.max_total = Some(MAXIMUM_BLOCK_WEIGHT);230 // Operational transactions have some extra reserved space, so that they231 // are included even if block reached `MAXIMUM_BLOCK_WEIGHT`.232 weights.reserved = Some(233 MAXIMUM_BLOCK_WEIGHT - NORMAL_DISPATCH_RATIO * MAXIMUM_BLOCK_WEIGHT234 );235 })236 .avg_block_initialization(AVERAGE_ON_INITIALIZE_RATIO)237 .build_or_panic();238 pub const Version: RuntimeVersion = VERSION;239 pub const SS58Prefix: u8 = 42;240}241242impl system::Config for Runtime {243 /// The data to be stored in an account.244 type AccountData = pallet_balances::AccountData<Balance>;245 /// The identifier used to distinguish between accounts.246 type AccountId = AccountId;247 /// The basic call filter to use in dispatchable.248 type BaseCallFilter = ();249 /// Maximum number of block number to block hash mappings to keep (oldest pruned first).250 type BlockHashCount = BlockHashCount;251 /// The maximum length of a block (in bytes).252 type BlockLength = RuntimeBlockLength;253 /// The index type for blocks.254 type BlockNumber = BlockNumber;255 /// The weight of the overhead invoked on the block import process, independent of the extrinsics included in that block.256 type BlockWeights = RuntimeBlockWeights;257 /// The aggregated dispatch type that is available for extrinsics.258 type Call = Call;259 /// The weight of database operations that the runtime can invoke.260 type DbWeight = RocksDbWeight;261 /// The ubiquitous event type.262 type Event = Event;263 /// The type for hashing blocks and tries.264 type Hash = Hash;265 /// The hashing algorithm used.266 type Hashing = BlakeTwo256;267 /// The header type.268 type Header = generic::Header<BlockNumber, BlakeTwo256>;269 /// The index type for storing how many extrinsics an account has signed.270 type Index = Index;271 /// The lookup mechanism to get account ID from whatever is passed in dispatchers.272 type Lookup = AccountIdLookup<AccountId, ()>;273 /// What to do if an account is fully reaped from the system.274 type OnKilledAccount = ();275 /// What to do if a new account is created.276 type OnNewAccount = ();277 type OnSetCode = cumulus_pallet_parachain_system::ParachainSetCode<Self>;278 /// The ubiquitous origin type.279 type Origin = Origin;280 /// This type is being generated by `construct_runtime!`.281 type PalletInfo = PalletInfo;282 /// This is used as an identifier of the chain. 42 is the generic substrate prefix.283 type SS58Prefix = SS58Prefix;284 /// Weight information for the extrinsics of this pallet.285 type SystemWeightInfo = system::weights::SubstrateWeight<Runtime>;286 /// Version of the runtime.287 type Version = Version;288}289290parameter_types! {291 pub const MinimumPeriod: u64 = SLOT_DURATION / 2;292}293294impl pallet_timestamp::Config for Runtime {295 /// A timestamp: milliseconds since the unix epoch.296 type Moment = u64;297 type OnTimestampSet = ();298 type MinimumPeriod = MinimumPeriod;299 type WeightInfo = ();300}301302parameter_types! {303 // pub const ExistentialDeposit: u128 = 500;304 pub const ExistentialDeposit: u128 = 0;305 pub const MaxLocks: u32 = 50;306}307308impl pallet_balances::Config for Runtime {309 type MaxLocks = MaxLocks;310 /// The type for recording an account's balance.311 type Balance = Balance;312 /// The ubiquitous event type.313 type Event = Event;314 type DustRemoval = Treasury;315 type ExistentialDeposit = ExistentialDeposit;316 type AccountStore = System;317 type WeightInfo = pallet_balances::weights::SubstrateWeight<Runtime>;318}319320pub const MICROUNIQUE: Balance = 1_000_000_000;321pub const MILLIUNIQUE: Balance = 1_000 * MICROUNIQUE;322pub const CENTIUNIQUE: Balance = 10 * MILLIUNIQUE;323pub const UNIQUE: Balance = 100 * CENTIUNIQUE;324325pub const fn deposit(items: u32, bytes: u32) -> Balance {326 items as Balance * 15 * CENTIUNIQUE + (bytes as Balance) * 6 * CENTIUNIQUE327}328329parameter_types! {330 pub TombstoneDeposit: Balance = deposit(331 1,332 sp_std::mem::size_of::<pallet_contracts::Pallet<Runtime>> as u32,333 );334 pub DepositPerContract: Balance = TombstoneDeposit::get();335 pub const DepositPerStorageByte: Balance = deposit(0, 1);336 pub const DepositPerStorageItem: Balance = deposit(1, 0);337 pub RentFraction: Perbill = Perbill::from_rational(1u32, 30 * DAYS);338 pub const SurchargeReward: Balance = 150 * MILLIUNIQUE;339 pub const SignedClaimHandicap: u32 = 2;340 pub const MaxDepth: u32 = 32;341 pub const MaxValueSize: u32 = 16 * 1024;342 pub const MaxCodeSize: u32 = 1024 * 1024 * 25; // 25 Mb 343 // The lazy deletion runs inside on_initialize.344 pub DeletionWeightLimit: Weight = AVERAGE_ON_INITIALIZE_RATIO *345 RuntimeBlockWeights::get().max_block;346 // The weight needed for decoding the queue should be less or equal than a fifth347 // of the overall weight dedicated to the lazy deletion.348 pub DeletionQueueDepth: u32 = ((DeletionWeightLimit::get() / (349 <Runtime as pallet_contracts::Config>::WeightInfo::on_initialize_per_queue_item(1) -350 <Runtime as pallet_contracts::Config>::WeightInfo::on_initialize_per_queue_item(0)351 )) / 5) as u32;352 pub Schedule: pallet_contracts::Schedule<Runtime> = Default::default();353}354355impl pallet_contracts::Config for Runtime {356 type Time = Timestamp;357 type Randomness = RandomnessCollectiveFlip;358 type Currency = Balances;359 type Event = Event;360 type RentPayment = ();361 type SignedClaimHandicap = SignedClaimHandicap;362 type TombstoneDeposit = TombstoneDeposit;363 type DepositPerContract = DepositPerContract;364 type DepositPerStorageByte = DepositPerStorageByte;365 type DepositPerStorageItem = DepositPerStorageItem;366 type RentFraction = RentFraction;367 type SurchargeReward = SurchargeReward;368 // type MaxDepth = MaxDepth;369 // type MaxValueSize = MaxValueSize;370 type WeightPrice = pallet_transaction_payment::Module<Self>;371 type WeightInfo = pallet_contracts::weights::SubstrateWeight<Self>;372 type ChainExtension = NFTExtension;373 type DeletionQueueDepth = DeletionQueueDepth;374 type DeletionWeightLimit = DeletionWeightLimit;375 // type MaxCodeSize = MaxCodeSize;376 type Schedule = Schedule;377 type CallStack = [pallet_contracts::Frame<Self>; 31];378}379380parameter_types! {381 pub const TransactionByteFee: Balance = 501 * MICROUNIQUE; // Targeting 0.1 Unique per NFT transfer 382}383384/// Linear implementor of `WeightToFeePolynomial` 385pub struct LinearFee<T>(sp_std::marker::PhantomData<T>);386387impl<T> WeightToFeePolynomial for LinearFee<T> where388 T: BaseArithmetic + From<u32> + Copy + Unsigned389{390 type Balance = T;391392 fn polynomial() -> WeightToFeeCoefficients<Self::Balance> {393 smallvec!(WeightToFeeCoefficient {394 coeff_integer: 146_700u32.into(), // Targeting 0.1 Unique per NFT transfer395 coeff_frac: Perbill::zero(),396 negative: false,397 degree: 1,398 })399 }400}401402impl pallet_transaction_payment::Config for Runtime {403 type OnChargeTransaction = pallet_transaction_payment::CurrencyAdapter<Balances, ()>;404 type TransactionByteFee = TransactionByteFee;405 type WeightToFee = LinearFee<Balance>;406 type FeeMultiplierUpdate = ();407}408409parameter_types! {410 pub const ProposalBond: Permill = Permill::from_percent(5);411 pub const ProposalBondMinimum: Balance = 1 * UNIQUE;412 pub const SpendPeriod: BlockNumber = 5 * MINUTES;413 pub const Burn: Permill = Permill::from_percent(0);414 pub const TipCountdown: BlockNumber = 1 * DAYS;415 pub const TipFindersFee: Percent = Percent::from_percent(20);416 pub const TipReportDepositBase: Balance = 1 * UNIQUE;417 pub const DataDepositPerByte: Balance = 1 * CENTIUNIQUE;418 pub const BountyDepositBase: Balance = 1 * UNIQUE;419 pub const BountyDepositPayoutDelay: BlockNumber = 1 * DAYS;420 pub const TreasuryModuleId: PalletId = PalletId(*b"py/trsry");421 pub const BountyUpdatePeriod: BlockNumber = 14 * DAYS;422 pub const MaximumReasonLength: u32 = 16384;423 pub const BountyCuratorDeposit: Permill = Permill::from_percent(50);424 pub const BountyValueMinimum: Balance = 5 * UNIQUE;425 pub const MaxApprovals: u32 = 100;426}427428impl pallet_treasury::Config for Runtime {429 type PalletId = TreasuryModuleId;430 type Currency = Balances;431 type ApproveOrigin = EnsureRoot<AccountId>;432 type RejectOrigin = EnsureRoot<AccountId>;433 type Event = Event;434 type OnSlash = ();435 type ProposalBond = ProposalBond;436 type ProposalBondMinimum = ProposalBondMinimum;437 type SpendPeriod = SpendPeriod;438 type Burn = Burn;439 type BurnDestination = ();440 type SpendFunds = ();441 type WeightInfo = pallet_treasury::weights::SubstrateWeight<Runtime>;442 type MaxApprovals = MaxApprovals;443}444445impl pallet_sudo::Config for Runtime {446 type Event = Event;447 type Call = Call;448}449450parameter_types! {451 pub const MinVestedTransfer: Balance = 10 * UNIQUE;452}453454impl pallet_vesting::Config for Runtime {455 type Event = Event;456 type Currency = Balances;457 type BlockNumberToBalance = ConvertInto;458 type MinVestedTransfer = MinVestedTransfer;459 type WeightInfo = ();460}461462parameter_types! {463 pub const ReservedDmpWeight: Weight = MAXIMUM_BLOCK_WEIGHT / 4;464 pub const ReservedXcmpWeight: Weight = MAXIMUM_BLOCK_WEIGHT / 4;465}466467impl cumulus_pallet_parachain_system::Config for Runtime {468 type Event = Event;469 type OnValidationData = ();470 type SelfParaId = parachain_info::Pallet<Runtime>;471 // type DownwardMessageHandlers = cumulus_primitives_utility::UnqueuedDmpAsParent<472 // MaxDownwardMessageWeight,473 // XcmExecutor<XcmConfig>,474 // Call,475 // >;476 type OutboundXcmpMessageSource = XcmpQueue;477 type DmpMessageHandler = DmpQueue;478 type ReservedDmpWeight = ReservedDmpWeight;479 type ReservedXcmpWeight = ReservedXcmpWeight;480 type XcmpMessageHandler = XcmpQueue;481}482483impl parachain_info::Config for Runtime {}484485impl cumulus_pallet_aura_ext::Config for Runtime {}486487parameter_types! {488 pub const RelayLocation: MultiLocation = X1(Parent);489 pub const RelayNetwork: NetworkId = NetworkId::Polkadot;490 pub RelayOrigin: Origin = cumulus_pallet_xcm::Origin::Relay.into();491 pub Ancestry: MultiLocation = X1(Parachain(ParachainInfo::parachain_id().into()));492}493494/// Type for specifying how a `MultiLocation` can be converted into an `AccountId`. This is used495/// when determining ownership of accounts for asset transacting and when attempting to use XCM496/// `Transact` in order to determine the dispatch Origin.497pub type LocationToAccountId = (498 // The parent (Relay-chain) origin converts to the default `AccountId`.499 ParentIsDefault<AccountId>,500 // Sibling parachain origins convert to AccountId via the `ParaId::into`.501 SiblingParachainConvertsVia<Sibling, AccountId>,502 // Straight up local `AccountId32` origins just alias directly to `AccountId`.503 AccountId32Aliases<RelayNetwork, AccountId>,504);505506/// Means for transacting assets on this chain.507pub type LocalAssetTransactor = CurrencyAdapter<508 // Use this currency:509 Balances,510 // Use this currency when it is a fungible asset matching the given location or name:511 IsConcrete<RelayLocation>,512 // Do a simple punn to convert an AccountId32 MultiLocation into a native chain account ID:513 LocationToAccountId,514 // Our chain's account ID type (we can't get away without mentioning it explicitly):515 AccountId,516 // We don't track any teleports.517 (),518>;519520/// This is the type we use to convert an (incoming) XCM origin into a local `Origin` instance,521/// ready for dispatching a transaction with Xcm's `Transact`. There is an `OriginKind` which can522/// biases the kind of local `Origin` it will become.523pub type XcmOriginToTransactDispatchOrigin = (524 // Sovereign account converter; this attempts to derive an `AccountId` from the origin location525 // using `LocationToAccountId` and then turn that into the usual `Signed` origin. Useful for526 // foreign chains who want to have a local sovereign account on this chain which they control.527 SovereignSignedViaLocation<LocationToAccountId, Origin>,528 // Native converter for Relay-chain (Parent) location; will converts to a `Relay` origin when529 // recognised.530 RelayChainAsNative<RelayOrigin, Origin>,531 // Native converter for sibling Parachains; will convert to a `SiblingPara` origin when532 // recognised.533 SiblingParachainAsNative<cumulus_pallet_xcm::Origin, Origin>,534 // Superuser converter for the Relay-chain (Parent) location. This will allow it to issue a535 // transaction from the Root origin.536 ParentAsSuperuser<Origin>,537 // Native signed account converter; this just converts an `AccountId32` origin into a normal538 // `Origin::Signed` origin of the same 32-byte value.539 SignedAccountId32AsNative<RelayNetwork, Origin>,540 // Xcm origins can be represented natively under the Xcm pallet's Xcm origin.541 XcmPassthrough<Origin>,542);543544parameter_types! {545 // One XCM operation is 1_000_000 weight - almost certainly a conservative estimate.546 pub UnitWeightCost: Weight = 1_000_000;547 // 1200 UNIQUEs buy 1 second of weight.548 pub const WeightPrice: (MultiLocation, u128) = (X1(Parent), 1_200 * UNIQUE);549}550551match_type! {552 pub type ParentOrParentsUnitPlurality: impl Contains<MultiLocation> = {553 X1(Parent) | X2(Parent, Plurality { id: BodyId::Unit, .. })554 };555}556557pub type Barrier = (558 TakeWeightCredit,559 AllowTopLevelPaidExecutionFrom<All<MultiLocation>>,560 AllowUnpaidExecutionFrom<ParentOrParentsUnitPlurality>,561 // ^^^ Parent & its unit plurality gets free execution562);563564pub struct XcmConfig;565impl Config for XcmConfig {566 type Call = Call;567 type XcmSender = XcmRouter;568 // How to withdraw and deposit an asset.569 type AssetTransactor = LocalAssetTransactor;570 type OriginConverter = XcmOriginToTransactDispatchOrigin;571 type IsReserve = NativeAsset;572 type IsTeleporter = NativeAsset; // <- should be enough to allow teleportation of ROC573 type LocationInverter = LocationInverter<Ancestry>;574 type Barrier = Barrier;575 type Weigher = FixedWeightBounds<UnitWeightCost, Call>;576 type Trader = UsingComponents<IdentityFee<Balance>, RelayLocation, AccountId, Balances, ()>;577 type ResponseHandler = (); // Don't handle responses for now.578}579580// parameter_types! {581// pub const MaxDownwardMessageWeight: Weight = MAXIMUM_BLOCK_WEIGHT / 10;582// }583584/// No local origins on this chain are allowed to dispatch XCM sends/executions.585pub type LocalOriginToLocation = (SignedToAccountId32<Origin, AccountId, RelayNetwork>,);586587/// The means for routing XCM messages which are not for local execution into the right message588/// queues.589pub type XcmRouter = (590 // Two routers - use UMP to communicate with the relay chain:591 cumulus_primitives_utility::ParentAsUmp<ParachainSystem>,592 // ..and XCMP to communicate with the sibling chains.593 XcmpQueue,594);595596impl pallet_xcm::Config for Runtime {597 type Event = Event;598 type SendXcmOrigin = EnsureXcmOrigin<Origin, LocalOriginToLocation>;599 type XcmRouter = XcmRouter;600 type ExecuteXcmOrigin = EnsureXcmOrigin<Origin, LocalOriginToLocation>;601 type XcmExecuteFilter = All<(MultiLocation, Xcm<Call>)>;602 type XcmExecutor = XcmExecutor<XcmConfig>;603 type XcmTeleportFilter = All<(MultiLocation, Vec<MultiAsset>)>;604 type XcmReserveTransferFilter = ();605 type Weigher = FixedWeightBounds<UnitWeightCost, Call>;606}607608impl cumulus_pallet_xcm::Config for Runtime {609 type Event = Event;610 type XcmExecutor = XcmExecutor<XcmConfig>;611}612613impl cumulus_pallet_xcmp_queue::Config for Runtime {614 type Event = Event;615 type XcmExecutor = XcmExecutor<XcmConfig>;616 type ChannelInfo = ParachainSystem;617}618619impl cumulus_pallet_dmp_queue::Config for Runtime {620 type Event = Event;621 type XcmExecutor = XcmExecutor<XcmConfig>;622 type ExecuteOverweightOrigin = frame_system::EnsureRoot<AccountId>;623}624625impl pallet_aura::Config for Runtime {626 type AuthorityId = AuraId;627}628629parameter_types! {630 pub TreasuryAccountId: AccountId = TreasuryModuleId::get().into_account();631 pub const CollectionCreationPrice: Balance = 100 * UNIQUE;632}633634/// Used for the pallet nft in `./nft.rs`635impl pallet_nft::Config for Runtime {636 type Event = Event;637 type WeightInfo = nft_weights::WeightInfo;638 type Currency = Balances;639 type CollectionCreationPrice = CollectionCreationPrice;640 type TreasuryAccountId = TreasuryAccountId;641}642643/// Reimport pallet inflation644extern crate pallet_inflation;645pub use pallet_inflation::*;646647parameter_types! {648 pub const InflationBlockInterval: BlockNumber = 100; // every time per how many blocks inflation is applied649}650651/// Used for the pallet inflation652impl pallet_inflation::Config for Runtime {653 type Currency = Balances;654 type TreasuryAccountId = TreasuryAccountId;655 type InflationBlockInterval = InflationBlockInterval;656}657658construct_runtime!(659 pub enum Runtime where660 Block = Block,661 NodeBlock = opaque::Block,662 UncheckedExtrinsic = UncheckedExtrinsic663 {664 Balances: pallet_balances::{Pallet, Call, Storage, Config<T>, Event<T>} = 30,665 Contracts: pallet_contracts::{Pallet, Call, Storage, Event<T>},666 RandomnessCollectiveFlip: pallet_randomness_collective_flip::{Pallet, Call, Storage},667 Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent},668 TransactionPayment: pallet_transaction_payment::{Pallet, Storage},669 Treasury: pallet_treasury::{Pallet, Call, Storage, Config, Event<T>},670 Sudo: pallet_sudo::{Pallet, Call, Storage, Config<T>, Event<T>},671 System: system::{Pallet, Call, Storage, Config, Event<T>},672 Vesting: pallet_vesting::{Pallet, Call, Config<T>, Storage, Event<T>},673674 ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Storage, Inherent, Event<T>, ValidateUnsigned} = 20,675 ParachainInfo: parachain_info::{Pallet, Storage, Config} = 21,676677 Aura: pallet_aura::{Pallet, Config<T>},678 AuraExt: cumulus_pallet_aura_ext::{Pallet, Config},679680 // XCM helpers.681 XcmpQueue: cumulus_pallet_xcmp_queue::{Pallet, Call, Storage, Event<T>} = 50,682 PolkadotXcm: pallet_xcm::{Pallet, Call, Event<T>, Origin} = 51,683 CumulusXcm: cumulus_pallet_xcm::{Pallet, Call, Event<T>, Origin} = 52,684 DmpQueue: cumulus_pallet_dmp_queue::{Pallet, Call, Storage, Event<T>} = 53,685686687 // Unique Pallets688 Inflation: pallet_inflation::{Pallet, Call, Storage},689 Nft: pallet_nft::{Pallet, Call, Config<T>, Storage, Event<T>},690 }691);692693/// The address format for describing accounts.694pub type Address = sp_runtime::MultiAddress<AccountId, ()>;695/// Block header type as expected by this runtime.696pub type Header = generic::Header<BlockNumber, BlakeTwo256>;697/// Block type as expected by this runtime.698pub type Block = generic::Block<Header, UncheckedExtrinsic>;699/// A Block signed with a Justification700pub type SignedBlock = generic::SignedBlock<Block>;701/// BlockId type as expected by this runtime.702pub type BlockId = generic::BlockId<Block>;703/// The SignedExtension to the basic transaction logic.704pub type SignedExtra = (705 system::CheckSpecVersion<Runtime>,706 // system::CheckTxVersion<Runtime>,707 system::CheckGenesis<Runtime>,708 system::CheckEra<Runtime>,709 system::CheckNonce<Runtime>,710 system::CheckWeight<Runtime>,711 pallet_nft::ChargeTransactionPayment<Runtime>,712);713/// Unchecked extrinsic type as expected by this runtime.714pub type UncheckedExtrinsic = generic::UncheckedExtrinsic<Address, Call, Signature, SignedExtra>;715/// Extrinsic type that has already been checked.716pub type CheckedExtrinsic = generic::CheckedExtrinsic<AccountId, Call, SignedExtra>;717/// Executive: handles dispatch to the various modules.718pub type Executive = frame_executive::Executive<719 Runtime,720 Block,721 frame_system::ChainContext<Runtime>,722 Runtime,723 AllPallets,724>;725726impl_opaque_keys! {727 pub struct SessionKeys {728 pub aura: Aura,729 }730}731732impl_runtime_apis! {733 impl sp_api::Core<Block> for Runtime {734 fn version() -> RuntimeVersion {735 VERSION736 }737738 fn execute_block(block: Block) {739 Executive::execute_block(block)740 }741742 fn initialize_block(header: &<Block as BlockT>::Header) {743 Executive::initialize_block(header)744 }745 }746747 impl sp_api::Metadata<Block> for Runtime {748 fn metadata() -> OpaqueMetadata {749 Runtime::metadata().into()750 }751 }752753 impl sp_block_builder::BlockBuilder<Block> for Runtime {754 fn apply_extrinsic(extrinsic: <Block as BlockT>::Extrinsic) -> ApplyExtrinsicResult {755 Executive::apply_extrinsic(extrinsic)756 }757758 fn finalize_block() -> <Block as BlockT>::Header {759 Executive::finalize_block()760 }761762 fn inherent_extrinsics(data: sp_inherents::InherentData) -> Vec<<Block as BlockT>::Extrinsic> {763 data.create_extrinsics()764 }765766 fn check_inherents(767 block: Block,768 data: sp_inherents::InherentData,769 ) -> sp_inherents::CheckInherentsResult {770 data.check_extrinsics(&block)771 }772773 // fn random_seed() -> <Block as BlockT>::Hash {774 // RandomnessCollectiveFlip::random_seed().0775 // }776 }777778 impl sp_transaction_pool::runtime_api::TaggedTransactionQueue<Block> for Runtime {779 fn validate_transaction(780 source: TransactionSource,781 tx: <Block as BlockT>::Extrinsic,782 ) -> TransactionValidity {783 Executive::validate_transaction(source, tx)784 }785 }786787 impl sp_offchain::OffchainWorkerApi<Block> for Runtime {788 fn offchain_worker(header: &<Block as BlockT>::Header) {789 Executive::offchain_worker(header)790 }791 }792793 impl sp_session::SessionKeys<Block> for Runtime {794 fn decode_session_keys(795 encoded: Vec<u8>,796 ) -> Option<Vec<(Vec<u8>, KeyTypeId)>> {797 SessionKeys::decode_into_raw_public_keys(&encoded)798 }799800 fn generate_session_keys(seed: Option<Vec<u8>>) -> Vec<u8> {801 SessionKeys::generate(seed)802 }803 }804805 impl sp_consensus_aura::AuraApi<Block, AuraId> for Runtime {806 fn slot_duration() -> sp_consensus_aura::SlotDuration {807 sp_consensus_aura::SlotDuration::from_millis(Aura::slot_duration())808 }809810 fn authorities() -> Vec<AuraId> {811 Aura::authorities()812 }813 }814815 impl cumulus_primitives_core::CollectCollationInfo<Block> for Runtime {816 fn collect_collation_info() -> cumulus_primitives_core::CollationInfo {817 ParachainSystem::collect_collation_info()818 }819 }820821 impl frame_system_rpc_runtime_api::AccountNonceApi<Block, AccountId, Index> for Runtime {822 fn account_nonce(account: AccountId) -> Index {823 System::account_nonce(account)824 }825 }826827 impl pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi<Block, Balance> for Runtime {828 fn query_info(uxt: <Block as BlockT>::Extrinsic, len: u32) -> RuntimeDispatchInfo<Balance> {829 TransactionPayment::query_info(uxt, len)830 }831 fn query_fee_details(uxt: <Block as BlockT>::Extrinsic, len: u32) -> FeeDetails<Balance> {832 TransactionPayment::query_fee_details(uxt, len)833 }834 }835836 impl pallet_contracts_rpc_runtime_api::ContractsApi<Block, AccountId, Balance, BlockNumber, Hash>837 for Runtime838 {839 fn call(840 origin: AccountId,841 dest: AccountId,842 value: Balance,843 gas_limit: u64,844 input_data: Vec<u8>,845 ) -> pallet_contracts_primitives::ContractExecResult {846 Contracts::bare_call(origin, dest, value, gas_limit, input_data, false)847 }848849 fn instantiate(850 origin: AccountId,851 endowment: Balance,852 gas_limit: u64,853 code: pallet_contracts_primitives::Code<Hash>,854 data: Vec<u8>,855 salt: Vec<u8>,856 ) -> pallet_contracts_primitives::ContractInstantiateResult<AccountId, BlockNumber>857 {858 Contracts::bare_instantiate(origin, endowment, gas_limit, code, data, salt, true, false)859 }860861 fn get_storage(862 address: AccountId,863 key: [u8; 32],864 ) -> pallet_contracts_primitives::GetStorageResult {865 Contracts::get_storage(address, key)866 }867868 fn rent_projection(869 address: AccountId,870 ) -> pallet_contracts_primitives::RentProjectionResult<BlockNumber> {871 Contracts::rent_projection(address)872 }873 }874875 #[cfg(feature = "runtime-benchmarks")]876 impl frame_benchmarking::Benchmark<Block> for Runtime {877 fn dispatch_benchmark(878 config: frame_benchmarking::BenchmarkConfig879 ) -> Result<Vec<frame_benchmarking::BenchmarkBatch>, sp_runtime::RuntimeString> {880 use frame_benchmarking::{Benchmarking, BenchmarkBatch, add_benchmark, TrackedStorageKey};881882 let whitelist: Vec<TrackedStorageKey> = vec![883 // Alice account884 hex_literal::hex!("d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d").to_vec().into(),885 // // Total Issuance886 // hex_literal::hex!("c2261276cc9d1f8598ea4b6a74b15c2f57c875e4cff74148e4628f264b974c80").to_vec().into(),887 // // Execution Phase888 // hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef7ff553b5a9862a516939d82b3d3d8661a").to_vec().into(),889 // // Event Count890 // hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef70a98fdbe9ce6c55837576c60c7af3850").to_vec().into(),891 // // System Events892 // hex_literal::hex!("26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7").to_vec().into(),893 ];894895 let mut batches = Vec::<BenchmarkBatch>::new();896 let params = (&config, &whitelist);897898 add_benchmark!(params, batches, pallet_nft, Nft);899 add_benchmark!(params, batches, pallet_inflation, Inflation);900901 if batches.is_empty() { return Err("Benchmark not found for this pallet.".into()) }902 Ok(batches)903 }904 }905}