mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-18 15:21:05 +00:00
Finish migration to v2 primitives (#5037)
* remove v0 primitives from polkadot-primitives * first pass: remove v0 * fix fallout in erasure-coding * remove v1 primitives, consolidate to v2 * the great import update * update runtime_api_impl_v1 to v2 as well * guide: add `Version` request for runtime API * add version query to runtime API * reintroduce OldV1SessionInfo in a limited way
This commit is contained in:
committed by
GitHub
parent
3394cbb142
commit
49f7e5cce4
@@ -24,7 +24,7 @@ use kusama_runtime as kusama;
|
||||
use kusama_runtime_constants::currency::UNITS as KSM;
|
||||
use pallet_im_online::sr25519::AuthorityId as ImOnlineId;
|
||||
use pallet_staking::Forcing;
|
||||
use polkadot_primitives::v1::{AccountId, AccountPublic, AssignmentId, ValidatorId};
|
||||
use polkadot_primitives::v2::{AccountId, AccountPublic, AssignmentId, ValidatorId};
|
||||
#[cfg(feature = "polkadot-native")]
|
||||
use polkadot_runtime as polkadot;
|
||||
#[cfg(feature = "polkadot-native")]
|
||||
@@ -64,9 +64,9 @@ const DEFAULT_PROTOCOL_ID: &str = "dot";
|
||||
#[serde(rename_all = "camelCase")]
|
||||
pub struct Extensions {
|
||||
/// Block numbers with known hashes.
|
||||
pub fork_blocks: sc_client_api::ForkBlocks<polkadot_primitives::v1::Block>,
|
||||
pub fork_blocks: sc_client_api::ForkBlocks<polkadot_primitives::v2::Block>,
|
||||
/// Known bad block hashes.
|
||||
pub bad_blocks: sc_client_api::BadBlocks<polkadot_primitives::v1::Block>,
|
||||
pub bad_blocks: sc_client_api::BadBlocks<polkadot_primitives::v2::Block>,
|
||||
/// The light sync state.
|
||||
///
|
||||
/// This value will be set by the `sync-state rpc` implementation.
|
||||
@@ -174,9 +174,9 @@ pub fn wococo_config() -> Result<RococoChainSpec, String> {
|
||||
))]
|
||||
fn default_parachains_host_configuration(
|
||||
) -> polkadot_runtime_parachains::configuration::HostConfiguration<
|
||||
polkadot_primitives::v1::BlockNumber,
|
||||
polkadot_primitives::v2::BlockNumber,
|
||||
> {
|
||||
use polkadot_primitives::v1::{MAX_CODE_SIZE, MAX_POV_SIZE};
|
||||
use polkadot_primitives::v2::{MAX_CODE_SIZE, MAX_POV_SIZE};
|
||||
|
||||
polkadot_runtime_parachains::configuration::HostConfiguration {
|
||||
validation_upgrade_cooldown: 2u32,
|
||||
@@ -569,7 +569,7 @@ fn westend_staging_testnet_config_genesis(wasm_binary: &[u8]) -> westend::Genesi
|
||||
},
|
||||
paras: Default::default(),
|
||||
registrar: westend_runtime::RegistrarConfig {
|
||||
next_free_para_id: polkadot_primitives::v1::LOWEST_PUBLIC_ID,
|
||||
next_free_para_id: polkadot_primitives::v2::LOWEST_PUBLIC_ID,
|
||||
},
|
||||
xcm_pallet: Default::default(),
|
||||
}
|
||||
@@ -1062,7 +1062,7 @@ fn rococo_staging_testnet_config_genesis(wasm_binary: &[u8]) -> rococo_runtime::
|
||||
config: default_parachains_host_configuration(),
|
||||
},
|
||||
registrar: rococo_runtime::RegistrarConfig {
|
||||
next_free_para_id: polkadot_primitives::v1::LOWEST_PUBLIC_ID,
|
||||
next_free_para_id: polkadot_primitives::v2::LOWEST_PUBLIC_ID,
|
||||
},
|
||||
xcm_pallet: Default::default(),
|
||||
transaction_payment: Default::default(),
|
||||
@@ -1502,7 +1502,7 @@ pub fn westend_testnet_genesis(
|
||||
},
|
||||
paras: Default::default(),
|
||||
registrar: westend_runtime::RegistrarConfig {
|
||||
next_free_para_id: polkadot_primitives::v1::LOWEST_PUBLIC_ID,
|
||||
next_free_para_id: polkadot_primitives::v2::LOWEST_PUBLIC_ID,
|
||||
},
|
||||
xcm_pallet: Default::default(),
|
||||
}
|
||||
@@ -1576,7 +1576,7 @@ pub fn rococo_testnet_genesis(
|
||||
},
|
||||
paras: rococo_runtime::ParasConfig { paras: vec![] },
|
||||
registrar: rococo_runtime::RegistrarConfig {
|
||||
next_free_para_id: polkadot_primitives::v1::LOWEST_PUBLIC_ID,
|
||||
next_free_para_id: polkadot_primitives::v2::LOWEST_PUBLIC_ID,
|
||||
},
|
||||
xcm_pallet: Default::default(),
|
||||
transaction_payment: Default::default(),
|
||||
|
||||
Reference in New Issue
Block a user