Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
Merge branch 'master' of github.com:paritytech/substrate into gupnik/…
Browse files Browse the repository at this point in the history
…derive-impl-improvements
  • Loading branch information
gupnik committed Aug 25, 2023
2 parents 718c1ce + 8dac0ab commit 969bf0e
Show file tree
Hide file tree
Showing 349 changed files with 12,162 additions and 2,020 deletions.
214 changes: 144 additions & 70 deletions Cargo.lock

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ members = [
"frame/benchmarking",
"frame/benchmarking/pov",
"frame/bounties",
"frame/broker",
"frame/child-bounties",
"frame/collective",
"frame/contracts",
Expand Down Expand Up @@ -187,6 +188,8 @@ members = [
"frame/recovery",
"frame/referenda",
"frame/remark",
"frame/tx-pause",
"frame/safe-mode",
"frame/salary",
"frame/scheduler",
"frame/scored-pool",
Expand Down
12 changes: 6 additions & 6 deletions bin/node-template/node/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -70,19 +70,19 @@ substrate-build-script-utils = { version = "3.0.0", path = "../../../utils/build
default = []
# Dependencies that are only required if runtime benchmarking should be build.
runtime-benchmarks = [
"node-template-runtime/runtime-benchmarks",
"frame-benchmarking/runtime-benchmarks",
"frame-benchmarking-cli/runtime-benchmarks",
"frame-benchmarking/runtime-benchmarks",
"frame-system/runtime-benchmarks",
"node-template-runtime/runtime-benchmarks",
"sc-service/runtime-benchmarks",
"sp-runtime/runtime-benchmarks"
"sp-runtime/runtime-benchmarks",
]
# Enable features that allow the runtime to be tried and debugged. Name might be subject to change
# in the near future.
try-runtime = [
"node-template-runtime/try-runtime",
"try-runtime-cli/try-runtime",
"frame-system/try-runtime",
"node-template-runtime/try-runtime",
"pallet-transaction-payment/try-runtime",
"sp-runtime/try-runtime"
"sp-runtime/try-runtime",
"try-runtime-cli/try-runtime",
]
10 changes: 6 additions & 4 deletions bin/node-template/pallets/template/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,15 @@ scale-info = { version = "2.5.0", default-features = false, features = ["derive"
frame-benchmarking = { version = "4.0.0-dev", default-features = false, optional = true, path = "../../../../frame/benchmarking" }
frame-support = { version = "4.0.0-dev", default-features = false, path = "../../../../frame/support" }
frame-system = { version = "4.0.0-dev", default-features = false, path = "../../../../frame/system" }
sp-std = { version = "8.0.0", default-features = false, path = "../../../../primitives/std" }

[dev-dependencies]
sp-core = { version = "21.0.0", path = "../../../../primitives/core" }
sp-io = { version = "23.0.0", path = "../../../../primitives/io" }
sp-runtime = { version = "24.0.0", path = "../../../../primitives/runtime" }

[features]
default = ["std"]
default = [ "std" ]
std = [
"codec/std",
"frame-benchmarking?/std",
Expand All @@ -36,16 +37,17 @@ std = [
"scale-info/std",
"sp-core/std",
"sp-io/std",
"sp-runtime/std"
"sp-runtime/std",
"sp-std/std",
]
runtime-benchmarks = [
"frame-benchmarking/runtime-benchmarks",
"frame-support/runtime-benchmarks",
"frame-system/runtime-benchmarks",
"sp-runtime/runtime-benchmarks"
"sp-runtime/runtime-benchmarks",
]
try-runtime = [
"frame-support/try-runtime",
"frame-system/try-runtime",
"sp-runtime/try-runtime"
"sp-runtime/try-runtime",
]
1 change: 1 addition & 0 deletions bin/node-template/pallets/template/src/benchmarking.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
//! Benchmarking setup for pallet-template
#![cfg(feature = "runtime-benchmarks")]
use super::*;
use sp_std::vec;

#[allow(unused)]
use crate::Pallet as Template;
Expand Down
20 changes: 11 additions & 9 deletions bin/node-template/runtime/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ sp-offchain = { version = "4.0.0-dev", default-features = false, path = "../../.
sp-runtime = { version = "24.0.0", default-features = false, path = "../../../primitives/runtime" }
sp-session = { version = "4.0.0-dev", default-features = false, path = "../../../primitives/session" }
sp-std = { version = "8.0.0", default-features = false, path = "../../../primitives/std" }
sp-storage = { version = "13.0.0", default-features = false, path = "../../../primitives/storage" }
sp-transaction-pool = { version = "4.0.0-dev", default-features = false, path = "../../../primitives/transaction-pool" }
sp-version = { version = "22.0.0", default-features = false, path = "../../../primitives/version" }

Expand All @@ -54,18 +55,17 @@ pallet-template = { version = "4.0.0-dev", default-features = false, path = "../
substrate-wasm-builder = { version = "5.0.0-dev", path = "../../../utils/wasm-builder", optional = true }

[features]
default = ["std"]
default = [ "std" ]
std = [
"frame-try-runtime?/std",
"frame-system-benchmarking?/std",
"frame-benchmarking?/std",
"codec/std",
"scale-info/std",
"frame-benchmarking?/std",
"frame-executive/std",
"frame-support/std",
"frame-system-benchmarking?/std",
"frame-system-rpc-runtime-api/std",
"frame-system/std",
"frame-try-runtime/std",
"frame-try-runtime?/std",
"pallet-aura/std",
"pallet-balances/std",
"pallet-grandpa/std",
Expand All @@ -74,6 +74,7 @@ std = [
"pallet-timestamp/std",
"pallet-transaction-payment-rpc-runtime-api/std",
"pallet-transaction-payment/std",
"scale-info/std",
"sp-api/std",
"sp-block-builder/std",
"sp-consensus-aura/std",
Expand All @@ -84,6 +85,7 @@ std = [
"sp-runtime/std",
"sp-session/std",
"sp-std/std",
"sp-storage/std",
"sp-transaction-pool/std",
"sp-version/std",
"substrate-wasm-builder",
Expand All @@ -101,17 +103,17 @@ runtime-benchmarks = [
"sp-runtime/runtime-benchmarks",
]
try-runtime = [
"frame-try-runtime/try-runtime",
"frame-executive/try-runtime",
"frame-system/try-runtime",
"frame-support/try-runtime",
"frame-system/try-runtime",
"frame-try-runtime/try-runtime",
"pallet-aura/try-runtime",
"pallet-balances/try-runtime",
"pallet-grandpa/try-runtime",
"pallet-sudo/try-runtime",
"pallet-template/try-runtime",
"pallet-timestamp/try-runtime",
"pallet-transaction-payment/try-runtime",
"sp-runtime/try-runtime"
"sp-runtime/try-runtime",
]
experimental = ["pallet-aura/experimental"]
experimental = [ "pallet-aura/experimental" ]
4 changes: 2 additions & 2 deletions bin/node-template/runtime/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -531,8 +531,8 @@ impl_runtime_apis! {
fn dispatch_benchmark(
config: frame_benchmarking::BenchmarkConfig
) -> Result<Vec<frame_benchmarking::BenchmarkBatch>, sp_runtime::RuntimeString> {
use frame_benchmarking::{baseline, Benchmarking, BenchmarkBatch, TrackedStorageKey};

use frame_benchmarking::{baseline, Benchmarking, BenchmarkBatch};
use sp_storage::TrackedStorageKey;
use frame_system_benchmarking::Pallet as SystemBench;
use baseline::Pallet as BaselineBench;

Expand Down
20 changes: 10 additions & 10 deletions bin/node/cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -147,45 +147,45 @@ pallet-balances = { version = "4.0.0-dev", path = "../../../frame/balances" }
sc-storage-monitor = { version = "0.1.0", path = "../../../client/storage-monitor" }

[features]
default = ["cli"]
default = [ "cli" ]
cli = [
"clap",
"clap_complete",
"frame-benchmarking-cli",
"node-inspect",
"sc-cli",
"frame-benchmarking-cli",
"substrate-frame-cli",
"sc-service/rocksdb",
"clap",
"clap_complete",
"substrate-build-script-utils",
"substrate-frame-cli",
"try-runtime-cli",
]
runtime-benchmarks = [
"kitchensink-runtime/runtime-benchmarks",
"frame-benchmarking-cli/runtime-benchmarks",
"frame-system/runtime-benchmarks",
"kitchensink-runtime/runtime-benchmarks",
"pallet-asset-tx-payment/runtime-benchmarks",
"pallet-assets/runtime-benchmarks",
"pallet-balances/runtime-benchmarks",
"pallet-im-online/runtime-benchmarks",
"pallet-timestamp/runtime-benchmarks",
"sc-client-db/runtime-benchmarks",
"sc-service/runtime-benchmarks",
"sp-runtime/runtime-benchmarks"
"sp-runtime/runtime-benchmarks",
]
# Enable features that allow the runtime to be tried and debugged. Name might be subject to change
# in the near future.
try-runtime = [
"kitchensink-runtime/try-runtime",
"try-runtime-cli/try-runtime",
"frame-system/try-runtime",
"kitchensink-runtime/try-runtime",
"pallet-asset-conversion-tx-payment/try-runtime",
"pallet-asset-tx-payment/try-runtime",
"pallet-assets/try-runtime",
"pallet-balances/try-runtime",
"pallet-im-online/try-runtime",
"pallet-timestamp/try-runtime",
"sp-runtime/try-runtime",
"substrate-cli-test-utils/try-runtime"
"substrate-cli-test-utils/try-runtime",
"try-runtime-cli/try-runtime",
]

[[bench]]
Expand Down
2 changes: 2 additions & 0 deletions bin/node/cli/src/chain_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,8 @@ pub fn testnet_genesis(
transaction_storage: Default::default(),
transaction_payment: Default::default(),
alliance: Default::default(),
safe_mode: Default::default(),
tx_pause: Default::default(),
alliance_motion: Default::default(),
nomination_pools: NominationPoolsConfig {
min_create_bond: 10 * DOLLARS,
Expand Down
7 changes: 2 additions & 5 deletions bin/node/primitives/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,5 @@ sp-core = { version = "21.0.0", default-features = false, path = "../../../primi
sp-runtime = { version = "24.0.0", default-features = false, path = "../../../primitives/runtime" }

[features]
default = ["std"]
std = [
"sp-core/std",
"sp-runtime/std",
]
default = [ "std" ]
std = [ "sp-core/std", "sp-runtime/std" ]
Loading

0 comments on commit 969bf0e

Please sign in to comment.