mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 08:11:03 +00:00
* Fix for new Substrate * Fix * Remove Utility constraint in NonTransfer * Bump * Fixes * Allow limited utilities in proxy filters. * Fix * Add SudoBalances proxy restrictions
This commit is contained in:
Generated
+172
-154
File diff suppressed because it is too large
Load Diff
+1
-1
@@ -4,7 +4,7 @@ path = "src/main.rs"
|
||||
|
||||
[package]
|
||||
name = "polkadot"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
[package]
|
||||
name = "polkadot-availability-store"
|
||||
description = "Persistent database for parachain data"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-cli"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
description = "Polkadot Relay-chain Client Node"
|
||||
edition = "2018"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-collator"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
description = "Collator node implementation"
|
||||
edition = "2018"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-erasure-coding"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-network"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
description = "Polkadot-specific networking protocol"
|
||||
edition = "2018"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-network-test"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
license = "GPL-3.0"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-parachain"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
description = "Types and utilities for creating and working with parachains"
|
||||
edition = "2018"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "test-parachain-adder"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
description = "Test parachain which adds to a number as its state transition"
|
||||
edition = "2018"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "test-parachain-halt"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
description = "Test parachain which executes forever"
|
||||
edition = "2018"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-primitives"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-rpc"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-runtime-common"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "kusama-runtime"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
build = "build.rs"
|
||||
@@ -46,6 +46,7 @@ identity = { package = "pallet-identity", git = "https://github.com/paritytech/s
|
||||
im-online = { package = "pallet-im-online", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
indices = { package = "pallet-indices", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
membership = { package = "pallet-membership", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
multisig = { package = "pallet-multisig", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
nicks = { package = "pallet-nicks", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
offences = { package = "pallet-offences", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
proxy = { package = "pallet-proxy", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
@@ -118,6 +119,7 @@ std = [
|
||||
"im-online/std",
|
||||
"indices/std",
|
||||
"membership/std",
|
||||
"multisig/std",
|
||||
"nicks/std",
|
||||
"offences/std",
|
||||
"proxy/std",
|
||||
|
||||
@@ -84,7 +84,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
|
||||
spec_name: create_runtime_str!("kusama"),
|
||||
impl_name: create_runtime_str!("parity-kusama"),
|
||||
authoring_version: 2,
|
||||
spec_version: 2000,
|
||||
spec_version: 2004,
|
||||
impl_version: 0,
|
||||
apis: RUNTIME_API_VERSIONS,
|
||||
transaction_version: 1,
|
||||
@@ -100,12 +100,14 @@ pub fn native_version() -> NativeVersion {
|
||||
}
|
||||
|
||||
/// Avoid processing transactions from slots and parachain registrar.
|
||||
pub struct IsCallable;
|
||||
impl Filter<Call> for IsCallable {
|
||||
pub struct BaseFilter;
|
||||
impl Filter<Call> for BaseFilter {
|
||||
fn filter(call: &Call) -> bool {
|
||||
!matches!(call, Call::Slots(_) | Call::Registrar(_))
|
||||
}
|
||||
}
|
||||
pub struct IsCallable;
|
||||
frame_support::impl_filter_stack!(IsCallable, BaseFilter, Call, is_callable);
|
||||
|
||||
parameter_types! {
|
||||
pub const Version: RuntimeVersion = VERSION;
|
||||
@@ -688,20 +690,26 @@ impl identity::Trait for Runtime {
|
||||
type ForceOrigin = collective::EnsureProportionMoreThan<_1, _2, AccountId, CouncilCollective>;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
// One storage item; value is size 4+4+16+32 bytes = 56 bytes.
|
||||
pub const MultisigDepositBase: Balance = 30 * CENTS;
|
||||
// Additional storage item size of 32 bytes.
|
||||
pub const MultisigDepositFactor: Balance = 5 * CENTS;
|
||||
pub const MaxSignatories: u16 = 100;
|
||||
}
|
||||
|
||||
impl utility::Trait for Runtime {
|
||||
type Event = Event;
|
||||
type Call = Call;
|
||||
type IsCallable = IsCallable;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
// One storage item; key size is 32; value is size 4+4+16+32 bytes = 56 bytes.
|
||||
pub const DepositBase: Balance = deposit(1, 88);
|
||||
// Additional storage item size of 32 bytes.
|
||||
pub const DepositFactor: Balance = deposit(0, 32);
|
||||
pub const MaxSignatories: u16 = 100;
|
||||
}
|
||||
|
||||
impl multisig::Trait for Runtime {
|
||||
type Event = Event;
|
||||
type Call = Call;
|
||||
type Currency = Balances;
|
||||
type MultisigDepositBase = MultisigDepositBase;
|
||||
type MultisigDepositFactor = MultisigDepositFactor;
|
||||
type DepositBase = DepositBase;
|
||||
type DepositFactor = DepositFactor;
|
||||
type MaxSignatories = MaxSignatories;
|
||||
type IsCallable = IsCallable;
|
||||
}
|
||||
@@ -783,16 +791,29 @@ impl InstanceFilter<Call> for ProxyType {
|
||||
fn filter(&self, c: &Call) -> bool {
|
||||
match self {
|
||||
ProxyType::Any => true,
|
||||
ProxyType::NonTransfer => !matches!(c,
|
||||
Call::Balances(..) | Call::Vesting(vesting::Call::vested_transfer(..))
|
||||
| Call::Indices(indices::Call::transfer(..))
|
||||
),
|
||||
ProxyType::Governance => matches!(c,
|
||||
Call::Democracy(..) | Call::Council(..) | Call::TechnicalCommittee(..)
|
||||
| Call::ElectionsPhragmen(..) | Call::Treasury(..)
|
||||
| Call::Utility(utility::Call::batch(..))
|
||||
| Call::Utility(utility::Call::as_limited_sub(..))
|
||||
),
|
||||
ProxyType::NonTransfer => !matches!(c,
|
||||
Call::Balances(..) | Call::Utility(..)
|
||||
| Call::Vesting(vesting::Call::vested_transfer(..))
|
||||
| Call::Indices(indices::Call::transfer(..))
|
||||
ProxyType::Staking => matches!(c,
|
||||
Call::Staking(..) | Call::Utility(utility::Call::batch(..))
|
||||
| Call::Utility(utility::Call::as_limited_sub(..))
|
||||
),
|
||||
ProxyType::Staking => matches!(c, Call::Staking(..)),
|
||||
}
|
||||
}
|
||||
fn is_superset(&self, o: &Self) -> bool {
|
||||
match (self, o) {
|
||||
(x, y) if x == y => true,
|
||||
(ProxyType::Any, _) => true,
|
||||
(_, ProxyType::Any) => false,
|
||||
(ProxyType::NonTransfer, _) => true,
|
||||
_ => false,
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -856,7 +877,7 @@ construct_runtime! {
|
||||
Registrar: registrar::{Module, Call, Storage, Event, Config<T>},
|
||||
|
||||
// Utility module.
|
||||
Utility: utility::{Module, Call, Storage, Event<T>},
|
||||
Utility: utility::{Module, Call, Event},
|
||||
|
||||
// Less simple identity module.
|
||||
Identity: identity::{Module, Call, Storage, Event<T>},
|
||||
@@ -874,7 +895,10 @@ construct_runtime! {
|
||||
Scheduler: scheduler::{Module, Call, Storage, Event<T>},
|
||||
|
||||
// Proxy module. Late addition.
|
||||
Proxy: proxy::{Module, Call, Storage, Event<T>}
|
||||
Proxy: proxy::{Module, Call, Storage, Event<T>},
|
||||
|
||||
// Multisig module. Late addition.
|
||||
Multisig: multisig::{Module, Call, Storage, Event<T>},
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-runtime"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
build = "build.rs"
|
||||
@@ -45,6 +45,7 @@ identity = { package = "pallet-identity", git = "https://github.com/paritytech/s
|
||||
im-online = { package = "pallet-im-online", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
indices = { package = "pallet-indices", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
membership = { package = "pallet-membership", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
multisig = { package = "pallet-multisig", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
nicks = { package = "pallet-nicks", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
offences = { package = "pallet-offences", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
proxy = { package = "pallet-proxy", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
@@ -115,6 +116,7 @@ std = [
|
||||
"im-online/std",
|
||||
"indices/std",
|
||||
"membership/std",
|
||||
"multisig/std",
|
||||
"nicks/std",
|
||||
"offences/std",
|
||||
"proxy/std",
|
||||
|
||||
@@ -89,7 +89,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
|
||||
spec_name: create_runtime_str!("polkadot"),
|
||||
impl_name: create_runtime_str!("parity-polkadot"),
|
||||
authoring_version: 0,
|
||||
spec_version: 3,
|
||||
spec_version: 4,
|
||||
impl_version: 0,
|
||||
apis: RUNTIME_API_VERSIONS,
|
||||
transaction_version: 0,
|
||||
@@ -104,8 +104,8 @@ pub fn native_version() -> NativeVersion {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct IsCallable;
|
||||
impl Filter<Call> for IsCallable {
|
||||
pub struct BaseFilter;
|
||||
impl Filter<Call> for BaseFilter {
|
||||
fn filter(call: &Call) -> bool {
|
||||
match call {
|
||||
Call::Parachains(parachains::Call::set_heads(..)) => true,
|
||||
@@ -127,11 +127,13 @@ impl Filter<Call> for IsCallable {
|
||||
Call::Session(_) | Call::FinalityTracker(_) | Call::Grandpa(_) | Call::ImOnline(_) |
|
||||
Call::AuthorityDiscovery(_) |
|
||||
Call::Utility(_) | Call::Claims(_) | Call::Vesting(_) | Call::Sudo(_) |
|
||||
Call::Identity(_) | Call::Proxy(_) =>
|
||||
Call::Identity(_) | Call::Proxy(_) | Call::Multisig(_) =>
|
||||
true,
|
||||
}
|
||||
}
|
||||
}
|
||||
pub struct IsCallable;
|
||||
frame_support::impl_filter_stack!(IsCallable, BaseFilter, Call, is_callable);
|
||||
|
||||
parameter_types! {
|
||||
pub const Version: RuntimeVersion = VERSION;
|
||||
@@ -720,20 +722,26 @@ impl vesting::Trait for Runtime {
|
||||
type MinVestedTransfer = MinVestedTransfer;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
// One storage item; value is size 4+4+16+32 bytes = 56 bytes.
|
||||
pub const MultisigDepositBase: Balance = 30 * CENTS;
|
||||
// Additional storage item size of 32 bytes.
|
||||
pub const MultisigDepositFactor: Balance = 5 * CENTS;
|
||||
pub const MaxSignatories: u16 = 100;
|
||||
}
|
||||
|
||||
impl utility::Trait for Runtime {
|
||||
type Event = Event;
|
||||
type Call = Call;
|
||||
type IsCallable = IsCallable;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
// One storage item; key size is 32; value is size 4+4+16+32 bytes = 56 bytes.
|
||||
pub const DepositBase: Balance = deposit(1, 88);
|
||||
// Additional storage item size of 32 bytes.
|
||||
pub const DepositFactor: Balance = deposit(0, 32);
|
||||
pub const MaxSignatories: u16 = 100;
|
||||
}
|
||||
|
||||
impl multisig::Trait for Runtime {
|
||||
type Event = Event;
|
||||
type Call = Call;
|
||||
type Currency = Balances;
|
||||
type MultisigDepositBase = MultisigDepositBase;
|
||||
type MultisigDepositFactor = MultisigDepositFactor;
|
||||
type DepositBase = DepositBase;
|
||||
type DepositFactor = DepositFactor;
|
||||
type MaxSignatories = MaxSignatories;
|
||||
type IsCallable = IsCallable;
|
||||
}
|
||||
@@ -758,6 +766,7 @@ pub enum ProxyType {
|
||||
NonTransfer,
|
||||
Governance,
|
||||
Staking,
|
||||
SudoBalances,
|
||||
}
|
||||
impl Default for ProxyType { fn default() -> Self { Self::Any } }
|
||||
impl InstanceFilter<Call> for ProxyType {
|
||||
@@ -765,15 +774,31 @@ impl InstanceFilter<Call> for ProxyType {
|
||||
match self {
|
||||
ProxyType::Any => true,
|
||||
ProxyType::NonTransfer => !matches!(c,
|
||||
Call::Balances(..) | Call::Utility(..)
|
||||
| Call::Vesting(vesting::Call::vested_transfer(..))
|
||||
Call::Balances(..) | Call::Vesting(vesting::Call::vested_transfer(..))
|
||||
| Call::Indices(indices::Call::transfer(..))
|
||||
),
|
||||
ProxyType::Governance => matches!(c,
|
||||
Call::Democracy(..) | Call::Council(..) | Call::TechnicalCommittee(..)
|
||||
| Call::ElectionsPhragmen(..) | Call::Treasury(..)
|
||||
| Call::Utility(utility::Call::batch(..))
|
||||
| Call::Utility(utility::Call::as_limited_sub(..))
|
||||
),
|
||||
ProxyType::Staking => matches!(c, Call::Staking(..)),
|
||||
ProxyType::Staking => matches!(c,
|
||||
Call::Staking(..) | Call::Utility(utility::Call::batch(..))
|
||||
| Call::Utility(utility::Call::as_limited_sub(..))
|
||||
),
|
||||
ProxyType::SudoBalances => matches!(c,
|
||||
Call::Sudo(sudo::Call::sudo(x)) if matches!(x.as_ref(), &Call::Balances(..))
|
||||
),
|
||||
}
|
||||
}
|
||||
fn is_superset(&self, o: &Self) -> bool {
|
||||
match (self, o) {
|
||||
(x, y) if x == y => true,
|
||||
(ProxyType::Any, _) => true,
|
||||
(_, ProxyType::Any) => false,
|
||||
(ProxyType::NonTransfer, _) => true,
|
||||
_ => false,
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -841,7 +866,7 @@ construct_runtime! {
|
||||
// Vesting. Usable initially, but removed once all vesting is finished.
|
||||
Vesting: vesting::{Module, Call, Storage, Event<T>, Config<T>},
|
||||
// Cunning utilities. Usable initially.
|
||||
Utility: utility::{Module, Call, Storage, Event<T>},
|
||||
Utility: utility::{Module, Call, Event},
|
||||
|
||||
// Sudo. Last module. Usable initially, but removed once governance enabled.
|
||||
Sudo: sudo::{Module, Call, Storage, Config<T>, Event<T>},
|
||||
@@ -850,7 +875,10 @@ construct_runtime! {
|
||||
Identity: identity::{Module, Call, Storage, Event<T>},
|
||||
|
||||
// Proxy module. Late addition.
|
||||
Proxy: proxy::{Module, Call, Storage, Event<T>}
|
||||
Proxy: proxy::{Module, Call, Storage, Event<T>},
|
||||
|
||||
// Multisig dispatch. Late addition.
|
||||
Multisig: multisig::{Module, Call, Storage, Event<T>},
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-test-runtime"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
build = "build.rs"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "westend-runtime"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
build = "build.rs"
|
||||
@@ -46,6 +46,7 @@ identity = { package = "pallet-identity", git = "https://github.com/paritytech/s
|
||||
im-online = { package = "pallet-im-online", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
indices = { package = "pallet-indices", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
membership = { package = "pallet-membership", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
multisig = { package = "pallet-multisig", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
nicks = { package = "pallet-nicks", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
offences = { package = "pallet-offences", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
proxy = { package = "pallet-proxy", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
@@ -121,6 +122,7 @@ std = [
|
||||
"im-online/std",
|
||||
"indices/std",
|
||||
"membership/std",
|
||||
"multisig/std",
|
||||
"nicks/std",
|
||||
"offences/std",
|
||||
"proxy/std",
|
||||
|
||||
@@ -82,7 +82,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
|
||||
spec_name: create_runtime_str!("westend"),
|
||||
impl_name: create_runtime_str!("parity-westend"),
|
||||
authoring_version: 2,
|
||||
spec_version: 20,
|
||||
spec_version: 24,
|
||||
impl_version: 0,
|
||||
apis: RUNTIME_API_VERSIONS,
|
||||
transaction_version: 1,
|
||||
@@ -98,12 +98,14 @@ pub fn native_version() -> NativeVersion {
|
||||
}
|
||||
|
||||
/// Avoid processing transactions from slots and parachain registrar.
|
||||
pub struct IsCallable;
|
||||
impl Filter<Call> for IsCallable {
|
||||
pub struct BaseFilter;
|
||||
impl Filter<Call> for BaseFilter {
|
||||
fn filter(call: &Call) -> bool {
|
||||
!matches!(call, Call::Registrar(_))
|
||||
}
|
||||
}
|
||||
pub struct IsCallable;
|
||||
frame_support::impl_filter_stack!(IsCallable, BaseFilter, Call, is_callable);
|
||||
|
||||
parameter_types! {
|
||||
pub const Version: RuntimeVersion = VERSION;
|
||||
@@ -520,20 +522,26 @@ impl identity::Trait for Runtime {
|
||||
type ForceOrigin = system::EnsureRoot<AccountId>;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
// One storage item; value is size 4+4+16+32 bytes = 56 bytes.
|
||||
pub const MultisigDepositBase: Balance = 30 * CENTS;
|
||||
// Additional storage item size of 32 bytes.
|
||||
pub const MultisigDepositFactor: Balance = 5 * CENTS;
|
||||
pub const MaxSignatories: u16 = 100;
|
||||
}
|
||||
|
||||
impl utility::Trait for Runtime {
|
||||
type Event = Event;
|
||||
type Call = Call;
|
||||
type IsCallable = IsCallable;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
// One storage item; key size is 32; value is size 4+4+16+32 bytes = 56 bytes.
|
||||
pub const DepositBase: Balance = deposit(1, 88);
|
||||
// Additional storage item size of 32 bytes.
|
||||
pub const DepositFactor: Balance = deposit(0, 32);
|
||||
pub const MaxSignatories: u16 = 100;
|
||||
}
|
||||
|
||||
impl multisig::Trait for Runtime {
|
||||
type Event = Event;
|
||||
type Call = Call;
|
||||
type Currency = Balances;
|
||||
type MultisigDepositBase = MultisigDepositBase;
|
||||
type MultisigDepositFactor = MultisigDepositFactor;
|
||||
type DepositBase = DepositBase;
|
||||
type DepositFactor = DepositFactor;
|
||||
type MaxSignatories = MaxSignatories;
|
||||
type IsCallable = IsCallable;
|
||||
}
|
||||
@@ -585,6 +593,7 @@ pub enum ProxyType {
|
||||
Any,
|
||||
NonTransfer,
|
||||
Staking,
|
||||
SudoBalances,
|
||||
}
|
||||
impl Default for ProxyType { fn default() -> Self { Self::Any } }
|
||||
impl InstanceFilter<Call> for ProxyType {
|
||||
@@ -592,9 +601,24 @@ impl InstanceFilter<Call> for ProxyType {
|
||||
match self {
|
||||
ProxyType::Any => true,
|
||||
ProxyType::NonTransfer => !matches!(c,
|
||||
Call::Balances(..) | Call::Utility(..) | Call::Indices(indices::Call::transfer(..))
|
||||
Call::Balances(..) | Call::Indices(indices::Call::transfer(..))
|
||||
),
|
||||
ProxyType::Staking => matches!(c, Call::Staking(..)),
|
||||
ProxyType::Staking => matches!(c,
|
||||
Call::Staking(..) | Call::Utility(utility::Call::batch(..))
|
||||
| Call::Utility(utility::Call::as_limited_sub(..))
|
||||
),
|
||||
ProxyType::SudoBalances => matches!(c,
|
||||
Call::Sudo(sudo::Call::sudo(x)) if matches!(x.as_ref(), &Call::Balances(..))
|
||||
),
|
||||
}
|
||||
}
|
||||
fn is_superset(&self, o: &Self) -> bool {
|
||||
match (self, o) {
|
||||
(x, y) if x == y => true,
|
||||
(ProxyType::Any, _) => true,
|
||||
(_, ProxyType::Any) => false,
|
||||
(ProxyType::NonTransfer, _) => true,
|
||||
_ => false,
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -646,7 +670,7 @@ construct_runtime! {
|
||||
Registrar: registrar::{Module, Call, Storage, Event, Config<T>},
|
||||
|
||||
// Utility module.
|
||||
Utility: utility::{Module, Call, Storage, Event<T>},
|
||||
Utility: utility::{Module, Call, Event},
|
||||
|
||||
// Less simple identity module.
|
||||
Identity: identity::{Module, Call, Storage, Event<T>},
|
||||
@@ -664,7 +688,10 @@ construct_runtime! {
|
||||
Sudo: sudo::{Module, Call, Storage, Event<T>, Config<T>},
|
||||
|
||||
// Proxy module. Late addition.
|
||||
Proxy: proxy::{Module, Call, Storage, Event<T>}
|
||||
Proxy: proxy::{Module, Call, Storage, Event<T>},
|
||||
|
||||
// Multisig module. Late addition.
|
||||
Multisig: multisig::{Module, Call, Storage, Event<T>},
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-service"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-statement-table"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "polkadot-validation"
|
||||
version = "0.8.3"
|
||||
version = "0.8.4"
|
||||
authors = ["Parity Technologies <admin@parity.io>"]
|
||||
edition = "2018"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user