mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 10:31:03 +00:00
Introduce a maximum code size and head data size (#835)
* add a maximum code size and head data size * get existing tests passing * add tests for slots logic * test registrar behavior * introduce maximums and bump versions * address review grumbles * work around publicizing derive * remove unneeded and wrong doc
This commit is contained in:
committed by
GitHub
parent
9b23f3f1f0
commit
295151338d
@@ -77,7 +77,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
|
||||
spec_name: create_runtime_str!("kusama"),
|
||||
impl_name: create_runtime_str!("parity-kusama"),
|
||||
authoring_version: 2,
|
||||
spec_version: 1047,
|
||||
spec_version: 1048,
|
||||
impl_version: 0,
|
||||
apis: RUNTIME_API_VERSIONS,
|
||||
};
|
||||
@@ -461,6 +461,11 @@ impl attestations::Trait for Runtime {
|
||||
type RewardAttestation = Staking;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
pub const MaxCodeSize: u32 = 10 * 1024 * 1024; // 10 MB
|
||||
pub const MaxHeadDataSize: u32 = 20 * 1024; // 20 KB
|
||||
}
|
||||
|
||||
impl parachains::Trait for Runtime {
|
||||
type Origin = Origin;
|
||||
type Call = Call;
|
||||
@@ -468,6 +473,8 @@ impl parachains::Trait for Runtime {
|
||||
type Randomness = RandomnessCollectiveFlip;
|
||||
type ActiveParachains = Registrar;
|
||||
type Registrar = Registrar;
|
||||
type MaxCodeSize = MaxCodeSize;
|
||||
type MaxHeadDataSize = MaxHeadDataSize;
|
||||
}
|
||||
|
||||
parameter_types! {
|
||||
|
||||
Reference in New Issue
Block a user