Преглед на файлове

node: Remove unnecessary dependencies.

Shamil Gadelshin преди 4 години
родител
ревизия
10fa8dd43f
променени са 3 файла, в които са добавени 115 реда и са изтрити 209 реда
  1. 59 18
      Cargo.lock
  2. 35 190
      node/Cargo.toml
  3. 21 1
      runtime/Cargo.toml

+ 59 - 18
Cargo.lock

@@ -1197,6 +1197,20 @@ dependencies = [
  "sp-version",
 ]
 
+[[package]]
+name = "frame-system-benchmarking"
+version = "2.0.0-rc4"
+source = "git+https://github.com/paritytech/substrate.git?rev=00768a1f21a579c478fe5d4f51e1fa71f7db9fd4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"
+dependencies = [
+ "frame-benchmarking",
+ "frame-support",
+ "frame-system",
+ "parity-scale-codec",
+ "sp-core",
+ "sp-runtime",
+ "sp-std",
+]
+
 [[package]]
 name = "frame-system-rpc-runtime-api"
 version = "2.0.0-rc4"
@@ -1944,34 +1958,23 @@ version = "3.0.0"
 dependencies = [
  "frame-benchmarking",
  "frame-benchmarking-cli",
- "frame-support",
  "frame-system",
  "futures 0.3.4",
- "hex-literal",
  "joystream-node-runtime",
  "jsonrpc-core",
- "log",
  "node-inspect",
- "pallet-authority-discovery",
- "pallet-balances",
  "pallet-contracts",
  "pallet-contracts-rpc",
  "pallet-grandpa",
  "pallet-im-online",
- "pallet-indices",
- "pallet-staking",
- "pallet-timestamp",
  "pallet-transaction-payment",
  "pallet-transaction-payment-rpc",
  "parity-scale-codec",
- "parking_lot 0.10.2",
- "rand 0.7.3",
  "sc-authority-discovery",
  "sc-basic-authorship",
  "sc-chain-spec",
  "sc-cli",
  "sc-client-api",
- "sc-client-db",
  "sc-consensus",
  "sc-consensus-babe",
  "sc-consensus-babe-rpc",
@@ -1981,13 +1984,9 @@ dependencies = [
  "sc-finality-grandpa-rpc",
  "sc-keystore",
  "sc-network",
- "sc-offchain",
- "sc-rpc",
  "sc-rpc-api",
  "sc-service",
  "sc-service-test",
- "sc-telemetry",
- "sc-tracing",
  "sc-transaction-pool",
  "serde",
  "serde_json",
@@ -2001,7 +2000,6 @@ dependencies = [
  "sp-finality-grandpa",
  "sp-finality-tracker",
  "sp-inherents",
- "sp-io",
  "sp-keyring",
  "sp-runtime",
  "sp-timestamp",
@@ -2010,8 +2008,6 @@ dependencies = [
  "substrate-browser-utils",
  "substrate-frame-rpc-system",
  "tempfile",
- "tokio 0.1.22",
- "tracing",
  "vergen",
  "wasm-bindgen",
  "wasm-bindgen-futures",
@@ -2021,9 +2017,11 @@ dependencies = [
 name = "joystream-node-runtime"
 version = "7.0.0"
 dependencies = [
+ "frame-benchmarking",
  "frame-executive",
  "frame-support",
  "frame-system",
+ "frame-system-benchmarking",
  "frame-system-rpc-runtime-api",
  "pallet-authority-discovery",
  "pallet-authorship",
@@ -2045,6 +2043,7 @@ dependencies = [
  "pallet-membership",
  "pallet-memo",
  "pallet-offences",
+ "pallet-offences-benchmarking",
  "pallet-proposals-codex",
  "pallet-proposals-discussion",
  "pallet-proposals-engine",
@@ -2052,6 +2051,7 @@ dependencies = [
  "pallet-recurring-reward",
  "pallet-service-discovery",
  "pallet-session",
+ "pallet-session-benchmarking",
  "pallet-stake",
  "pallet-staking",
  "pallet-staking-reward-curve",
@@ -3244,6 +3244,7 @@ name = "pallet-collective"
 version = "2.0.0-rc4"
 source = "git+https://github.com/paritytech/substrate.git?rev=00768a1f21a579c478fe5d4f51e1fa71f7db9fd4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"
 dependencies = [
+ "frame-benchmarking",
  "frame-support",
  "frame-system",
  "parity-scale-codec",
@@ -3449,6 +3450,7 @@ name = "pallet-im-online"
 version = "2.0.0-rc4"
 source = "git+https://github.com/paritytech/substrate.git?rev=00768a1f21a579c478fe5d4f51e1fa71f7db9fd4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"
 dependencies = [
+ "frame-benchmarking",
  "frame-support",
  "frame-system",
  "pallet-authorship",
@@ -3468,6 +3470,7 @@ name = "pallet-indices"
 version = "2.0.0-rc4"
 source = "git+https://github.com/paritytech/substrate.git?rev=00768a1f21a579c478fe5d4f51e1fa71f7db9fd4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"
 dependencies = [
+ "frame-benchmarking",
  "frame-support",
  "frame-system",
  "parity-scale-codec",
@@ -3524,6 +3527,27 @@ dependencies = [
  "sp-std",
 ]
 
+[[package]]
+name = "pallet-offences-benchmarking"
+version = "2.0.0-rc4"
+source = "git+https://github.com/paritytech/substrate.git?rev=00768a1f21a579c478fe5d4f51e1fa71f7db9fd4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"
+dependencies = [
+ "frame-benchmarking",
+ "frame-support",
+ "frame-system",
+ "pallet-babe",
+ "pallet-balances",
+ "pallet-grandpa",
+ "pallet-im-online",
+ "pallet-offences",
+ "pallet-session",
+ "pallet-staking",
+ "parity-scale-codec",
+ "sp-runtime",
+ "sp-staking",
+ "sp-std",
+]
+
 [[package]]
 name = "pallet-proposals-codex"
 version = "3.0.0"
@@ -3667,6 +3691,20 @@ dependencies = [
  "sp-trie",
 ]
 
+[[package]]
+name = "pallet-session-benchmarking"
+version = "2.0.0-rc4"
+source = "git+https://github.com/paritytech/substrate.git?rev=00768a1f21a579c478fe5d4f51e1fa71f7db9fd4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"
+dependencies = [
+ "frame-benchmarking",
+ "frame-support",
+ "frame-system",
+ "pallet-session",
+ "pallet-staking",
+ "sp-runtime",
+ "sp-std",
+]
+
 [[package]]
 name = "pallet-stake"
 version = "3.0.0"
@@ -3688,11 +3726,13 @@ name = "pallet-staking"
 version = "2.0.0-rc4"
 source = "git+https://github.com/paritytech/substrate.git?rev=00768a1f21a579c478fe5d4f51e1fa71f7db9fd4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"
 dependencies = [
+ "frame-benchmarking",
  "frame-support",
  "frame-system",
  "pallet-authorship",
  "pallet-session",
  "parity-scale-codec",
+ "rand_chacha 0.2.2",
  "serde",
  "sp-application-crypto",
  "sp-io",
@@ -3764,6 +3804,7 @@ dependencies = [
  "parity-scale-codec",
  "serde",
  "sp-inherents",
+ "sp-io",
  "sp-runtime",
  "sp-std",
  "sp-timestamp",

+ 35 - 190
node/Cargo.toml

@@ -13,27 +13,13 @@ path = 'bin/main.rs'
 [lib]
 crate-type = ["cdylib", "rlib"]
 
-#[dependencies]
-#derive_more = '0.14.0'
-#exit-future = '0.1.4'
-
-#hex = '0.4'
-
 [dependencies]
 # third-party dependencies
-codec = { package = "parity-scale-codec", version = "1.3.1" }
 serde = { version = "1.0.102", features = ["derive"] }
 futures = { version = "0.3.1", features = ["compat"] }
-hex-literal = "0.2.1"
 jsonrpc-core = "14.2.0"
-log = "0.4.8"
-rand = "0.7.2"
-structopt = { version = "0.3.8"}
-tracing = "0.1.10"
-parking_lot = "0.10.0"
-
+structopt = { version = "0.3.8", optional = true}
 serde_json = '1.0'
-tokio = '0.1.22'
 
 # primitives
 sp-authority-discovery = { package = 'sp-authority-discovery', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
@@ -41,15 +27,13 @@ sp-consensus-babe = { package = 'sp-consensus-babe', git = 'https://github.com/p
 sp-finality-grandpa = { package = 'sp-finality-grandpa', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sp-core = { package = 'sp-core', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sp-runtime = { package = 'sp-runtime', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sp-timestamp = { package = 'sp-timestamp', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sp-finality-tracker = { package = 'sp-finality-tracker', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sp-inherents = { package = 'sp-inherents', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sp-keyring = { package = 'sp-keyring', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sp-io = { package = 'sp-io', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sp-consensus = { package = 'sp-consensus', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sp-transaction-pool = { package = 'sp-transaction-pool', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sp-api = { package = 'sp-api', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sp-blockchain = { package = 'sp-blockchain', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+sp-block-builder = { package = 'sp-block-builder', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 
 # client dependencies
 sc-client-api = { package = 'sc-client-api', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
@@ -59,68 +43,31 @@ sc-transaction-pool = { package = 'sc-transaction-pool', git = 'https://github.c
 sc-network = { package = 'sc-network', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-consensus-babe = { package = 'sc-consensus-babe', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4'}
 sc-finality-grandpa = { package = 'sc-finality-grandpa', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sc-client-db = { package = 'sc-client-db', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sc-offchain = { package = 'sc-offchain', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sc-rpc = { package = 'sc-rpc', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-basic-authorship = { package = 'sc-basic-authorship', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-service = { package = 'sc-service', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sc-tracing = { package = 'sc-tracing', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sc-telemetry = { package = 'sc-telemetry', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-authority-discovery = { package = 'sc-authority-discovery', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-consensus-epochs = { package = 'sc-consensus-epochs', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-keystore = { package = 'sc-keystore', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-consensus-babe-rpc = { package = 'sc-consensus-babe-rpc', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-finality-grandpa-rpc = { package = 'sc-finality-grandpa-rpc', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-rpc-api = { package = 'sc-rpc-api', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-sp-block-builder = { package = 'sp-block-builder', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-pallet-contracts-rpc = { package = 'pallet-contracts-rpc', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-pallet-transaction-payment-rpc = { package = 'pallet-transaction-payment-rpc', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-substrate-frame-rpc-system = { package = 'substrate-frame-rpc-system', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-executor = { package = 'sc-executor', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-frame-benchmarking = { package = 'frame-benchmarking', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-
-#sc-client-api = { version = "2.0.0-rc4", path = "../../../client/api" }
-#jsonrpc-core = "14.2.0"
-#node-primitives = { version = "2.0.0-rc4", path = "../primitives" }
-#node-runtime = { version = "2.0.0-rc4", path = "../runtime" }
-#sp-runtime = { version = "2.0.0-rc4", path = "../../../primitives/runtime" }
-#sp-api = { version = "2.0.0-rc4", path = "../../../primitives/api" }
-#pallet-contracts-rpc = { version = "0.8.0-rc4", path = "../../../frame/contracts/rpc/" }
-#pallet-transaction-payment-rpc = { version = "2.0.0-rc4", path = "../../../frame/transaction-payment/rpc/" }
-#substrate-frame-rpc-system = { version = "2.0.0-rc4", path = "../../../utils/frame/rpc/system" }
-#sp-transaction-pool = { version = "2.0.0-rc4", path = "../../../primitives/transaction-pool" }
-#sc-consensus-babe = { version = "0.8.0-rc4", path = "../../../client/consensus/babe" }
-#sc-consensus-babe-rpc = { version = "0.8.0-rc4", path = "../../../client/consensus/babe/rpc" }
-#sp-consensus-babe = { version = "0.8.0-rc4", path = "../../../primitives/consensus/babe" }
-#sc-keystore = { version = "2.0.0-rc4", path = "../../../client/keystore" }
-#sc-consensus-epochs = { version = "0.8.0-rc4", path = "../../../client/consensus/epochs" }
-#sp-consensus = { version = "0.8.0-rc4", path = "../../../primitives/consensus/common" }
-#sp-blockchain = { version = "2.0.0-rc4", path = "../../../primitives/blockchain" }
-#sc-finality-grandpa = { version = "0.8.0-rc4", path = "../../../client/finality-grandpa" }
-#sc-finality-grandpa-rpc = { version = "0.8.0-rc4", path = "../../../client/finality-grandpa/rpc" }
-#sc-rpc-api = { version = "0.8.0-rc4", path = "../../../client/rpc-api" }
-#sp-block-builder = { version = "2.0.0-rc4", path = "../../../primitives/block-builder" }
 
 # frame dependencies
-pallet-indices = { package = 'pallet-indices', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-pallet-timestamp = { package = 'pallet-timestamp', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 pallet-contracts = { package = 'pallet-contracts', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-frame-system = { package = 'frame-system', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-pallet-balances = { package = 'pallet-balances', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-pallet-transaction-payment = { package = 'pallet-transaction-payment', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-frame-support = { package = 'frame-support', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 pallet-im-online = { package = 'pallet-im-online', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-pallet-authority-discovery = { package = 'pallet-authority-discovery', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-pallet-staking = { package = 'pallet-staking', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-pallet-grandpa = { package = 'pallet-grandpa', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+pallet-contracts-rpc = { package = 'pallet-contracts-rpc', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+pallet-transaction-payment-rpc = { package = 'pallet-transaction-payment-rpc', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+substrate-frame-rpc-system = { package = 'substrate-frame-rpc-system', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+frame-benchmarking = { package = 'frame-benchmarking', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 
 # node-specific dependencies
 node-runtime = { package= "joystream-node-runtime", path = "../runtime" }
 
 # CLI-specific dependencies
-sc-cli = { package = 'sc-cli', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-frame-benchmarking-cli = { package = 'frame-benchmarking-cli', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-node-inspect = { package = 'node-inspect', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+sc-cli = { package = 'sc-cli', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', optional = true }
+frame-benchmarking-cli = { package = 'frame-benchmarking-cli', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', optional = true }
+node-inspect = { package = 'node-inspect', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', optional = true }
 
 # WASM-specific dependencies
 wasm-bindgen = { version = "0.2.57", optional = true }
@@ -128,136 +75,34 @@ wasm-bindgen-futures = { version = "0.4.7", optional = true }
 browser-utils = { package = 'substrate-browser-utils', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', optional = true}
 
 [dev-dependencies]
-#sc-keystore = { version = "2.0.0-rc4", path = "../../../client/keystore" }
-#sc-consensus = { version = "0.8.0-rc4", path = "../../../client/consensus/common" }
+tempfile = "3.1.0"
+codec = { package = "parity-scale-codec", version = "1.3.1" }
+sp-timestamp = { package = 'sp-timestamp', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+sp-keyring = { package = 'sp-keyring', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 sc-consensus-babe = { git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', features = ["test-helpers"]}
-#sc-consensus-epochs = { version = "0.8.0-rc4", path = "../../../client/consensus/epochs" }
 sc-service-test = { git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
-#futures = "0.3.4"
-tempfile = "3.1.0"
-#assert_cmd = "1.0"
-#nix = "0.17"
-#serde_json = "1.0"
-#regex = "1"
-#platforms = "0.2.1"
-
-#[dependencies.substrate-basic-authorship]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-basic-authorship'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.babe]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-consensus-babe'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.babe-primitives]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-consensus-babe-primitives'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.codec]
-#package = 'parity-scale-codec'
-#version = '1.0.0'
-#
-#[dependencies.ctrlc]
-#features = ['termination']
-#version = '3.0'
-#
-#[dependencies.inherents]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-inherents'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.network]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-network'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.primitives]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-primitives'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.sr-io]
-#git = 'https://github.com/paritytech/substrate.git'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.substrate-cli]
-#git = 'https://github.com/paritytech/substrate.git'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.substrate-client]
-#git = 'https://github.com/paritytech/substrate.git'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.substrate-executor]
-#git = 'https://github.com/paritytech/substrate.git'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.substrate-service]
-#git = 'https://github.com/paritytech/substrate.git'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.transaction-pool]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-transaction-pool'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.substrate-telemetry]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-telemetry'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.grandpa]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-finality-grandpa'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.grandpa-primitives]
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-finality-grandpa-primitives'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.im-online]
-#default_features = false
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'srml-im-online'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.substrate-rpc]
-#default_features = false
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-rpc'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.authority-discovery]
-#default_features = false
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-authority-discovery'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.client-db]
-#default_features = false
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-client-db'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.runtime-primitives]
-#default_features = false
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'sr-primitives'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.offchain]
-#default_features = false
-#git = 'https://github.com/paritytech/substrate.git'
-#package = 'substrate-offchain'
-#rev = 'c37bb08535c49a12320af7facfd555ce05cce2e8'
-#
-#[dependencies.libp2p]
-#version = '0.13.2'
-#default-features = false
+frame-system = { package = 'frame-system', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+pallet-transaction-payment = { package = 'pallet-transaction-payment', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
+pallet-grandpa = { package = 'pallet-grandpa', git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4' }
 
 [build-dependencies]
 vergen = '3'
+
+[features]
+default = [ "cli" ]
+browser = [
+	"browser-utils",
+	"wasm-bindgen",
+	"wasm-bindgen-futures",
+]
+cli = [
+	"node-inspect",
+	"sc-cli",
+	"frame-benchmarking-cli",
+	"sc-service/db",
+	"structopt",
+]
+runtime-benchmarks = [
+	"node-runtime/runtime-benchmarks",
+	"frame-benchmarking-cli",
+]

+ 21 - 1
runtime/Cargo.toml

@@ -56,6 +56,12 @@ pallet-contracts = { package = 'pallet-contracts', default-features = false, git
 pallet-contracts-rpc-runtime-api = { package = 'pallet-contracts-rpc-runtime-api', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4'}
 pallet-contracts-primitives = { package = 'pallet-contracts-primitives', default-features = false, git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4'}
 
+# Benchmarking
+frame-benchmarking = { git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', default-features = false, optional = true }
+frame-system-benchmarking = { git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', default-features = false, optional = true }
+pallet-offences-benchmarking = { git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', default-features = false, optional = true }
+pallet-session-benchmarking = { git = 'https://github.com/paritytech/substrate.git', rev = '00768a1f21a579c478fe5d4f51e1fa71f7db9fd4', default-features = false, optional = true }
+
 # Joystream
 common = { package = 'pallet-common', default-features = false, path = '../runtime-modules/common'}
 memo = { package = 'pallet-memo', default-features = false, path = '../runtime-modules/memo'}
@@ -155,6 +161,20 @@ std = [
     'proposals-discussion/std',
     'proposals-codex/std',
 ]
-
+runtime-benchmarks = [
+    "system/runtime-benchmarks",
+	"frame-support/runtime-benchmarks",
+	"sp-runtime/runtime-benchmarks",
+	"pallet-balances/runtime-benchmarks",
+	"pallet-collective/runtime-benchmarks",
+	"pallet-im-online/runtime-benchmarks",
+	"pallet-indices/runtime-benchmarks",
+	"pallet-staking/runtime-benchmarks",
+	"pallet-timestamp/runtime-benchmarks",
+    "frame-benchmarking",
+    "frame-system-benchmarking",
+    "pallet-offences-benchmarking",
+	"pallet-session-benchmarking",
+]