From 95f3ebfe8f3b34ff888132dc369a5832e4f347c8 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Mon, 17 Jun 2024 16:15:23 +0800 Subject: [PATCH 01/44] Inherent uses closures to obtain variables and deletes useless code --- client/consensus/aura/src/collator.rs | 368 ------------------ client/consensus/aura/src/collators/mod.rs | 17 - .../consensus/aura/src/collators/on_demand.rs | 232 ----------- client/consensus/aura/src/lib.rs | 3 - node/src/service.rs | 52 +-- 5 files changed, 27 insertions(+), 645 deletions(-) delete mode 100644 client/consensus/aura/src/collator.rs delete mode 100644 client/consensus/aura/src/collators/mod.rs delete mode 100644 client/consensus/aura/src/collators/on_demand.rs diff --git a/client/consensus/aura/src/collator.rs b/client/consensus/aura/src/collator.rs deleted file mode 100644 index 000caf7..0000000 --- a/client/consensus/aura/src/collator.rs +++ /dev/null @@ -1,368 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -use codec::{Codec, Encode}; -use cumulus_client_collator::service::ServiceInterface as CollatorServiceInterface; -use cumulus_client_consensus_common::{ - self as consensus_common, ParachainBlockImportMarker, ParachainCandidate, -}; -use cumulus_client_consensus_proposer::ProposerInterface; -use cumulus_primitives_core::{ - relay_chain::Hash as PHash, DigestItem, ParachainBlockData, PersistedValidationData, -}; - -use cumulus_client_parachain_inherent::{ParachainInherentData, ParachainInherentDataProvider}; -use cumulus_relay_chain_interface::RelayChainInterface; - -use polkadot_node_primitives::{Collation, MaybeCompressedPoV}; -use polkadot_primitives::{Header as PHeader, Id as ParaId}; - -use cumulus_client_consensus_aura::collator::seal; -use futures::lock::Mutex; -use futures::prelude::*; -use magnet_primitives_order::OrderRecord; -use sc_consensus::BlockImport; -use sc_consensus_aura::standalone as aura_internal; -use sp_api::ProvideRuntimeApi; -use sp_application_crypto::AppPublic; -use sp_consensus_aura::{AuraApi, Slot, SlotDuration}; -use sp_core::crypto::Pair; -use sp_inherents::{CreateInherentDataProviders, InherentData, InherentDataProvider}; -use sp_keystore::KeystorePtr; -use sp_runtime::{ - generic::Digest, - traits::{Block as BlockT, Member}, -}; -use sp_timestamp::Timestamp; -use std::sync::Arc; -use std::{convert::TryFrom, error::Error, time::Duration}; - -/// Parameters for instantiating a [`Collator`]. -pub struct Params { - /// A builder for inherent data builders. - pub create_inherent_data_providers: CIDP, - /// The block import handle. - pub block_import: BI, - /// An interface to the relay-chain client. - pub relay_client: RClient, - /// The keystore handle used for accessing parachain key material. - pub keystore: KeystorePtr, - /// The identifier of the parachain within the relay-chain. - pub para_id: ParaId, - /// The block proposer used for building blocks. - pub proposer: Proposer, - /// The collator service used for bundling proposals into collations and announcing - /// to the network. - pub collator_service: CS, -} - -/// A utility struct for writing collation logic that makes use of Aura entirely -/// or in part. See module docs for more details. -pub struct Collator { - create_inherent_data_providers: CIDP, - block_import: BI, - relay_client: RClient, - keystore: KeystorePtr, - para_id: ParaId, - proposer: Proposer, - collator_service: CS, - _marker: std::marker::PhantomData<(Block, Box)>, -} - -impl Collator -where - Block: BlockT, - RClient: RelayChainInterface, - CIDP: CreateInherentDataProviders< - Block, - (PHash, Option, ParaId, u64, Option), - > + 'static, - BI: BlockImport + ParachainBlockImportMarker + Send + Sync + 'static, - Proposer: ProposerInterface, - CS: CollatorServiceInterface, - P: Pair, - P::Public: AppPublic + Member, - P::Signature: TryFrom> + Member + Codec, -{ - /// Instantiate a new instance of the `Aura` manager. - pub fn new(params: Params) -> Self { - Collator { - create_inherent_data_providers: params.create_inherent_data_providers, - block_import: params.block_import, - relay_client: params.relay_client, - keystore: params.keystore, - para_id: params.para_id, - proposer: params.proposer, - collator_service: params.collator_service, - _marker: std::marker::PhantomData, - } - } - - /// Explicitly creates the inherent data for parachain block authoring and overrides - /// the timestamp inherent data with the one provided, if any. - pub async fn create_inherent_data( - &self, - relay_parent: PHash, - validation_data: &PersistedValidationData, - parent_hash: Block::Hash, - timestamp: impl Into>, - order_record: Arc>>, - ) -> Result<(ParachainInherentData, InherentData), Box> { - let paras_inherent_data = ParachainInherentDataProvider::create_at( - relay_parent, - &self.relay_client, - validation_data, - self.para_id, - ) - .await; - - let paras_inherent_data = match paras_inherent_data { - Some(p) => p, - None => { - return Err( - format!("Could not create paras inherent data at {:?}", relay_parent).into() - ) - }, - }; - let order_record_local = order_record.lock().await; - let mut other_inherent_data; - if order_record_local.relay_parent.is_none() { - other_inherent_data = self - .create_inherent_data_providers - .create_inherent_data_providers( - parent_hash, - (relay_parent, None, self.para_id, order_record_local.sequence_number, None), - ) - .map_err(|e| e as Box) - .await? - .create_inherent_data() - .await - .map_err(Box::new)?; - } else { - other_inherent_data = self - .create_inherent_data_providers - .create_inherent_data_providers( - parent_hash, - ( - order_record_local.relay_parent.expect("can not get relay_parent hash"), - order_record_local.validation_data.clone(), - self.para_id, - order_record_local.sequence_number, - order_record_local.author_pub.clone(), - ), - ) - .map_err(|e| e as Box) - .await? - .create_inherent_data() - .await - .map_err(Box::new)?; - } - - if let Some(timestamp) = timestamp.into() { - other_inherent_data.replace_data(sp_timestamp::INHERENT_IDENTIFIER, ×tamp); - } - - Ok((paras_inherent_data, other_inherent_data)) - } - - /// Propose, seal, and import a block, packaging it into a collation. - /// - /// Provide the slot to build at as well as any other necessary pre-digest logs, - /// the inherent data, and the proposal duration and PoV size limits. - /// - /// The Aura pre-digest should not be explicitly provided and is set internally. - /// - /// This does not announce the collation to the parachain network or the relay chain. - pub async fn collate( - &mut self, - parent_header: &Block::Header, - slot_claim: &SlotClaim, - additional_pre_digest: impl Into>>, - inherent_data: (ParachainInherentData, InherentData), - proposal_duration: Duration, - max_pov_size: usize, - ) -> Result< - Option<(Collation, ParachainBlockData, Block::Hash)>, - Box, - > { - let mut digest = additional_pre_digest.into().unwrap_or_default(); - digest.push(slot_claim.pre_digest.clone()); - - let maybe_proposal = self - .proposer - .propose( - &parent_header, - &inherent_data.0, - inherent_data.1, - Digest { logs: digest }, - proposal_duration, - Some(max_pov_size), - ) - .await - .map_err(|e| Box::new(e) as Box)?; - - let proposal = match maybe_proposal { - None => return Ok(None), - Some(p) => p, - }; - - let sealed_importable = seal::<_, P>( - proposal.block, - proposal.storage_changes, - &slot_claim.author_pub, - &self.keystore, - ) - .map_err(|e| e as Box)?; - - let post_hash = sealed_importable.post_hash(); - let block = Block::new( - sealed_importable.post_header(), - sealed_importable - .body - .as_ref() - .expect("body always created with this `propose` fn; qed") - .clone(), - ); - - self.block_import - .import_block(sealed_importable) - .map_err(|e| Box::new(e) as Box) - .await?; - - if let Some((collation, block_data)) = self.collator_service.build_collation( - parent_header, - post_hash, - ParachainCandidate { block, proof: proposal.proof }, - ) { - tracing::info!( - target: crate::LOG_TARGET, - "PoV size {{ header: {}kb, extrinsics: {}kb, storage_proof: {}kb }}", - block_data.header().encode().len() as f64 / 1024f64, - block_data.extrinsics().encode().len() as f64 / 1024f64, - block_data.storage_proof().encode().len() as f64 / 1024f64, - ); - - if let MaybeCompressedPoV::Compressed(ref pov) = collation.proof_of_validity { - tracing::info!( - target: crate::LOG_TARGET, - "Compressed PoV size: {}kb", - pov.block_data.0.len() as f64 / 1024f64, - ); - } - - Ok(Some((collation, block_data, post_hash))) - } else { - Err(Box::::from("Unable to produce collation") - as Box) - } - } - - /// Get the underlying collator service. - pub fn collator_service(&self) -> &CS { - &self.collator_service - } -} - -/// A claim on an Aura slot. -pub struct SlotClaim { - author_pub: Pub, - pre_digest: DigestItem, - timestamp: Timestamp, -} - -impl SlotClaim { - /// Create a slot-claim from the given author public key, slot, and timestamp. - /// - /// This does not check whether the author actually owns the slot or the timestamp - /// falls within the slot. - pub fn unchecked

(author_pub: Pub, slot: Slot, timestamp: Timestamp) -> Self - where - P: Pair, - P::Public: Codec, - P::Signature: Codec, - { - SlotClaim { author_pub, timestamp, pre_digest: aura_internal::pre_digest::

(slot) } - } - - /// Get the author's public key. - pub fn author_pub(&self) -> &Pub { - &self.author_pub - } - - /// Get the Aura pre-digest for this slot. - pub fn pre_digest(&self) -> &DigestItem { - &self.pre_digest - } - - /// Get the timestamp corresponding to the relay-chain slot this claim was - /// generated against. - pub fn timestamp(&self) -> Timestamp { - self.timestamp - } -} - -/// Attempt to claim a slot derived from the given relay-parent header's slot. -pub async fn claim_slot( - client: &C, - parent_hash: B::Hash, - relay_parent_header: &PHeader, - slot_duration: SlotDuration, - relay_chain_slot_duration: Duration, - keystore: &KeystorePtr, -) -> Result>, Box> -where - B: BlockT, - C: ProvideRuntimeApi + Send + Sync + 'static, - C::Api: AuraApi, - P: Pair, - P::Public: Codec, - P::Signature: Codec, -{ - // load authorities - let authorities = client.runtime_api().authorities(parent_hash).map_err(Box::new)?; - - // Determine the current slot and timestamp based on the relay-parent's. - let (slot_now, timestamp) = match consensus_common::relay_slot_and_timestamp( - relay_parent_header, - relay_chain_slot_duration, - ) { - Some((r_s, t)) => { - let our_slot = Slot::from_timestamp(t, slot_duration); - tracing::debug!( - target: crate::LOG_TARGET, - relay_slot = ?r_s, - para_slot = ?our_slot, - timestamp = ?t, - ?slot_duration, - ?relay_chain_slot_duration, - "Adjusted relay-chain slot to parachain slot" - ); - (our_slot, t) - }, - None => return Ok(None), - }; - - // Try to claim the slot locally. - let author_pub = { - let res = aura_internal::claim_slot::

(slot_now, &authorities, keystore).await; - match res { - Some(p) => p, - None => return Ok(None), - } - }; - - Ok(Some(SlotClaim::unchecked::

(author_pub, slot_now, timestamp))) -} diff --git a/client/consensus/aura/src/collators/mod.rs b/client/consensus/aura/src/collators/mod.rs deleted file mode 100644 index 716ae56..0000000 --- a/client/consensus/aura/src/collators/mod.rs +++ /dev/null @@ -1,17 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -pub mod on_demand; diff --git a/client/consensus/aura/src/collators/on_demand.rs b/client/consensus/aura/src/collators/on_demand.rs deleted file mode 100644 index c284653..0000000 --- a/client/consensus/aura/src/collators/on_demand.rs +++ /dev/null @@ -1,232 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -use codec::{Codec, Decode}; -use cumulus_client_collator::{ - relay_chain_driven::CollationRequest, service::ServiceInterface as CollatorServiceInterface, -}; -use cumulus_client_consensus_common::ParachainBlockImportMarker; -use cumulus_client_consensus_proposer::ProposerInterface; -use cumulus_primitives_core::{ - relay_chain::BlockId as RBlockId, relay_chain::Hash as PHash, CollectCollationInfo, -}; -use cumulus_relay_chain_interface::RelayChainInterface; - -use polkadot_node_primitives::CollationResult; -use polkadot_overseer::Handle as OverseerHandle; -use polkadot_primitives::{CollatorPair, Id as ParaId}; - -use cumulus_primitives_core::PersistedValidationData; -use futures::lock::Mutex; -use futures::prelude::*; -use futures::{channel::mpsc::Receiver, prelude::*}; -use magnet_primitives_order::OrderRecord; -use sc_client_api::{backend::AuxStore, BlockBackend, BlockOf}; -use sc_consensus::BlockImport; -use sp_api::ProvideRuntimeApi; -use sp_application_crypto::AppPublic; -use sp_blockchain::HeaderBackend; -use sp_consensus::SyncOracle; -use sp_consensus_aura::{AuraApi, SlotDuration}; -use sp_core::crypto::Pair; -use sp_inherents::CreateInherentDataProviders; -use sp_keystore::KeystorePtr; -use sp_runtime::traits::{Block as BlockT, Header as HeaderT, Member}; -use std::{convert::TryFrom, sync::Arc, time::Duration}; -/// Parameters for [`run`]. -pub struct Params { - /// Inherent data providers. Only non-consensus inherent data should be provided, i.e. - /// the timestamp, slot, and paras inherents should be omitted, as they are set by this - /// collator. - pub create_inherent_data_providers: CIDP, - /// Used to actually import blocks. - pub block_import: BI, - /// The underlying para client. - pub para_client: Arc, - /// A handle to the relay-chain client. - pub relay_client: RClient, - /// A chain synchronization oracle. - pub sync_oracle: SO, - /// The underlying keystore, which should contain Aura consensus keys. - pub keystore: KeystorePtr, - /// The collator key used to sign collations before submitting to validators. - pub collator_key: CollatorPair, - /// The para's ID. - pub para_id: ParaId, - /// A handle to the relay-chain client's "Overseer" or task orchestrator. - pub overseer_handle: OverseerHandle, - /// The length of slots in this chain. - pub slot_duration: SlotDuration, - /// The length of slots in the relay chain. - pub relay_chain_slot_duration: Duration, - /// The underlying block proposer this should call into. - pub proposer: Proposer, - /// The generic collator service used to plug into this consensus engine. - pub collator_service: CS, - /// The amount of time to spend authoring each block. - pub authoring_duration: Duration, - /// Receiver for collation requests. If `None`, Aura consensus will establish a new receiver. - /// Should be used when a chain migrates from a different consensus algorithm and was already - /// processing collation requests before initializing Aura. - pub collation_request_receiver: Option>, -} - -/// Run bare Aura consensus as a relay-chain-driven collator. -pub fn run( - params: Params, - order_record: Arc>>, -) -> impl Future + Send + 'static -where - Block: BlockT + Send, - Client: ProvideRuntimeApi - + BlockOf - + AuxStore - + HeaderBackend - + BlockBackend - + Send - + Sync - + 'static, - Client::Api: AuraApi + CollectCollationInfo, - RClient: RelayChainInterface + Send + Clone + 'static, - CIDP: CreateInherentDataProviders< - Block, - (PHash, Option, ParaId, u64, Option), - > + Send - + 'static, - CIDP::InherentDataProviders: Send, - BI: BlockImport + ParachainBlockImportMarker + Send + Sync + 'static, - SO: SyncOracle + Send + Sync + Clone + 'static, - Proposer: ProposerInterface + Send + Sync + 'static, - CS: CollatorServiceInterface + Send + Sync + 'static, - P: Pair, - P::Public: AppPublic + Member + Codec, - P::Signature: TryFrom> + Member + Codec, -{ - async move { - let mut collation_requests = match params.collation_request_receiver { - Some(receiver) => receiver, - None => { - cumulus_client_collator::relay_chain_driven::init( - params.collator_key, - params.para_id, - params.overseer_handle, - ) - .await - }, - }; - - let mut collator = { - let params = crate::collator::Params { - create_inherent_data_providers: params.create_inherent_data_providers, - block_import: params.block_import, - relay_client: params.relay_client.clone(), - keystore: params.keystore.clone(), - para_id: params.para_id, - proposer: params.proposer, - collator_service: params.collator_service, - }; - - crate::collator::Collator::::new(params) - }; - - while let Some(request) = collation_requests.next().await { - macro_rules! reject_with_error { - ($err:expr) => {{ - request.complete(None); - tracing::error!(target: crate::LOG_TARGET, err = ?{ $err }); - continue; - }}; - } - - macro_rules! try_request { - ($x:expr) => {{ - match $x { - Ok(x) => x, - Err(e) => reject_with_error!(e), - } - }}; - } - - let validation_data = request.persisted_validation_data(); - - let parent_header = - try_request!(Block::Header::decode(&mut &validation_data.parent_head.0[..])); - - let parent_hash = parent_header.hash(); - - if !collator.collator_service().check_block_status(parent_hash, &parent_header) { - continue; - } - - let relay_parent_header = - match params.relay_client.header(RBlockId::hash(*request.relay_parent())).await { - Err(e) => reject_with_error!(e), - Ok(None) => continue, // sanity: would be inconsistent to get `None` here - Ok(Some(h)) => h, - }; - let claim = match crate::collator::claim_slot::<_, _, P>( - &*params.para_client, - parent_hash, - &relay_parent_header, - params.slot_duration, - params.relay_chain_slot_duration, - ¶ms.keystore, - ) - .await - { - Ok(None) => continue, - Ok(Some(c)) => c, - Err(e) => reject_with_error!(e), - }; - let (parachain_inherent_data, other_inherent_data) = try_request!( - collator - .create_inherent_data( - *request.relay_parent(), - &validation_data, - parent_hash, - claim.timestamp(), - order_record.clone(), - ) - .await - ); - let maybe_collation = try_request!( - collator - .collate( - &parent_header, - &claim, - None, - (parachain_inherent_data, other_inherent_data), - params.authoring_duration, - // Set the block limit to 50% of the maximum PoV size. - // - // TODO: If we got benchmarking that includes the proof size, - // we should be able to use the maximum pov size. - (validation_data.max_pov_size / 2) as usize, - ) - .await - ); - - if let Some((collation, _, post_hash)) = maybe_collation { - let result_sender = - Some(collator.collator_service().announce_with_barrier(post_hash)); - request.complete(Some(CollationResult { collation, result_sender })); - } else { - request.complete(None); - tracing::debug!(target: crate::LOG_TARGET, "No block proposal"); - } - } - } -} diff --git a/client/consensus/aura/src/lib.rs b/client/consensus/aura/src/lib.rs index e806a80..e71099a 100644 --- a/client/consensus/aura/src/lib.rs +++ b/client/consensus/aura/src/lib.rs @@ -14,9 +14,6 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -pub mod collator; -pub mod collators; - const LOG_TARGET: &str = "on_demand_aura::magnet"; use sp_core::crypto::{ByteArray, Pair}; diff --git a/node/src/service.rs b/node/src/service.rs index 9f7d483..41340a7 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -550,12 +550,12 @@ fn start_consensus( announce_block: Arc>) + Send + Sync>, order_record: Arc>>, ) -> Result<(), sc_service::Error> { - // use cumulus_client_consensus_aura::collators::basic::{ - // self as basic_aura, Params as BasicAuraParams, - // }; - use magnet_client_consensus_aura::collators::on_demand::{ - self as on_demand_aura, Params as BasicAuraParams, + use cumulus_client_consensus_aura::collators::basic::{ + self as basic_aura, Params as BasicAuraParams, }; + // use magnet_client_consensus_aura::collators::on_demand::{ + // self as on_demand_aura, Params as BasicAuraParams, + // }; // NOTE: because we use Aura here explicitly, we can use `CollatorSybilResistance::Resistant` // when starting the network. @@ -580,16 +580,25 @@ fn start_consensus( ); let relay_chain_interface_clone = relay_chain_interface.clone(); let params = BasicAuraParams { - create_inherent_data_providers: move |_block_hash, - ( - relay_parent, - validation_data, - para_id, - sequence_number, - author_pub, - )| { + // create_inherent_data_providers: move |_, ()| async move { Ok(()) }, + create_inherent_data_providers: move |_, ()| { let relay_chain_interface = relay_chain_interface.clone(); + let order_record_clone = order_record.clone(); async move { + let parent_hash = relay_chain_interface.best_block_hash().await?; + let (relay_parent, validation_data, sequence_number, author_pub) = { + let order_record_local = order_record_clone.lock().await; + if order_record_local.validation_data.is_none() { + (parent_hash, None, order_record_local.sequence_number, None) + } else { + ( + order_record_local.relay_parent.expect("can not get relay_parent hash"), + order_record_local.validation_data.clone(), + order_record_local.sequence_number, + order_record_local.author_pub.clone(), + ) + } + }; let order_inherent = magnet_primitives_order::OrderInherentData::create_at( relay_parent, &relay_chain_interface, @@ -624,18 +633,11 @@ fn start_consensus( collation_request_receiver: None, }; - let fut = on_demand_aura::run::< - Block, - sp_consensus_aura::sr25519::AuthorityPair, - _, - _, - _, - _, - _, - _, - _, - >(params, order_record); - task_manager.spawn_essential_handle().spawn("on_demand_aura", None, fut); + let fut = + basic_aura::run::( + params, + ); + task_manager.spawn_essential_handle().spawn("aura", None, fut); Ok(()) } From adc92d7f15f7e76eb7670a7d8f59a009ed703bc9 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Mon, 17 Jun 2024 22:59:13 +0800 Subject: [PATCH 02/44] add client code of bulk mode --- Cargo.lock | 114 +- client/coretime/bulk/Cargo.toml | 56 + client/coretime/bulk/src/lib.rs | 66 + client/coretime/bulk/src/metadata.rs | 19308 +++++++++++++++++++++++++ node/Cargo.toml | 1 + node/src/service.rs | 2 + 6 files changed, 19513 insertions(+), 34 deletions(-) create mode 100644 client/coretime/bulk/Cargo.toml create mode 100644 client/coretime/bulk/src/lib.rs create mode 100644 client/coretime/bulk/src/metadata.rs diff --git a/Cargo.lock b/Cargo.lock index b5f817e..a2a128e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2979,7 +2979,7 @@ checksum = "7d9ce6874da5d4415896cd45ffbc4d1cfc0c4f9c079427bd870742c30f2f65a9" dependencies = [ "curve25519-dalek 4.1.2", "ed25519", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "hex", "rand_core 0.6.4", "sha2 0.10.8", @@ -2988,9 +2988,9 @@ dependencies = [ [[package]] name = "either" -version = "1.11.0" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a47c1c47d2f5964e29c61246e81db715514cd532db6b5116a25ea3c03d6780a2" +checksum = "3dca9240753cf90908d7e4aac30f630662b02aebaa1b58a3cadabdb23385b58b" dependencies = [ "serde", ] @@ -4500,9 +4500,9 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.14.3" +version = "0.14.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "290f1a1d9242c78d09ce40a5e87e7554ee637af1351968159f4952f028f75604" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" dependencies = [ "ahash 0.8.11", "allocator-api2", @@ -4515,7 +4515,7 @@ version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" dependencies = [ - "hashbrown 0.14.3", + "hashbrown 0.14.5", ] [[package]] @@ -4860,7 +4860,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" dependencies = [ "equivalent", - "hashbrown 0.14.3", + "hashbrown 0.14.5", ] [[package]] @@ -4893,9 +4893,9 @@ dependencies = [ [[package]] name = "instant" -version = "0.1.12" +version = "0.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" +checksum = "e0242819d153cba4b4b05a5a8f2a7e9bbf97b6055b2a002b395c96b5ff3c0222" dependencies = [ "cfg-if", ] @@ -5860,7 +5860,7 @@ version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3262e75e648fce39813cb56ac41f3c3e3f65217ebf3844d818d1f9398cfb0dc" dependencies = [ - "hashbrown 0.14.3", + "hashbrown 0.14.5", ] [[package]] @@ -5994,6 +5994,52 @@ dependencies = [ "tracing", ] +[[package]] +name = "magnet-client-coretime-bulk" +version = "0.1.0" +dependencies = [ + "async-trait", + "cumulus-client-collator", + "cumulus-client-consensus-aura", + "cumulus-client-consensus-common", + "cumulus-client-consensus-proposer", + "cumulus-client-parachain-inherent", + "cumulus-primitives-aura", + "cumulus-primitives-core", + "cumulus-primitives-parachain-inherent", + "cumulus-relay-chain-interface", + "futures", + "log", + "parity-scale-codec", + "polkadot-node-primitives", + "polkadot-node-subsystem", + "polkadot-overseer", + "polkadot-primitives", + "sc-client-api", + "sc-consensus", + "sc-consensus-aura", + "sc-consensus-babe", + "sc-consensus-slots", + "sc-service", + "sc-telemetry", + "schnellru", + "sp-api", + "sp-application-crypto 30.0.0", + "sp-block-builder", + "sp-blockchain", + "sp-consensus", + "sp-consensus-aura", + "sp-core 28.0.0", + "sp-inherents", + "sp-keystore 0.34.0", + "sp-runtime 31.0.1", + "sp-state-machine 0.35.0", + "sp-timestamp", + "substrate-prometheus-endpoint", + "subxt", + "tracing", +] + [[package]] name = "magnet-primitives-order" version = "0.2.0" @@ -8460,6 +8506,7 @@ dependencies = [ "jsonrpsee", "log", "magnet-client-consensus-aura", + "magnet-client-coretime-bulk", "magnet-primitives-order", "mp-system", "pallet-balances", @@ -10339,9 +10386,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.81" +version = "1.0.85" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d1597b0c024618f09a9c3b8655b7e430397a36d23fdafec26d6965e9eec3eba" +checksum = "22244ce15aa966053a896d1accb3a6e68469b97c7f33f284b99f0d576879fc23" dependencies = [ "unicode-ident", ] @@ -12510,9 +12557,9 @@ dependencies = [ [[package]] name = "scale-info" -version = "2.11.2" +version = "2.11.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c453e59a955f81fb62ee5d596b450383d699f152d350e9d23a0db2adb78e4c0" +checksum = "eca070c12893629e2cc820a9761bedf6ce1dcddc9852984d1dc734b8bd9bd024" dependencies = [ "bitvec", "cfg-if", @@ -12524,11 +12571,11 @@ dependencies = [ [[package]] name = "scale-info-derive" -version = "2.11.2" +version = "2.11.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18cf6c6447f813ef19eb450e985bcce6705f9ce7660db221b59093d15c79c4b7" +checksum = "2d35494501194174bda522a32605929eefc9ecf7e0a326c26db1fdd85881eb62" dependencies = [ - "proc-macro-crate 1.3.1", + "proc-macro-crate 3.1.0", "proc-macro2", "quote", "syn 1.0.109", @@ -12775,9 +12822,9 @@ checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" [[package]] name = "serde" -version = "1.0.198" +version = "1.0.203" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9846a40c979031340571da2545a4e5b7c4163bdae79b301d5f86d03979451fcc" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" dependencies = [ "serde_derive", ] @@ -12793,9 +12840,9 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.198" +version = "1.0.203" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e88edab869b01783ba905e7d0153f9fc1a6505a96e4ad3018011eedb838566d9" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" dependencies = [ "proc-macro2", "quote", @@ -12804,9 +12851,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.116" +version = "1.0.117" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e17db7126d17feb94eb3fad46bf1a96b034e8aacbc2e775fe81505f8b0b2813" +checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3" dependencies = [ "itoa", "ryu", @@ -13037,7 +13084,7 @@ dependencies = [ "fnv", "futures-lite 1.13.0", "futures-util", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "hex", "hmac 0.12.1", "itertools 0.11.0", @@ -13091,7 +13138,7 @@ dependencies = [ "fnv", "futures-lite 2.3.0", "futures-util", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "hex", "hmac 0.12.1", "itertools 0.11.0", @@ -13141,7 +13188,7 @@ dependencies = [ "futures-channel", "futures-lite 1.13.0", "futures-util", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "hex", "itertools 0.11.0", "log", @@ -13177,7 +13224,7 @@ dependencies = [ "futures-channel", "futures-lite 2.3.0", "futures-util", - "hashbrown 0.14.3", + "hashbrown 0.14.5", "hex", "itertools 0.11.0", "log", @@ -15161,9 +15208,9 @@ checksum = "3369f5ac52d5eb6ab48c6b4ffdc8efbcad6b89c765749064ba298f2c68a16a76" [[package]] name = "thiserror" -version = "1.0.58" +version = "1.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03468839009160513471e86a034bb2c5c0e4baae3b43f79ffc55c4a5427b3297" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" dependencies = [ "thiserror-impl", ] @@ -15190,9 +15237,9 @@ dependencies = [ [[package]] name = "thiserror-impl" -version = "1.0.58" +version = "1.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c61f3ba182994efc43764a46c018c347bc492c79f024e705f46567b418f6d4f7" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" dependencies = [ "proc-macro2", "quote", @@ -15378,9 +15425,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.10" +version = "0.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5419f34732d9eb6ee4c3578b7989078579b7f039cbbb9ca2c4da015749371e15" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" dependencies = [ "bytes", "futures-core", @@ -15388,7 +15435,6 @@ dependencies = [ "futures-sink", "pin-project-lite 0.2.14", "tokio", - "tracing", ] [[package]] diff --git a/client/coretime/bulk/Cargo.toml b/client/coretime/bulk/Cargo.toml new file mode 100644 index 0000000..bc5a7c1 --- /dev/null +++ b/client/coretime/bulk/Cargo.toml @@ -0,0 +1,56 @@ +[package] +name = "magnet-client-coretime-bulk" +authors = ["Anonymous"] +description = "magnet-coretime" +license = "Apache License 2.0" +homepage = "https://magnet.magport.io/" +repository.workspace = true +edition.workspace = true +version = "0.1.0" + +[dependencies] +async-trait = { workspace = true } +codec = { package = "parity-scale-codec", workspace = true, features = [ "derive" ] } +futures = { workspace = true } +tracing = { workspace = true } +schnellru = { workspace = true } +log = { workspace = true } +subxt = { workspace = true, features = ["substrate-compat"]} + +# Substrate +sc-client-api = { workspace = true } +sc-consensus = { workspace = true } +sc-consensus-aura = { workspace = true } +sc-consensus-babe = { workspace = true } +sc-consensus-slots = { workspace = true } +sc-telemetry = { workspace = true } +sp-api = { workspace = true } +sp-application-crypto = { workspace = true } +sp-block-builder = { workspace = true } +sp-blockchain = { workspace = true } +sp-consensus = { workspace = true } +sp-consensus-aura = { workspace = true } +sp-core = { workspace = true } +sp-inherents = { workspace = true } +sp-keystore = { workspace = true } +sp-runtime = { workspace = true } +sp-timestamp = { workspace = true } +sp-state-machine = { workspace = true } +substrate-prometheus-endpoint = { workspace = true } +sc-service = { workspace = true } + +# Cumulus +cumulus-client-consensus-common = { workspace = true } +cumulus-client-parachain-inherent = { workspace = true } +cumulus-relay-chain-interface = { workspace = true } +cumulus-client-consensus-proposer = { workspace = true } +cumulus-primitives-aura = { workspace = true } +cumulus-primitives-core = { workspace = true } +cumulus-primitives-parachain-inherent = { workspace = true } +cumulus-client-collator = { workspace = true } +cumulus-client-consensus-aura= { workspace = true } +# Polkadot +polkadot-primitives = { workspace = true } +polkadot-node-primitives = { workspace = true } +polkadot-node-subsystem = { workspace = true } +polkadot-overseer = { workspace = true } diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs new file mode 100644 index 0000000..7de61d0 --- /dev/null +++ b/client/coretime/bulk/src/lib.rs @@ -0,0 +1,66 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . +use cumulus_primitives_core::BlockT; +use cumulus_primitives_core::ParaId; +use cumulus_relay_chain_interface::RelayChainInterface; +use sc_client_api::UsageProvider; +use sc_service::TaskManager; +use sp_api::ProvideRuntimeApi; +use std::error::Error; +use std::sync::Arc; +mod metadata; +use subxt::client::OfflineClientT; +use subxt::{ + config::polkadot::PolkadotExtrinsicParamsBuilder as Params, tx::Signer, utils::MultiSignature, + Config, OnlineClient, PolkadotConfig, +}; + +pub fn spawn_bulk_task( + parachain: Arc, + para_id: ParaId, + relay_chain: R, + task_manager: &TaskManager, +) -> sc_service::error::Result<()> +where + Block: BlockT, + R: RelayChainInterface + Clone + 'static, + T: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, +{ + task_manager.spawn_essential_handle().spawn("bulk task", "magport", { + let parachain = parachain.clone(); + + async move { + let api = OnlineClient::::from_url("127.0.0.1:8855").await.unwrap(); + + loop { + let events = api.events().at_latest().await.unwrap(); + + // We can dynamically decode events: + println!("Dynamic event details:"); + for event in events.iter() { + let event = event.unwrap(); + + let pallet = event.pallet_name(); + let variant = event.variant_name(); + let field_values = event.field_values().unwrap(); + + println!("{pallet}::{variant}: {field_values}"); + } + } + } + }); + Ok(()) +} diff --git a/client/coretime/bulk/src/metadata.rs b/client/coretime/bulk/src/metadata.rs new file mode 100644 index 0000000..5805941 --- /dev/null +++ b/client/coretime/bulk/src/metadata.rs @@ -0,0 +1,19308 @@ +#[allow(dead_code, unused_imports, non_camel_case_types)] +#[allow(clippy::all)] +#[allow(rustdoc::broken_intra_doc_links)] +pub mod api { + #[allow(unused_imports)] + mod root_mod { + pub use super::*; + } + pub static PALLETS: [&str; 19usize] = [ + "System", + "ParachainSystem", + "Timestamp", + "ParachainInfo", + "Balances", + "TransactionPayment", + "Authorship", + "CollatorSelection", + "Session", + "Aura", + "AuraExt", + "XcmpQueue", + "PolkadotXcm", + "CumulusXcm", + "MessageQueue", + "Utility", + "Multisig", + "Broker", + "Sudo", + ]; + pub static RUNTIME_APIS: [&str; 12usize] = [ + "AuraApi", + "Core", + "Metadata", + "BlockBuilder", + "TaggedTransactionQueue", + "OffchainWorkerApi", + "SessionKeys", + "AccountNonceApi", + "TransactionPaymentApi", + "TransactionPaymentCallApi", + "CollectCollationInfo", + "GenesisBuilder", + ]; + #[doc = r" The error type returned when there is a runtime issue."] + pub type DispatchError = runtime_types::sp_runtime::DispatchError; + #[doc = r" The outer event enum."] + pub type Event = runtime_types::coretime_rococo_runtime::RuntimeEvent; + #[doc = r" The outer extrinsic enum."] + pub type Call = runtime_types::coretime_rococo_runtime::RuntimeCall; + #[doc = r" The outer error enum representing the DispatchError's Module variant."] + pub type Error = runtime_types::coretime_rococo_runtime::RuntimeError; + pub fn constants() -> ConstantsApi { + ConstantsApi + } + pub fn storage() -> StorageApi { + StorageApi + } + pub fn tx() -> TransactionApi { + TransactionApi + } + pub fn apis() -> runtime_apis::RuntimeApi { + runtime_apis::RuntimeApi + } + pub mod runtime_apis { + use super::root_mod; + use super::runtime_types; + use subxt::ext::codec::Encode; + pub struct RuntimeApi; + impl RuntimeApi { + pub fn aura_api(&self) -> aura_api::AuraApi { + aura_api::AuraApi + } + pub fn core(&self) -> core::Core { + core::Core + } + pub fn metadata(&self) -> metadata::Metadata { + metadata::Metadata + } + pub fn block_builder(&self) -> block_builder::BlockBuilder { + block_builder::BlockBuilder + } + pub fn tagged_transaction_queue( + &self, + ) -> tagged_transaction_queue::TaggedTransactionQueue { + tagged_transaction_queue::TaggedTransactionQueue + } + pub fn offchain_worker_api(&self) -> offchain_worker_api::OffchainWorkerApi { + offchain_worker_api::OffchainWorkerApi + } + pub fn session_keys(&self) -> session_keys::SessionKeys { + session_keys::SessionKeys + } + pub fn account_nonce_api(&self) -> account_nonce_api::AccountNonceApi { + account_nonce_api::AccountNonceApi + } + pub fn transaction_payment_api( + &self, + ) -> transaction_payment_api::TransactionPaymentApi { + transaction_payment_api::TransactionPaymentApi + } + pub fn transaction_payment_call_api( + &self, + ) -> transaction_payment_call_api::TransactionPaymentCallApi { + transaction_payment_call_api::TransactionPaymentCallApi + } + pub fn collect_collation_info(&self) -> collect_collation_info::CollectCollationInfo { + collect_collation_info::CollectCollationInfo + } + pub fn genesis_builder(&self) -> genesis_builder::GenesisBuilder { + genesis_builder::GenesisBuilder + } + } + pub mod aura_api { + use super::root_mod; + use super::runtime_types; + #[doc = " API necessary for block authorship with aura."] + pub struct AuraApi; + impl AuraApi { + #[doc = " Returns the slot duration for Aura."] + #[doc = ""] + #[doc = " Currently, only the value provided by this type at genesis will be used."] + pub fn slot_duration( + &self, + ) -> ::subxt::runtime_api::Payload< + types::SlotDuration, + runtime_types::sp_consensus_slots::SlotDuration, + > { + ::subxt::runtime_api::Payload::new_static( + "AuraApi", + "slot_duration", + types::SlotDuration {}, + [ + 233u8, 210u8, 132u8, 172u8, 100u8, 125u8, 239u8, 92u8, 114u8, 82u8, + 7u8, 110u8, 179u8, 196u8, 10u8, 19u8, 211u8, 15u8, 174u8, 2u8, 91u8, + 73u8, 133u8, 100u8, 205u8, 201u8, 191u8, 60u8, 163u8, 122u8, 215u8, + 10u8, + ], + ) + } + #[doc = " Return the current set of authorities."] + pub fn authorities( + &self, + ) -> ::subxt::runtime_api::Payload< + types::Authorities, + ::std::vec::Vec, + > { + ::subxt::runtime_api::Payload::new_static( + "AuraApi", + "authorities", + types::Authorities {}, + [ + 96u8, 136u8, 226u8, 244u8, 105u8, 189u8, 8u8, 250u8, 71u8, 230u8, 37u8, + 123u8, 218u8, 47u8, 179u8, 16u8, 170u8, 181u8, 165u8, 77u8, 102u8, + 51u8, 43u8, 51u8, 186u8, 84u8, 49u8, 15u8, 208u8, 226u8, 129u8, 230u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SlotDuration {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Authorities {} + } + } + pub mod core { + use super::root_mod; + use super::runtime_types; + #[doc = " The `Core` runtime api that every Substrate runtime needs to implement."] + pub struct Core; + impl Core { + #[doc = " Returns the version of the runtime."] + pub fn version( + &self, + ) -> ::subxt::runtime_api::Payload< + types::Version, + runtime_types::sp_version::RuntimeVersion, + > { + ::subxt::runtime_api::Payload::new_static( + "Core", + "version", + types::Version {}, + [ + 76u8, 202u8, 17u8, 117u8, 189u8, 237u8, 239u8, 237u8, 151u8, 17u8, + 125u8, 159u8, 218u8, 92u8, 57u8, 238u8, 64u8, 147u8, 40u8, 72u8, 157u8, + 116u8, 37u8, 195u8, 156u8, 27u8, 123u8, 173u8, 178u8, 102u8, 136u8, + 6u8, + ], + ) + } + #[doc = " Execute the given block."] + pub fn execute_block( + &self, + block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > >, + ) -> ::subxt::runtime_api::Payload { + ::subxt::runtime_api::Payload::new_static( + "Core", + "execute_block", + types::ExecuteBlock { block }, + [ + 133u8, 135u8, 228u8, 65u8, 106u8, 27u8, 85u8, 158u8, 112u8, 254u8, + 93u8, 26u8, 102u8, 201u8, 118u8, 216u8, 249u8, 247u8, 91u8, 74u8, 56u8, + 208u8, 231u8, 115u8, 131u8, 29u8, 209u8, 6u8, 65u8, 57u8, 214u8, 125u8, + ], + ) + } + #[doc = " Initialize a block with the given header."] + pub fn initialize_block( + &self, + header: runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + >, + ) -> ::subxt::runtime_api::Payload { + ::subxt::runtime_api::Payload::new_static( + "Core", + "initialize_block", + types::InitializeBlock { header }, + [ + 146u8, 138u8, 72u8, 240u8, 63u8, 96u8, 110u8, 189u8, 77u8, 92u8, 96u8, + 232u8, 41u8, 217u8, 105u8, 148u8, 83u8, 190u8, 152u8, 219u8, 19u8, + 87u8, 163u8, 1u8, 232u8, 25u8, 221u8, 74u8, 224u8, 67u8, 223u8, 34u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Version {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExecuteBlock { pub block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InitializeBlock { + pub header: + runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, + } + } + } + pub mod metadata { + use super::root_mod; + use super::runtime_types; + #[doc = " The `Metadata` api trait that returns metadata for the runtime."] + pub struct Metadata; + impl Metadata { + #[doc = " Returns the metadata of a runtime."] + pub fn metadata( + &self, + ) -> ::subxt::runtime_api::Payload< + types::Metadata, + runtime_types::sp_core::OpaqueMetadata, + > { + ::subxt::runtime_api::Payload::new_static( + "Metadata", + "metadata", + types::Metadata {}, + [ + 231u8, 24u8, 67u8, 152u8, 23u8, 26u8, 188u8, 82u8, 229u8, 6u8, 185u8, + 27u8, 175u8, 68u8, 83u8, 122u8, 69u8, 89u8, 185u8, 74u8, 248u8, 87u8, + 217u8, 124u8, 193u8, 252u8, 199u8, 186u8, 196u8, 179u8, 179u8, 96u8, + ], + ) + } + #[doc = " Returns the metadata at a given version."] + #[doc = ""] + #[doc = " If the given `version` isn't supported, this will return `None`."] + #[doc = " Use [`Self::metadata_versions`] to find out about supported metadata version of the runtime."] + pub fn metadata_at_version( + &self, + version: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::MetadataAtVersion, + ::core::option::Option, + > { + ::subxt::runtime_api::Payload::new_static( + "Metadata", + "metadata_at_version", + types::MetadataAtVersion { version }, + [ + 131u8, 53u8, 212u8, 234u8, 16u8, 25u8, 120u8, 252u8, 153u8, 153u8, + 216u8, 28u8, 54u8, 113u8, 52u8, 236u8, 146u8, 68u8, 142u8, 8u8, 10u8, + 169u8, 131u8, 142u8, 204u8, 38u8, 48u8, 108u8, 134u8, 86u8, 226u8, + 61u8, + ], + ) + } + #[doc = " Returns the supported metadata versions."] + #[doc = ""] + #[doc = " This can be used to call `metadata_at_version`."] + pub fn metadata_versions( + &self, + ) -> ::subxt::runtime_api::Payload< + types::MetadataVersions, + ::std::vec::Vec<::core::primitive::u32>, + > { + ::subxt::runtime_api::Payload::new_static( + "Metadata", + "metadata_versions", + types::MetadataVersions {}, + [ + 23u8, 144u8, 137u8, 91u8, 188u8, 39u8, 231u8, 208u8, 252u8, 218u8, + 224u8, 176u8, 77u8, 32u8, 130u8, 212u8, 223u8, 76u8, 100u8, 190u8, + 82u8, 94u8, 190u8, 8u8, 82u8, 244u8, 225u8, 179u8, 85u8, 176u8, 56u8, + 16u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Metadata {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MetadataAtVersion { + pub version: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MetadataVersions {} + } + } + pub mod block_builder { + use super::root_mod; + use super::runtime_types; + #[doc = " The `BlockBuilder` api trait that provides the required functionality for building a block."] + pub struct BlockBuilder; + impl BlockBuilder { + #[doc = " Apply the given extrinsic."] + #[doc = ""] + #[doc = " Returns an inclusion outcome which specifies if this extrinsic is included in"] + #[doc = " this block or not."] + pub fn apply_extrinsic( + &self, + extrinsic : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, + ) -> ::subxt::runtime_api::Payload< + types::ApplyExtrinsic, + ::core::result::Result< + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + runtime_types::sp_runtime::transaction_validity::TransactionValidityError, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "BlockBuilder", + "apply_extrinsic", + types::ApplyExtrinsic { extrinsic }, + [ + 72u8, 54u8, 139u8, 3u8, 118u8, 136u8, 65u8, 47u8, 6u8, 105u8, 125u8, + 223u8, 160u8, 29u8, 103u8, 74u8, 79u8, 149u8, 48u8, 90u8, 237u8, 2u8, + 97u8, 201u8, 123u8, 34u8, 167u8, 37u8, 187u8, 35u8, 176u8, 97u8, + ], + ) + } + #[doc = " Finish the current block."] + pub fn finalize_block( + &self, + ) -> ::subxt::runtime_api::Payload< + types::FinalizeBlock, + runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, + > { + ::subxt::runtime_api::Payload::new_static( + "BlockBuilder", + "finalize_block", + types::FinalizeBlock {}, + [ + 244u8, 207u8, 24u8, 33u8, 13u8, 69u8, 9u8, 249u8, 145u8, 143u8, 122u8, + 96u8, 197u8, 55u8, 64u8, 111u8, 238u8, 224u8, 34u8, 201u8, 27u8, 146u8, + 232u8, 99u8, 191u8, 30u8, 114u8, 16u8, 32u8, 220u8, 58u8, 62u8, + ], + ) + } + #[doc = " Generate inherent extrinsics. The inherent data will vary from chain to chain."] pub fn inherent_extrinsics (& self , inherent : runtime_types :: sp_inherents :: InherentData ,) -> :: subxt :: runtime_api :: Payload < types :: InherentExtrinsics , :: std :: vec :: Vec < :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > >{ + ::subxt::runtime_api::Payload::new_static( + "BlockBuilder", + "inherent_extrinsics", + types::InherentExtrinsics { inherent }, + [ + 254u8, 110u8, 245u8, 201u8, 250u8, 192u8, 27u8, 228u8, 151u8, 213u8, + 166u8, 89u8, 94u8, 81u8, 189u8, 234u8, 64u8, 18u8, 245u8, 80u8, 29u8, + 18u8, 140u8, 129u8, 113u8, 236u8, 135u8, 55u8, 79u8, 159u8, 175u8, + 183u8, + ], + ) + } + #[doc = " Check that the inherents are valid. The inherent data will vary from chain to chain."] + pub fn check_inherents( + &self, + block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > >, + data: runtime_types::sp_inherents::InherentData, + ) -> ::subxt::runtime_api::Payload< + types::CheckInherents, + runtime_types::sp_inherents::CheckInherentsResult, + > { + ::subxt::runtime_api::Payload::new_static( + "BlockBuilder", + "check_inherents", + types::CheckInherents { block, data }, + [ + 153u8, 134u8, 1u8, 215u8, 139u8, 11u8, 53u8, 51u8, 210u8, 175u8, 197u8, + 28u8, 38u8, 209u8, 175u8, 247u8, 142u8, 157u8, 50u8, 151u8, 164u8, + 191u8, 181u8, 118u8, 80u8, 97u8, 160u8, 248u8, 110u8, 217u8, 181u8, + 234u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApplyExtrinsic { pub extrinsic : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct FinalizeBlock {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InherentExtrinsics { + pub inherent: runtime_types::sp_inherents::InherentData, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckInherents { pub block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > , pub data : runtime_types :: sp_inherents :: InherentData , } + } + } + pub mod tagged_transaction_queue { + use super::root_mod; + use super::runtime_types; + #[doc = " The `TaggedTransactionQueue` api trait for interfering with the transaction queue."] + pub struct TaggedTransactionQueue; + impl TaggedTransactionQueue { + #[doc = " Validate the transaction."] + #[doc = ""] + #[doc = " This method is invoked by the transaction pool to learn details about given transaction."] + #[doc = " The implementation should make sure to verify the correctness of the transaction"] + #[doc = " against current state. The given `block_hash` corresponds to the hash of the block"] + #[doc = " that is used as current state."] + #[doc = ""] + #[doc = " Note that this call may be performed by the pool multiple times and transactions"] + #[doc = " might be verified in any possible order."] + pub fn validate_transaction( + &self, + source: runtime_types::sp_runtime::transaction_validity::TransactionSource, + tx : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, + block_hash: ::subxt::utils::H256, + ) -> ::subxt::runtime_api::Payload< + types::ValidateTransaction, + ::core::result::Result< + runtime_types::sp_runtime::transaction_validity::ValidTransaction, + runtime_types::sp_runtime::transaction_validity::TransactionValidityError, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "TaggedTransactionQueue", + "validate_transaction", + types::ValidateTransaction { source, tx, block_hash }, + [ + 196u8, 50u8, 90u8, 49u8, 109u8, 251u8, 200u8, 35u8, 23u8, 150u8, 140u8, + 143u8, 232u8, 164u8, 133u8, 89u8, 32u8, 240u8, 115u8, 39u8, 95u8, 70u8, + 162u8, 76u8, 122u8, 73u8, 151u8, 144u8, 234u8, 120u8, 100u8, 29u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidateTransaction { pub source : runtime_types :: sp_runtime :: transaction_validity :: TransactionSource , pub tx : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub block_hash : :: subxt :: utils :: H256 , } + } + } + pub mod offchain_worker_api { + use super::root_mod; + use super::runtime_types; + #[doc = " The offchain worker api."] + pub struct OffchainWorkerApi; + impl OffchainWorkerApi { + #[doc = " Starts the off-chain task for given block header."] + pub fn offchain_worker( + &self, + header: runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + >, + ) -> ::subxt::runtime_api::Payload { + ::subxt::runtime_api::Payload::new_static( + "OffchainWorkerApi", + "offchain_worker", + types::OffchainWorker { header }, + [ + 10u8, 135u8, 19u8, 153u8, 33u8, 216u8, 18u8, 242u8, 33u8, 140u8, 4u8, + 223u8, 200u8, 130u8, 103u8, 118u8, 137u8, 24u8, 19u8, 127u8, 161u8, + 29u8, 184u8, 111u8, 222u8, 111u8, 253u8, 73u8, 45u8, 31u8, 79u8, 60u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OffchainWorker { + pub header: + runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, + } + } + } + pub mod session_keys { + use super::root_mod; + use super::runtime_types; + #[doc = " Session keys runtime api."] + pub struct SessionKeys; + impl SessionKeys { + #[doc = " Generate a set of session keys with optionally using the given seed."] + #[doc = " The keys should be stored within the keystore exposed via runtime"] + #[doc = " externalities."] + #[doc = ""] + #[doc = " The seed needs to be a valid `utf8` string."] + #[doc = ""] + #[doc = " Returns the concatenated SCALE encoded public keys."] + pub fn generate_session_keys( + &self, + seed: ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, + ) -> ::subxt::runtime_api::Payload< + types::GenerateSessionKeys, + ::std::vec::Vec<::core::primitive::u8>, + > { + ::subxt::runtime_api::Payload::new_static( + "SessionKeys", + "generate_session_keys", + types::GenerateSessionKeys { seed }, + [ + 96u8, 171u8, 164u8, 166u8, 175u8, 102u8, 101u8, 47u8, 133u8, 95u8, + 102u8, 202u8, 83u8, 26u8, 238u8, 47u8, 126u8, 132u8, 22u8, 11u8, 33u8, + 190u8, 175u8, 94u8, 58u8, 245u8, 46u8, 80u8, 195u8, 184u8, 107u8, 65u8, + ], + ) + } + #[doc = " Decode the given public session keys."] + #[doc = ""] + #[doc = " Returns the list of public raw public keys + key type."] + pub fn decode_session_keys( + &self, + encoded: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::runtime_api::Payload< + types::DecodeSessionKeys, + ::core::option::Option< + ::std::vec::Vec<( + ::std::vec::Vec<::core::primitive::u8>, + runtime_types::sp_core::crypto::KeyTypeId, + )>, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "SessionKeys", + "decode_session_keys", + types::DecodeSessionKeys { encoded }, + [ + 57u8, 242u8, 18u8, 51u8, 132u8, 110u8, 238u8, 255u8, 39u8, 194u8, 8u8, + 54u8, 198u8, 178u8, 75u8, 151u8, 148u8, 176u8, 144u8, 197u8, 87u8, + 29u8, 179u8, 235u8, 176u8, 78u8, 252u8, 103u8, 72u8, 203u8, 151u8, + 248u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct GenerateSessionKeys { + pub seed: ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DecodeSessionKeys { + pub encoded: ::std::vec::Vec<::core::primitive::u8>, + } + } + } + pub mod account_nonce_api { + use super::root_mod; + use super::runtime_types; + #[doc = " The API to query account nonce."] + pub struct AccountNonceApi; + impl AccountNonceApi { + #[doc = " Get current account nonce of given `AccountId`."] + pub fn account_nonce( + &self, + account: ::subxt::utils::AccountId32, + ) -> ::subxt::runtime_api::Payload { + ::subxt::runtime_api::Payload::new_static( + "AccountNonceApi", + "account_nonce", + types::AccountNonce { account }, + [ + 231u8, 82u8, 7u8, 227u8, 131u8, 2u8, 215u8, 252u8, 173u8, 82u8, 11u8, + 103u8, 200u8, 25u8, 114u8, 116u8, 79u8, 229u8, 152u8, 150u8, 236u8, + 37u8, 101u8, 26u8, 220u8, 146u8, 182u8, 101u8, 73u8, 55u8, 191u8, + 171u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AccountNonce { + pub account: ::subxt::utils::AccountId32, + } + } + } + pub mod transaction_payment_api { + use super::root_mod; + use super::runtime_types; + pub struct TransactionPaymentApi; + impl TransactionPaymentApi { + pub fn query_info( + &self, + uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, + len: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::QueryInfo, + runtime_types::pallet_transaction_payment::types::RuntimeDispatchInfo< + ::core::primitive::u128, + runtime_types::sp_weights::weight_v2::Weight, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentApi", + "query_info", + types::QueryInfo { uxt, len }, + [ + 56u8, 30u8, 174u8, 34u8, 202u8, 24u8, 177u8, 189u8, 145u8, 36u8, 1u8, + 156u8, 98u8, 209u8, 178u8, 49u8, 198u8, 23u8, 150u8, 173u8, 35u8, + 205u8, 147u8, 129u8, 42u8, 22u8, 69u8, 3u8, 129u8, 8u8, 196u8, 139u8, + ], + ) + } + pub fn query_fee_details( + &self, + uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, + len: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::QueryFeeDetails, + runtime_types::pallet_transaction_payment::types::FeeDetails< + ::core::primitive::u128, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentApi", + "query_fee_details", + types::QueryFeeDetails { uxt, len }, + [ + 117u8, 60u8, 137u8, 159u8, 237u8, 252u8, 216u8, 238u8, 232u8, 1u8, + 100u8, 152u8, 26u8, 185u8, 145u8, 125u8, 68u8, 189u8, 4u8, 30u8, 125u8, + 7u8, 196u8, 153u8, 235u8, 51u8, 219u8, 108u8, 185u8, 254u8, 100u8, + 201u8, + ], + ) + } + pub fn query_weight_to_fee( + &self, + weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentApi", + "query_weight_to_fee", + types::QueryWeightToFee { weight }, + [ + 206u8, 243u8, 189u8, 83u8, 231u8, 244u8, 247u8, 52u8, 126u8, 208u8, + 224u8, 5u8, 163u8, 108u8, 254u8, 114u8, 214u8, 156u8, 227u8, 217u8, + 211u8, 198u8, 121u8, 164u8, 110u8, 54u8, 181u8, 146u8, 50u8, 146u8, + 146u8, 23u8, + ], + ) + } + pub fn query_length_to_fee( + &self, + length: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentApi", + "query_length_to_fee", + types::QueryLengthToFee { length }, + [ + 92u8, 132u8, 29u8, 119u8, 66u8, 11u8, 196u8, 224u8, 129u8, 23u8, 249u8, + 12u8, 32u8, 28u8, 92u8, 50u8, 188u8, 101u8, 203u8, 229u8, 248u8, 216u8, + 130u8, 150u8, 212u8, 161u8, 81u8, 254u8, 116u8, 89u8, 162u8, 48u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryInfo { pub uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub len : :: core :: primitive :: u32 , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryFeeDetails { pub uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub len : :: core :: primitive :: u32 , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryWeightToFee { + pub weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryLengthToFee { + pub length: ::core::primitive::u32, + } + } + } + pub mod transaction_payment_call_api { + use super::root_mod; + use super::runtime_types; + pub struct TransactionPaymentCallApi; + impl TransactionPaymentCallApi { + #[doc = " Query information of a dispatch class, weight, and fee of a given encoded `Call`."] + pub fn query_call_info( + &self, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + len: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::QueryCallInfo, + runtime_types::pallet_transaction_payment::types::RuntimeDispatchInfo< + ::core::primitive::u128, + runtime_types::sp_weights::weight_v2::Weight, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentCallApi", + "query_call_info", + types::QueryCallInfo { call, len }, + [ + 144u8, 172u8, 193u8, 149u8, 28u8, 82u8, 208u8, 226u8, 171u8, 59u8, + 10u8, 77u8, 230u8, 162u8, 177u8, 49u8, 193u8, 102u8, 128u8, 112u8, + 235u8, 183u8, 35u8, 97u8, 139u8, 157u8, 177u8, 173u8, 205u8, 6u8, + 255u8, 26u8, + ], + ) + } + #[doc = " Query fee details of a given encoded `Call`."] + pub fn query_call_fee_details( + &self, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + len: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload< + types::QueryCallFeeDetails, + runtime_types::pallet_transaction_payment::types::FeeDetails< + ::core::primitive::u128, + >, + > { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentCallApi", + "query_call_fee_details", + types::QueryCallFeeDetails { call, len }, + [ + 53u8, 126u8, 3u8, 45u8, 40u8, 132u8, 229u8, 63u8, 8u8, 241u8, 124u8, + 160u8, 30u8, 139u8, 140u8, 97u8, 78u8, 59u8, 151u8, 84u8, 29u8, 36u8, + 232u8, 93u8, 116u8, 66u8, 35u8, 191u8, 43u8, 172u8, 29u8, 8u8, + ], + ) + } + #[doc = " Query the output of the current `WeightToFee` given some input."] + pub fn query_weight_to_fee( + &self, + weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentCallApi", + "query_weight_to_fee", + types::QueryWeightToFee { weight }, + [ + 117u8, 91u8, 94u8, 22u8, 248u8, 212u8, 15u8, 23u8, 97u8, 116u8, 64u8, + 228u8, 83u8, 123u8, 87u8, 77u8, 97u8, 7u8, 98u8, 181u8, 6u8, 165u8, + 114u8, 141u8, 164u8, 113u8, 126u8, 88u8, 174u8, 171u8, 224u8, 35u8, + ], + ) + } + #[doc = " Query the output of the current `LengthToFee` given some input."] + pub fn query_length_to_fee( + &self, + length: ::core::primitive::u32, + ) -> ::subxt::runtime_api::Payload + { + ::subxt::runtime_api::Payload::new_static( + "TransactionPaymentCallApi", + "query_length_to_fee", + types::QueryLengthToFee { length }, + [ + 246u8, 40u8, 4u8, 160u8, 152u8, 94u8, 170u8, 53u8, 205u8, 122u8, 5u8, + 69u8, 70u8, 25u8, 128u8, 156u8, 119u8, 134u8, 116u8, 147u8, 14u8, + 164u8, 65u8, 140u8, 86u8, 13u8, 250u8, 218u8, 89u8, 95u8, 234u8, 228u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryCallInfo { + pub call: runtime_types::coretime_rococo_runtime::RuntimeCall, + pub len: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryCallFeeDetails { + pub call: runtime_types::coretime_rococo_runtime::RuntimeCall, + pub len: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryWeightToFee { + pub weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryLengthToFee { + pub length: ::core::primitive::u32, + } + } + } + pub mod collect_collation_info { + use super::root_mod; + use super::runtime_types; + #[doc = " Runtime api to collect information about a collation."] + pub struct CollectCollationInfo; + impl CollectCollationInfo { + #[doc = " Collect information about a collation."] + #[doc = ""] + #[doc = " The given `header` is the header of the built block for that"] + #[doc = " we are collecting the collation info for."] + pub fn collect_collation_info( + &self, + header: runtime_types::sp_runtime::generic::header::Header< + ::core::primitive::u32, + >, + ) -> ::subxt::runtime_api::Payload< + types::CollectCollationInfo, + runtime_types::cumulus_primitives_core::CollationInfo, + > { + ::subxt::runtime_api::Payload::new_static( + "CollectCollationInfo", + "collect_collation_info", + types::CollectCollationInfo { header }, + [ + 56u8, 138u8, 105u8, 91u8, 216u8, 40u8, 255u8, 98u8, 86u8, 138u8, 185u8, + 155u8, 80u8, 141u8, 85u8, 48u8, 252u8, 235u8, 178u8, 231u8, 111u8, + 216u8, 71u8, 20u8, 33u8, 202u8, 24u8, 215u8, 214u8, 132u8, 51u8, 166u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CollectCollationInfo { + pub header: + runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, + } + } + } + pub mod genesis_builder { + use super::root_mod; + use super::runtime_types; + #[doc = " API to interact with GenesisConfig for the runtime"] + pub struct GenesisBuilder; + impl GenesisBuilder { + #[doc = " Creates the default `GenesisConfig` and returns it as a JSON blob."] + #[doc = ""] + #[doc = " This function instantiates the default `GenesisConfig` struct for the runtime and serializes it into a JSON"] + #[doc = " blob. It returns a `Vec` containing the JSON representation of the default `GenesisConfig`."] + pub fn create_default_config( + &self, + ) -> ::subxt::runtime_api::Payload< + types::CreateDefaultConfig, + ::std::vec::Vec<::core::primitive::u8>, + > { + ::subxt::runtime_api::Payload::new_static( + "GenesisBuilder", + "create_default_config", + types::CreateDefaultConfig {}, + [ + 238u8, 5u8, 139u8, 81u8, 184u8, 155u8, 221u8, 118u8, 190u8, 76u8, + 229u8, 67u8, 132u8, 89u8, 83u8, 80u8, 56u8, 171u8, 169u8, 64u8, 123u8, + 20u8, 129u8, 159u8, 28u8, 135u8, 84u8, 52u8, 192u8, 98u8, 104u8, 214u8, + ], + ) + } + #[doc = " Build `GenesisConfig` from a JSON blob not using any defaults and store it in the storage."] + #[doc = ""] + #[doc = " This function deserializes the full `GenesisConfig` from the given JSON blob and puts it into the storage."] + #[doc = " If the provided JSON blob is incorrect or incomplete or the deserialization fails, an error is returned."] + #[doc = " It is recommended to log any errors encountered during the process."] + #[doc = ""] + #[doc = " Please note that provided json blob must contain all `GenesisConfig` fields, no defaults will be used."] + pub fn build_config( + &self, + json: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::runtime_api::Payload< + types::BuildConfig, + ::core::result::Result<(), ::std::string::String>, + > { + ::subxt::runtime_api::Payload::new_static( + "GenesisBuilder", + "build_config", + types::BuildConfig { json }, + [ + 6u8, 98u8, 68u8, 125u8, 157u8, 26u8, 107u8, 86u8, 213u8, 227u8, 26u8, + 229u8, 122u8, 161u8, 229u8, 114u8, 123u8, 192u8, 66u8, 231u8, 148u8, + 175u8, 5u8, 185u8, 248u8, 88u8, 40u8, 122u8, 230u8, 209u8, 170u8, + 254u8, + ], + ) + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CreateDefaultConfig {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BuildConfig { + pub json: ::std::vec::Vec<::core::primitive::u8>, + } + } + } + } + pub fn custom() -> CustomValuesApi { + CustomValuesApi + } + pub struct CustomValuesApi; + impl CustomValuesApi {} + pub struct ConstantsApi; + impl ConstantsApi { + pub fn system(&self) -> system::constants::ConstantsApi { + system::constants::ConstantsApi + } + pub fn timestamp(&self) -> timestamp::constants::ConstantsApi { + timestamp::constants::ConstantsApi + } + pub fn balances(&self) -> balances::constants::ConstantsApi { + balances::constants::ConstantsApi + } + pub fn transaction_payment(&self) -> transaction_payment::constants::ConstantsApi { + transaction_payment::constants::ConstantsApi + } + pub fn xcmp_queue(&self) -> xcmp_queue::constants::ConstantsApi { + xcmp_queue::constants::ConstantsApi + } + pub fn message_queue(&self) -> message_queue::constants::ConstantsApi { + message_queue::constants::ConstantsApi + } + pub fn utility(&self) -> utility::constants::ConstantsApi { + utility::constants::ConstantsApi + } + pub fn multisig(&self) -> multisig::constants::ConstantsApi { + multisig::constants::ConstantsApi + } + pub fn broker(&self) -> broker::constants::ConstantsApi { + broker::constants::ConstantsApi + } + } + pub struct StorageApi; + impl StorageApi { + pub fn system(&self) -> system::storage::StorageApi { + system::storage::StorageApi + } + pub fn parachain_system(&self) -> parachain_system::storage::StorageApi { + parachain_system::storage::StorageApi + } + pub fn timestamp(&self) -> timestamp::storage::StorageApi { + timestamp::storage::StorageApi + } + pub fn parachain_info(&self) -> parachain_info::storage::StorageApi { + parachain_info::storage::StorageApi + } + pub fn balances(&self) -> balances::storage::StorageApi { + balances::storage::StorageApi + } + pub fn transaction_payment(&self) -> transaction_payment::storage::StorageApi { + transaction_payment::storage::StorageApi + } + pub fn authorship(&self) -> authorship::storage::StorageApi { + authorship::storage::StorageApi + } + pub fn collator_selection(&self) -> collator_selection::storage::StorageApi { + collator_selection::storage::StorageApi + } + pub fn session(&self) -> session::storage::StorageApi { + session::storage::StorageApi + } + pub fn aura(&self) -> aura::storage::StorageApi { + aura::storage::StorageApi + } + pub fn aura_ext(&self) -> aura_ext::storage::StorageApi { + aura_ext::storage::StorageApi + } + pub fn xcmp_queue(&self) -> xcmp_queue::storage::StorageApi { + xcmp_queue::storage::StorageApi + } + pub fn polkadot_xcm(&self) -> polkadot_xcm::storage::StorageApi { + polkadot_xcm::storage::StorageApi + } + pub fn message_queue(&self) -> message_queue::storage::StorageApi { + message_queue::storage::StorageApi + } + pub fn multisig(&self) -> multisig::storage::StorageApi { + multisig::storage::StorageApi + } + pub fn broker(&self) -> broker::storage::StorageApi { + broker::storage::StorageApi + } + pub fn sudo(&self) -> sudo::storage::StorageApi { + sudo::storage::StorageApi + } + } + pub struct TransactionApi; + impl TransactionApi { + pub fn system(&self) -> system::calls::TransactionApi { + system::calls::TransactionApi + } + pub fn parachain_system(&self) -> parachain_system::calls::TransactionApi { + parachain_system::calls::TransactionApi + } + pub fn timestamp(&self) -> timestamp::calls::TransactionApi { + timestamp::calls::TransactionApi + } + pub fn parachain_info(&self) -> parachain_info::calls::TransactionApi { + parachain_info::calls::TransactionApi + } + pub fn balances(&self) -> balances::calls::TransactionApi { + balances::calls::TransactionApi + } + pub fn collator_selection(&self) -> collator_selection::calls::TransactionApi { + collator_selection::calls::TransactionApi + } + pub fn session(&self) -> session::calls::TransactionApi { + session::calls::TransactionApi + } + pub fn xcmp_queue(&self) -> xcmp_queue::calls::TransactionApi { + xcmp_queue::calls::TransactionApi + } + pub fn polkadot_xcm(&self) -> polkadot_xcm::calls::TransactionApi { + polkadot_xcm::calls::TransactionApi + } + pub fn cumulus_xcm(&self) -> cumulus_xcm::calls::TransactionApi { + cumulus_xcm::calls::TransactionApi + } + pub fn message_queue(&self) -> message_queue::calls::TransactionApi { + message_queue::calls::TransactionApi + } + pub fn utility(&self) -> utility::calls::TransactionApi { + utility::calls::TransactionApi + } + pub fn multisig(&self) -> multisig::calls::TransactionApi { + multisig::calls::TransactionApi + } + pub fn broker(&self) -> broker::calls::TransactionApi { + broker::calls::TransactionApi + } + pub fn sudo(&self) -> sudo::calls::TransactionApi { + sudo::calls::TransactionApi + } + } + #[doc = r" check whether the metadata provided is aligned with this statically generated code."] + pub fn is_codegen_valid_for(metadata: &::subxt::Metadata) -> bool { + let runtime_metadata_hash = metadata + .hasher() + .only_these_pallets(&PALLETS) + .only_these_runtime_apis(&RUNTIME_APIS) + .hash(); + runtime_metadata_hash + == [ + 242u8, 249u8, 231u8, 131u8, 221u8, 227u8, 243u8, 80u8, 94u8, 43u8, 167u8, 107u8, + 160u8, 189u8, 68u8, 67u8, 246u8, 202u8, 187u8, 14u8, 58u8, 172u8, 27u8, 33u8, + 232u8, 78u8, 146u8, 148u8, 181u8, 89u8, 134u8, 221u8, + ] + } + pub mod system { + use super::root_mod; + use super::runtime_types; + #[doc = "Error for the System pallet"] + pub type Error = runtime_types::frame_system::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::frame_system::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Remark { + pub remark: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::blocks::StaticExtrinsic for Remark { + const PALLET: &'static str = "System"; + const CALL: &'static str = "remark"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetHeapPages { + pub pages: ::core::primitive::u64, + } + impl ::subxt::blocks::StaticExtrinsic for SetHeapPages { + const PALLET: &'static str = "System"; + const CALL: &'static str = "set_heap_pages"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCode { + pub code: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::blocks::StaticExtrinsic for SetCode { + const PALLET: &'static str = "System"; + const CALL: &'static str = "set_code"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCodeWithoutChecks { + pub code: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::blocks::StaticExtrinsic for SetCodeWithoutChecks { + const PALLET: &'static str = "System"; + const CALL: &'static str = "set_code_without_checks"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetStorage { + pub items: ::std::vec::Vec<( + ::std::vec::Vec<::core::primitive::u8>, + ::std::vec::Vec<::core::primitive::u8>, + )>, + } + impl ::subxt::blocks::StaticExtrinsic for SetStorage { + const PALLET: &'static str = "System"; + const CALL: &'static str = "set_storage"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillStorage { + pub keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + } + impl ::subxt::blocks::StaticExtrinsic for KillStorage { + const PALLET: &'static str = "System"; + const CALL: &'static str = "kill_storage"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KillPrefix { + pub prefix: ::std::vec::Vec<::core::primitive::u8>, + pub subkeys: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for KillPrefix { + const PALLET: &'static str = "System"; + const CALL: &'static str = "kill_prefix"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemarkWithEvent { + pub remark: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::blocks::StaticExtrinsic for RemarkWithEvent { + const PALLET: &'static str = "System"; + const CALL: &'static str = "remark_with_event"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AuthorizeUpgrade { + pub code_hash: ::subxt::utils::H256, + } + impl ::subxt::blocks::StaticExtrinsic for AuthorizeUpgrade { + const PALLET: &'static str = "System"; + const CALL: &'static str = "authorize_upgrade"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AuthorizeUpgradeWithoutChecks { + pub code_hash: ::subxt::utils::H256, + } + impl ::subxt::blocks::StaticExtrinsic for AuthorizeUpgradeWithoutChecks { + const PALLET: &'static str = "System"; + const CALL: &'static str = "authorize_upgrade_without_checks"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApplyAuthorizedUpgrade { + pub code: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::blocks::StaticExtrinsic for ApplyAuthorizedUpgrade { + const PALLET: &'static str = "System"; + const CALL: &'static str = "apply_authorized_upgrade"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::remark`]."] + pub fn remark( + &self, + remark: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "remark", + types::Remark { remark }, + [ + 43u8, 126u8, 180u8, 174u8, 141u8, 48u8, 52u8, 125u8, 166u8, 212u8, + 216u8, 98u8, 100u8, 24u8, 132u8, 71u8, 101u8, 64u8, 246u8, 169u8, 33u8, + 250u8, 147u8, 208u8, 2u8, 40u8, 129u8, 209u8, 232u8, 207u8, 207u8, + 13u8, + ], + ) + } + #[doc = "See [`Pallet::set_heap_pages`]."] + pub fn set_heap_pages( + &self, + pages: ::core::primitive::u64, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "set_heap_pages", + types::SetHeapPages { pages }, + [ + 188u8, 191u8, 99u8, 216u8, 219u8, 109u8, 141u8, 50u8, 78u8, 235u8, + 215u8, 242u8, 195u8, 24u8, 111u8, 76u8, 229u8, 64u8, 99u8, 225u8, + 134u8, 121u8, 81u8, 209u8, 127u8, 223u8, 98u8, 215u8, 150u8, 70u8, + 57u8, 147u8, + ], + ) + } + #[doc = "See [`Pallet::set_code`]."] + pub fn set_code( + &self, + code: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "set_code", + types::SetCode { code }, + [ + 233u8, 248u8, 88u8, 245u8, 28u8, 65u8, 25u8, 169u8, 35u8, 237u8, 19u8, + 203u8, 136u8, 160u8, 18u8, 3u8, 20u8, 197u8, 81u8, 169u8, 244u8, 188u8, + 27u8, 147u8, 147u8, 236u8, 65u8, 25u8, 3u8, 143u8, 182u8, 22u8, + ], + ) + } + #[doc = "See [`Pallet::set_code_without_checks`]."] + pub fn set_code_without_checks( + &self, + code: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "set_code_without_checks", + types::SetCodeWithoutChecks { code }, + [ + 82u8, 212u8, 157u8, 44u8, 70u8, 0u8, 143u8, 15u8, 109u8, 109u8, 107u8, + 157u8, 141u8, 42u8, 169u8, 11u8, 15u8, 186u8, 252u8, 138u8, 10u8, + 147u8, 15u8, 178u8, 247u8, 229u8, 213u8, 98u8, 207u8, 231u8, 119u8, + 115u8, + ], + ) + } + #[doc = "See [`Pallet::set_storage`]."] + pub fn set_storage( + &self, + items: ::std::vec::Vec<( + ::std::vec::Vec<::core::primitive::u8>, + ::std::vec::Vec<::core::primitive::u8>, + )>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "set_storage", + types::SetStorage { items }, + [ + 141u8, 216u8, 52u8, 222u8, 223u8, 136u8, 123u8, 181u8, 19u8, 75u8, + 163u8, 102u8, 229u8, 189u8, 158u8, 142u8, 95u8, 235u8, 240u8, 49u8, + 150u8, 76u8, 78u8, 137u8, 126u8, 88u8, 183u8, 88u8, 231u8, 146u8, + 234u8, 43u8, + ], + ) + } + #[doc = "See [`Pallet::kill_storage`]."] + pub fn kill_storage( + &self, + keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "kill_storage", + types::KillStorage { keys }, + [ + 73u8, 63u8, 196u8, 36u8, 144u8, 114u8, 34u8, 213u8, 108u8, 93u8, 209u8, + 234u8, 153u8, 185u8, 33u8, 91u8, 187u8, 195u8, 223u8, 130u8, 58u8, + 156u8, 63u8, 47u8, 228u8, 249u8, 216u8, 139u8, 143u8, 177u8, 41u8, + 35u8, + ], + ) + } + #[doc = "See [`Pallet::kill_prefix`]."] + pub fn kill_prefix( + &self, + prefix: ::std::vec::Vec<::core::primitive::u8>, + subkeys: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "kill_prefix", + types::KillPrefix { prefix, subkeys }, + [ + 184u8, 57u8, 139u8, 24u8, 208u8, 87u8, 108u8, 215u8, 198u8, 189u8, + 175u8, 242u8, 167u8, 215u8, 97u8, 63u8, 110u8, 166u8, 238u8, 98u8, + 67u8, 236u8, 111u8, 110u8, 234u8, 81u8, 102u8, 5u8, 182u8, 5u8, 214u8, + 85u8, + ], + ) + } + #[doc = "See [`Pallet::remark_with_event`]."] + pub fn remark_with_event( + &self, + remark: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "remark_with_event", + types::RemarkWithEvent { remark }, + [ + 120u8, 120u8, 153u8, 92u8, 184u8, 85u8, 34u8, 2u8, 174u8, 206u8, 105u8, + 228u8, 233u8, 130u8, 80u8, 246u8, 228u8, 59u8, 234u8, 240u8, 4u8, 49u8, + 147u8, 170u8, 115u8, 91u8, 149u8, 200u8, 228u8, 181u8, 8u8, 154u8, + ], + ) + } + #[doc = "See [`Pallet::authorize_upgrade`]."] + pub fn authorize_upgrade( + &self, + code_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "authorize_upgrade", + types::AuthorizeUpgrade { code_hash }, + [ + 4u8, 14u8, 76u8, 107u8, 209u8, 129u8, 9u8, 39u8, 193u8, 17u8, 84u8, + 254u8, 170u8, 214u8, 24u8, 155u8, 29u8, 184u8, 249u8, 241u8, 109u8, + 58u8, 145u8, 131u8, 109u8, 63u8, 38u8, 165u8, 107u8, 215u8, 217u8, + 172u8, + ], + ) + } + #[doc = "See [`Pallet::authorize_upgrade_without_checks`]."] + pub fn authorize_upgrade_without_checks( + &self, + code_hash: ::subxt::utils::H256, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "authorize_upgrade_without_checks", + types::AuthorizeUpgradeWithoutChecks { code_hash }, + [ + 126u8, 126u8, 55u8, 26u8, 47u8, 55u8, 66u8, 8u8, 167u8, 18u8, 29u8, + 136u8, 146u8, 14u8, 189u8, 117u8, 16u8, 227u8, 162u8, 61u8, 149u8, + 197u8, 104u8, 184u8, 185u8, 161u8, 99u8, 154u8, 80u8, 125u8, 181u8, + 233u8, + ], + ) + } + #[doc = "See [`Pallet::apply_authorized_upgrade`]."] + pub fn apply_authorized_upgrade( + &self, + code: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "System", + "apply_authorized_upgrade", + types::ApplyAuthorizedUpgrade { code }, + [ + 232u8, 107u8, 127u8, 38u8, 230u8, 29u8, 97u8, 4u8, 160u8, 191u8, 222u8, + 156u8, 245u8, 102u8, 196u8, 141u8, 44u8, 163u8, 98u8, 68u8, 125u8, + 32u8, 124u8, 101u8, 108u8, 93u8, 211u8, 52u8, 0u8, 231u8, 33u8, 227u8, + ], + ) + } + } + } + #[doc = "Event for the System pallet."] + pub type Event = runtime_types::frame_system::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An extrinsic completed successfully."] + pub struct ExtrinsicSuccess { + pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + } + impl ::subxt::events::StaticEvent for ExtrinsicSuccess { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "ExtrinsicSuccess"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An extrinsic failed."] + pub struct ExtrinsicFailed { + pub dispatch_error: runtime_types::sp_runtime::DispatchError, + pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + } + impl ::subxt::events::StaticEvent for ExtrinsicFailed { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "ExtrinsicFailed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "`:code` was updated."] + pub struct CodeUpdated; + impl ::subxt::events::StaticEvent for CodeUpdated { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "CodeUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new account was created."] + pub struct NewAccount { + pub account: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for NewAccount { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "NewAccount"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was reaped."] + pub struct KilledAccount { + pub account: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for KilledAccount { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "KilledAccount"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "On on-chain remark happened."] + pub struct Remarked { + pub sender: ::subxt::utils::AccountId32, + pub hash: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for Remarked { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "Remarked"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An upgrade was authorized."] + pub struct UpgradeAuthorized { + pub code_hash: ::subxt::utils::H256, + pub check_version: ::core::primitive::bool, + } + impl ::subxt::events::StaticEvent for UpgradeAuthorized { + const PALLET: &'static str = "System"; + const EVENT: &'static str = "UpgradeAuthorized"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The full account information for a particular account ID."] + pub fn account_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::AccountInfo< + ::core::primitive::u32, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "Account", + vec![], + [ + 14u8, 233u8, 115u8, 214u8, 0u8, 109u8, 222u8, 121u8, 162u8, 65u8, 60u8, + 175u8, 209u8, 79u8, 222u8, 124u8, 22u8, 235u8, 138u8, 176u8, 133u8, + 124u8, 90u8, 158u8, 85u8, 45u8, 37u8, 174u8, 47u8, 79u8, 47u8, 166u8, + ], + ) + } + #[doc = " The full account information for a particular account ID."] + pub fn account( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::AccountInfo< + ::core::primitive::u32, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "Account", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 14u8, 233u8, 115u8, 214u8, 0u8, 109u8, 222u8, 121u8, 162u8, 65u8, 60u8, + 175u8, 209u8, 79u8, 222u8, 124u8, 22u8, 235u8, 138u8, 176u8, 133u8, + 124u8, 90u8, 158u8, 85u8, 45u8, 37u8, 174u8, 47u8, 79u8, 47u8, 166u8, + ], + ) + } + #[doc = " Total extrinsics count for the current block."] + pub fn extrinsic_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "ExtrinsicCount", + vec![], + [ + 102u8, 76u8, 236u8, 42u8, 40u8, 231u8, 33u8, 222u8, 123u8, 147u8, + 153u8, 148u8, 234u8, 203u8, 181u8, 119u8, 6u8, 187u8, 177u8, 199u8, + 120u8, 47u8, 137u8, 254u8, 96u8, 100u8, 165u8, 182u8, 249u8, 230u8, + 159u8, 79u8, + ], + ) + } + #[doc = " The current weight for the block."] + pub fn block_weight( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_support::dispatch::PerDispatchClass< + runtime_types::sp_weights::weight_v2::Weight, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "BlockWeight", + vec![], + [ + 158u8, 46u8, 228u8, 89u8, 210u8, 214u8, 84u8, 154u8, 50u8, 68u8, 63u8, + 62u8, 43u8, 42u8, 99u8, 27u8, 54u8, 42u8, 146u8, 44u8, 241u8, 216u8, + 229u8, 30u8, 216u8, 255u8, 165u8, 238u8, 181u8, 130u8, 36u8, 102u8, + ], + ) + } + #[doc = " Total length (in bytes) for all extrinsics put together, for the current block."] + pub fn all_extrinsics_len( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "AllExtrinsicsLen", + vec![], + [ + 117u8, 86u8, 61u8, 243u8, 41u8, 51u8, 102u8, 214u8, 137u8, 100u8, + 243u8, 185u8, 122u8, 174u8, 187u8, 117u8, 86u8, 189u8, 63u8, 135u8, + 101u8, 218u8, 203u8, 201u8, 237u8, 254u8, 128u8, 183u8, 169u8, 221u8, + 242u8, 65u8, + ], + ) + } + #[doc = " Map of block numbers to block hashes."] + pub fn block_hash_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "BlockHash", + vec![], + [ + 217u8, 32u8, 215u8, 253u8, 24u8, 182u8, 207u8, 178u8, 157u8, 24u8, + 103u8, 100u8, 195u8, 165u8, 69u8, 152u8, 112u8, 181u8, 56u8, 192u8, + 164u8, 16u8, 20u8, 222u8, 28u8, 214u8, 144u8, 142u8, 146u8, 69u8, + 202u8, 118u8, + ], + ) + } + #[doc = " Map of block numbers to block hashes."] + pub fn block_hash( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "BlockHash", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 217u8, 32u8, 215u8, 253u8, 24u8, 182u8, 207u8, 178u8, 157u8, 24u8, + 103u8, 100u8, 195u8, 165u8, 69u8, 152u8, 112u8, 181u8, 56u8, 192u8, + 164u8, 16u8, 20u8, 222u8, 28u8, 214u8, 144u8, 142u8, 146u8, 69u8, + 202u8, 118u8, + ], + ) + } + #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] + pub fn extrinsic_data_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "ExtrinsicData", + vec![], + [ + 160u8, 180u8, 122u8, 18u8, 196u8, 26u8, 2u8, 37u8, 115u8, 232u8, 133u8, + 220u8, 106u8, 245u8, 4u8, 129u8, 42u8, 84u8, 241u8, 45u8, 199u8, 179u8, + 128u8, 61u8, 170u8, 137u8, 231u8, 156u8, 247u8, 57u8, 47u8, 38u8, + ], + ) + } + #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] + pub fn extrinsic_data( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "ExtrinsicData", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 160u8, 180u8, 122u8, 18u8, 196u8, 26u8, 2u8, 37u8, 115u8, 232u8, 133u8, + 220u8, 106u8, 245u8, 4u8, 129u8, 42u8, 84u8, 241u8, 45u8, 199u8, 179u8, + 128u8, 61u8, 170u8, 137u8, 231u8, 156u8, 247u8, 57u8, 47u8, 38u8, + ], + ) + } + #[doc = " The current block number being processed. Set by `execute_block`."] + pub fn number( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "Number", + vec![], + [ + 30u8, 194u8, 177u8, 90u8, 194u8, 232u8, 46u8, 180u8, 85u8, 129u8, 14u8, + 9u8, 8u8, 8u8, 23u8, 95u8, 230u8, 5u8, 13u8, 105u8, 125u8, 2u8, 22u8, + 200u8, 78u8, 93u8, 115u8, 28u8, 150u8, 113u8, 48u8, 53u8, + ], + ) + } + #[doc = " Hash of the previous block."] + pub fn parent_hash( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::H256, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "ParentHash", + vec![], + [ + 26u8, 130u8, 11u8, 216u8, 155u8, 71u8, 128u8, 170u8, 30u8, 153u8, 21u8, + 192u8, 62u8, 93u8, 137u8, 80u8, 120u8, 81u8, 202u8, 94u8, 248u8, 125u8, + 71u8, 82u8, 141u8, 229u8, 32u8, 56u8, 73u8, 50u8, 101u8, 78u8, + ], + ) + } + #[doc = " Digest of the current block, also part of the block header."] + pub fn digest( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_runtime::generic::digest::Digest, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "Digest", + vec![], + [ + 61u8, 64u8, 237u8, 91u8, 145u8, 232u8, 17u8, 254u8, 181u8, 16u8, 234u8, + 91u8, 51u8, 140u8, 254u8, 131u8, 98u8, 135u8, 21u8, 37u8, 251u8, 20u8, + 58u8, 92u8, 123u8, 141u8, 14u8, 227u8, 146u8, 46u8, 222u8, 117u8, + ], + ) + } + #[doc = " Events deposited for the current block."] + #[doc = ""] + #[doc = " NOTE: The item is unbound and should therefore never be read on chain."] + #[doc = " It could otherwise inflate the PoV size of a block."] + #[doc = ""] + #[doc = " Events have a large in-memory size. Box the events to not go out-of-memory"] + #[doc = " just in case someone still reads them from within the runtime."] + pub fn events( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::frame_system::EventRecord< + runtime_types::coretime_rococo_runtime::RuntimeEvent, + ::subxt::utils::H256, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "Events", + vec![], + [ + 116u8, 34u8, 143u8, 0u8, 100u8, 96u8, 191u8, 144u8, 117u8, 233u8, + 245u8, 65u8, 232u8, 97u8, 101u8, 184u8, 150u8, 152u8, 218u8, 179u8, + 195u8, 142u8, 170u8, 211u8, 191u8, 58u8, 100u8, 54u8, 248u8, 57u8, + 227u8, 165u8, + ], + ) + } + #[doc = " The number of events in the `Events` list."] + pub fn event_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "EventCount", + vec![], + [ + 175u8, 24u8, 252u8, 184u8, 210u8, 167u8, 146u8, 143u8, 164u8, 80u8, + 151u8, 205u8, 189u8, 189u8, 55u8, 220u8, 47u8, 101u8, 181u8, 33u8, + 254u8, 131u8, 13u8, 143u8, 3u8, 244u8, 245u8, 45u8, 2u8, 210u8, 79u8, + 133u8, + ], + ) + } + #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] + #[doc = " of events in the `>` list."] + #[doc = ""] + #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] + #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] + #[doc = " in case of changes fetch the list of events of interest."] + #[doc = ""] + #[doc = " The value has the type `(BlockNumberFor, EventIndex)` because if we used only just"] + #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] + #[doc = " no notification will be triggered thus the event might be lost."] + pub fn event_topics_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "System", + "EventTopics", + vec![], + [ + 40u8, 225u8, 14u8, 75u8, 44u8, 176u8, 76u8, 34u8, 143u8, 107u8, 69u8, + 133u8, 114u8, 13u8, 172u8, 250u8, 141u8, 73u8, 12u8, 65u8, 217u8, 63u8, + 120u8, 241u8, 48u8, 106u8, 143u8, 161u8, 128u8, 100u8, 166u8, 59u8, + ], + ) + } + #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] + #[doc = " of events in the `>` list."] + #[doc = ""] + #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] + #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] + #[doc = " in case of changes fetch the list of events of interest."] + #[doc = ""] + #[doc = " The value has the type `(BlockNumberFor, EventIndex)` because if we used only just"] + #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] + #[doc = " no notification will be triggered thus the event might be lost."] + pub fn event_topics( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "EventTopics", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 40u8, 225u8, 14u8, 75u8, 44u8, 176u8, 76u8, 34u8, 143u8, 107u8, 69u8, + 133u8, 114u8, 13u8, 172u8, 250u8, 141u8, 73u8, 12u8, 65u8, 217u8, 63u8, + 120u8, 241u8, 48u8, 106u8, 143u8, 161u8, 128u8, 100u8, 166u8, 59u8, + ], + ) + } + #[doc = " Stores the `spec_version` and `spec_name` of when the last runtime upgrade happened."] + pub fn last_runtime_upgrade( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::LastRuntimeUpgradeInfo, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "LastRuntimeUpgrade", + vec![], + [ + 137u8, 29u8, 175u8, 75u8, 197u8, 208u8, 91u8, 207u8, 156u8, 87u8, + 148u8, 68u8, 91u8, 140u8, 22u8, 233u8, 1u8, 229u8, 56u8, 34u8, 40u8, + 194u8, 253u8, 30u8, 163u8, 39u8, 54u8, 209u8, 13u8, 27u8, 139u8, 184u8, + ], + ) + } + #[doc = " True if we have upgraded so that `type RefCount` is `u32`. False (default) if not."] + pub fn upgraded_to_u32_ref_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "UpgradedToU32RefCount", + vec![], + [ + 229u8, 73u8, 9u8, 132u8, 186u8, 116u8, 151u8, 171u8, 145u8, 29u8, 34u8, + 130u8, 52u8, 146u8, 124u8, 175u8, 79u8, 189u8, 147u8, 230u8, 234u8, + 107u8, 124u8, 31u8, 2u8, 22u8, 86u8, 190u8, 4u8, 147u8, 50u8, 245u8, + ], + ) + } + #[doc = " True if we have upgraded so that AccountInfo contains three types of `RefCount`. False"] + #[doc = " (default) if not."] + pub fn upgraded_to_triple_ref_count( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "UpgradedToTripleRefCount", + vec![], + [ + 97u8, 66u8, 124u8, 243u8, 27u8, 167u8, 147u8, 81u8, 254u8, 201u8, + 101u8, 24u8, 40u8, 231u8, 14u8, 179u8, 154u8, 163u8, 71u8, 81u8, 185u8, + 167u8, 82u8, 254u8, 189u8, 3u8, 101u8, 207u8, 206u8, 194u8, 155u8, + 151u8, + ], + ) + } + #[doc = " The execution phase of the block."] + pub fn execution_phase( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::Phase, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "ExecutionPhase", + vec![], + [ + 191u8, 129u8, 100u8, 134u8, 126u8, 116u8, 154u8, 203u8, 220u8, 200u8, + 0u8, 26u8, 161u8, 250u8, 133u8, 205u8, 146u8, 24u8, 5u8, 156u8, 158u8, + 35u8, 36u8, 253u8, 52u8, 235u8, 86u8, 167u8, 35u8, 100u8, 119u8, 27u8, + ], + ) + } + #[doc = " `Some` if a code upgrade has been authorized."] + pub fn authorized_upgrade( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::frame_system::CodeUpgradeAuthorization, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "System", + "AuthorizedUpgrade", + vec![], + [ + 165u8, 97u8, 27u8, 138u8, 2u8, 28u8, 55u8, 92u8, 96u8, 96u8, 168u8, + 169u8, 55u8, 178u8, 44u8, 127u8, 58u8, 140u8, 206u8, 178u8, 1u8, 37u8, + 214u8, 213u8, 251u8, 123u8, 5u8, 111u8, 90u8, 148u8, 217u8, 135u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Block & extrinsics weights: base values and limits."] + pub fn block_weights( + &self, + ) -> ::subxt::constants::Address + { + ::subxt::constants::Address::new_static( + "System", + "BlockWeights", + [ + 176u8, 124u8, 225u8, 136u8, 25u8, 73u8, 247u8, 33u8, 82u8, 206u8, 85u8, + 190u8, 127u8, 102u8, 71u8, 11u8, 185u8, 8u8, 58u8, 0u8, 94u8, 55u8, + 163u8, 177u8, 104u8, 59u8, 60u8, 136u8, 246u8, 116u8, 0u8, 239u8, + ], + ) + } + #[doc = " The maximum length of a block (in bytes)."] + pub fn block_length( + &self, + ) -> ::subxt::constants::Address { + ::subxt::constants::Address::new_static( + "System", + "BlockLength", + [ + 23u8, 242u8, 225u8, 39u8, 225u8, 67u8, 152u8, 41u8, 155u8, 104u8, 68u8, + 229u8, 185u8, 133u8, 10u8, 143u8, 184u8, 152u8, 234u8, 44u8, 140u8, + 96u8, 166u8, 235u8, 162u8, 160u8, 72u8, 7u8, 35u8, 194u8, 3u8, 37u8, + ], + ) + } + #[doc = " Maximum number of block number to block hash mappings to keep (oldest pruned first)."] + pub fn block_hash_count( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "System", + "BlockHashCount", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The weight of runtime database operations the runtime can invoke."] + pub fn db_weight( + &self, + ) -> ::subxt::constants::Address { + ::subxt::constants::Address::new_static( + "System", + "DbWeight", + [ + 42u8, 43u8, 178u8, 142u8, 243u8, 203u8, 60u8, 173u8, 118u8, 111u8, + 200u8, 170u8, 102u8, 70u8, 237u8, 187u8, 198u8, 120u8, 153u8, 232u8, + 183u8, 76u8, 74u8, 10u8, 70u8, 243u8, 14u8, 218u8, 213u8, 126u8, 29u8, + 177u8, + ], + ) + } + #[doc = " Get the chain's current version."] + pub fn version( + &self, + ) -> ::subxt::constants::Address { + ::subxt::constants::Address::new_static( + "System", + "Version", + [ + 219u8, 45u8, 162u8, 245u8, 177u8, 246u8, 48u8, 126u8, 191u8, 157u8, + 228u8, 83u8, 111u8, 133u8, 183u8, 13u8, 148u8, 108u8, 92u8, 102u8, + 72u8, 205u8, 74u8, 242u8, 233u8, 79u8, 20u8, 170u8, 72u8, 202u8, 158u8, + 165u8, + ], + ) + } + #[doc = " The designated SS58 prefix of this chain."] + #[doc = ""] + #[doc = " This replaces the \"ss58Format\" property declared in the chain spec. Reason is"] + #[doc = " that the runtime should know about the prefix in order to make use of it as"] + #[doc = " an identifier of the chain."] + pub fn ss58_prefix(&self) -> ::subxt::constants::Address<::core::primitive::u16> { + ::subxt::constants::Address::new_static( + "System", + "SS58Prefix", + [ + 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, + 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, + 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, + ], + ) + } + } + } + } + pub mod parachain_system { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::cumulus_pallet_parachain_system::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::cumulus_pallet_parachain_system::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetValidationData { + pub data: + runtime_types::cumulus_primitives_parachain_inherent::ParachainInherentData, + } + impl ::subxt::blocks::StaticExtrinsic for SetValidationData { + const PALLET: &'static str = "ParachainSystem"; + const CALL: &'static str = "set_validation_data"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SudoSendUpwardMessage { + pub message: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::blocks::StaticExtrinsic for SudoSendUpwardMessage { + const PALLET: &'static str = "ParachainSystem"; + const CALL: &'static str = "sudo_send_upward_message"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AuthorizeUpgrade { + pub code_hash: ::subxt::utils::H256, + pub check_version: ::core::primitive::bool, + } + impl ::subxt::blocks::StaticExtrinsic for AuthorizeUpgrade { + const PALLET: &'static str = "ParachainSystem"; + const CALL: &'static str = "authorize_upgrade"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct EnactAuthorizedUpgrade { + pub code: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::blocks::StaticExtrinsic for EnactAuthorizedUpgrade { + const PALLET: &'static str = "ParachainSystem"; + const CALL: &'static str = "enact_authorized_upgrade"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::set_validation_data`]."] + pub fn set_validation_data( + &self, + data : runtime_types :: cumulus_primitives_parachain_inherent :: ParachainInherentData, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ParachainSystem", + "set_validation_data", + types::SetValidationData { data }, + [ + 167u8, 126u8, 75u8, 137u8, 220u8, 60u8, 106u8, 214u8, 92u8, 170u8, + 136u8, 176u8, 98u8, 0u8, 234u8, 217u8, 146u8, 113u8, 149u8, 88u8, + 114u8, 141u8, 228u8, 105u8, 136u8, 71u8, 233u8, 18u8, 70u8, 36u8, 24u8, + 249u8, + ], + ) + } + #[doc = "See [`Pallet::sudo_send_upward_message`]."] + pub fn sudo_send_upward_message( + &self, + message: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ParachainSystem", + "sudo_send_upward_message", + types::SudoSendUpwardMessage { message }, + [ + 1u8, 231u8, 11u8, 78u8, 127u8, 117u8, 248u8, 67u8, 230u8, 199u8, 126u8, + 47u8, 20u8, 62u8, 252u8, 138u8, 199u8, 48u8, 41u8, 21u8, 28u8, 157u8, + 218u8, 143u8, 4u8, 253u8, 62u8, 192u8, 94u8, 252u8, 92u8, 180u8, + ], + ) + } + #[doc = "See [`Pallet::authorize_upgrade`]."] + pub fn authorize_upgrade( + &self, + code_hash: ::subxt::utils::H256, + check_version: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ParachainSystem", + "authorize_upgrade", + types::AuthorizeUpgrade { code_hash, check_version }, + [ + 213u8, 114u8, 107u8, 169u8, 223u8, 147u8, 205u8, 204u8, 3u8, 81u8, + 228u8, 0u8, 82u8, 57u8, 43u8, 95u8, 12u8, 59u8, 241u8, 176u8, 143u8, + 131u8, 253u8, 166u8, 98u8, 187u8, 94u8, 235u8, 177u8, 110u8, 162u8, + 218u8, + ], + ) + } + #[doc = "See [`Pallet::enact_authorized_upgrade`]."] + pub fn enact_authorized_upgrade( + &self, + code: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "ParachainSystem", + "enact_authorized_upgrade", + types::EnactAuthorizedUpgrade { code }, + [ + 232u8, 135u8, 114u8, 87u8, 196u8, 146u8, 244u8, 19u8, 106u8, 73u8, + 88u8, 193u8, 48u8, 14u8, 72u8, 133u8, 247u8, 147u8, 50u8, 95u8, 252u8, + 213u8, 192u8, 47u8, 244u8, 102u8, 195u8, 120u8, 179u8, 87u8, 94u8, 8u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::cumulus_pallet_parachain_system::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The validation function has been scheduled to apply."] + pub struct ValidationFunctionStored; + impl ::subxt::events::StaticEvent for ValidationFunctionStored { + const PALLET: &'static str = "ParachainSystem"; + const EVENT: &'static str = "ValidationFunctionStored"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The validation function was applied as of the contained relay chain block number."] + pub struct ValidationFunctionApplied { + pub relay_chain_block_num: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for ValidationFunctionApplied { + const PALLET: &'static str = "ParachainSystem"; + const EVENT: &'static str = "ValidationFunctionApplied"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The relay-chain aborted the upgrade process."] + pub struct ValidationFunctionDiscarded; + impl ::subxt::events::StaticEvent for ValidationFunctionDiscarded { + const PALLET: &'static str = "ParachainSystem"; + const EVENT: &'static str = "ValidationFunctionDiscarded"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some downward messages have been received and will be processed."] + pub struct DownwardMessagesReceived { + pub count: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for DownwardMessagesReceived { + const PALLET: &'static str = "ParachainSystem"; + const EVENT: &'static str = "DownwardMessagesReceived"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Downward messages were processed using the given weight."] + pub struct DownwardMessagesProcessed { + pub weight_used: runtime_types::sp_weights::weight_v2::Weight, + pub dmq_head: ::subxt::utils::H256, + } + impl ::subxt::events::StaticEvent for DownwardMessagesProcessed { + const PALLET: &'static str = "ParachainSystem"; + const EVENT: &'static str = "DownwardMessagesProcessed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An upward message was sent to the relay chain."] + pub struct UpwardMessageSent { + pub message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, + } + impl ::subxt::events::StaticEvent for UpwardMessageSent { + const PALLET: &'static str = "ParachainSystem"; + const EVENT: &'static str = "UpwardMessageSent"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Latest included block descendants the runtime accepted. In other words, these are"] + #[doc = " ancestors of the currently executing block which have not been included in the observed"] + #[doc = " relay-chain state."] + #[doc = ""] + #[doc = " The segment length is limited by the capacity returned from the [`ConsensusHook`] configured"] + #[doc = " in the pallet."] pub fn unincluded_segment (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: Ancestor < :: subxt :: utils :: H256 > > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "UnincludedSegment", + vec![], + [ + 73u8, 83u8, 226u8, 16u8, 203u8, 233u8, 221u8, 109u8, 23u8, 114u8, 56u8, + 154u8, 100u8, 116u8, 253u8, 10u8, 164u8, 22u8, 110u8, 73u8, 245u8, + 226u8, 54u8, 146u8, 67u8, 109u8, 149u8, 142u8, 154u8, 218u8, 55u8, + 178u8, + ], + ) + } + #[doc = " Storage field that keeps track of bandwidth used by the unincluded segment along with the"] + #[doc = " latest HRMP watermark. Used for limiting the acceptance of new blocks with"] + #[doc = " respect to relay chain constraints."] pub fn aggregated_unincluded_segment (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: SegmentTracker < :: subxt :: utils :: H256 > , :: subxt :: storage :: address :: Yes , () , () >{ + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "AggregatedUnincludedSegment", + vec![], + [ + 165u8, 51u8, 182u8, 156u8, 65u8, 114u8, 167u8, 133u8, 245u8, 52u8, + 32u8, 119u8, 159u8, 65u8, 201u8, 108u8, 99u8, 43u8, 84u8, 63u8, 95u8, + 182u8, 134u8, 163u8, 51u8, 202u8, 243u8, 82u8, 225u8, 192u8, 186u8, + 2u8, + ], + ) + } + #[doc = " In case of a scheduled upgrade, this storage field contains the validation code to be"] + #[doc = " applied."] + #[doc = ""] + #[doc = " As soon as the relay chain gives us the go-ahead signal, we will overwrite the"] + #[doc = " [`:code`][sp_core::storage::well_known_keys::CODE] which will result the next block process"] + #[doc = " with the new validation code. This concludes the upgrade process."] + pub fn pending_validation_code( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "PendingValidationCode", + vec![], + [ + 78u8, 159u8, 219u8, 211u8, 177u8, 80u8, 102u8, 93u8, 83u8, 146u8, 90u8, + 233u8, 232u8, 11u8, 104u8, 172u8, 93u8, 68u8, 44u8, 228u8, 99u8, 197u8, + 254u8, 28u8, 181u8, 215u8, 247u8, 238u8, 49u8, 49u8, 195u8, 249u8, + ], + ) + } + #[doc = " Validation code that is set by the parachain and is to be communicated to collator and"] + #[doc = " consequently the relay-chain."] + #[doc = ""] + #[doc = " This will be cleared in `on_initialize` of each new block if no other pallet already set"] + #[doc = " the value."] + pub fn new_validation_code( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "NewValidationCode", + vec![], + [ + 185u8, 123u8, 152u8, 122u8, 230u8, 136u8, 79u8, 73u8, 206u8, 19u8, + 59u8, 57u8, 75u8, 250u8, 83u8, 185u8, 29u8, 76u8, 89u8, 137u8, 77u8, + 163u8, 25u8, 125u8, 182u8, 67u8, 2u8, 180u8, 48u8, 237u8, 49u8, 171u8, + ], + ) + } + #[doc = " The [`PersistedValidationData`] set for this block."] + #[doc = " This value is expected to be set only once per block and it's never stored"] + #[doc = " in the trie."] + pub fn validation_data( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v6::PersistedValidationData< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "ValidationData", + vec![], + [ + 193u8, 240u8, 25u8, 56u8, 103u8, 173u8, 56u8, 56u8, 229u8, 243u8, 91u8, + 25u8, 249u8, 95u8, 122u8, 93u8, 37u8, 181u8, 54u8, 244u8, 217u8, 200u8, + 62u8, 136u8, 80u8, 148u8, 16u8, 177u8, 124u8, 211u8, 95u8, 24u8, + ], + ) + } + #[doc = " Were the validation data set to notify the relay chain?"] + pub fn did_set_validation_code( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "DidSetValidationCode", + vec![], + [ + 233u8, 228u8, 48u8, 111u8, 200u8, 35u8, 30u8, 139u8, 251u8, 77u8, + 196u8, 252u8, 35u8, 222u8, 129u8, 235u8, 7u8, 19u8, 156u8, 82u8, 126u8, + 173u8, 29u8, 62u8, 20u8, 67u8, 166u8, 116u8, 108u8, 182u8, 57u8, 246u8, + ], + ) + } + #[doc = " The relay chain block number associated with the last parachain block."] + #[doc = ""] + #[doc = " This is updated in `on_finalize`."] + pub fn last_relay_chain_block_number( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "LastRelayChainBlockNumber", + vec![], + [ + 17u8, 65u8, 131u8, 169u8, 195u8, 243u8, 195u8, 93u8, 220u8, 174u8, + 75u8, 216u8, 214u8, 227u8, 96u8, 40u8, 8u8, 153u8, 116u8, 160u8, 79u8, + 255u8, 35u8, 232u8, 242u8, 42u8, 100u8, 150u8, 208u8, 210u8, 142u8, + 186u8, + ], + ) + } + #[doc = " An option which indicates if the relay-chain restricts signalling a validation code upgrade."] + #[doc = " In other words, if this is `Some` and [`NewValidationCode`] is `Some` then the produced"] + #[doc = " candidate will be invalid."] + #[doc = ""] + #[doc = " This storage item is a mirror of the corresponding value for the current parachain from the"] + #[doc = " relay-chain. This value is ephemeral which means it doesn't hit the storage. This value is"] + #[doc = " set after the inherent."] + pub fn upgrade_restriction_signal( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::option::Option< + runtime_types::polkadot_primitives::v6::UpgradeRestriction, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "UpgradeRestrictionSignal", + vec![], + [ + 235u8, 240u8, 37u8, 44u8, 181u8, 52u8, 7u8, 216u8, 20u8, 139u8, 69u8, + 124u8, 21u8, 173u8, 237u8, 64u8, 105u8, 88u8, 49u8, 69u8, 123u8, 55u8, + 181u8, 167u8, 112u8, 183u8, 190u8, 231u8, 231u8, 127u8, 77u8, 148u8, + ], + ) + } + #[doc = " Optional upgrade go-ahead signal from the relay-chain."] + #[doc = ""] + #[doc = " This storage item is a mirror of the corresponding value for the current parachain from the"] + #[doc = " relay-chain. This value is ephemeral which means it doesn't hit the storage. This value is"] + #[doc = " set after the inherent."] + pub fn upgrade_go_ahead( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::option::Option, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "UpgradeGoAhead", + vec![], + [ + 149u8, 144u8, 186u8, 88u8, 180u8, 34u8, 82u8, 226u8, 100u8, 148u8, + 246u8, 55u8, 233u8, 97u8, 43u8, 0u8, 48u8, 31u8, 69u8, 154u8, 29u8, + 147u8, 241u8, 91u8, 81u8, 126u8, 206u8, 117u8, 14u8, 149u8, 87u8, 88u8, + ], + ) + } + #[doc = " The state proof for the last relay parent block."] + #[doc = ""] + #[doc = " This field is meant to be updated each block with the validation data inherent. Therefore,"] + #[doc = " before processing of the inherent, e.g. in `on_initialize` this data may be stale."] + #[doc = ""] + #[doc = " This data is also absent from the genesis."] + pub fn relay_state_proof( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_trie::storage_proof::StorageProof, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "RelayStateProof", + vec![], + [ + 46u8, 115u8, 163u8, 190u8, 246u8, 47u8, 200u8, 159u8, 206u8, 204u8, + 94u8, 250u8, 127u8, 112u8, 109u8, 111u8, 210u8, 195u8, 244u8, 41u8, + 36u8, 187u8, 71u8, 150u8, 149u8, 253u8, 143u8, 33u8, 83u8, 189u8, + 182u8, 238u8, + ], + ) + } + #[doc = " The snapshot of some state related to messaging relevant to the current parachain as per"] + #[doc = " the relay parent."] + #[doc = ""] + #[doc = " This field is meant to be updated each block with the validation data inherent. Therefore,"] + #[doc = " before processing of the inherent, e.g. in `on_initialize` this data may be stale."] + #[doc = ""] + #[doc = " This data is also absent from the genesis."] pub fn relevant_messaging_state (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: cumulus_pallet_parachain_system :: relay_state_snapshot :: MessagingStateSnapshot , :: subxt :: storage :: address :: Yes , () , () >{ + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "RelevantMessagingState", + vec![], + [ + 117u8, 166u8, 186u8, 126u8, 21u8, 174u8, 86u8, 253u8, 163u8, 90u8, + 54u8, 226u8, 186u8, 253u8, 126u8, 168u8, 145u8, 45u8, 155u8, 32u8, + 97u8, 110u8, 208u8, 125u8, 47u8, 113u8, 165u8, 199u8, 210u8, 118u8, + 217u8, 73u8, + ], + ) + } + #[doc = " The parachain host configuration that was obtained from the relay parent."] + #[doc = ""] + #[doc = " This field is meant to be updated each block with the validation data inherent. Therefore,"] + #[doc = " before processing of the inherent, e.g. in `on_initialize` this data may be stale."] + #[doc = ""] + #[doc = " This data is also absent from the genesis."] + pub fn host_configuration( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_primitives::v6::AbridgedHostConfiguration, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "HostConfiguration", + vec![], + [ + 252u8, 23u8, 111u8, 189u8, 120u8, 204u8, 129u8, 223u8, 248u8, 179u8, + 239u8, 173u8, 133u8, 61u8, 140u8, 2u8, 75u8, 32u8, 204u8, 178u8, 69u8, + 21u8, 44u8, 227u8, 178u8, 179u8, 33u8, 26u8, 131u8, 156u8, 78u8, 85u8, + ], + ) + } + #[doc = " The last downward message queue chain head we have observed."] + #[doc = ""] + #[doc = " This value is loaded before and saved after processing inbound downward messages carried"] + #[doc = " by the system inherent."] + pub fn last_dmq_mqc_head( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::cumulus_primitives_parachain_inherent::MessageQueueChain, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "LastDmqMqcHead", + vec![], + [ + 1u8, 70u8, 140u8, 40u8, 51u8, 127u8, 75u8, 80u8, 5u8, 49u8, 196u8, + 31u8, 30u8, 61u8, 54u8, 252u8, 0u8, 0u8, 100u8, 115u8, 177u8, 250u8, + 138u8, 48u8, 107u8, 41u8, 93u8, 87u8, 195u8, 107u8, 206u8, 227u8, + ], + ) + } + #[doc = " The message queue chain heads we have observed per each channel incoming channel."] + #[doc = ""] + #[doc = " This value is loaded before and saved after processing inbound downward messages carried"] + #[doc = " by the system inherent."] + pub fn last_hrmp_mqc_heads( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::KeyedVec< + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::cumulus_primitives_parachain_inherent::MessageQueueChain, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "LastHrmpMqcHeads", + vec![], + [ + 131u8, 170u8, 142u8, 30u8, 101u8, 113u8, 131u8, 81u8, 38u8, 168u8, + 98u8, 3u8, 9u8, 109u8, 96u8, 179u8, 115u8, 177u8, 128u8, 11u8, 238u8, + 54u8, 81u8, 60u8, 97u8, 112u8, 224u8, 175u8, 86u8, 133u8, 182u8, 76u8, + ], + ) + } + #[doc = " Number of downward messages processed in a block."] + #[doc = ""] + #[doc = " This will be cleared in `on_initialize` of each new block."] + pub fn processed_downward_messages( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "ProcessedDownwardMessages", + vec![], + [ + 151u8, 234u8, 196u8, 87u8, 130u8, 79u8, 4u8, 102u8, 47u8, 10u8, 33u8, + 132u8, 149u8, 118u8, 61u8, 141u8, 5u8, 1u8, 30u8, 120u8, 220u8, 156u8, + 16u8, 11u8, 14u8, 52u8, 126u8, 151u8, 244u8, 149u8, 197u8, 51u8, + ], + ) + } + #[doc = " HRMP watermark that was set in a block."] + #[doc = ""] + #[doc = " This will be cleared in `on_initialize` of each new block."] + pub fn hrmp_watermark( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "HrmpWatermark", + vec![], + [ + 77u8, 62u8, 59u8, 220u8, 7u8, 125u8, 98u8, 249u8, 108u8, 212u8, 223u8, + 99u8, 152u8, 13u8, 29u8, 80u8, 166u8, 65u8, 232u8, 113u8, 145u8, 128u8, + 123u8, 35u8, 238u8, 31u8, 113u8, 156u8, 220u8, 104u8, 217u8, 165u8, + ], + ) + } + #[doc = " HRMP messages that were sent in a block."] + #[doc = ""] + #[doc = " This will be cleared in `on_initialize` of each new block."] + pub fn hrmp_outbound_messages( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::polkadot_core_primitives::OutboundHrmpMessage< + runtime_types::polkadot_parachain_primitives::primitives::Id, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "HrmpOutboundMessages", + vec![], + [ + 42u8, 9u8, 96u8, 217u8, 25u8, 101u8, 129u8, 147u8, 150u8, 20u8, 164u8, + 186u8, 217u8, 178u8, 15u8, 201u8, 233u8, 104u8, 92u8, 120u8, 29u8, + 245u8, 196u8, 13u8, 141u8, 210u8, 102u8, 62u8, 216u8, 80u8, 246u8, + 145u8, + ], + ) + } + #[doc = " Upward messages that were sent in a block."] + #[doc = ""] + #[doc = " This will be cleared in `on_initialize` of each new block."] + pub fn upward_messages( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "UpwardMessages", + vec![], + [ + 179u8, 127u8, 8u8, 94u8, 194u8, 246u8, 53u8, 79u8, 80u8, 22u8, 18u8, + 75u8, 116u8, 163u8, 90u8, 161u8, 30u8, 140u8, 57u8, 126u8, 60u8, 91u8, + 23u8, 30u8, 120u8, 245u8, 125u8, 96u8, 152u8, 25u8, 248u8, 85u8, + ], + ) + } + #[doc = " Upward messages that are still pending and not yet send to the relay chain."] + pub fn pending_upward_messages( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "PendingUpwardMessages", + vec![], + [ + 239u8, 45u8, 18u8, 173u8, 148u8, 150u8, 55u8, 176u8, 173u8, 156u8, + 246u8, 226u8, 198u8, 214u8, 104u8, 187u8, 186u8, 13u8, 83u8, 194u8, + 153u8, 29u8, 228u8, 109u8, 26u8, 18u8, 212u8, 151u8, 246u8, 24u8, + 133u8, 216u8, + ], + ) + } + #[doc = " The factor to multiply the base delivery fee by for UMP."] + pub fn upward_delivery_fee_factor( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::fixed_point::FixedU128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "UpwardDeliveryFeeFactor", + vec![], + [ + 40u8, 217u8, 164u8, 111u8, 151u8, 132u8, 69u8, 226u8, 163u8, 175u8, + 43u8, 239u8, 179u8, 217u8, 136u8, 161u8, 13u8, 251u8, 163u8, 102u8, + 24u8, 27u8, 168u8, 89u8, 221u8, 83u8, 93u8, 64u8, 96u8, 117u8, 146u8, + 71u8, + ], + ) + } + #[doc = " The number of HRMP messages we observed in `on_initialize` and thus used that number for"] + #[doc = " announcing the weight of `on_initialize` and `on_finalize`."] + pub fn announced_hrmp_messages_per_candidate( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "AnnouncedHrmpMessagesPerCandidate", + vec![], + [ + 93u8, 11u8, 229u8, 172u8, 73u8, 87u8, 13u8, 149u8, 15u8, 94u8, 163u8, + 107u8, 156u8, 22u8, 131u8, 177u8, 96u8, 247u8, 213u8, 224u8, 41u8, + 126u8, 157u8, 33u8, 154u8, 194u8, 95u8, 234u8, 65u8, 19u8, 58u8, 161u8, + ], + ) + } + #[doc = " The weight we reserve at the beginning of the block for processing XCMP messages. This"] + #[doc = " overrides the amount set in the Config trait."] + pub fn reserved_xcmp_weight_override( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_weights::weight_v2::Weight, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "ReservedXcmpWeightOverride", + vec![], + [ + 176u8, 93u8, 203u8, 74u8, 18u8, 170u8, 246u8, 203u8, 109u8, 89u8, 86u8, + 77u8, 96u8, 66u8, 189u8, 79u8, 184u8, 253u8, 11u8, 230u8, 87u8, 120u8, + 1u8, 254u8, 215u8, 41u8, 210u8, 86u8, 239u8, 206u8, 60u8, 2u8, + ], + ) + } + #[doc = " The weight we reserve at the beginning of the block for processing DMP messages. This"] + #[doc = " overrides the amount set in the Config trait."] + pub fn reserved_dmp_weight_override( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_weights::weight_v2::Weight, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "ReservedDmpWeightOverride", + vec![], + [ + 205u8, 124u8, 9u8, 156u8, 255u8, 207u8, 208u8, 23u8, 179u8, 132u8, + 254u8, 157u8, 237u8, 240u8, 167u8, 203u8, 253u8, 111u8, 136u8, 32u8, + 100u8, 152u8, 16u8, 19u8, 175u8, 14u8, 108u8, 61u8, 59u8, 231u8, 70u8, + 112u8, + ], + ) + } + #[doc = " A custom head data that should be returned as result of `validate_block`."] + #[doc = ""] + #[doc = " See `Pallet::set_custom_validation_head_data` for more information."] + pub fn custom_validation_head_data( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainSystem", + "CustomValidationHeadData", + vec![], + [ + 52u8, 186u8, 187u8, 57u8, 245u8, 171u8, 202u8, 23u8, 92u8, 80u8, 118u8, + 66u8, 251u8, 156u8, 175u8, 254u8, 141u8, 185u8, 115u8, 209u8, 170u8, + 165u8, 1u8, 242u8, 120u8, 234u8, 162u8, 24u8, 135u8, 105u8, 8u8, 177u8, + ], + ) + } + } + } + } + pub mod timestamp { + use super::root_mod; + use super::runtime_types; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_timestamp::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Set { + #[codec(compact)] + pub now: ::core::primitive::u64, + } + impl ::subxt::blocks::StaticExtrinsic for Set { + const PALLET: &'static str = "Timestamp"; + const CALL: &'static str = "set"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::set`]."] + pub fn set(&self, now: ::core::primitive::u64) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Timestamp", + "set", + types::Set { now }, + [ + 37u8, 95u8, 49u8, 218u8, 24u8, 22u8, 0u8, 95u8, 72u8, 35u8, 155u8, + 199u8, 213u8, 54u8, 207u8, 22u8, 185u8, 193u8, 221u8, 70u8, 18u8, + 200u8, 4u8, 231u8, 195u8, 173u8, 6u8, 122u8, 11u8, 203u8, 231u8, 227u8, + ], + ) + } + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The current time for the current block."] + pub fn now( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Timestamp", + "Now", + vec![], + [ + 44u8, 50u8, 80u8, 30u8, 195u8, 146u8, 123u8, 238u8, 8u8, 163u8, 187u8, + 92u8, 61u8, 39u8, 51u8, 29u8, 173u8, 169u8, 217u8, 158u8, 85u8, 187u8, + 141u8, 26u8, 12u8, 115u8, 51u8, 11u8, 200u8, 244u8, 138u8, 152u8, + ], + ) + } + #[doc = " Whether the timestamp has been updated in this block."] + #[doc = ""] + #[doc = " This value is updated to `true` upon successful submission of a timestamp by a node."] + #[doc = " It is then checked at the end of each block execution in the `on_finalize` hook."] + pub fn did_update( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Timestamp", + "DidUpdate", + vec![], + [ + 229u8, 175u8, 246u8, 102u8, 237u8, 158u8, 212u8, 229u8, 238u8, 214u8, + 205u8, 160u8, 164u8, 252u8, 195u8, 75u8, 139u8, 110u8, 22u8, 34u8, + 248u8, 204u8, 107u8, 46u8, 20u8, 200u8, 238u8, 167u8, 71u8, 41u8, + 214u8, 140u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The minimum period between blocks."] + #[doc = ""] + #[doc = " Be aware that this is different to the *expected* period that the block production"] + #[doc = " apparatus provides. Your chosen consensus system will generally work with this to"] + #[doc = " determine a sensible block time. For example, in the Aura pallet it will be double this"] + #[doc = " period on default settings."] + pub fn minimum_period( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u64> { + ::subxt::constants::Address::new_static( + "Timestamp", + "MinimumPeriod", + [ + 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, + 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, + 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, + 246u8, + ], + ) + } + } + } + } + pub mod parachain_info { + use super::root_mod; + use super::runtime_types; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::staging_parachain_info::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + } + pub struct TransactionApi; + impl TransactionApi {} + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + pub fn parachain_id( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::polkadot_parachain_primitives::primitives::Id, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "ParachainInfo", + "ParachainId", + vec![], + [ + 160u8, 130u8, 74u8, 181u8, 231u8, 180u8, 246u8, 152u8, 204u8, 44u8, + 245u8, 91u8, 113u8, 246u8, 218u8, 50u8, 254u8, 248u8, 35u8, 219u8, + 83u8, 144u8, 228u8, 245u8, 122u8, 53u8, 194u8, 172u8, 222u8, 118u8, + 202u8, 91u8, + ], + ) + } + } + } + } + pub mod balances { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::pallet_balances::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_balances::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TransferAllowDeath { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for TransferAllowDeath { + const PALLET: &'static str = "Balances"; + const CALL: &'static str = "transfer_allow_death"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceTransfer { + pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for ForceTransfer { + const PALLET: &'static str = "Balances"; + const CALL: &'static str = "force_transfer"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TransferKeepAlive { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub value: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for TransferKeepAlive { + const PALLET: &'static str = "Balances"; + const CALL: &'static str = "transfer_keep_alive"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TransferAll { + pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub keep_alive: ::core::primitive::bool, + } + impl ::subxt::blocks::StaticExtrinsic for TransferAll { + const PALLET: &'static str = "Balances"; + const CALL: &'static str = "transfer_all"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnreserve { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub amount: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for ForceUnreserve { + const PALLET: &'static str = "Balances"; + const CALL: &'static str = "force_unreserve"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpgradeAccounts { + pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + impl ::subxt::blocks::StaticExtrinsic for UpgradeAccounts { + const PALLET: &'static str = "Balances"; + const CALL: &'static str = "upgrade_accounts"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSetBalance { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + pub new_free: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for ForceSetBalance { + const PALLET: &'static str = "Balances"; + const CALL: &'static str = "force_set_balance"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceAdjustTotalIssuance { + pub direction: runtime_types::pallet_balances::types::AdjustmentDirection, + #[codec(compact)] + pub delta: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for ForceAdjustTotalIssuance { + const PALLET: &'static str = "Balances"; + const CALL: &'static str = "force_adjust_total_issuance"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::transfer_allow_death`]."] + pub fn transfer_allow_death( + &self, + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "transfer_allow_death", + types::TransferAllowDeath { dest, value }, + [ + 51u8, 166u8, 195u8, 10u8, 139u8, 218u8, 55u8, 130u8, 6u8, 194u8, 35u8, + 140u8, 27u8, 205u8, 214u8, 222u8, 102u8, 43u8, 143u8, 145u8, 86u8, + 219u8, 210u8, 147u8, 13u8, 39u8, 51u8, 21u8, 237u8, 179u8, 132u8, + 130u8, + ], + ) + } + #[doc = "See [`Pallet::force_transfer`]."] + pub fn force_transfer( + &self, + source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "force_transfer", + types::ForceTransfer { source, dest, value }, + [ + 154u8, 93u8, 222u8, 27u8, 12u8, 248u8, 63u8, 213u8, 224u8, 86u8, 250u8, + 153u8, 249u8, 102u8, 83u8, 160u8, 79u8, 125u8, 105u8, 222u8, 77u8, + 180u8, 90u8, 105u8, 81u8, 217u8, 60u8, 25u8, 213u8, 51u8, 185u8, 96u8, + ], + ) + } + #[doc = "See [`Pallet::transfer_keep_alive`]."] + pub fn transfer_keep_alive( + &self, + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + value: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "transfer_keep_alive", + types::TransferKeepAlive { dest, value }, + [ + 245u8, 14u8, 190u8, 193u8, 32u8, 210u8, 74u8, 92u8, 25u8, 182u8, 76u8, + 55u8, 247u8, 83u8, 114u8, 75u8, 143u8, 236u8, 117u8, 25u8, 54u8, 157u8, + 208u8, 207u8, 233u8, 89u8, 70u8, 161u8, 235u8, 242u8, 222u8, 59u8, + ], + ) + } + #[doc = "See [`Pallet::transfer_all`]."] + pub fn transfer_all( + &self, + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + keep_alive: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "transfer_all", + types::TransferAll { dest, keep_alive }, + [ + 105u8, 132u8, 49u8, 144u8, 195u8, 250u8, 34u8, 46u8, 213u8, 248u8, + 112u8, 188u8, 81u8, 228u8, 136u8, 18u8, 67u8, 172u8, 37u8, 38u8, 238u8, + 9u8, 34u8, 15u8, 67u8, 34u8, 148u8, 195u8, 223u8, 29u8, 154u8, 6u8, + ], + ) + } + #[doc = "See [`Pallet::force_unreserve`]."] + pub fn force_unreserve( + &self, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + amount: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "force_unreserve", + types::ForceUnreserve { who, amount }, + [ + 142u8, 151u8, 64u8, 205u8, 46u8, 64u8, 62u8, 122u8, 108u8, 49u8, 223u8, + 140u8, 120u8, 153u8, 35u8, 165u8, 187u8, 38u8, 157u8, 200u8, 123u8, + 199u8, 198u8, 168u8, 208u8, 159u8, 39u8, 134u8, 92u8, 103u8, 84u8, + 171u8, + ], + ) + } + #[doc = "See [`Pallet::upgrade_accounts`]."] + pub fn upgrade_accounts( + &self, + who: ::std::vec::Vec<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "upgrade_accounts", + types::UpgradeAccounts { who }, + [ + 66u8, 200u8, 179u8, 104u8, 65u8, 2u8, 101u8, 56u8, 130u8, 161u8, 224u8, + 233u8, 255u8, 124u8, 70u8, 122u8, 8u8, 49u8, 103u8, 178u8, 68u8, 47u8, + 214u8, 166u8, 217u8, 116u8, 178u8, 50u8, 212u8, 164u8, 98u8, 226u8, + ], + ) + } + #[doc = "See [`Pallet::force_set_balance`]."] + pub fn force_set_balance( + &self, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + new_free: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "force_set_balance", + types::ForceSetBalance { who, new_free }, + [ + 114u8, 229u8, 59u8, 204u8, 180u8, 83u8, 17u8, 4u8, 59u8, 4u8, 55u8, + 39u8, 151u8, 196u8, 124u8, 60u8, 209u8, 65u8, 193u8, 11u8, 44u8, 164u8, + 116u8, 93u8, 169u8, 30u8, 199u8, 165u8, 55u8, 231u8, 223u8, 43u8, + ], + ) + } + #[doc = "See [`Pallet::force_adjust_total_issuance`]."] + pub fn force_adjust_total_issuance( + &self, + direction: runtime_types::pallet_balances::types::AdjustmentDirection, + delta: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Balances", + "force_adjust_total_issuance", + types::ForceAdjustTotalIssuance { direction, delta }, + [ + 208u8, 134u8, 56u8, 133u8, 232u8, 164u8, 10u8, 213u8, 53u8, 193u8, + 190u8, 63u8, 236u8, 186u8, 96u8, 122u8, 104u8, 87u8, 173u8, 38u8, 58u8, + 176u8, 21u8, 78u8, 42u8, 106u8, 46u8, 248u8, 251u8, 190u8, 150u8, + 202u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_balances::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was created with some free balance."] + pub struct Endowed { + pub account: ::subxt::utils::AccountId32, + pub free_balance: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Endowed { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Endowed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] + #[doc = "resulting in an outright loss."] + pub struct DustLost { + pub account: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for DustLost { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "DustLost"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Transfer succeeded."] + pub struct Transfer { + pub from: ::subxt::utils::AccountId32, + pub to: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Transfer { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Transfer"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A balance was set by root."] + pub struct BalanceSet { + pub who: ::subxt::utils::AccountId32, + pub free: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for BalanceSet { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "BalanceSet"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was reserved (moved from free to reserved)."] + pub struct Reserved { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Reserved { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Reserved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was unreserved (moved from reserved to free)."] + pub struct Unreserved { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Unreserved { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Unreserved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was moved from the reserve of the first account to the second account."] + #[doc = "Final argument indicates the destination balance type."] + pub struct ReserveRepatriated { + pub from: ::subxt::utils::AccountId32, + pub to: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + pub destination_status: + runtime_types::frame_support::traits::tokens::misc::BalanceStatus, + } + impl ::subxt::events::StaticEvent for ReserveRepatriated { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "ReserveRepatriated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was deposited (e.g. for transaction fees)."] + pub struct Deposit { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Deposit { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Deposit"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] + pub struct Withdraw { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Withdraw { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Withdraw"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] + pub struct Slashed { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Slashed { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Slashed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was minted into an account."] + pub struct Minted { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Minted { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Minted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was burned from an account."] + pub struct Burned { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Burned { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Burned"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was suspended from an account (it can be restored later)."] + pub struct Suspended { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Suspended { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Suspended"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some amount was restored into an account."] + pub struct Restored { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Restored { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Restored"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was upgraded."] + pub struct Upgraded { + pub who: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Upgraded { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Upgraded"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] + pub struct Issued { + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Issued { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Issued"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] + pub struct Rescinded { + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Rescinded { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Rescinded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was locked."] + pub struct Locked { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Locked { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Locked"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was unlocked."] + pub struct Unlocked { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Unlocked { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Unlocked"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was frozen."] + pub struct Frozen { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Frozen { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Frozen"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some balance was thawed."] + pub struct Thawed { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for Thawed { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "Thawed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `TotalIssuance` was forcefully changed."] + pub struct TotalIssuanceForced { + pub old: ::core::primitive::u128, + pub new: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for TotalIssuanceForced { + const PALLET: &'static str = "Balances"; + const EVENT: &'static str = "TotalIssuanceForced"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The total units issued in the system."] + pub fn total_issuance( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "TotalIssuance", + vec![], + [ + 116u8, 70u8, 119u8, 194u8, 69u8, 37u8, 116u8, 206u8, 171u8, 70u8, + 171u8, 210u8, 226u8, 111u8, 184u8, 204u8, 206u8, 11u8, 68u8, 72u8, + 255u8, 19u8, 194u8, 11u8, 27u8, 194u8, 81u8, 204u8, 59u8, 224u8, 202u8, + 185u8, + ], + ) + } + #[doc = " The total units of outstanding deactivated balance in the system."] + pub fn inactive_issuance( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "InactiveIssuance", + vec![], + [ + 212u8, 185u8, 19u8, 50u8, 250u8, 72u8, 173u8, 50u8, 4u8, 104u8, 161u8, + 249u8, 77u8, 247u8, 204u8, 248u8, 11u8, 18u8, 57u8, 4u8, 82u8, 110u8, + 30u8, 216u8, 16u8, 37u8, 87u8, 67u8, 189u8, 235u8, 214u8, 155u8, + ], + ) + } + #[doc = " The Balances pallet example of storing the balance of an account."] + #[doc = ""] + #[doc = " # Example"] + #[doc = ""] + #[doc = " ```nocompile"] + #[doc = " impl pallet_balances::Config for Runtime {"] + #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] + #[doc = " }"] + #[doc = " ```"] + #[doc = ""] + #[doc = " You can also store the balance of an account in the `System` pallet."] + #[doc = ""] + #[doc = " # Example"] + #[doc = ""] + #[doc = " ```nocompile"] + #[doc = " impl pallet_balances::Config for Runtime {"] + #[doc = " type AccountStore = System"] + #[doc = " }"] + #[doc = " ```"] + #[doc = ""] + #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] + #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] + #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] + #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] + pub fn account_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Account", + vec![], + [ + 213u8, 38u8, 200u8, 69u8, 218u8, 0u8, 112u8, 181u8, 160u8, 23u8, 96u8, + 90u8, 3u8, 88u8, 126u8, 22u8, 103u8, 74u8, 64u8, 69u8, 29u8, 247u8, + 18u8, 17u8, 234u8, 143u8, 189u8, 22u8, 247u8, 194u8, 154u8, 249u8, + ], + ) + } + #[doc = " The Balances pallet example of storing the balance of an account."] + #[doc = ""] + #[doc = " # Example"] + #[doc = ""] + #[doc = " ```nocompile"] + #[doc = " impl pallet_balances::Config for Runtime {"] + #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] + #[doc = " }"] + #[doc = " ```"] + #[doc = ""] + #[doc = " You can also store the balance of an account in the `System` pallet."] + #[doc = ""] + #[doc = " # Example"] + #[doc = ""] + #[doc = " ```nocompile"] + #[doc = " impl pallet_balances::Config for Runtime {"] + #[doc = " type AccountStore = System"] + #[doc = " }"] + #[doc = " ```"] + #[doc = ""] + #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] + #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] + #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] + #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] + pub fn account( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Account", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 213u8, 38u8, 200u8, 69u8, 218u8, 0u8, 112u8, 181u8, 160u8, 23u8, 96u8, + 90u8, 3u8, 88u8, 126u8, 22u8, 103u8, 74u8, 64u8, 69u8, 29u8, 247u8, + 18u8, 17u8, 234u8, 143u8, 189u8, 22u8, 247u8, 194u8, 154u8, 249u8, + ], + ) + } + #[doc = " Any liquidity locks on some account balances."] + #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] + pub fn locks_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Locks", + vec![], + [ + 10u8, 223u8, 55u8, 0u8, 249u8, 69u8, 168u8, 41u8, 75u8, 35u8, 120u8, + 167u8, 18u8, 132u8, 9u8, 20u8, 91u8, 51u8, 27u8, 69u8, 136u8, 187u8, + 13u8, 220u8, 163u8, 122u8, 26u8, 141u8, 174u8, 249u8, 85u8, 37u8, + ], + ) + } + #[doc = " Any liquidity locks on some account balances."] + #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] + pub fn locks( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Locks", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 10u8, 223u8, 55u8, 0u8, 249u8, 69u8, 168u8, 41u8, 75u8, 35u8, 120u8, + 167u8, 18u8, 132u8, 9u8, 20u8, 91u8, 51u8, 27u8, 69u8, 136u8, 187u8, + 13u8, 220u8, 163u8, 122u8, 26u8, 141u8, 174u8, 249u8, 85u8, 37u8, + ], + ) + } + #[doc = " Named reserves on some account balances."] + pub fn reserves_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::ReserveData< + [::core::primitive::u8; 8usize], + ::core::primitive::u128, + >, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Reserves", + vec![], + [ + 112u8, 10u8, 241u8, 77u8, 64u8, 187u8, 106u8, 159u8, 13u8, 153u8, + 140u8, 178u8, 182u8, 50u8, 1u8, 55u8, 149u8, 92u8, 196u8, 229u8, 170u8, + 106u8, 193u8, 88u8, 255u8, 244u8, 2u8, 193u8, 62u8, 235u8, 204u8, 91u8, + ], + ) + } + #[doc = " Named reserves on some account balances."] + pub fn reserves( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::ReserveData< + [::core::primitive::u8; 8usize], + ::core::primitive::u128, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Reserves", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 112u8, 10u8, 241u8, 77u8, 64u8, 187u8, 106u8, 159u8, 13u8, 153u8, + 140u8, 178u8, 182u8, 50u8, 1u8, 55u8, 149u8, 92u8, 196u8, 229u8, 170u8, + 106u8, 193u8, 88u8, 255u8, 244u8, 2u8, 193u8, 62u8, 235u8, 204u8, 91u8, + ], + ) + } + #[doc = " Holds on account balances."] + pub fn holds_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + runtime_types::coretime_rococo_runtime::RuntimeHoldReason, + ::core::primitive::u128, + >, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Holds", + vec![], + [ + 37u8, 176u8, 2u8, 18u8, 109u8, 26u8, 66u8, 81u8, 28u8, 104u8, 149u8, + 117u8, 119u8, 114u8, 196u8, 35u8, 172u8, 155u8, 66u8, 195u8, 98u8, + 37u8, 134u8, 22u8, 106u8, 221u8, 215u8, 97u8, 25u8, 28u8, 21u8, 206u8, + ], + ) + } + #[doc = " Holds on account balances."] + pub fn holds( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + runtime_types::coretime_rococo_runtime::RuntimeHoldReason, + ::core::primitive::u128, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Holds", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 37u8, 176u8, 2u8, 18u8, 109u8, 26u8, 66u8, 81u8, 28u8, 104u8, 149u8, + 117u8, 119u8, 114u8, 196u8, 35u8, 172u8, 155u8, 66u8, 195u8, 98u8, + 37u8, 134u8, 22u8, 106u8, 221u8, 215u8, 97u8, 25u8, 28u8, 21u8, 206u8, + ], + ) + } + #[doc = " Freeze locks on account balances."] + pub fn freezes_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Freezes", + vec![], + [ + 69u8, 49u8, 165u8, 76u8, 135u8, 142u8, 179u8, 118u8, 50u8, 109u8, 53u8, + 112u8, 110u8, 94u8, 30u8, 93u8, 173u8, 38u8, 27u8, 142u8, 19u8, 5u8, + 163u8, 4u8, 68u8, 218u8, 179u8, 224u8, 118u8, 218u8, 115u8, 64u8, + ], + ) + } + #[doc = " Freeze locks on account balances."] + pub fn freezes( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_balances::types::IdAmount< + (), + ::core::primitive::u128, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Balances", + "Freezes", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 69u8, 49u8, 165u8, 76u8, 135u8, 142u8, 179u8, 118u8, 50u8, 109u8, 53u8, + 112u8, 110u8, 94u8, 30u8, 93u8, 173u8, 38u8, 27u8, 142u8, 19u8, 5u8, + 163u8, 4u8, 68u8, 218u8, 179u8, 224u8, 118u8, 218u8, 115u8, 64u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The minimum amount required to keep an account open. MUST BE GREATER THAN ZERO!"] + #[doc = ""] + #[doc = " If you *really* need it to be zero, you can enable the feature `insecure_zero_ed` for"] + #[doc = " this pallet. However, you do so at your own risk: this will open up a major DoS vector."] + #[doc = " In case you have multiple sources of provider references, you may also get unexpected"] + #[doc = " behaviour if you set this to zero."] + #[doc = ""] + #[doc = " Bottom line: Do yourself a favour and make it at least one!"] + pub fn existential_deposit( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Balances", + "ExistentialDeposit", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The maximum number of locks that should exist on an account."] + #[doc = " Not strictly enforced, but used for weight estimation."] + pub fn max_locks(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxLocks", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of named reserves that can exist on an account."] + pub fn max_reserves(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxReserves", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of individual freeze locks that can exist on an account at any time."] + pub fn max_freezes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Balances", + "MaxFreezes", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod transaction_payment { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_transaction_payment::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] + #[doc = "has been paid by `who`."] + pub struct TransactionFeePaid { + pub who: ::subxt::utils::AccountId32, + pub actual_fee: ::core::primitive::u128, + pub tip: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for TransactionFeePaid { + const PALLET: &'static str = "TransactionPayment"; + const EVENT: &'static str = "TransactionFeePaid"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + pub fn next_fee_multiplier( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::fixed_point::FixedU128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "TransactionPayment", + "NextFeeMultiplier", + vec![], + [ + 247u8, 39u8, 81u8, 170u8, 225u8, 226u8, 82u8, 147u8, 34u8, 113u8, + 147u8, 213u8, 59u8, 80u8, 139u8, 35u8, 36u8, 196u8, 152u8, 19u8, 9u8, + 159u8, 176u8, 79u8, 249u8, 201u8, 170u8, 1u8, 129u8, 79u8, 146u8, + 197u8, + ], + ) + } + pub fn storage_version( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_transaction_payment::Releases, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "TransactionPayment", + "StorageVersion", + vec![], + [ + 105u8, 243u8, 158u8, 241u8, 159u8, 231u8, 253u8, 6u8, 4u8, 32u8, 85u8, + 178u8, 126u8, 31u8, 203u8, 134u8, 154u8, 38u8, 122u8, 155u8, 150u8, + 251u8, 174u8, 15u8, 74u8, 134u8, 216u8, 244u8, 168u8, 175u8, 158u8, + 144u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " A fee multiplier for `Operational` extrinsics to compute \"virtual tip\" to boost their"] + #[doc = " `priority`"] + #[doc = ""] + #[doc = " This value is multiplied by the `final_fee` to obtain a \"virtual tip\" that is later"] + #[doc = " added to a tip component in regular `priority` calculations."] + #[doc = " It means that a `Normal` transaction can front-run a similarly-sized `Operational`"] + #[doc = " extrinsic (with no tip), by including a tip value greater than the virtual tip."] + #[doc = ""] + #[doc = " ```rust,ignore"] + #[doc = " // For `Normal`"] + #[doc = " let priority = priority_calc(tip);"] + #[doc = ""] + #[doc = " // For `Operational`"] + #[doc = " let virtual_tip = (inclusion_fee + tip) * OperationalFeeMultiplier;"] + #[doc = " let priority = priority_calc(tip + virtual_tip);"] + #[doc = " ```"] + #[doc = ""] + #[doc = " Note that since we use `final_fee` the multiplier applies also to the regular `tip`"] + #[doc = " sent with the transaction. So, not only does the transaction get a priority bump based"] + #[doc = " on the `inclusion_fee`, but we also amplify the impact of tips applied to `Operational`"] + #[doc = " transactions."] + pub fn operational_fee_multiplier( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u8> { + ::subxt::constants::Address::new_static( + "TransactionPayment", + "OperationalFeeMultiplier", + [ + 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, + 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, + 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, + 165u8, + ], + ) + } + } + } + } + pub mod authorship { + use super::root_mod; + use super::runtime_types; + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Author of current block."] + pub fn author( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::AccountId32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Authorship", + "Author", + vec![], + [ + 247u8, 192u8, 118u8, 227u8, 47u8, 20u8, 203u8, 199u8, 216u8, 87u8, + 220u8, 50u8, 166u8, 61u8, 168u8, 213u8, 253u8, 62u8, 202u8, 199u8, + 61u8, 192u8, 237u8, 53u8, 22u8, 148u8, 164u8, 245u8, 99u8, 24u8, 146u8, + 18u8, + ], + ) + } + } + } + } + pub mod collator_selection { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::pallet_collator_selection::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_collator_selection::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetInvulnerables { + pub new: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + impl ::subxt::blocks::StaticExtrinsic for SetInvulnerables { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "set_invulnerables"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetDesiredCandidates { + pub max: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for SetDesiredCandidates { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "set_desired_candidates"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetCandidacyBond { + pub bond: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for SetCandidacyBond { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "set_candidacy_bond"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RegisterAsCandidate; + impl ::subxt::blocks::StaticExtrinsic for RegisterAsCandidate { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "register_as_candidate"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LeaveIntent; + impl ::subxt::blocks::StaticExtrinsic for LeaveIntent { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "leave_intent"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AddInvulnerable { + pub who: ::subxt::utils::AccountId32, + } + impl ::subxt::blocks::StaticExtrinsic for AddInvulnerable { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "add_invulnerable"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveInvulnerable { + pub who: ::subxt::utils::AccountId32, + } + impl ::subxt::blocks::StaticExtrinsic for RemoveInvulnerable { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "remove_invulnerable"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpdateBond { + pub new_deposit: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for UpdateBond { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "update_bond"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TakeCandidateSlot { + pub deposit: ::core::primitive::u128, + pub target: ::subxt::utils::AccountId32, + } + impl ::subxt::blocks::StaticExtrinsic for TakeCandidateSlot { + const PALLET: &'static str = "CollatorSelection"; + const CALL: &'static str = "take_candidate_slot"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::set_invulnerables`]."] + pub fn set_invulnerables( + &self, + new: ::std::vec::Vec<::subxt::utils::AccountId32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "set_invulnerables", + types::SetInvulnerables { new }, + [ + 113u8, 217u8, 14u8, 48u8, 6u8, 198u8, 8u8, 170u8, 8u8, 237u8, 230u8, + 184u8, 17u8, 181u8, 15u8, 126u8, 117u8, 3u8, 208u8, 215u8, 40u8, 16u8, + 150u8, 162u8, 37u8, 196u8, 235u8, 36u8, 247u8, 24u8, 187u8, 17u8, + ], + ) + } + #[doc = "See [`Pallet::set_desired_candidates`]."] + pub fn set_desired_candidates( + &self, + max: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "set_desired_candidates", + types::SetDesiredCandidates { max }, + [ + 174u8, 44u8, 232u8, 155u8, 228u8, 219u8, 239u8, 75u8, 86u8, 150u8, + 135u8, 214u8, 58u8, 9u8, 25u8, 133u8, 245u8, 101u8, 85u8, 246u8, 15u8, + 248u8, 165u8, 87u8, 88u8, 28u8, 10u8, 196u8, 86u8, 89u8, 28u8, 165u8, + ], + ) + } + #[doc = "See [`Pallet::set_candidacy_bond`]."] + pub fn set_candidacy_bond( + &self, + bond: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "set_candidacy_bond", + types::SetCandidacyBond { bond }, + [ + 250u8, 4u8, 185u8, 228u8, 101u8, 223u8, 49u8, 44u8, 172u8, 148u8, + 216u8, 242u8, 192u8, 88u8, 228u8, 59u8, 225u8, 222u8, 171u8, 40u8, + 23u8, 1u8, 46u8, 183u8, 189u8, 191u8, 156u8, 12u8, 218u8, 116u8, 76u8, + 59u8, + ], + ) + } + #[doc = "See [`Pallet::register_as_candidate`]."] + pub fn register_as_candidate( + &self, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "register_as_candidate", + types::RegisterAsCandidate {}, + [ + 69u8, 222u8, 214u8, 106u8, 105u8, 168u8, 82u8, 239u8, 158u8, 117u8, + 224u8, 89u8, 228u8, 51u8, 221u8, 244u8, 88u8, 63u8, 72u8, 119u8, 224u8, + 111u8, 93u8, 39u8, 18u8, 66u8, 72u8, 105u8, 70u8, 66u8, 178u8, 173u8, + ], + ) + } + #[doc = "See [`Pallet::leave_intent`]."] + pub fn leave_intent(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "leave_intent", + types::LeaveIntent {}, + [ + 126u8, 57u8, 10u8, 67u8, 120u8, 229u8, 70u8, 23u8, 154u8, 215u8, 226u8, + 178u8, 203u8, 152u8, 195u8, 177u8, 157u8, 158u8, 40u8, 17u8, 93u8, + 225u8, 253u8, 217u8, 48u8, 165u8, 55u8, 79u8, 43u8, 123u8, 193u8, + 147u8, + ], + ) + } + #[doc = "See [`Pallet::add_invulnerable`]."] + pub fn add_invulnerable( + &self, + who: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "add_invulnerable", + types::AddInvulnerable { who }, + [ + 115u8, 109u8, 38u8, 19u8, 81u8, 194u8, 124u8, 140u8, 239u8, 23u8, 85u8, + 62u8, 241u8, 83u8, 11u8, 241u8, 14u8, 34u8, 206u8, 63u8, 104u8, 78u8, + 96u8, 182u8, 173u8, 198u8, 230u8, 107u8, 102u8, 6u8, 164u8, 75u8, + ], + ) + } + #[doc = "See [`Pallet::remove_invulnerable`]."] + pub fn remove_invulnerable( + &self, + who: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "remove_invulnerable", + types::RemoveInvulnerable { who }, + [ + 103u8, 146u8, 23u8, 136u8, 61u8, 65u8, 172u8, 157u8, 216u8, 200u8, + 119u8, 28u8, 189u8, 215u8, 13u8, 100u8, 102u8, 13u8, 94u8, 12u8, 78u8, + 156u8, 149u8, 74u8, 126u8, 118u8, 127u8, 49u8, 129u8, 2u8, 12u8, 118u8, + ], + ) + } + #[doc = "See [`Pallet::update_bond`]."] + pub fn update_bond( + &self, + new_deposit: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "update_bond", + types::UpdateBond { new_deposit }, + [ + 47u8, 184u8, 193u8, 220u8, 160u8, 1u8, 253u8, 203u8, 8u8, 142u8, 43u8, + 151u8, 190u8, 138u8, 201u8, 174u8, 233u8, 112u8, 200u8, 247u8, 251u8, + 94u8, 23u8, 224u8, 150u8, 179u8, 190u8, 140u8, 199u8, 50u8, 2u8, 249u8, + ], + ) + } + #[doc = "See [`Pallet::take_candidate_slot`]."] + pub fn take_candidate_slot( + &self, + deposit: ::core::primitive::u128, + target: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "CollatorSelection", + "take_candidate_slot", + types::TakeCandidateSlot { deposit, target }, + [ + 48u8, 150u8, 189u8, 206u8, 199u8, 196u8, 173u8, 3u8, 206u8, 10u8, 50u8, + 160u8, 15u8, 53u8, 189u8, 126u8, 154u8, 36u8, 90u8, 66u8, 235u8, 12u8, + 107u8, 44u8, 117u8, 33u8, 207u8, 194u8, 251u8, 194u8, 224u8, 80u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_collator_selection::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "New Invulnerables were set."] + pub struct NewInvulnerables { + pub invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, + } + impl ::subxt::events::StaticEvent for NewInvulnerables { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "NewInvulnerables"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new Invulnerable was added."] + pub struct InvulnerableAdded { + pub account_id: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for InvulnerableAdded { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "InvulnerableAdded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An Invulnerable was removed."] + pub struct InvulnerableRemoved { + pub account_id: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for InvulnerableRemoved { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "InvulnerableRemoved"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The number of desired candidates was set."] + pub struct NewDesiredCandidates { + pub desired_candidates: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for NewDesiredCandidates { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "NewDesiredCandidates"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The candidacy bond was set."] + pub struct NewCandidacyBond { + pub bond_amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for NewCandidacyBond { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "NewCandidacyBond"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new candidate joined."] + pub struct CandidateAdded { + pub account_id: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for CandidateAdded { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "CandidateAdded"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Bond of a candidate updated."] + pub struct CandidateBondUpdated { + pub account_id: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for CandidateBondUpdated { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "CandidateBondUpdated"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A candidate was removed."] + pub struct CandidateRemoved { + pub account_id: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for CandidateRemoved { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "CandidateRemoved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was replaced in the candidate list by another one."] + pub struct CandidateReplaced { + pub old: ::subxt::utils::AccountId32, + pub new: ::subxt::utils::AccountId32, + pub deposit: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for CandidateReplaced { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "CandidateReplaced"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An account was unable to be added to the Invulnerables because they did not have keys"] + #[doc = "registered. Other Invulnerables may have been set."] + pub struct InvalidInvulnerableSkipped { + pub account_id: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for InvalidInvulnerableSkipped { + const PALLET: &'static str = "CollatorSelection"; + const EVENT: &'static str = "InvalidInvulnerableSkipped"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The invulnerable, permissioned collators. This list must be sorted."] + pub fn invulnerables( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::subxt::utils::AccountId32, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "CollatorSelection", + "Invulnerables", + vec![], + [ + 109u8, 180u8, 25u8, 41u8, 152u8, 158u8, 186u8, 214u8, 89u8, 222u8, + 103u8, 14u8, 91u8, 3u8, 65u8, 6u8, 255u8, 62u8, 47u8, 255u8, 132u8, + 164u8, 217u8, 200u8, 130u8, 29u8, 168u8, 23u8, 81u8, 217u8, 35u8, + 123u8, + ], + ) + } + #[doc = " The (community, limited) collation candidates. `Candidates` and `Invulnerables` should be"] + #[doc = " mutually exclusive."] + #[doc = ""] + #[doc = " This list is sorted in ascending order by deposit and when the deposits are equal, the least"] + #[doc = " recently updated is considered greater."] + pub fn candidate_list( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_collator_selection::pallet::CandidateInfo< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "CollatorSelection", + "CandidateList", + vec![], + [ + 77u8, 195u8, 89u8, 139u8, 79u8, 111u8, 151u8, 215u8, 19u8, 152u8, 67u8, + 49u8, 74u8, 76u8, 3u8, 60u8, 51u8, 140u8, 6u8, 134u8, 159u8, 55u8, + 196u8, 57u8, 189u8, 31u8, 219u8, 218u8, 164u8, 189u8, 196u8, 60u8, + ], + ) + } + #[doc = " Last block authored by collator."] + pub fn last_authored_block_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "CollatorSelection", + "LastAuthoredBlock", + vec![], + [ + 176u8, 170u8, 165u8, 244u8, 101u8, 126u8, 24u8, 132u8, 228u8, 138u8, + 72u8, 241u8, 144u8, 100u8, 79u8, 112u8, 9u8, 46u8, 210u8, 80u8, 12u8, + 126u8, 32u8, 214u8, 26u8, 171u8, 155u8, 3u8, 233u8, 22u8, 164u8, 25u8, + ], + ) + } + #[doc = " Last block authored by collator."] + pub fn last_authored_block( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "CollatorSelection", + "LastAuthoredBlock", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 176u8, 170u8, 165u8, 244u8, 101u8, 126u8, 24u8, 132u8, 228u8, 138u8, + 72u8, 241u8, 144u8, 100u8, 79u8, 112u8, 9u8, 46u8, 210u8, 80u8, 12u8, + 126u8, 32u8, 214u8, 26u8, 171u8, 155u8, 3u8, 233u8, 22u8, 164u8, 25u8, + ], + ) + } + #[doc = " Desired number of candidates."] + #[doc = ""] + #[doc = " This should ideally always be less than [`Config::MaxCandidates`] for weights to be correct."] + pub fn desired_candidates( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "CollatorSelection", + "DesiredCandidates", + vec![], + [ + 69u8, 199u8, 130u8, 132u8, 10u8, 127u8, 204u8, 220u8, 59u8, 107u8, + 96u8, 180u8, 42u8, 235u8, 14u8, 126u8, 231u8, 242u8, 162u8, 126u8, + 63u8, 223u8, 15u8, 250u8, 22u8, 210u8, 54u8, 34u8, 235u8, 191u8, 250u8, + 21u8, + ], + ) + } + #[doc = " Fixed amount to deposit to become a collator."] + #[doc = ""] + #[doc = " When a collator calls `leave_intent` they immediately receive the deposit back."] + pub fn candidacy_bond( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "CollatorSelection", + "CandidacyBond", + vec![], + [ + 71u8, 134u8, 156u8, 102u8, 201u8, 83u8, 240u8, 251u8, 189u8, 213u8, + 211u8, 182u8, 126u8, 122u8, 41u8, 174u8, 105u8, 29u8, 216u8, 23u8, + 255u8, 55u8, 245u8, 187u8, 234u8, 234u8, 178u8, 155u8, 145u8, 49u8, + 196u8, 214u8, + ], + ) + } + } + } + } + pub mod session { + use super::root_mod; + use super::runtime_types; + #[doc = "Error for the session pallet."] + pub type Error = runtime_types::pallet_session::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_session::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetKeys { + pub keys: runtime_types::coretime_rococo_runtime::SessionKeys, + pub proof: ::std::vec::Vec<::core::primitive::u8>, + } + impl ::subxt::blocks::StaticExtrinsic for SetKeys { + const PALLET: &'static str = "Session"; + const CALL: &'static str = "set_keys"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PurgeKeys; + impl ::subxt::blocks::StaticExtrinsic for PurgeKeys { + const PALLET: &'static str = "Session"; + const CALL: &'static str = "purge_keys"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::set_keys`]."] + pub fn set_keys( + &self, + keys: runtime_types::coretime_rococo_runtime::SessionKeys, + proof: ::std::vec::Vec<::core::primitive::u8>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Session", + "set_keys", + types::SetKeys { keys, proof }, + [ + 10u8, 183u8, 202u8, 82u8, 236u8, 202u8, 212u8, 220u8, 51u8, 217u8, + 229u8, 169u8, 238u8, 141u8, 129u8, 231u8, 203u8, 176u8, 97u8, 148u8, + 240u8, 87u8, 177u8, 245u8, 33u8, 109u8, 243u8, 52u8, 46u8, 118u8, + 164u8, 35u8, + ], + ) + } + #[doc = "See [`Pallet::purge_keys`]."] + pub fn purge_keys(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Session", + "purge_keys", + types::PurgeKeys {}, + [ + 215u8, 204u8, 146u8, 236u8, 32u8, 78u8, 198u8, 79u8, 85u8, 214u8, 15u8, + 151u8, 158u8, 31u8, 146u8, 119u8, 119u8, 204u8, 151u8, 169u8, 226u8, + 67u8, 217u8, 39u8, 241u8, 245u8, 203u8, 240u8, 203u8, 172u8, 16u8, + 209u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_session::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "New session has happened. Note that the argument is the session index, not the"] + #[doc = "block number as the type might suggest."] + pub struct NewSession { + pub session_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for NewSession { + const PALLET: &'static str = "Session"; + const EVENT: &'static str = "NewSession"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The current set of validators."] + pub fn validators( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::subxt::utils::AccountId32>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Session", + "Validators", + vec![], + [ + 50u8, 86u8, 154u8, 222u8, 249u8, 209u8, 156u8, 22u8, 155u8, 25u8, + 133u8, 194u8, 210u8, 50u8, 38u8, 28u8, 139u8, 201u8, 90u8, 139u8, + 115u8, 12u8, 12u8, 141u8, 4u8, 178u8, 201u8, 241u8, 223u8, 234u8, 6u8, + 86u8, + ], + ) + } + #[doc = " Current index of the session."] + pub fn current_index( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Session", + "CurrentIndex", + vec![], + [ + 167u8, 151u8, 125u8, 150u8, 159u8, 21u8, 78u8, 217u8, 237u8, 183u8, + 135u8, 65u8, 187u8, 114u8, 188u8, 206u8, 16u8, 32u8, 69u8, 208u8, + 134u8, 159u8, 232u8, 224u8, 243u8, 27u8, 31u8, 166u8, 145u8, 44u8, + 221u8, 230u8, + ], + ) + } + #[doc = " True if the underlying economic identities or weighting behind the validators"] + #[doc = " has changed in the queued validator set."] + pub fn queued_changed( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Session", + "QueuedChanged", + vec![], + [ + 184u8, 137u8, 224u8, 137u8, 31u8, 236u8, 95u8, 164u8, 102u8, 225u8, + 198u8, 227u8, 140u8, 37u8, 113u8, 57u8, 59u8, 4u8, 202u8, 102u8, 117u8, + 36u8, 226u8, 64u8, 113u8, 141u8, 199u8, 111u8, 99u8, 144u8, 198u8, + 153u8, + ], + ) + } + #[doc = " The queued keys for the next session. When the next session begins, these keys"] + #[doc = " will be used to determine the validator's session keys."] + pub fn queued_keys( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<( + ::subxt::utils::AccountId32, + runtime_types::coretime_rococo_runtime::SessionKeys, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Session", + "QueuedKeys", + vec![], + [ + 3u8, 214u8, 191u8, 168u8, 90u8, 94u8, 107u8, 111u8, 170u8, 31u8, 78u8, + 61u8, 240u8, 184u8, 170u8, 104u8, 178u8, 229u8, 159u8, 89u8, 207u8, + 37u8, 49u8, 209u8, 131u8, 165u8, 14u8, 169u8, 13u8, 68u8, 151u8, 144u8, + ], + ) + } + #[doc = " Indices of disabled validators."] + #[doc = ""] + #[doc = " The vec is always kept sorted so that we can find whether a given validator is"] + #[doc = " disabled using binary search. It gets cleared when `on_session_ending` returns"] + #[doc = " a new set of identities."] + pub fn disabled_validators( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u32>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Session", + "DisabledValidators", + vec![], + [ + 213u8, 19u8, 168u8, 234u8, 187u8, 200u8, 180u8, 97u8, 234u8, 189u8, + 36u8, 233u8, 158u8, 184u8, 45u8, 35u8, 129u8, 213u8, 133u8, 8u8, 104u8, + 183u8, 46u8, 68u8, 154u8, 240u8, 132u8, 22u8, 247u8, 11u8, 54u8, 221u8, + ], + ) + } + #[doc = " The next session keys for a validator."] + pub fn next_keys_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::coretime_rococo_runtime::SessionKeys, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Session", + "NextKeys", + vec![], + [ + 193u8, 216u8, 53u8, 103u8, 143u8, 241u8, 201u8, 54u8, 108u8, 149u8, + 241u8, 42u8, 3u8, 151u8, 223u8, 246u8, 30u8, 6u8, 239u8, 206u8, 27u8, + 172u8, 43u8, 226u8, 177u8, 111u8, 203u8, 78u8, 49u8, 34u8, 200u8, 6u8, + ], + ) + } + #[doc = " The next session keys for a validator."] + pub fn next_keys( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::coretime_rococo_runtime::SessionKeys, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Session", + "NextKeys", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 193u8, 216u8, 53u8, 103u8, 143u8, 241u8, 201u8, 54u8, 108u8, 149u8, + 241u8, 42u8, 3u8, 151u8, 223u8, 246u8, 30u8, 6u8, 239u8, 206u8, 27u8, + 172u8, 43u8, 226u8, 177u8, 111u8, 203u8, 78u8, 49u8, 34u8, 200u8, 6u8, + ], + ) + } + #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] + pub fn key_owner_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::AccountId32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Session", + "KeyOwner", + vec![], + [ + 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, + 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, + 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, + 206u8, + ], + ) + } + #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] + pub fn key_owner_iter1( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::AccountId32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Session", + "KeyOwner", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, + 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, + 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, + 206u8, + ], + ) + } + #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] + pub fn key_owner( + &self, + _0: impl ::std::borrow::Borrow, + _1: impl ::std::borrow::Borrow<[::core::primitive::u8]>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::AccountId32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Session", + "KeyOwner", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, + 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, + 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, + 206u8, + ], + ) + } + } + } + } + pub mod aura { + use super::root_mod; + use super::runtime_types; + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The current authority set."] + pub fn authorities( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::sp_consensus_aura::sr25519::app_sr25519::Public, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Aura", + "Authorities", + vec![], + [ + 232u8, 129u8, 167u8, 104u8, 47u8, 188u8, 238u8, 164u8, 6u8, 29u8, + 129u8, 45u8, 64u8, 182u8, 194u8, 47u8, 0u8, 73u8, 63u8, 102u8, 204u8, + 94u8, 111u8, 96u8, 137u8, 7u8, 141u8, 110u8, 180u8, 80u8, 228u8, 16u8, + ], + ) + } + #[doc = " The current slot of this block."] + #[doc = ""] + #[doc = " This will be set in `on_initialize`."] + pub fn current_slot( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_consensus_slots::Slot, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Aura", + "CurrentSlot", + vec![], + [ + 112u8, 199u8, 115u8, 248u8, 217u8, 242u8, 45u8, 231u8, 178u8, 53u8, + 236u8, 167u8, 219u8, 238u8, 81u8, 243u8, 39u8, 140u8, 68u8, 19u8, + 201u8, 169u8, 211u8, 133u8, 135u8, 213u8, 150u8, 105u8, 60u8, 252u8, + 43u8, 57u8, + ], + ) + } + } + } + } + pub mod aura_ext { + use super::root_mod; + use super::runtime_types; + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " Serves as cache for the authorities."] + #[doc = ""] + #[doc = " The authorities in AuRa are overwritten in `on_initialize` when we switch to a new session,"] + #[doc = " but we require the old authorities to verify the seal when validating a PoV. This will"] + #[doc = " always be updated to the latest AuRa authorities in `on_finalize`."] + pub fn authorities( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::sp_consensus_aura::sr25519::app_sr25519::Public, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "AuraExt", + "Authorities", + vec![], + [ + 232u8, 129u8, 167u8, 104u8, 47u8, 188u8, 238u8, 164u8, 6u8, 29u8, + 129u8, 45u8, 64u8, 182u8, 194u8, 47u8, 0u8, 73u8, 63u8, 102u8, 204u8, + 94u8, 111u8, 96u8, 137u8, 7u8, 141u8, 110u8, 180u8, 80u8, 228u8, 16u8, + ], + ) + } + #[doc = " Current slot paired with a number of authored blocks."] + #[doc = ""] + #[doc = " Updated on each block initialization."] + pub fn slot_info( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + (runtime_types::sp_consensus_slots::Slot, ::core::primitive::u32), + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "AuraExt", + "SlotInfo", + vec![], + [ + 135u8, 135u8, 71u8, 123u8, 102u8, 223u8, 215u8, 76u8, 183u8, 169u8, + 108u8, 60u8, 122u8, 5u8, 24u8, 201u8, 96u8, 59u8, 132u8, 95u8, 253u8, + 100u8, 148u8, 184u8, 133u8, 146u8, 101u8, 201u8, 91u8, 30u8, 76u8, + 169u8, + ], + ) + } + } + } + } + pub mod xcmp_queue { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::cumulus_pallet_xcmp_queue::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::cumulus_pallet_xcmp_queue::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SuspendXcmExecution; + impl ::subxt::blocks::StaticExtrinsic for SuspendXcmExecution { + const PALLET: &'static str = "XcmpQueue"; + const CALL: &'static str = "suspend_xcm_execution"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ResumeXcmExecution; + impl ::subxt::blocks::StaticExtrinsic for ResumeXcmExecution { + const PALLET: &'static str = "XcmpQueue"; + const CALL: &'static str = "resume_xcm_execution"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpdateSuspendThreshold { + pub new: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for UpdateSuspendThreshold { + const PALLET: &'static str = "XcmpQueue"; + const CALL: &'static str = "update_suspend_threshold"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpdateDropThreshold { + pub new: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for UpdateDropThreshold { + const PALLET: &'static str = "XcmpQueue"; + const CALL: &'static str = "update_drop_threshold"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UpdateResumeThreshold { + pub new: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for UpdateResumeThreshold { + const PALLET: &'static str = "XcmpQueue"; + const CALL: &'static str = "update_resume_threshold"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::suspend_xcm_execution`]."] + pub fn suspend_xcm_execution( + &self, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmpQueue", + "suspend_xcm_execution", + types::SuspendXcmExecution {}, + [ + 54u8, 120u8, 33u8, 251u8, 74u8, 56u8, 29u8, 76u8, 104u8, 218u8, 115u8, + 198u8, 148u8, 237u8, 9u8, 191u8, 241u8, 48u8, 33u8, 24u8, 60u8, 144u8, + 22u8, 78u8, 58u8, 50u8, 26u8, 188u8, 231u8, 42u8, 201u8, 76u8, + ], + ) + } + #[doc = "See [`Pallet::resume_xcm_execution`]."] + pub fn resume_xcm_execution( + &self, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmpQueue", + "resume_xcm_execution", + types::ResumeXcmExecution {}, + [ + 173u8, 231u8, 78u8, 253u8, 108u8, 234u8, 199u8, 124u8, 184u8, 154u8, + 95u8, 194u8, 13u8, 77u8, 175u8, 7u8, 7u8, 112u8, 161u8, 72u8, 133u8, + 71u8, 63u8, 218u8, 97u8, 226u8, 133u8, 6u8, 93u8, 177u8, 247u8, 109u8, + ], + ) + } + #[doc = "See [`Pallet::update_suspend_threshold`]."] + pub fn update_suspend_threshold( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmpQueue", + "update_suspend_threshold", + types::UpdateSuspendThreshold { new }, + [ + 64u8, 91u8, 172u8, 51u8, 220u8, 174u8, 54u8, 47u8, 57u8, 89u8, 75u8, + 39u8, 126u8, 198u8, 143u8, 35u8, 70u8, 125u8, 167u8, 14u8, 17u8, 18u8, + 146u8, 222u8, 100u8, 92u8, 81u8, 239u8, 173u8, 43u8, 42u8, 174u8, + ], + ) + } + #[doc = "See [`Pallet::update_drop_threshold`]."] + pub fn update_drop_threshold( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmpQueue", + "update_drop_threshold", + types::UpdateDropThreshold { new }, + [ + 123u8, 54u8, 12u8, 180u8, 165u8, 198u8, 141u8, 200u8, 149u8, 168u8, + 186u8, 237u8, 162u8, 91u8, 89u8, 242u8, 229u8, 16u8, 32u8, 254u8, 59u8, + 168u8, 31u8, 134u8, 217u8, 251u8, 0u8, 102u8, 113u8, 194u8, 175u8, 9u8, + ], + ) + } + #[doc = "See [`Pallet::update_resume_threshold`]."] + pub fn update_resume_threshold( + &self, + new: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "XcmpQueue", + "update_resume_threshold", + types::UpdateResumeThreshold { new }, + [ + 172u8, 136u8, 11u8, 106u8, 42u8, 157u8, 167u8, 183u8, 87u8, 62u8, + 182u8, 17u8, 184u8, 59u8, 215u8, 230u8, 18u8, 243u8, 212u8, 34u8, 54u8, + 188u8, 95u8, 119u8, 173u8, 20u8, 91u8, 206u8, 212u8, 57u8, 136u8, 77u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::cumulus_pallet_xcmp_queue::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An HRMP message was sent to a sibling parachain."] + pub struct XcmpMessageSent { + pub message_hash: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for XcmpMessageSent { + const PALLET: &'static str = "XcmpQueue"; + const EVENT: &'static str = "XcmpMessageSent"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The suspended inbound XCMP channels. All others are not suspended."] + #[doc = ""] + #[doc = " This is a `StorageValue` instead of a `StorageMap` since we expect multiple reads per block"] + #[doc = " to different keys with a one byte payload. The access to `BoundedBTreeSet` will be cached"] + #[doc = " within the block and therefore only included once in the proof size."] + #[doc = ""] + #[doc = " NOTE: The PoV benchmarking cannot know this and will over-estimate, but the actual proof"] + #[doc = " will be smaller."] + pub fn inbound_xcmp_suspended( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_btree_set::BoundedBTreeSet< + runtime_types::polkadot_parachain_primitives::primitives::Id, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "InboundXcmpSuspended", + vec![], + [ + 110u8, 23u8, 239u8, 104u8, 136u8, 224u8, 179u8, 180u8, 40u8, 159u8, + 54u8, 15u8, 55u8, 111u8, 75u8, 147u8, 131u8, 127u8, 9u8, 57u8, 133u8, + 70u8, 175u8, 181u8, 232u8, 49u8, 13u8, 19u8, 59u8, 151u8, 179u8, 215u8, + ], + ) + } + #[doc = " The non-empty XCMP channels in order of becoming non-empty, and the index of the first"] + #[doc = " and last outbound message. If the two indices are equal, then it indicates an empty"] + #[doc = " queue and there must be a non-`Ok` `OutboundStatus`. We assume queues grow no greater"] + #[doc = " than 65535 items. Queue indices for normal messages begin at one; zero is reserved in"] + #[doc = " case of the need to send a high-priority signal message this block."] + #[doc = " The bool is true if there is a signal message waiting to be sent."] + pub fn outbound_xcmp_status( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec< + runtime_types::cumulus_pallet_xcmp_queue::OutboundChannelDetails, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "OutboundXcmpStatus", + vec![], + [ + 181u8, 5u8, 216u8, 176u8, 154u8, 233u8, 116u8, 14u8, 151u8, 1u8, 114u8, + 16u8, 42u8, 20u8, 63u8, 233u8, 79u8, 122u8, 87u8, 255u8, 75u8, 149u8, + 176u8, 106u8, 23u8, 101u8, 228u8, 120u8, 217u8, 167u8, 127u8, 117u8, + ], + ) + } + #[doc = " The messages outbound in a given XCMP channel."] + pub fn outbound_xcmp_messages_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "OutboundXcmpMessages", + vec![], + [ + 156u8, 3u8, 202u8, 175u8, 175u8, 129u8, 38u8, 144u8, 35u8, 59u8, 228u8, + 159u8, 142u8, 25u8, 19u8, 73u8, 73u8, 6u8, 115u8, 19u8, 236u8, 235u8, + 144u8, 172u8, 31u8, 168u8, 24u8, 65u8, 115u8, 95u8, 77u8, 63u8, + ], + ) + } + #[doc = " The messages outbound in a given XCMP channel."] + pub fn outbound_xcmp_messages_iter1( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain_primitives::primitives::Id, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "OutboundXcmpMessages", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 156u8, 3u8, 202u8, 175u8, 175u8, 129u8, 38u8, 144u8, 35u8, 59u8, 228u8, + 159u8, 142u8, 25u8, 19u8, 73u8, 73u8, 6u8, 115u8, 19u8, 236u8, 235u8, + 144u8, 172u8, 31u8, 168u8, 24u8, 65u8, 115u8, 95u8, 77u8, 63u8, + ], + ) + } + #[doc = " The messages outbound in a given XCMP channel."] + pub fn outbound_xcmp_messages( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain_primitives::primitives::Id, + >, + _1: impl ::std::borrow::Borrow<::core::primitive::u16>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "OutboundXcmpMessages", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 156u8, 3u8, 202u8, 175u8, 175u8, 129u8, 38u8, 144u8, 35u8, 59u8, 228u8, + 159u8, 142u8, 25u8, 19u8, 73u8, 73u8, 6u8, 115u8, 19u8, 236u8, 235u8, + 144u8, 172u8, 31u8, 168u8, 24u8, 65u8, 115u8, 95u8, 77u8, 63u8, + ], + ) + } + #[doc = " Any signal messages waiting to be sent."] + pub fn signal_messages_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "SignalMessages", + vec![], + [ + 182u8, 143u8, 233u8, 233u8, 111u8, 137u8, 174u8, 165u8, 166u8, 7u8, + 229u8, 183u8, 99u8, 108u8, 30u8, 162u8, 71u8, 55u8, 122u8, 124u8, + 249u8, 203u8, 142u8, 124u8, 158u8, 213u8, 182u8, 159u8, 206u8, 249u8, + 180u8, 24u8, + ], + ) + } + #[doc = " Any signal messages waiting to be sent."] + pub fn signal_messages( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain_primitives::primitives::Id, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::std::vec::Vec<::core::primitive::u8>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "SignalMessages", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 182u8, 143u8, 233u8, 233u8, 111u8, 137u8, 174u8, 165u8, 166u8, 7u8, + 229u8, 183u8, 99u8, 108u8, 30u8, 162u8, 71u8, 55u8, 122u8, 124u8, + 249u8, 203u8, 142u8, 124u8, 158u8, 213u8, 182u8, 159u8, 206u8, 249u8, + 180u8, 24u8, + ], + ) + } + #[doc = " The configuration which controls the dynamics of the outbound queue."] + pub fn queue_config( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::cumulus_pallet_xcmp_queue::QueueConfigData, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "QueueConfig", + vec![], + [ + 185u8, 67u8, 247u8, 243u8, 211u8, 232u8, 57u8, 240u8, 237u8, 181u8, + 23u8, 114u8, 215u8, 128u8, 193u8, 1u8, 176u8, 53u8, 110u8, 195u8, + 148u8, 80u8, 187u8, 143u8, 62u8, 30u8, 143u8, 34u8, 248u8, 109u8, 3u8, + 141u8, + ], + ) + } + #[doc = " Whether or not the XCMP queue is suspended from executing incoming XCMs or not."] + pub fn queue_suspended( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "QueueSuspended", + vec![], + [ + 165u8, 66u8, 105u8, 244u8, 113u8, 43u8, 177u8, 252u8, 212u8, 243u8, + 143u8, 184u8, 87u8, 51u8, 163u8, 104u8, 29u8, 84u8, 119u8, 74u8, 233u8, + 129u8, 203u8, 105u8, 2u8, 101u8, 19u8, 170u8, 69u8, 253u8, 80u8, 132u8, + ], + ) + } + #[doc = " The factor to multiply the base delivery fee by."] + pub fn delivery_fee_factor_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::fixed_point::FixedU128, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "DeliveryFeeFactor", + vec![], + [ + 43u8, 5u8, 63u8, 235u8, 115u8, 155u8, 130u8, 27u8, 75u8, 216u8, 177u8, + 135u8, 203u8, 147u8, 167u8, 95u8, 208u8, 188u8, 25u8, 14u8, 84u8, 63u8, + 116u8, 41u8, 148u8, 110u8, 115u8, 215u8, 196u8, 36u8, 75u8, 102u8, + ], + ) + } + #[doc = " The factor to multiply the base delivery fee by."] + pub fn delivery_fee_factor( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::polkadot_parachain_primitives::primitives::Id, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::sp_arithmetic::fixed_point::FixedU128, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "XcmpQueue", + "DeliveryFeeFactor", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 43u8, 5u8, 63u8, 235u8, 115u8, 155u8, 130u8, 27u8, 75u8, 216u8, 177u8, + 135u8, 203u8, 147u8, 167u8, 95u8, 208u8, 188u8, 25u8, 14u8, 84u8, 63u8, + 116u8, 41u8, 148u8, 110u8, 115u8, 215u8, 196u8, 36u8, 75u8, 102u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The maximum number of inbound XCMP channels that can be suspended simultaneously."] + #[doc = ""] + #[doc = " Any further channel suspensions will fail and messages may get dropped without further"] + #[doc = " notice. Choosing a high value (1000) is okay; the trade-off that is described in"] + #[doc = " [`InboundXcmpSuspended`] still applies at that scale."] + pub fn max_inbound_suspended( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "XcmpQueue", + "MaxInboundSuspended", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod polkadot_xcm { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::pallet_xcm::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_xcm::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Send { + pub dest: ::std::boxed::Box, + pub message: ::std::boxed::Box, + } + impl ::subxt::blocks::StaticExtrinsic for Send { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "send"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TeleportAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for TeleportAssets { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "teleport_assets"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReserveTransferAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for ReserveTransferAssets { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "reserve_transfer_assets"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Execute { + pub message: ::std::boxed::Box, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + impl ::subxt::blocks::StaticExtrinsic for Execute { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "execute"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceXcmVersion { + pub location: + ::std::boxed::Box, + pub version: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for ForceXcmVersion { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "force_xcm_version"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceDefaultXcmVersion { + pub maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, + } + impl ::subxt::blocks::StaticExtrinsic for ForceDefaultXcmVersion { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "force_default_xcm_version"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSubscribeVersionNotify { + pub location: ::std::boxed::Box, + } + impl ::subxt::blocks::StaticExtrinsic for ForceSubscribeVersionNotify { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "force_subscribe_version_notify"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceUnsubscribeVersionNotify { + pub location: ::std::boxed::Box, + } + impl ::subxt::blocks::StaticExtrinsic for ForceUnsubscribeVersionNotify { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "force_unsubscribe_version_notify"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LimitedReserveTransferAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + pub weight_limit: runtime_types::xcm::v3::WeightLimit, + } + impl ::subxt::blocks::StaticExtrinsic for LimitedReserveTransferAssets { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "limited_reserve_transfer_assets"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LimitedTeleportAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + pub weight_limit: runtime_types::xcm::v3::WeightLimit, + } + impl ::subxt::blocks::StaticExtrinsic for LimitedTeleportAssets { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "limited_teleport_assets"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceSuspension { + pub suspended: ::core::primitive::bool, + } + impl ::subxt::blocks::StaticExtrinsic for ForceSuspension { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "force_suspension"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct TransferAssets { + pub dest: ::std::boxed::Box, + pub beneficiary: ::std::boxed::Box, + pub assets: ::std::boxed::Box, + pub fee_asset_item: ::core::primitive::u32, + pub weight_limit: runtime_types::xcm::v3::WeightLimit, + } + impl ::subxt::blocks::StaticExtrinsic for TransferAssets { + const PALLET: &'static str = "PolkadotXcm"; + const CALL: &'static str = "transfer_assets"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::send`]."] + pub fn send( + &self, + dest: runtime_types::xcm::VersionedLocation, + message: runtime_types::xcm::VersionedXcm, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "send", + types::Send { + dest: ::std::boxed::Box::new(dest), + message: ::std::boxed::Box::new(message), + }, + [ + 47u8, 63u8, 128u8, 176u8, 10u8, 137u8, 124u8, 238u8, 155u8, 37u8, + 193u8, 160u8, 83u8, 240u8, 21u8, 179u8, 169u8, 131u8, 27u8, 104u8, + 195u8, 208u8, 123u8, 14u8, 221u8, 12u8, 45u8, 81u8, 148u8, 76u8, 17u8, + 100u8, + ], + ) + } + #[doc = "See [`Pallet::teleport_assets`]."] + pub fn teleport_assets( + &self, + dest: runtime_types::xcm::VersionedLocation, + beneficiary: runtime_types::xcm::VersionedLocation, + assets: runtime_types::xcm::VersionedAssets, + fee_asset_item: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "teleport_assets", + types::TeleportAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + }, + [ + 124u8, 191u8, 118u8, 61u8, 45u8, 225u8, 97u8, 83u8, 198u8, 20u8, 139u8, + 117u8, 241u8, 1u8, 19u8, 54u8, 79u8, 181u8, 131u8, 112u8, 11u8, 118u8, + 147u8, 12u8, 89u8, 156u8, 123u8, 123u8, 195u8, 45u8, 50u8, 107u8, + ], + ) + } + #[doc = "See [`Pallet::reserve_transfer_assets`]."] + pub fn reserve_transfer_assets( + &self, + dest: runtime_types::xcm::VersionedLocation, + beneficiary: runtime_types::xcm::VersionedLocation, + assets: runtime_types::xcm::VersionedAssets, + fee_asset_item: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "reserve_transfer_assets", + types::ReserveTransferAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + }, + [ + 97u8, 102u8, 230u8, 44u8, 135u8, 197u8, 43u8, 53u8, 182u8, 125u8, + 140u8, 141u8, 229u8, 73u8, 29u8, 55u8, 159u8, 104u8, 197u8, 20u8, + 124u8, 234u8, 250u8, 94u8, 133u8, 253u8, 189u8, 6u8, 216u8, 162u8, + 218u8, 89u8, + ], + ) + } + #[doc = "See [`Pallet::execute`]."] + pub fn execute( + &self, + message: runtime_types::xcm::VersionedXcm2, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "execute", + types::Execute { message: ::std::boxed::Box::new(message), max_weight }, + [ + 71u8, 109u8, 92u8, 110u8, 198u8, 150u8, 140u8, 125u8, 248u8, 236u8, + 177u8, 156u8, 198u8, 223u8, 51u8, 15u8, 52u8, 240u8, 20u8, 200u8, 68u8, + 145u8, 36u8, 156u8, 159u8, 153u8, 125u8, 48u8, 181u8, 61u8, 53u8, + 208u8, + ], + ) + } + #[doc = "See [`Pallet::force_xcm_version`]."] + pub fn force_xcm_version( + &self, + location: runtime_types::staging_xcm::v4::location::Location, + version: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "force_xcm_version", + types::ForceXcmVersion { + location: ::std::boxed::Box::new(location), + version, + }, + [ + 69u8, 151u8, 198u8, 154u8, 69u8, 181u8, 41u8, 111u8, 145u8, 230u8, + 103u8, 42u8, 237u8, 91u8, 235u8, 6u8, 156u8, 65u8, 187u8, 48u8, 171u8, + 200u8, 49u8, 4u8, 9u8, 210u8, 229u8, 152u8, 187u8, 88u8, 80u8, 246u8, + ], + ) + } + #[doc = "See [`Pallet::force_default_xcm_version`]."] + pub fn force_default_xcm_version( + &self, + maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "force_default_xcm_version", + types::ForceDefaultXcmVersion { maybe_xcm_version }, + [ + 43u8, 114u8, 102u8, 104u8, 209u8, 234u8, 108u8, 173u8, 109u8, 188u8, + 94u8, 214u8, 136u8, 43u8, 153u8, 75u8, 161u8, 192u8, 76u8, 12u8, 221u8, + 237u8, 158u8, 247u8, 41u8, 193u8, 35u8, 174u8, 183u8, 207u8, 79u8, + 213u8, + ], + ) + } + #[doc = "See [`Pallet::force_subscribe_version_notify`]."] + pub fn force_subscribe_version_notify( + &self, + location: runtime_types::xcm::VersionedLocation, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "force_subscribe_version_notify", + types::ForceSubscribeVersionNotify { + location: ::std::boxed::Box::new(location), + }, + [ + 203u8, 171u8, 70u8, 130u8, 46u8, 63u8, 76u8, 50u8, 105u8, 23u8, 249u8, + 190u8, 115u8, 74u8, 70u8, 125u8, 132u8, 112u8, 138u8, 60u8, 33u8, 35u8, + 45u8, 29u8, 95u8, 103u8, 187u8, 182u8, 188u8, 196u8, 248u8, 152u8, + ], + ) + } + #[doc = "See [`Pallet::force_unsubscribe_version_notify`]."] + pub fn force_unsubscribe_version_notify( + &self, + location: runtime_types::xcm::VersionedLocation, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "force_unsubscribe_version_notify", + types::ForceUnsubscribeVersionNotify { + location: ::std::boxed::Box::new(location), + }, + [ + 6u8, 113u8, 168u8, 215u8, 233u8, 202u8, 249u8, 134u8, 131u8, 8u8, + 142u8, 203u8, 142u8, 95u8, 216u8, 70u8, 38u8, 99u8, 166u8, 97u8, 218u8, + 132u8, 247u8, 14u8, 42u8, 99u8, 4u8, 115u8, 200u8, 180u8, 213u8, 50u8, + ], + ) + } + #[doc = "See [`Pallet::limited_reserve_transfer_assets`]."] + pub fn limited_reserve_transfer_assets( + &self, + dest: runtime_types::xcm::VersionedLocation, + beneficiary: runtime_types::xcm::VersionedLocation, + assets: runtime_types::xcm::VersionedAssets, + fee_asset_item: ::core::primitive::u32, + weight_limit: runtime_types::xcm::v3::WeightLimit, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "limited_reserve_transfer_assets", + types::LimitedReserveTransferAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + weight_limit, + }, + [ + 198u8, 66u8, 204u8, 162u8, 222u8, 246u8, 141u8, 165u8, 241u8, 62u8, + 43u8, 236u8, 56u8, 200u8, 54u8, 47u8, 174u8, 83u8, 167u8, 220u8, 174u8, + 111u8, 123u8, 202u8, 248u8, 232u8, 166u8, 80u8, 152u8, 223u8, 86u8, + 141u8, + ], + ) + } + #[doc = "See [`Pallet::limited_teleport_assets`]."] + pub fn limited_teleport_assets( + &self, + dest: runtime_types::xcm::VersionedLocation, + beneficiary: runtime_types::xcm::VersionedLocation, + assets: runtime_types::xcm::VersionedAssets, + fee_asset_item: ::core::primitive::u32, + weight_limit: runtime_types::xcm::v3::WeightLimit, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "limited_teleport_assets", + types::LimitedTeleportAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + weight_limit, + }, + [ + 70u8, 61u8, 32u8, 43u8, 101u8, 104u8, 251u8, 60u8, 212u8, 124u8, 113u8, + 243u8, 241u8, 183u8, 5u8, 231u8, 209u8, 231u8, 136u8, 3u8, 145u8, + 242u8, 179u8, 171u8, 185u8, 185u8, 7u8, 34u8, 5u8, 203u8, 21u8, 210u8, + ], + ) + } + #[doc = "See [`Pallet::force_suspension`]."] + pub fn force_suspension( + &self, + suspended: ::core::primitive::bool, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "force_suspension", + types::ForceSuspension { suspended }, + [ + 78u8, 125u8, 93u8, 55u8, 129u8, 44u8, 36u8, 227u8, 75u8, 46u8, 68u8, + 202u8, 81u8, 127u8, 111u8, 92u8, 149u8, 38u8, 225u8, 185u8, 183u8, + 154u8, 89u8, 159u8, 79u8, 10u8, 229u8, 1u8, 226u8, 243u8, 65u8, 238u8, + ], + ) + } + #[doc = "See [`Pallet::transfer_assets`]."] + pub fn transfer_assets( + &self, + dest: runtime_types::xcm::VersionedLocation, + beneficiary: runtime_types::xcm::VersionedLocation, + assets: runtime_types::xcm::VersionedAssets, + fee_asset_item: ::core::primitive::u32, + weight_limit: runtime_types::xcm::v3::WeightLimit, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "PolkadotXcm", + "transfer_assets", + types::TransferAssets { + dest: ::std::boxed::Box::new(dest), + beneficiary: ::std::boxed::Box::new(beneficiary), + assets: ::std::boxed::Box::new(assets), + fee_asset_item, + weight_limit, + }, + [ + 44u8, 155u8, 182u8, 37u8, 123u8, 148u8, 150u8, 191u8, 117u8, 32u8, + 16u8, 238u8, 121u8, 188u8, 217u8, 110u8, 10u8, 236u8, 174u8, 91u8, + 100u8, 201u8, 109u8, 109u8, 60u8, 177u8, 233u8, 66u8, 181u8, 191u8, + 105u8, 37u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_xcm::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Execution of an XCM message was attempted."] + pub struct Attempted { + pub outcome: runtime_types::staging_xcm::v4::traits::Outcome, + } + impl ::subxt::events::StaticEvent for Attempted { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "Attempted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A XCM message was sent."] + pub struct Sent { + pub origin: runtime_types::staging_xcm::v4::location::Location, + pub destination: runtime_types::staging_xcm::v4::location::Location, + pub message: runtime_types::staging_xcm::v4::Xcm, + pub message_id: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for Sent { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "Sent"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response received which does not match a registered query. This may be because a"] + #[doc = "matching query was never registered, it may be because it is a duplicate response, or"] + #[doc = "because the query timed out."] + pub struct UnexpectedResponse { + pub origin: runtime_types::staging_xcm::v4::location::Location, + pub query_id: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for UnexpectedResponse { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "UnexpectedResponse"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] + #[doc = "no registered notification call."] + pub struct ResponseReady { + pub query_id: ::core::primitive::u64, + pub response: runtime_types::staging_xcm::v4::Response, + } + impl ::subxt::events::StaticEvent for ResponseReady { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "ResponseReady"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and query is removed. The registered notification has"] + #[doc = "been dispatched and executed successfully."] + pub struct Notified { + pub query_id: ::core::primitive::u64, + pub pallet_index: ::core::primitive::u8, + pub call_index: ::core::primitive::u8, + } + impl ::subxt::events::StaticEvent for Notified { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "Notified"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and query is removed. The registered notification"] + #[doc = "could not be dispatched because the dispatch weight is greater than the maximum weight"] + #[doc = "originally budgeted by this runtime for the query result."] + pub struct NotifyOverweight { + pub query_id: ::core::primitive::u64, + pub pallet_index: ::core::primitive::u8, + pub call_index: ::core::primitive::u8, + pub actual_weight: runtime_types::sp_weights::weight_v2::Weight, + pub max_budgeted_weight: runtime_types::sp_weights::weight_v2::Weight, + } + impl ::subxt::events::StaticEvent for NotifyOverweight { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "NotifyOverweight"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and query is removed. There was a general error with"] + #[doc = "dispatching the notification call."] + pub struct NotifyDispatchError { + pub query_id: ::core::primitive::u64, + pub pallet_index: ::core::primitive::u8, + pub call_index: ::core::primitive::u8, + } + impl ::subxt::events::StaticEvent for NotifyDispatchError { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "NotifyDispatchError"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] + #[doc = "decoded into a `Call`; this might be due to dispatch function having a signature which"] + #[doc = "is not `(origin, QueryId, Response)`."] + pub struct NotifyDecodeFailed { + pub query_id: ::core::primitive::u64, + pub pallet_index: ::core::primitive::u8, + pub call_index: ::core::primitive::u8, + } + impl ::subxt::events::StaticEvent for NotifyDecodeFailed { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "NotifyDecodeFailed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Expected query response has been received but the origin location of the response does"] + #[doc = "not match that expected. The query remains registered for a later, valid, response to"] + #[doc = "be received and acted upon."] + pub struct InvalidResponder { + pub origin: runtime_types::staging_xcm::v4::location::Location, + pub query_id: ::core::primitive::u64, + pub expected_location: + ::core::option::Option, + } + impl ::subxt::events::StaticEvent for InvalidResponder { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "InvalidResponder"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Expected query response has been received but the expected origin location placed in"] + #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] + #[doc = ""] + #[doc = "This is unexpected (since a location placed in storage in a previously executing"] + #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] + #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] + #[doc = "needed."] + pub struct InvalidResponderVersion { + pub origin: runtime_types::staging_xcm::v4::location::Location, + pub query_id: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for InvalidResponderVersion { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "InvalidResponderVersion"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Received query response has been read and removed."] + pub struct ResponseTaken { + pub query_id: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for ResponseTaken { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "ResponseTaken"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some assets have been placed in an asset trap."] + pub struct AssetsTrapped { + pub hash: ::subxt::utils::H256, + pub origin: runtime_types::staging_xcm::v4::location::Location, + pub assets: runtime_types::xcm::VersionedAssets, + } + impl ::subxt::events::StaticEvent for AssetsTrapped { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "AssetsTrapped"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "An XCM version change notification message has been attempted to be sent."] + #[doc = ""] + #[doc = "The cost of sending it (borne by the chain) is included."] + pub struct VersionChangeNotified { + pub destination: runtime_types::staging_xcm::v4::location::Location, + pub result: ::core::primitive::u32, + pub cost: runtime_types::staging_xcm::v4::asset::Assets, + pub message_id: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for VersionChangeNotified { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "VersionChangeNotified"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The supported version of a location has been changed. This might be through an"] + #[doc = "automatic notification or a manual intervention."] + pub struct SupportedVersionChanged { + pub location: runtime_types::staging_xcm::v4::location::Location, + pub version: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for SupportedVersionChanged { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "SupportedVersionChanged"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A given location which had a version change subscription was dropped owing to an error"] + #[doc = "sending the notification to it."] + pub struct NotifyTargetSendFail { + pub location: runtime_types::staging_xcm::v4::location::Location, + pub query_id: ::core::primitive::u64, + pub error: runtime_types::xcm::v3::traits::Error, + } + impl ::subxt::events::StaticEvent for NotifyTargetSendFail { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "NotifyTargetSendFail"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A given location which had a version change subscription was dropped owing to an error"] + #[doc = "migrating the location to our new XCM format."] + pub struct NotifyTargetMigrationFail { + pub location: runtime_types::xcm::VersionedLocation, + pub query_id: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for NotifyTargetMigrationFail { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "NotifyTargetMigrationFail"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Expected query response has been received but the expected querier location placed in"] + #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] + #[doc = ""] + #[doc = "This is unexpected (since a location placed in storage in a previously executing"] + #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] + #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] + #[doc = "needed."] + pub struct InvalidQuerierVersion { + pub origin: runtime_types::staging_xcm::v4::location::Location, + pub query_id: ::core::primitive::u64, + } + impl ::subxt::events::StaticEvent for InvalidQuerierVersion { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "InvalidQuerierVersion"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Expected query response has been received but the querier location of the response does"] + #[doc = "not match the expected. The query remains registered for a later, valid, response to"] + #[doc = "be received and acted upon."] + pub struct InvalidQuerier { + pub origin: runtime_types::staging_xcm::v4::location::Location, + pub query_id: ::core::primitive::u64, + pub expected_querier: runtime_types::staging_xcm::v4::location::Location, + pub maybe_actual_querier: + ::core::option::Option, + } + impl ::subxt::events::StaticEvent for InvalidQuerier { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "InvalidQuerier"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A remote has requested XCM version change notification from us and we have honored it."] + #[doc = "A version information message is sent to them and its cost is included."] + pub struct VersionNotifyStarted { + pub destination: runtime_types::staging_xcm::v4::location::Location, + pub cost: runtime_types::staging_xcm::v4::asset::Assets, + pub message_id: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for VersionNotifyStarted { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "VersionNotifyStarted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "We have requested that a remote chain send us XCM version change notifications."] + pub struct VersionNotifyRequested { + pub destination: runtime_types::staging_xcm::v4::location::Location, + pub cost: runtime_types::staging_xcm::v4::asset::Assets, + pub message_id: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for VersionNotifyRequested { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "VersionNotifyRequested"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "We have requested that a remote chain stops sending us XCM version change"] + #[doc = "notifications."] + pub struct VersionNotifyUnrequested { + pub destination: runtime_types::staging_xcm::v4::location::Location, + pub cost: runtime_types::staging_xcm::v4::asset::Assets, + pub message_id: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for VersionNotifyUnrequested { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "VersionNotifyUnrequested"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Fees were paid from a location for an operation (often for using `SendXcm`)."] + pub struct FeesPaid { + pub paying: runtime_types::staging_xcm::v4::location::Location, + pub fees: runtime_types::staging_xcm::v4::asset::Assets, + } + impl ::subxt::events::StaticEvent for FeesPaid { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "FeesPaid"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some assets have been claimed from an asset trap"] + pub struct AssetsClaimed { + pub hash: ::subxt::utils::H256, + pub origin: runtime_types::staging_xcm::v4::location::Location, + pub assets: runtime_types::xcm::VersionedAssets, + } + impl ::subxt::events::StaticEvent for AssetsClaimed { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "AssetsClaimed"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A XCM version migration finished."] + pub struct VersionMigrationFinished { + pub version: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for VersionMigrationFinished { + const PALLET: &'static str = "PolkadotXcm"; + const EVENT: &'static str = "VersionMigrationFinished"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The latest available query index."] + pub fn query_counter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "QueryCounter", + vec![], + [ + 216u8, 73u8, 160u8, 232u8, 60u8, 245u8, 218u8, 219u8, 152u8, 68u8, + 146u8, 219u8, 255u8, 7u8, 86u8, 112u8, 83u8, 49u8, 94u8, 173u8, 64u8, + 203u8, 147u8, 226u8, 236u8, 39u8, 129u8, 106u8, 209u8, 113u8, 150u8, + 50u8, + ], + ) + } + #[doc = " The ongoing queries."] + pub fn queries_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "Queries", + vec![], + [ + 246u8, 75u8, 240u8, 129u8, 106u8, 114u8, 99u8, 154u8, 176u8, 188u8, + 146u8, 125u8, 244u8, 103u8, 187u8, 171u8, 60u8, 119u8, 4u8, 90u8, 58u8, + 180u8, 48u8, 165u8, 145u8, 125u8, 227u8, 233u8, 11u8, 142u8, 122u8, + 3u8, + ], + ) + } + #[doc = " The ongoing queries."] + pub fn queries( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u64>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "Queries", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 246u8, 75u8, 240u8, 129u8, 106u8, 114u8, 99u8, 154u8, 176u8, 188u8, + 146u8, 125u8, 244u8, 103u8, 187u8, 171u8, 60u8, 119u8, 4u8, 90u8, 58u8, + 180u8, 48u8, 165u8, 145u8, 125u8, 227u8, 233u8, 11u8, 142u8, 122u8, + 3u8, + ], + ) + } + #[doc = " The existing asset traps."] + #[doc = ""] + #[doc = " Key is the blake2 256 hash of (origin, versioned `Assets`) pair. Value is the number of"] + #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] + pub fn asset_traps_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "AssetTraps", + vec![], + [ + 148u8, 41u8, 254u8, 134u8, 61u8, 172u8, 126u8, 146u8, 78u8, 178u8, + 50u8, 77u8, 226u8, 8u8, 200u8, 78u8, 77u8, 91u8, 26u8, 133u8, 104u8, + 126u8, 28u8, 28u8, 202u8, 62u8, 87u8, 183u8, 231u8, 191u8, 5u8, 181u8, + ], + ) + } + #[doc = " The existing asset traps."] + #[doc = ""] + #[doc = " Key is the blake2 256 hash of (origin, versioned `Assets`) pair. Value is the number of"] + #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] + pub fn asset_traps( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "AssetTraps", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 148u8, 41u8, 254u8, 134u8, 61u8, 172u8, 126u8, 146u8, 78u8, 178u8, + 50u8, 77u8, 226u8, 8u8, 200u8, 78u8, 77u8, 91u8, 26u8, 133u8, 104u8, + 126u8, 28u8, 28u8, 202u8, 62u8, 87u8, 183u8, 231u8, 191u8, 5u8, 181u8, + ], + ) + } + #[doc = " Default version to encode XCM when latest version of destination is unknown. If `None`,"] + #[doc = " then the destinations whose XCM version is unknown are considered unreachable."] + pub fn safe_xcm_version( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "SafeXcmVersion", + vec![], + [ + 187u8, 8u8, 74u8, 126u8, 80u8, 215u8, 177u8, 60u8, 223u8, 123u8, 196u8, + 155u8, 166u8, 66u8, 25u8, 164u8, 191u8, 66u8, 116u8, 131u8, 116u8, + 188u8, 224u8, 122u8, 75u8, 195u8, 246u8, 188u8, 83u8, 134u8, 49u8, + 143u8, + ], + ) + } + #[doc = " The Latest versions that we know various locations support."] + pub fn supported_version_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "SupportedVersion", + vec![], + [ + 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, + 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, + 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, + 202u8, 24u8, + ], + ) + } + #[doc = " The Latest versions that we know various locations support."] + pub fn supported_version_iter1( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "SupportedVersion", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, + 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, + 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, + 202u8, 24u8, + ], + ) + } + #[doc = " The Latest versions that we know various locations support."] + pub fn supported_version( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "SupportedVersion", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, + 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, + 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, + 202u8, 24u8, + ], + ) + } + #[doc = " All locations that we have requested version notifications from."] + pub fn version_notifiers_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "VersionNotifiers", + vec![], + [ + 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, + 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, + 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, + 201u8, 49u8, + ], + ) + } + #[doc = " All locations that we have requested version notifications from."] + pub fn version_notifiers_iter1( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "VersionNotifiers", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, + 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, + 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, + 201u8, 49u8, + ], + ) + } + #[doc = " All locations that we have requested version notifications from."] + pub fn version_notifiers( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u64, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "VersionNotifiers", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, + 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, + 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, + 201u8, 49u8, + ], + ) + } + #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] + #[doc = " of our versions we informed them of."] + pub fn version_notify_targets_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + ::core::primitive::u64, + runtime_types::sp_weights::weight_v2::Weight, + ::core::primitive::u32, + ), + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "VersionNotifyTargets", + vec![], + [ + 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, + 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, + 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, + ], + ) + } + #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] + #[doc = " of our versions we informed them of."] + pub fn version_notify_targets_iter1( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + ::core::primitive::u64, + runtime_types::sp_weights::weight_v2::Weight, + ::core::primitive::u32, + ), + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "VersionNotifyTargets", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, + 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, + 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, + ], + ) + } + #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] + #[doc = " of our versions we informed them of."] + pub fn version_notify_targets( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ( + ::core::primitive::u64, + runtime_types::sp_weights::weight_v2::Weight, + ::core::primitive::u32, + ), + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "VersionNotifyTargets", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, + 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, + 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, + ], + ) + } + #[doc = " Destinations whose latest XCM version we would like to know. Duplicates not allowed, and"] + #[doc = " the `u32` counter is the number of times that a send to the destination has been attempted,"] + #[doc = " which is used as a prioritization."] + pub fn version_discovery_queue( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + runtime_types::xcm::VersionedLocation, + ::core::primitive::u32, + )>, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "VersionDiscoveryQueue", + vec![], + [ + 95u8, 74u8, 97u8, 94u8, 40u8, 140u8, 175u8, 176u8, 224u8, 222u8, 83u8, + 199u8, 170u8, 102u8, 3u8, 77u8, 127u8, 208u8, 155u8, 122u8, 176u8, + 51u8, 15u8, 253u8, 231u8, 245u8, 91u8, 192u8, 60u8, 144u8, 101u8, + 168u8, + ], + ) + } + #[doc = " The current migration's stage, if any."] + pub fn current_migration( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::VersionMigrationStage, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "CurrentMigration", + vec![], + [ + 74u8, 138u8, 181u8, 162u8, 59u8, 251u8, 37u8, 28u8, 232u8, 51u8, 30u8, + 152u8, 252u8, 133u8, 95u8, 195u8, 47u8, 127u8, 21u8, 44u8, 62u8, 143u8, + 170u8, 234u8, 160u8, 37u8, 131u8, 179u8, 57u8, 241u8, 140u8, 124u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on a remote chain."] + pub fn remote_locked_fungibles_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "RemoteLockedFungibles", + vec![], + [ + 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, + 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, + 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, + 201u8, 150u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on a remote chain."] + pub fn remote_locked_fungibles_iter1( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "RemoteLockedFungibles", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, + 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, + 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, + 201u8, 150u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on a remote chain."] + pub fn remote_locked_fungibles_iter2( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "RemoteLockedFungibles", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, + 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, + 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, + 201u8, 150u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on a remote chain."] + pub fn remote_locked_fungibles( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _2: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "RemoteLockedFungibles", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_2.borrow()), + ], + [ + 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, + 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, + 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, + 201u8, 150u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on this chain."] + pub fn locked_fungibles_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u128, + runtime_types::xcm::VersionedLocation, + )>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "LockedFungibles", + vec![], + [ + 254u8, 234u8, 1u8, 27u8, 27u8, 32u8, 217u8, 24u8, 47u8, 30u8, 62u8, + 80u8, 86u8, 125u8, 120u8, 24u8, 143u8, 229u8, 161u8, 153u8, 240u8, + 246u8, 80u8, 15u8, 49u8, 189u8, 20u8, 204u8, 239u8, 198u8, 97u8, 174u8, + ], + ) + } + #[doc = " Fungible assets which we know are locked on this chain."] + pub fn locked_fungibles( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec<( + ::core::primitive::u128, + runtime_types::xcm::VersionedLocation, + )>, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "LockedFungibles", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 254u8, 234u8, 1u8, 27u8, 27u8, 32u8, 217u8, 24u8, 47u8, 30u8, 62u8, + 80u8, 86u8, 125u8, 120u8, 24u8, 143u8, 229u8, 161u8, 153u8, 240u8, + 246u8, 80u8, 15u8, 49u8, 189u8, 20u8, 204u8, 239u8, 198u8, 97u8, 174u8, + ], + ) + } + #[doc = " Global suspension state of the XCM executor."] + pub fn xcm_execution_suspended( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::bool, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "PolkadotXcm", + "XcmExecutionSuspended", + vec![], + [ + 182u8, 54u8, 69u8, 68u8, 78u8, 76u8, 103u8, 79u8, 47u8, 136u8, 99u8, + 104u8, 128u8, 129u8, 249u8, 54u8, 214u8, 136u8, 97u8, 48u8, 178u8, + 42u8, 26u8, 27u8, 82u8, 24u8, 33u8, 77u8, 33u8, 27u8, 20u8, 127u8, + ], + ) + } + } + } + } + pub mod cumulus_xcm { + use super::root_mod; + use super::runtime_types; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::cumulus_pallet_xcm::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + } + pub struct TransactionApi; + impl TransactionApi {} + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::cumulus_pallet_xcm::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Downward message is invalid XCM."] + #[doc = "\\[ id \\]"] + pub struct InvalidFormat(pub [::core::primitive::u8; 32usize]); + impl ::subxt::events::StaticEvent for InvalidFormat { + const PALLET: &'static str = "CumulusXcm"; + const EVENT: &'static str = "InvalidFormat"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Downward message is unsupported version of XCM."] + #[doc = "\\[ id \\]"] + pub struct UnsupportedVersion(pub [::core::primitive::u8; 32usize]); + impl ::subxt::events::StaticEvent for UnsupportedVersion { + const PALLET: &'static str = "CumulusXcm"; + const EVENT: &'static str = "UnsupportedVersion"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Downward message executed with the given outcome."] + #[doc = "\\[ id, outcome \\]"] + pub struct ExecutedDownward( + pub [::core::primitive::u8; 32usize], + pub runtime_types::staging_xcm::v4::traits::Outcome, + ); + impl ::subxt::events::StaticEvent for ExecutedDownward { + const PALLET: &'static str = "CumulusXcm"; + const EVENT: &'static str = "ExecutedDownward"; + } + } + } + pub mod message_queue { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::pallet_message_queue::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_message_queue::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReapPage { + pub message_origin: + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + pub page_index: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for ReapPage { + const PALLET: &'static str = "MessageQueue"; + const CALL: &'static str = "reap_page"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExecuteOverweight { + pub message_origin: + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + pub page: ::core::primitive::u32, + pub index: ::core::primitive::u32, + pub weight_limit: runtime_types::sp_weights::weight_v2::Weight, + } + impl ::subxt::blocks::StaticExtrinsic for ExecuteOverweight { + const PALLET: &'static str = "MessageQueue"; + const CALL: &'static str = "execute_overweight"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::reap_page`]."] + pub fn reap_page( + &self, + message_origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + page_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "MessageQueue", + "reap_page", + types::ReapPage { message_origin, page_index }, + [ + 116u8, 17u8, 120u8, 238u8, 117u8, 222u8, 10u8, 166u8, 132u8, 181u8, + 114u8, 150u8, 242u8, 202u8, 31u8, 143u8, 212u8, 65u8, 145u8, 249u8, + 27u8, 204u8, 137u8, 133u8, 220u8, 187u8, 137u8, 90u8, 112u8, 55u8, + 104u8, 163u8, + ], + ) + } + #[doc = "See [`Pallet::execute_overweight`]."] + pub fn execute_overweight( + &self, + message_origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + page: ::core::primitive::u32, + index: ::core::primitive::u32, + weight_limit: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "MessageQueue", + "execute_overweight", + types::ExecuteOverweight { message_origin, page, index, weight_limit }, + [ + 177u8, 54u8, 82u8, 58u8, 94u8, 125u8, 241u8, 172u8, 52u8, 7u8, 236u8, + 80u8, 66u8, 99u8, 42u8, 199u8, 38u8, 195u8, 65u8, 118u8, 166u8, 246u8, + 239u8, 195u8, 144u8, 153u8, 155u8, 8u8, 224u8, 56u8, 106u8, 135u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_message_queue::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Message discarded due to an error in the `MessageProcessor` (usually a format error)."] + pub struct ProcessingFailed { + pub id: ::subxt::utils::H256, + pub origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + pub error: runtime_types::frame_support::traits::messages::ProcessMessageError, + } + impl ::subxt::events::StaticEvent for ProcessingFailed { + const PALLET: &'static str = "MessageQueue"; + const EVENT: &'static str = "ProcessingFailed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Message is processed."] + pub struct Processed { + pub id: ::subxt::utils::H256, + pub origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + pub weight_used: runtime_types::sp_weights::weight_v2::Weight, + pub success: ::core::primitive::bool, + } + impl ::subxt::events::StaticEvent for Processed { + const PALLET: &'static str = "MessageQueue"; + const EVENT: &'static str = "Processed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Message placed in overweight queue."] + pub struct OverweightEnqueued { + pub id: [::core::primitive::u8; 32usize], + pub origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + pub page_index: ::core::primitive::u32, + pub message_index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for OverweightEnqueued { + const PALLET: &'static str = "MessageQueue"; + const EVENT: &'static str = "OverweightEnqueued"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "This page was reaped."] + pub struct PageReaped { + pub origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + pub index: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for PageReaped { + const PALLET: &'static str = "MessageQueue"; + const EVENT: &'static str = "PageReaped"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The index of the first and last (non-empty) pages."] + pub fn book_state_for_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_message_queue::BookState< + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "MessageQueue", + "BookStateFor", + vec![], + [ + 33u8, 240u8, 235u8, 59u8, 150u8, 42u8, 91u8, 248u8, 235u8, 52u8, 170u8, + 52u8, 195u8, 129u8, 6u8, 174u8, 57u8, 242u8, 30u8, 220u8, 232u8, 4u8, + 246u8, 218u8, 162u8, 174u8, 102u8, 95u8, 210u8, 92u8, 133u8, 143u8, + ], + ) + } + #[doc = " The index of the first and last (non-empty) pages."] + pub fn book_state_for( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_message_queue::BookState< + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "MessageQueue", + "BookStateFor", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 33u8, 240u8, 235u8, 59u8, 150u8, 42u8, 91u8, 248u8, 235u8, 52u8, 170u8, + 52u8, 195u8, 129u8, 6u8, 174u8, 57u8, 242u8, 30u8, 220u8, 232u8, 4u8, + 246u8, 218u8, 162u8, 174u8, 102u8, 95u8, 210u8, 92u8, 133u8, 143u8, + ], + ) + } + #[doc = " The origin at which we should begin servicing."] + pub fn service_head( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "MessageQueue", + "ServiceHead", + vec![], + [ + 104u8, 146u8, 240u8, 41u8, 171u8, 68u8, 20u8, 147u8, 212u8, 155u8, + 59u8, 39u8, 174u8, 186u8, 97u8, 250u8, 41u8, 247u8, 67u8, 190u8, 252u8, + 167u8, 234u8, 36u8, 124u8, 239u8, 163u8, 72u8, 223u8, 82u8, 82u8, + 171u8, + ], + ) + } + #[doc = " The map of page indices to pages."] + pub fn pages_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_message_queue::Page<::core::primitive::u32>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "MessageQueue", + "Pages", + vec![], + [ + 45u8, 202u8, 18u8, 128u8, 31u8, 194u8, 175u8, 173u8, 99u8, 81u8, 161u8, + 44u8, 32u8, 183u8, 238u8, 181u8, 110u8, 240u8, 203u8, 12u8, 152u8, + 58u8, 239u8, 190u8, 144u8, 168u8, 210u8, 33u8, 121u8, 250u8, 137u8, + 142u8, + ], + ) + } + #[doc = " The map of page indices to pages."] + pub fn pages_iter1( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_message_queue::Page<::core::primitive::u32>, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "MessageQueue", + "Pages", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 45u8, 202u8, 18u8, 128u8, 31u8, 194u8, 175u8, 173u8, 99u8, 81u8, 161u8, + 44u8, 32u8, 183u8, 238u8, 181u8, 110u8, 240u8, 203u8, 12u8, 152u8, + 58u8, 239u8, 190u8, 144u8, 168u8, 210u8, 33u8, 121u8, 250u8, 137u8, + 142u8, + ], + ) + } + #[doc = " The map of page indices to pages."] + pub fn pages( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + >, + _1: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_message_queue::Page<::core::primitive::u32>, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "MessageQueue", + "Pages", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 45u8, 202u8, 18u8, 128u8, 31u8, 194u8, 175u8, 173u8, 99u8, 81u8, 161u8, + 44u8, 32u8, 183u8, 238u8, 181u8, 110u8, 240u8, 203u8, 12u8, 152u8, + 58u8, 239u8, 190u8, 144u8, 168u8, 210u8, 33u8, 121u8, 250u8, 137u8, + 142u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The size of the page; this implies the maximum message size which can be sent."] + #[doc = ""] + #[doc = " A good value depends on the expected message sizes, their weights, the weight that is"] + #[doc = " available for processing them and the maximal needed message size. The maximal message"] + #[doc = " size is slightly lower than this as defined by [`MaxMessageLenOf`]."] + pub fn heap_size(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "MessageQueue", + "HeapSize", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The maximum number of stale pages (i.e. of overweight messages) allowed before culling"] + #[doc = " can happen. Once there are more stale pages than this, then historical pages may be"] + #[doc = " dropped, even if they contain unprocessed overweight messages."] + pub fn max_stale(&self) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "MessageQueue", + "MaxStale", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " The amount of weight (if any) which should be provided to the message queue for"] + #[doc = " servicing enqueued items."] + #[doc = ""] + #[doc = " This may be legitimately `None` in the case that you will call"] + #[doc = " `ServiceQueues::service_queues` manually."] + pub fn service_weight( + &self, + ) -> ::subxt::constants::Address< + ::core::option::Option, + > { + ::subxt::constants::Address::new_static( + "MessageQueue", + "ServiceWeight", + [ + 204u8, 140u8, 63u8, 167u8, 49u8, 8u8, 148u8, 163u8, 190u8, 224u8, 15u8, + 103u8, 86u8, 153u8, 248u8, 117u8, 223u8, 117u8, 210u8, 80u8, 205u8, + 155u8, 40u8, 11u8, 59u8, 63u8, 129u8, 156u8, 17u8, 83u8, 177u8, 250u8, + ], + ) + } + } + } + } + pub mod utility { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::pallet_utility::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_utility::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Batch { + pub calls: ::std::vec::Vec, + } + impl ::subxt::blocks::StaticExtrinsic for Batch { + const PALLET: &'static str = "Utility"; + const CALL: &'static str = "batch"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsDerivative { + pub index: ::core::primitive::u16, + pub call: + ::std::boxed::Box, + } + impl ::subxt::blocks::StaticExtrinsic for AsDerivative { + const PALLET: &'static str = "Utility"; + const CALL: &'static str = "as_derivative"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BatchAll { + pub calls: ::std::vec::Vec, + } + impl ::subxt::blocks::StaticExtrinsic for BatchAll { + const PALLET: &'static str = "Utility"; + const CALL: &'static str = "batch_all"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DispatchAs { + pub as_origin: + ::std::boxed::Box, + pub call: + ::std::boxed::Box, + } + impl ::subxt::blocks::StaticExtrinsic for DispatchAs { + const PALLET: &'static str = "Utility"; + const CALL: &'static str = "dispatch_as"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ForceBatch { + pub calls: ::std::vec::Vec, + } + impl ::subxt::blocks::StaticExtrinsic for ForceBatch { + const PALLET: &'static str = "Utility"; + const CALL: &'static str = "force_batch"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WithWeight { + pub call: + ::std::boxed::Box, + pub weight: runtime_types::sp_weights::weight_v2::Weight, + } + impl ::subxt::blocks::StaticExtrinsic for WithWeight { + const PALLET: &'static str = "Utility"; + const CALL: &'static str = "with_weight"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::batch`]."] + pub fn batch( + &self, + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "batch", + types::Batch { calls }, + [ + 196u8, 209u8, 52u8, 231u8, 46u8, 197u8, 7u8, 8u8, 85u8, 223u8, 142u8, + 251u8, 7u8, 60u8, 113u8, 87u8, 8u8, 125u8, 194u8, 180u8, 144u8, 212u8, + 243u8, 127u8, 87u8, 76u8, 7u8, 54u8, 64u8, 141u8, 206u8, 51u8, + ], + ) + } + #[doc = "See [`Pallet::as_derivative`]."] + pub fn as_derivative( + &self, + index: ::core::primitive::u16, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "as_derivative", + types::AsDerivative { index, call: ::std::boxed::Box::new(call) }, + [ + 126u8, 211u8, 152u8, 5u8, 89u8, 68u8, 210u8, 83u8, 191u8, 217u8, 168u8, + 29u8, 141u8, 230u8, 4u8, 219u8, 91u8, 223u8, 27u8, 85u8, 63u8, 251u8, + 141u8, 0u8, 99u8, 230u8, 91u8, 145u8, 177u8, 106u8, 14u8, 189u8, + ], + ) + } + #[doc = "See [`Pallet::batch_all`]."] + pub fn batch_all( + &self, + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "batch_all", + types::BatchAll { calls }, + [ + 131u8, 0u8, 44u8, 110u8, 130u8, 180u8, 218u8, 239u8, 123u8, 185u8, + 204u8, 239u8, 83u8, 11u8, 0u8, 138u8, 164u8, 212u8, 139u8, 147u8, 20u8, + 105u8, 176u8, 167u8, 207u8, 66u8, 244u8, 13u8, 56u8, 50u8, 183u8, 26u8, + ], + ) + } + #[doc = "See [`Pallet::dispatch_as`]."] + pub fn dispatch_as( + &self, + as_origin: runtime_types::coretime_rococo_runtime::OriginCaller, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "dispatch_as", + types::DispatchAs { + as_origin: ::std::boxed::Box::new(as_origin), + call: ::std::boxed::Box::new(call), + }, + [ + 103u8, 50u8, 121u8, 101u8, 30u8, 227u8, 123u8, 125u8, 94u8, 185u8, + 74u8, 165u8, 178u8, 61u8, 204u8, 15u8, 220u8, 149u8, 88u8, 142u8, + 213u8, 16u8, 27u8, 11u8, 233u8, 82u8, 225u8, 11u8, 118u8, 201u8, 160u8, + 99u8, + ], + ) + } + #[doc = "See [`Pallet::force_batch`]."] + pub fn force_batch( + &self, + calls: ::std::vec::Vec, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "force_batch", + types::ForceBatch { calls }, + [ + 137u8, 141u8, 119u8, 237u8, 225u8, 180u8, 133u8, 11u8, 223u8, 67u8, + 96u8, 59u8, 207u8, 168u8, 81u8, 69u8, 109u8, 14u8, 202u8, 96u8, 10u8, + 66u8, 102u8, 222u8, 29u8, 9u8, 69u8, 28u8, 2u8, 99u8, 127u8, 173u8, + ], + ) + } + #[doc = "See [`Pallet::with_weight`]."] + pub fn with_weight( + &self, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Utility", + "with_weight", + types::WithWeight { call: ::std::boxed::Box::new(call), weight }, + [ + 169u8, 60u8, 21u8, 80u8, 219u8, 219u8, 154u8, 125u8, 254u8, 169u8, + 22u8, 243u8, 7u8, 4u8, 225u8, 11u8, 134u8, 236u8, 83u8, 184u8, 188u8, + 10u8, 248u8, 127u8, 240u8, 220u8, 74u8, 212u8, 104u8, 60u8, 31u8, + 164u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_utility::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] + #[doc = "well as the error."] + pub struct BatchInterrupted { + pub index: ::core::primitive::u32, + pub error: runtime_types::sp_runtime::DispatchError, + } + impl ::subxt::events::StaticEvent for BatchInterrupted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchInterrupted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Batch of dispatches completed fully with no error."] + pub struct BatchCompleted; + impl ::subxt::events::StaticEvent for BatchCompleted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchCompleted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Batch of dispatches completed but has errors."] + pub struct BatchCompletedWithErrors; + impl ::subxt::events::StaticEvent for BatchCompletedWithErrors { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "BatchCompletedWithErrors"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A single item within a Batch of dispatches has completed with no error."] + pub struct ItemCompleted; + impl ::subxt::events::StaticEvent for ItemCompleted { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "ItemCompleted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A single item within a Batch of dispatches has completed with error."] + pub struct ItemFailed { + pub error: runtime_types::sp_runtime::DispatchError, + } + impl ::subxt::events::StaticEvent for ItemFailed { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "ItemFailed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A call was dispatched."] + pub struct DispatchedAs { + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for DispatchedAs { + const PALLET: &'static str = "Utility"; + const EVENT: &'static str = "DispatchedAs"; + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The limit on the number of batched calls."] + pub fn batched_calls_limit( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Utility", + "batched_calls_limit", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod multisig { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::pallet_multisig::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_multisig::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsMultiThreshold1 { + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub call: + ::std::boxed::Box, + } + impl ::subxt::blocks::StaticExtrinsic for AsMultiThreshold1 { + const PALLET: &'static str = "Multisig"; + const CALL: &'static str = "as_multi_threshold_1"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + pub call: + ::std::boxed::Box, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + impl ::subxt::blocks::StaticExtrinsic for AsMulti { + const PALLET: &'static str = "Multisig"; + const CALL: &'static str = "as_multi"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ApproveAsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + pub call_hash: [::core::primitive::u8; 32usize], + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + impl ::subxt::blocks::StaticExtrinsic for ApproveAsMulti { + const PALLET: &'static str = "Multisig"; + const CALL: &'static str = "approve_as_multi"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CancelAsMulti { + pub threshold: ::core::primitive::u16, + pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + pub timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub call_hash: [::core::primitive::u8; 32usize], + } + impl ::subxt::blocks::StaticExtrinsic for CancelAsMulti { + const PALLET: &'static str = "Multisig"; + const CALL: &'static str = "cancel_as_multi"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::as_multi_threshold_1`]."] + pub fn as_multi_threshold_1( + &self, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Multisig", + "as_multi_threshold_1", + types::AsMultiThreshold1 { + other_signatories, + call: ::std::boxed::Box::new(call), + }, + [ + 254u8, 54u8, 88u8, 235u8, 170u8, 12u8, 95u8, 53u8, 93u8, 170u8, 39u8, + 224u8, 0u8, 128u8, 16u8, 91u8, 152u8, 70u8, 66u8, 52u8, 134u8, 110u8, + 178u8, 37u8, 53u8, 125u8, 162u8, 72u8, 102u8, 78u8, 73u8, 96u8, + ], + ) + } + #[doc = "See [`Pallet::as_multi`]."] + pub fn as_multi( + &self, + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Multisig", + "as_multi", + types::AsMulti { + threshold, + other_signatories, + maybe_timepoint, + call: ::std::boxed::Box::new(call), + max_weight, + }, + [ + 125u8, 11u8, 76u8, 234u8, 44u8, 41u8, 237u8, 218u8, 233u8, 225u8, + 254u8, 203u8, 234u8, 214u8, 181u8, 116u8, 14u8, 100u8, 187u8, 243u8, + 166u8, 26u8, 216u8, 0u8, 196u8, 134u8, 66u8, 121u8, 92u8, 100u8, 165u8, + 180u8, + ], + ) + } + #[doc = "See [`Pallet::approve_as_multi`]."] + pub fn approve_as_multi( + &self, + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + call_hash: [::core::primitive::u8; 32usize], + max_weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Multisig", + "approve_as_multi", + types::ApproveAsMulti { + threshold, + other_signatories, + maybe_timepoint, + call_hash, + max_weight, + }, + [ + 248u8, 46u8, 131u8, 35u8, 204u8, 12u8, 218u8, 150u8, 88u8, 131u8, 89u8, + 13u8, 95u8, 122u8, 87u8, 107u8, 136u8, 154u8, 92u8, 199u8, 108u8, 92u8, + 207u8, 171u8, 113u8, 8u8, 47u8, 248u8, 65u8, 26u8, 203u8, 135u8, + ], + ) + } + #[doc = "See [`Pallet::cancel_as_multi`]."] + pub fn cancel_as_multi( + &self, + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + call_hash: [::core::primitive::u8; 32usize], + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Multisig", + "cancel_as_multi", + types::CancelAsMulti { threshold, other_signatories, timepoint, call_hash }, + [ + 212u8, 179u8, 123u8, 40u8, 209u8, 228u8, 181u8, 0u8, 109u8, 28u8, 27u8, + 48u8, 15u8, 47u8, 203u8, 54u8, 106u8, 114u8, 28u8, 118u8, 101u8, 201u8, + 95u8, 187u8, 46u8, 182u8, 4u8, 30u8, 227u8, 105u8, 14u8, 81u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_multisig::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new multisig operation has begun."] + pub struct NewMultisig { + pub approving: ::subxt::utils::AccountId32, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for NewMultisig { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "NewMultisig"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A multisig operation has been approved by someone."] + pub struct MultisigApproval { + pub approving: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for MultisigApproval { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigApproval"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A multisig operation has been executed."] + pub struct MultisigExecuted { + pub approving: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], + pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for MultisigExecuted { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigExecuted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A multisig operation has been cancelled."] + pub struct MultisigCancelled { + pub cancelling: ::subxt::utils::AccountId32, + pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + pub multisig: ::subxt::utils::AccountId32, + pub call_hash: [::core::primitive::u8; 32usize], + } + impl ::subxt::events::StaticEvent for MultisigCancelled { + const PALLET: &'static str = "Multisig"; + const EVENT: &'static str = "MultisigCancelled"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The set of open multisig operations."] + pub fn multisigs_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_multisig::Multisig< + ::core::primitive::u32, + ::core::primitive::u128, + ::subxt::utils::AccountId32, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Multisig", + "Multisigs", + vec![], + [ + 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, + 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, + 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, + ], + ) + } + #[doc = " The set of open multisig operations."] + pub fn multisigs_iter1( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_multisig::Multisig< + ::core::primitive::u32, + ::core::primitive::u128, + ::subxt::utils::AccountId32, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Multisig", + "Multisigs", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, + 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, + 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, + ], + ) + } + #[doc = " The set of open multisig operations."] + pub fn multisigs( + &self, + _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, + _1: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_multisig::Multisig< + ::core::primitive::u32, + ::core::primitive::u128, + ::subxt::utils::AccountId32, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Multisig", + "Multisigs", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, + 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, + 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " The base amount of currency needed to reserve for creating a multisig execution or to"] + #[doc = " store a dispatch call for later."] + #[doc = ""] + #[doc = " This is held for an additional storage item whose value size is"] + #[doc = " `4 + sizeof((BlockNumber, Balance, AccountId))` bytes and whose key size is"] + #[doc = " `32 + sizeof(AccountId)` bytes."] + pub fn deposit_base(&self) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Multisig", + "DepositBase", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The amount of currency needed per unit threshold when creating a multisig execution."] + #[doc = ""] + #[doc = " This is held for adding 32 bytes more into a pre-existing storage value."] + pub fn deposit_factor( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u128> { + ::subxt::constants::Address::new_static( + "Multisig", + "DepositFactor", + [ + 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, + 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, + 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, + ], + ) + } + #[doc = " The maximum amount of signatories allowed in the multisig."] + pub fn max_signatories( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Multisig", + "MaxSignatories", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod broker { + use super::root_mod; + use super::runtime_types; + #[doc = "The `Error` enum of this pallet."] + pub type Error = runtime_types::pallet_broker::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_broker::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Configure { + pub config: runtime_types::pallet_broker::types::ConfigRecord< + ::core::primitive::u32, + ::core::primitive::u32, + >, + } + impl ::subxt::blocks::StaticExtrinsic for Configure { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "configure"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Reserve { + pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + } + impl ::subxt::blocks::StaticExtrinsic for Reserve { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "reserve"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Unreserve { + pub item_index: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for Unreserve { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "unreserve"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetLease { + pub task: ::core::primitive::u32, + pub until: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for SetLease { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "set_lease"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct StartSales { + pub initial_price: ::core::primitive::u128, + pub core_count: ::core::primitive::u16, + } + impl ::subxt::blocks::StaticExtrinsic for StartSales { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "start_sales"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Purchase { + pub price_limit: ::core::primitive::u128, + } + impl ::subxt::blocks::StaticExtrinsic for Purchase { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "purchase"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Renew { + pub core: ::core::primitive::u16, + } + impl ::subxt::blocks::StaticExtrinsic for Renew { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "renew"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Transfer { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub new_owner: ::subxt::utils::AccountId32, + } + impl ::subxt::blocks::StaticExtrinsic for Transfer { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "transfer"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Partition { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub pivot: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for Partition { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "partition"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Interlace { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub pivot: runtime_types::pallet_broker::core_mask::CoreMask, + } + impl ::subxt::blocks::StaticExtrinsic for Interlace { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "interlace"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Assign { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub task: ::core::primitive::u32, + pub finality: runtime_types::pallet_broker::types::Finality, + } + impl ::subxt::blocks::StaticExtrinsic for Assign { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "assign"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Pool { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub payee: ::subxt::utils::AccountId32, + pub finality: runtime_types::pallet_broker::types::Finality, + } + impl ::subxt::blocks::StaticExtrinsic for Pool { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "pool"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ClaimRevenue { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub max_timeslices: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for ClaimRevenue { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "claim_revenue"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PurchaseCredit { + pub amount: ::core::primitive::u128, + pub beneficiary: ::subxt::utils::AccountId32, + } + impl ::subxt::blocks::StaticExtrinsic for PurchaseCredit { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "purchase_credit"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DropRegion { + pub region_id: runtime_types::pallet_broker::types::RegionId, + } + impl ::subxt::blocks::StaticExtrinsic for DropRegion { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "drop_region"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DropContribution { + pub region_id: runtime_types::pallet_broker::types::RegionId, + } + impl ::subxt::blocks::StaticExtrinsic for DropContribution { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "drop_contribution"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DropHistory { + pub when: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for DropHistory { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "drop_history"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DropRenewal { + pub core: ::core::primitive::u16, + pub when: ::core::primitive::u32, + } + impl ::subxt::blocks::StaticExtrinsic for DropRenewal { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "drop_renewal"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RequestCoreCount { + pub core_count: ::core::primitive::u16, + } + impl ::subxt::blocks::StaticExtrinsic for RequestCoreCount { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "request_core_count"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct NotifyCoreCount { + pub core_count: ::core::primitive::u16, + } + impl ::subxt::blocks::StaticExtrinsic for NotifyCoreCount { + const PALLET: &'static str = "Broker"; + const CALL: &'static str = "notify_core_count"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::configure`]."] + pub fn configure( + &self, + config: runtime_types::pallet_broker::types::ConfigRecord< + ::core::primitive::u32, + ::core::primitive::u32, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "configure", + types::Configure { config }, + [ + 47u8, 41u8, 114u8, 129u8, 138u8, 255u8, 77u8, 164u8, 39u8, 215u8, + 231u8, 16u8, 128u8, 220u8, 80u8, 21u8, 199u8, 112u8, 5u8, 209u8, 6u8, + 196u8, 157u8, 38u8, 124u8, 127u8, 134u8, 246u8, 255u8, 191u8, 29u8, + 235u8, + ], + ) + } + #[doc = "See [`Pallet::reserve`]."] + pub fn reserve( + &self, + workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "reserve", + types::Reserve { workload }, + [ + 179u8, 93u8, 196u8, 189u8, 19u8, 203u8, 18u8, 244u8, 161u8, 158u8, + 222u8, 96u8, 140u8, 137u8, 255u8, 4u8, 126u8, 244u8, 236u8, 163u8, + 99u8, 232u8, 70u8, 173u8, 205u8, 167u8, 26u8, 55u8, 133u8, 249u8, 20u8, + 154u8, + ], + ) + } + #[doc = "See [`Pallet::unreserve`]."] + pub fn unreserve( + &self, + item_index: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "unreserve", + types::Unreserve { item_index }, + [ + 159u8, 127u8, 127u8, 134u8, 252u8, 69u8, 255u8, 67u8, 14u8, 221u8, + 14u8, 56u8, 194u8, 46u8, 33u8, 150u8, 67u8, 124u8, 122u8, 138u8, 74u8, + 186u8, 185u8, 182u8, 42u8, 20u8, 42u8, 178u8, 245u8, 72u8, 116u8, 18u8, + ], + ) + } + #[doc = "See [`Pallet::set_lease`]."] + pub fn set_lease( + &self, + task: ::core::primitive::u32, + until: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "set_lease", + types::SetLease { task, until }, + [ + 183u8, 72u8, 230u8, 156u8, 226u8, 167u8, 172u8, 191u8, 10u8, 221u8, + 224u8, 153u8, 217u8, 195u8, 165u8, 138u8, 154u8, 158u8, 140u8, 121u8, + 77u8, 139u8, 152u8, 7u8, 250u8, 8u8, 33u8, 183u8, 250u8, 150u8, 105u8, + 199u8, + ], + ) + } + #[doc = "See [`Pallet::start_sales`]."] + pub fn start_sales( + &self, + initial_price: ::core::primitive::u128, + core_count: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "start_sales", + types::StartSales { initial_price, core_count }, + [ + 78u8, 51u8, 30u8, 152u8, 207u8, 24u8, 207u8, 149u8, 236u8, 132u8, 62u8, + 228u8, 250u8, 140u8, 44u8, 240u8, 59u8, 114u8, 148u8, 198u8, 151u8, + 127u8, 221u8, 188u8, 250u8, 161u8, 104u8, 7u8, 225u8, 80u8, 170u8, + 207u8, + ], + ) + } + #[doc = "See [`Pallet::purchase`]."] + pub fn purchase( + &self, + price_limit: ::core::primitive::u128, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "purchase", + types::Purchase { price_limit }, + [ + 180u8, 34u8, 117u8, 232u8, 116u8, 211u8, 229u8, 201u8, 144u8, 72u8, + 36u8, 255u8, 68u8, 70u8, 150u8, 113u8, 230u8, 12u8, 152u8, 88u8, 137u8, + 220u8, 36u8, 6u8, 96u8, 236u8, 108u8, 186u8, 103u8, 92u8, 207u8, 176u8, + ], + ) + } + #[doc = "See [`Pallet::renew`]."] + pub fn renew( + &self, + core: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "renew", + types::Renew { core }, + [ + 89u8, 65u8, 189u8, 173u8, 166u8, 60u8, 207u8, 186u8, 18u8, 239u8, + 130u8, 6u8, 200u8, 56u8, 74u8, 221u8, 220u8, 88u8, 213u8, 202u8, 125u8, + 44u8, 75u8, 102u8, 192u8, 238u8, 170u8, 18u8, 186u8, 101u8, 181u8, + 105u8, + ], + ) + } + #[doc = "See [`Pallet::transfer`]."] + pub fn transfer( + &self, + region_id: runtime_types::pallet_broker::types::RegionId, + new_owner: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "transfer", + types::Transfer { region_id, new_owner }, + [ + 80u8, 18u8, 186u8, 227u8, 213u8, 255u8, 214u8, 84u8, 250u8, 102u8, + 108u8, 104u8, 158u8, 4u8, 14u8, 94u8, 122u8, 6u8, 74u8, 182u8, 193u8, + 11u8, 191u8, 226u8, 2u8, 184u8, 104u8, 126u8, 66u8, 22u8, 125u8, 249u8, + ], + ) + } + #[doc = "See [`Pallet::partition`]."] + pub fn partition( + &self, + region_id: runtime_types::pallet_broker::types::RegionId, + pivot: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "partition", + types::Partition { region_id, pivot }, + [ + 8u8, 89u8, 3u8, 231u8, 184u8, 148u8, 1u8, 32u8, 90u8, 170u8, 209u8, + 110u8, 243u8, 170u8, 140u8, 168u8, 241u8, 4u8, 223u8, 68u8, 70u8, 52u8, + 109u8, 128u8, 61u8, 167u8, 51u8, 133u8, 74u8, 141u8, 0u8, 36u8, + ], + ) + } + #[doc = "See [`Pallet::interlace`]."] + pub fn interlace( + &self, + region_id: runtime_types::pallet_broker::types::RegionId, + pivot: runtime_types::pallet_broker::core_mask::CoreMask, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "interlace", + types::Interlace { region_id, pivot }, + [ + 7u8, 93u8, 42u8, 166u8, 194u8, 35u8, 255u8, 78u8, 40u8, 127u8, 224u8, + 63u8, 218u8, 150u8, 143u8, 233u8, 48u8, 33u8, 140u8, 72u8, 247u8, + 251u8, 179u8, 25u8, 68u8, 157u8, 27u8, 108u8, 183u8, 159u8, 33u8, + 123u8, + ], + ) + } + #[doc = "See [`Pallet::assign`]."] + pub fn assign( + &self, + region_id: runtime_types::pallet_broker::types::RegionId, + task: ::core::primitive::u32, + finality: runtime_types::pallet_broker::types::Finality, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "assign", + types::Assign { region_id, task, finality }, + [ + 91u8, 132u8, 233u8, 43u8, 154u8, 152u8, 15u8, 44u8, 202u8, 230u8, + 122u8, 5u8, 3u8, 5u8, 116u8, 221u8, 207u8, 161u8, 160u8, 100u8, 151u8, + 98u8, 161u8, 218u8, 124u8, 92u8, 45u8, 0u8, 103u8, 188u8, 223u8, 53u8, + ], + ) + } + #[doc = "See [`Pallet::pool`]."] + pub fn pool( + &self, + region_id: runtime_types::pallet_broker::types::RegionId, + payee: ::subxt::utils::AccountId32, + finality: runtime_types::pallet_broker::types::Finality, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "pool", + types::Pool { region_id, payee, finality }, + [ + 14u8, 189u8, 13u8, 148u8, 5u8, 149u8, 194u8, 194u8, 84u8, 123u8, 52u8, + 69u8, 38u8, 226u8, 26u8, 222u8, 247u8, 149u8, 148u8, 248u8, 145u8, + 205u8, 36u8, 139u8, 40u8, 126u8, 14u8, 54u8, 83u8, 248u8, 240u8, 139u8, + ], + ) + } + #[doc = "See [`Pallet::claim_revenue`]."] + pub fn claim_revenue( + &self, + region_id: runtime_types::pallet_broker::types::RegionId, + max_timeslices: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "claim_revenue", + types::ClaimRevenue { region_id, max_timeslices }, + [ + 124u8, 55u8, 35u8, 170u8, 105u8, 123u8, 63u8, 62u8, 63u8, 149u8, 17u8, + 149u8, 185u8, 220u8, 151u8, 206u8, 14u8, 217u8, 84u8, 97u8, 81u8, + 250u8, 122u8, 124u8, 189u8, 144u8, 211u8, 126u8, 158u8, 80u8, 249u8, + 237u8, + ], + ) + } + #[doc = "See [`Pallet::purchase_credit`]."] + pub fn purchase_credit( + &self, + amount: ::core::primitive::u128, + beneficiary: ::subxt::utils::AccountId32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "purchase_credit", + types::PurchaseCredit { amount, beneficiary }, + [ + 112u8, 183u8, 193u8, 102u8, 30u8, 216u8, 254u8, 165u8, 45u8, 117u8, + 26u8, 95u8, 232u8, 47u8, 237u8, 81u8, 13u8, 191u8, 179u8, 107u8, 183u8, + 182u8, 168u8, 106u8, 164u8, 89u8, 193u8, 116u8, 36u8, 181u8, 146u8, + 160u8, + ], + ) + } + #[doc = "See [`Pallet::drop_region`]."] + pub fn drop_region( + &self, + region_id: runtime_types::pallet_broker::types::RegionId, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "drop_region", + types::DropRegion { region_id }, + [ + 192u8, 116u8, 124u8, 133u8, 187u8, 176u8, 149u8, 187u8, 230u8, 107u8, + 149u8, 185u8, 139u8, 18u8, 154u8, 186u8, 153u8, 56u8, 199u8, 218u8, + 117u8, 84u8, 113u8, 15u8, 233u8, 177u8, 33u8, 224u8, 182u8, 191u8, + 202u8, 234u8, + ], + ) + } + #[doc = "See [`Pallet::drop_contribution`]."] + pub fn drop_contribution( + &self, + region_id: runtime_types::pallet_broker::types::RegionId, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "drop_contribution", + types::DropContribution { region_id }, + [ + 174u8, 22u8, 254u8, 7u8, 41u8, 231u8, 26u8, 174u8, 125u8, 110u8, 9u8, + 27u8, 116u8, 152u8, 51u8, 247u8, 167u8, 126u8, 92u8, 232u8, 122u8, + 189u8, 37u8, 166u8, 181u8, 75u8, 33u8, 188u8, 147u8, 110u8, 111u8, + 10u8, + ], + ) + } + #[doc = "See [`Pallet::drop_history`]."] + pub fn drop_history( + &self, + when: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "drop_history", + types::DropHistory { when }, + [ + 57u8, 162u8, 131u8, 40u8, 152u8, 60u8, 57u8, 118u8, 165u8, 10u8, 170u8, + 202u8, 43u8, 5u8, 118u8, 213u8, 151u8, 89u8, 119u8, 247u8, 133u8, 78u8, + 13u8, 229u8, 159u8, 106u8, 47u8, 244u8, 140u8, 20u8, 80u8, 106u8, + ], + ) + } + #[doc = "See [`Pallet::drop_renewal`]."] + pub fn drop_renewal( + &self, + core: ::core::primitive::u16, + when: ::core::primitive::u32, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "drop_renewal", + types::DropRenewal { core, when }, + [ + 209u8, 97u8, 211u8, 220u8, 204u8, 144u8, 175u8, 124u8, 55u8, 157u8, + 186u8, 45u8, 197u8, 25u8, 107u8, 108u8, 45u8, 163u8, 95u8, 200u8, + 130u8, 163u8, 22u8, 229u8, 15u8, 249u8, 135u8, 102u8, 12u8, 179u8, + 77u8, 162u8, + ], + ) + } + #[doc = "See [`Pallet::request_core_count`]."] + pub fn request_core_count( + &self, + core_count: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "request_core_count", + types::RequestCoreCount { core_count }, + [ + 32u8, 197u8, 224u8, 109u8, 148u8, 220u8, 31u8, 58u8, 219u8, 175u8, + 220u8, 169u8, 217u8, 190u8, 128u8, 122u8, 142u8, 12u8, 52u8, 105u8, + 40u8, 236u8, 54u8, 27u8, 246u8, 8u8, 152u8, 213u8, 127u8, 25u8, 118u8, + 20u8, + ], + ) + } + #[doc = "See [`Pallet::notify_core_count`]."] + pub fn notify_core_count( + &self, + core_count: ::core::primitive::u16, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Broker", + "notify_core_count", + types::NotifyCoreCount { core_count }, + [ + 53u8, 44u8, 53u8, 90u8, 247u8, 189u8, 94u8, 149u8, 143u8, 96u8, 51u8, + 87u8, 68u8, 179u8, 121u8, 183u8, 82u8, 109u8, 247u8, 21u8, 164u8, + 180u8, 133u8, 228u8, 247u8, 220u8, 15u8, 48u8, 113u8, 246u8, 112u8, + 49u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_broker::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A Region of Bulk Coretime has been purchased."] + pub struct Purchased { + pub who: ::subxt::utils::AccountId32, + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub price: ::core::primitive::u128, + pub duration: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Purchased { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Purchased"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The workload of a core has become renewable."] + pub struct Renewable { + pub core: ::core::primitive::u16, + pub price: ::core::primitive::u128, + pub begin: ::core::primitive::u32, + pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + } + impl ::subxt::events::StaticEvent for Renewable { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Renewable"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A workload has been renewed."] + pub struct Renewed { + pub who: ::subxt::utils::AccountId32, + pub price: ::core::primitive::u128, + pub old_core: ::core::primitive::u16, + pub core: ::core::primitive::u16, + pub begin: ::core::primitive::u32, + pub duration: ::core::primitive::u32, + pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + } + impl ::subxt::events::StaticEvent for Renewed { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Renewed"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Ownership of a Region has been transferred."] + pub struct Transferred { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub duration: ::core::primitive::u32, + pub old_owner: ::subxt::utils::AccountId32, + pub owner: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for Transferred { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Transferred"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A Region has been split into two non-overlapping Regions."] + pub struct Partitioned { + pub old_region_id: runtime_types::pallet_broker::types::RegionId, + pub new_region_ids: ( + runtime_types::pallet_broker::types::RegionId, + runtime_types::pallet_broker::types::RegionId, + ), + } + impl ::subxt::events::StaticEvent for Partitioned { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Partitioned"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A Region has been converted into two overlapping Regions each of lesser regularity."] + pub struct Interlaced { + pub old_region_id: runtime_types::pallet_broker::types::RegionId, + pub new_region_ids: ( + runtime_types::pallet_broker::types::RegionId, + runtime_types::pallet_broker::types::RegionId, + ), + } + impl ::subxt::events::StaticEvent for Interlaced { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Interlaced"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A Region has been assigned to a particular task."] + pub struct Assigned { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub duration: ::core::primitive::u32, + pub task: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Assigned { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Assigned"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A Region has been added to the Instantaneous Coretime Pool."] + pub struct Pooled { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub duration: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Pooled { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Pooled"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new number of cores has been requested."] + pub struct CoreCountRequested { + pub core_count: ::core::primitive::u16, + } + impl ::subxt::events::StaticEvent for CoreCountRequested { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "CoreCountRequested"; + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The number of cores available for scheduling has changed."] + pub struct CoreCountChanged { + pub core_count: ::core::primitive::u16, + } + impl ::subxt::events::StaticEvent for CoreCountChanged { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "CoreCountChanged"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "There is a new reservation for a workload."] + pub struct ReservationMade { + pub index: ::core::primitive::u32, + pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + } + impl ::subxt::events::StaticEvent for ReservationMade { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "ReservationMade"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A reservation for a workload has been cancelled."] + pub struct ReservationCancelled { + pub index: ::core::primitive::u32, + pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + } + impl ::subxt::events::StaticEvent for ReservationCancelled { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "ReservationCancelled"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new sale has been initialized."] + pub struct SaleInitialized { + pub sale_start: ::core::primitive::u32, + pub leadin_length: ::core::primitive::u32, + pub start_price: ::core::primitive::u128, + pub regular_price: ::core::primitive::u128, + pub region_begin: ::core::primitive::u32, + pub region_end: ::core::primitive::u32, + pub ideal_cores_sold: ::core::primitive::u16, + pub cores_offered: ::core::primitive::u16, + } + impl ::subxt::events::StaticEvent for SaleInitialized { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "SaleInitialized"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A new lease has been created."] + pub struct Leased { + pub task: ::core::primitive::u32, + pub until: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for Leased { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Leased"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A lease is about to end."] + pub struct LeaseEnding { + pub task: ::core::primitive::u32, + pub when: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for LeaseEnding { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "LeaseEnding"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The sale rotation has been started and a new sale is imminent."] + pub struct SalesStarted { + pub price: ::core::primitive::u128, + pub core_count: ::core::primitive::u16, + } + impl ::subxt::events::StaticEvent for SalesStarted { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "SalesStarted"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The act of claiming revenue has begun."] + pub struct RevenueClaimBegun { + pub region: runtime_types::pallet_broker::types::RegionId, + pub max_timeslices: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for RevenueClaimBegun { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "RevenueClaimBegun"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A particular timeslice has a non-zero claim."] + pub struct RevenueClaimItem { + pub when: ::core::primitive::u32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for RevenueClaimItem { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "RevenueClaimItem"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A revenue claim has (possibly only in part) been paid."] + pub struct RevenueClaimPaid { + pub who: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + pub next: ::core::option::Option, + } + impl ::subxt::events::StaticEvent for RevenueClaimPaid { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "RevenueClaimPaid"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some Instantaneous Coretime Pool credit has been purchased."] + pub struct CreditPurchased { + pub who: ::subxt::utils::AccountId32, + pub beneficiary: ::subxt::utils::AccountId32, + pub amount: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for CreditPurchased { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "CreditPurchased"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A Region has been dropped due to being out of date."] + pub struct RegionDropped { + pub region_id: runtime_types::pallet_broker::types::RegionId, + pub duration: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for RegionDropped { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "RegionDropped"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some historical Instantaneous Core Pool contribution record has been dropped."] + pub struct ContributionDropped { + pub region_id: runtime_types::pallet_broker::types::RegionId, + } + impl ::subxt::events::StaticEvent for ContributionDropped { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "ContributionDropped"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some historical Instantaneous Core Pool payment record has been initialized."] + pub struct HistoryInitialized { + pub when: ::core::primitive::u32, + pub private_pool_size: ::core::primitive::u32, + pub system_pool_size: ::core::primitive::u32, + } + impl ::subxt::events::StaticEvent for HistoryInitialized { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "HistoryInitialized"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some historical Instantaneous Core Pool payment record has been dropped."] + pub struct HistoryDropped { + pub when: ::core::primitive::u32, + pub revenue: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for HistoryDropped { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "HistoryDropped"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some historical Instantaneous Core Pool payment record has been ignored because the"] + #[doc = "timeslice was already known. Governance may need to intervene."] + pub struct HistoryIgnored { + pub when: ::core::primitive::u32, + pub revenue: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for HistoryIgnored { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "HistoryIgnored"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some historical Instantaneous Core Pool Revenue is ready for payout claims."] + pub struct ClaimsReady { + pub when: ::core::primitive::u32, + pub system_payout: ::core::primitive::u128, + pub private_payout: ::core::primitive::u128, + } + impl ::subxt::events::StaticEvent for ClaimsReady { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "ClaimsReady"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A Core has been assigned to one or more tasks and/or the Pool on the Relay-chain."] + pub struct CoreAssigned { + pub core: ::core::primitive::u16, + pub when: ::core::primitive::u32, + pub assignment: ::std::vec::Vec<( + runtime_types::pallet_broker::coretime_interface::CoreAssignment, + ::core::primitive::u16, + )>, + } + impl ::subxt::events::StaticEvent for CoreAssigned { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "CoreAssigned"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Some historical Instantaneous Core Pool payment record has been dropped."] + pub struct AllowedRenewalDropped { + pub when: ::core::primitive::u32, + pub core: ::core::primitive::u16, + } + impl ::subxt::events::StaticEvent for AllowedRenewalDropped { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "AllowedRenewalDropped"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The current configuration of this pallet."] + pub fn configuration( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::ConfigRecord< + ::core::primitive::u32, + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Configuration", + vec![], + [ + 235u8, 144u8, 177u8, 6u8, 2u8, 211u8, 0u8, 98u8, 225u8, 133u8, 98u8, + 140u8, 13u8, 117u8, 87u8, 151u8, 42u8, 52u8, 237u8, 170u8, 59u8, 108u8, + 169u8, 254u8, 87u8, 225u8, 64u8, 42u8, 226u8, 214u8, 219u8, 255u8, + ], + ) + } + #[doc = " The Polkadot Core reservations (generally tasked with the maintenance of System Chains)."] + pub fn reservations( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Reservations", + vec![], + [ + 181u8, 60u8, 95u8, 87u8, 83u8, 84u8, 101u8, 181u8, 171u8, 223u8, 229u8, + 6u8, 197u8, 87u8, 137u8, 19u8, 132u8, 252u8, 158u8, 51u8, 193u8, 13u8, + 205u8, 24u8, 133u8, 27u8, 53u8, 23u8, 97u8, 160u8, 39u8, 38u8, + ], + ) + } + #[doc = " The Polkadot Core legacy leases."] + pub fn leases( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::LeaseRecordItem, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Leases", + vec![], + [ + 120u8, 85u8, 234u8, 191u8, 14u8, 161u8, 200u8, 43u8, 248u8, 220u8, + 220u8, 183u8, 62u8, 101u8, 32u8, 34u8, 2u8, 157u8, 140u8, 107u8, 114u8, + 168u8, 121u8, 161u8, 113u8, 223u8, 86u8, 183u8, 226u8, 233u8, 2u8, + 250u8, + ], + ) + } + #[doc = " The current status of miscellaneous subsystems of this pallet."] + pub fn status( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::StatusRecord, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Status", + vec![], + [ + 226u8, 93u8, 147u8, 26u8, 160u8, 235u8, 247u8, 150u8, 187u8, 108u8, + 138u8, 71u8, 227u8, 121u8, 51u8, 106u8, 10u8, 18u8, 58u8, 56u8, 128u8, + 186u8, 93u8, 230u8, 176u8, 248u8, 111u8, 140u8, 148u8, 39u8, 84u8, + 144u8, + ], + ) + } + #[doc = " The details of the current sale, including its properties and status."] + pub fn sale_info( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::SaleInfoRecord< + ::core::primitive::u128, + ::core::primitive::u32, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "SaleInfo", + vec![], + [ + 127u8, 255u8, 82u8, 247u8, 241u8, 27u8, 105u8, 176u8, 147u8, 196u8, + 190u8, 63u8, 235u8, 1u8, 165u8, 106u8, 91u8, 165u8, 58u8, 132u8, 100u8, + 94u8, 106u8, 224u8, 16u8, 33u8, 50u8, 120u8, 90u8, 163u8, 108u8, 165u8, + ], + ) + } + #[doc = " Records of allowed renewals."] + pub fn allowed_renewals_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::AllowedRenewalRecord< + ::core::primitive::u128, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "AllowedRenewals", + vec![], + [ + 198u8, 33u8, 189u8, 111u8, 176u8, 156u8, 94u8, 163u8, 130u8, 227u8, + 84u8, 165u8, 51u8, 92u8, 103u8, 62u8, 254u8, 102u8, 161u8, 31u8, 228u8, + 88u8, 91u8, 62u8, 155u8, 23u8, 183u8, 246u8, 73u8, 90u8, 151u8, 209u8, + ], + ) + } + #[doc = " Records of allowed renewals."] + pub fn allowed_renewals( + &self, + _0: impl ::std::borrow::Borrow< + runtime_types::pallet_broker::types::AllowedRenewalId, + >, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::AllowedRenewalRecord< + ::core::primitive::u128, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "AllowedRenewals", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 198u8, 33u8, 189u8, 111u8, 176u8, 156u8, 94u8, 163u8, 130u8, 227u8, + 84u8, 165u8, 51u8, 92u8, 103u8, 62u8, 254u8, 102u8, 161u8, 31u8, 228u8, + 88u8, 91u8, 62u8, 155u8, 23u8, 183u8, 246u8, 73u8, 90u8, 151u8, 209u8, + ], + ) + } + #[doc = " The current (unassigned) Regions."] + pub fn regions_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::RegionRecord< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Regions", + vec![], + [ + 13u8, 138u8, 239u8, 59u8, 188u8, 5u8, 37u8, 111u8, 236u8, 244u8, 11u8, + 46u8, 70u8, 54u8, 140u8, 148u8, 153u8, 181u8, 57u8, 114u8, 27u8, 156u8, + 177u8, 222u8, 211u8, 79u8, 213u8, 252u8, 68u8, 12u8, 150u8, 70u8, + ], + ) + } + #[doc = " The current (unassigned) Regions."] + pub fn regions( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::RegionRecord< + ::subxt::utils::AccountId32, + ::core::primitive::u128, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Regions", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 13u8, 138u8, 239u8, 59u8, 188u8, 5u8, 37u8, 111u8, 236u8, 244u8, 11u8, + 46u8, 70u8, 54u8, 140u8, 148u8, 153u8, 181u8, 57u8, 114u8, 27u8, 156u8, + 177u8, 222u8, 211u8, 79u8, 213u8, 252u8, 68u8, 12u8, 150u8, 70u8, + ], + ) + } + #[doc = " The work we plan on having each core do at a particular time in the future."] + pub fn workplan_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Workplan", + vec![], + [ + 208u8, 23u8, 159u8, 5u8, 97u8, 15u8, 8u8, 3u8, 120u8, 151u8, 25u8, + 172u8, 99u8, 84u8, 164u8, 151u8, 35u8, 231u8, 194u8, 176u8, 74u8, + 132u8, 110u8, 238u8, 159u8, 197u8, 36u8, 64u8, 54u8, 69u8, 72u8, 163u8, + ], + ) + } + #[doc = " The work we plan on having each core do at a particular time in the future."] + pub fn workplan_iter1( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Workplan", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 208u8, 23u8, 159u8, 5u8, 97u8, 15u8, 8u8, 3u8, 120u8, 151u8, 25u8, + 172u8, 99u8, 84u8, 164u8, 151u8, 35u8, 231u8, 194u8, 176u8, 74u8, + 132u8, 110u8, 238u8, 159u8, 197u8, 36u8, 64u8, 54u8, 69u8, 72u8, 163u8, + ], + ) + } + #[doc = " The work we plan on having each core do at a particular time in the future."] + pub fn workplan( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + _1: impl ::std::borrow::Borrow<::core::primitive::u16>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Workplan", + vec![ + ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), + ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), + ], + [ + 208u8, 23u8, 159u8, 5u8, 97u8, 15u8, 8u8, 3u8, 120u8, 151u8, 25u8, + 172u8, 99u8, 84u8, 164u8, 151u8, 35u8, 231u8, 194u8, 176u8, 74u8, + 132u8, 110u8, 238u8, 159u8, 197u8, 36u8, 64u8, 54u8, 69u8, 72u8, 163u8, + ], + ) + } + #[doc = " The current workload of each core. This gets updated with workplan as timeslices pass."] + pub fn workload_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Workload", + vec![], + [ + 45u8, 113u8, 84u8, 213u8, 62u8, 242u8, 79u8, 85u8, 136u8, 4u8, 216u8, + 202u8, 30u8, 188u8, 60u8, 157u8, 245u8, 141u8, 248u8, 95u8, 247u8, + 119u8, 9u8, 235u8, 164u8, 169u8, 68u8, 99u8, 217u8, 131u8, 250u8, + 137u8, + ], + ) + } + #[doc = " The current workload of each core. This gets updated with workplan as timeslices pass."] + pub fn workload( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u16>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "Workload", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 45u8, 113u8, 84u8, 213u8, 62u8, 242u8, 79u8, 85u8, 136u8, 4u8, 216u8, + 202u8, 30u8, 188u8, 60u8, 157u8, 245u8, 141u8, 248u8, 95u8, 247u8, + 119u8, 9u8, 235u8, 164u8, 169u8, 68u8, 99u8, 217u8, 131u8, 250u8, + 137u8, + ], + ) + } + #[doc = " Record of a single contribution to the Instantaneous Coretime Pool."] + pub fn insta_pool_contribution_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::ContributionRecord< + ::subxt::utils::AccountId32, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "InstaPoolContribution", + vec![], + [ + 225u8, 37u8, 29u8, 149u8, 219u8, 135u8, 224u8, 209u8, 135u8, 209u8, + 121u8, 140u8, 72u8, 231u8, 213u8, 173u8, 125u8, 250u8, 14u8, 41u8, + 65u8, 242u8, 58u8, 65u8, 27u8, 164u8, 32u8, 174u8, 175u8, 253u8, 205u8, + 192u8, + ], + ) + } + #[doc = " Record of a single contribution to the Instantaneous Coretime Pool."] + pub fn insta_pool_contribution( + &self, + _0: impl ::std::borrow::Borrow, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::ContributionRecord< + ::subxt::utils::AccountId32, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "InstaPoolContribution", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 225u8, 37u8, 29u8, 149u8, 219u8, 135u8, 224u8, 209u8, 135u8, 209u8, + 121u8, 140u8, 72u8, 231u8, 213u8, 173u8, 125u8, 250u8, 14u8, 41u8, + 65u8, 242u8, 58u8, 65u8, 27u8, 164u8, 32u8, 174u8, 175u8, 253u8, 205u8, + 192u8, + ], + ) + } + #[doc = " Record of Coretime entering or leaving the Instantaneous Coretime Pool."] + pub fn insta_pool_io_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::PoolIoRecord, + (), + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "InstaPoolIo", + vec![], + [ + 162u8, 151u8, 195u8, 176u8, 123u8, 253u8, 27u8, 213u8, 21u8, 145u8, + 189u8, 94u8, 166u8, 4u8, 46u8, 24u8, 68u8, 151u8, 16u8, 131u8, 45u8, + 201u8, 54u8, 188u8, 26u8, 164u8, 35u8, 251u8, 78u8, 56u8, 39u8, 141u8, + ], + ) + } + #[doc = " Record of Coretime entering or leaving the Instantaneous Coretime Pool."] + pub fn insta_pool_io( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::PoolIoRecord, + ::subxt::storage::address::Yes, + ::subxt::storage::address::Yes, + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "InstaPoolIo", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 162u8, 151u8, 195u8, 176u8, 123u8, 253u8, 27u8, 213u8, 21u8, 145u8, + 189u8, 94u8, 166u8, 4u8, 46u8, 24u8, 68u8, 151u8, 16u8, 131u8, 45u8, + 201u8, 54u8, 188u8, 26u8, 164u8, 35u8, 251u8, 78u8, 56u8, 39u8, 141u8, + ], + ) + } + #[doc = " Total InstaPool rewards for each Timeslice and the number of core parts which contributed."] + pub fn insta_pool_history_iter( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::InstaPoolHistoryRecord< + ::core::primitive::u128, + >, + (), + (), + ::subxt::storage::address::Yes, + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "InstaPoolHistory", + vec![], + [ + 126u8, 207u8, 245u8, 55u8, 169u8, 211u8, 138u8, 201u8, 39u8, 31u8, + 176u8, 228u8, 252u8, 247u8, 198u8, 195u8, 134u8, 17u8, 139u8, 200u8, + 58u8, 159u8, 232u8, 213u8, 232u8, 43u8, 30u8, 15u8, 151u8, 236u8, 76u8, + 85u8, + ], + ) + } + #[doc = " Total InstaPool rewards for each Timeslice and the number of core parts which contributed."] + pub fn insta_pool_history( + &self, + _0: impl ::std::borrow::Borrow<::core::primitive::u32>, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + runtime_types::pallet_broker::types::InstaPoolHistoryRecord< + ::core::primitive::u128, + >, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "InstaPoolHistory", + vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], + [ + 126u8, 207u8, 245u8, 55u8, 169u8, 211u8, 138u8, 201u8, 39u8, 31u8, + 176u8, 228u8, 252u8, 247u8, 198u8, 195u8, 134u8, 17u8, 139u8, 200u8, + 58u8, 159u8, 232u8, 213u8, 232u8, 43u8, 30u8, 15u8, 151u8, 236u8, 76u8, + 85u8, + ], + ) + } + #[doc = " Received core count change from the relay chain."] + pub fn core_count_inbox( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::core::primitive::u16, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Broker", + "CoreCountInbox", + vec![], + [ + 78u8, 33u8, 242u8, 74u8, 188u8, 71u8, 31u8, 182u8, 130u8, 205u8, 58u8, + 165u8, 83u8, 161u8, 140u8, 26u8, 208u8, 233u8, 130u8, 27u8, 170u8, + 220u8, 249u8, 195u8, 200u8, 141u8, 28u8, 20u8, 68u8, 86u8, 23u8, 182u8, + ], + ) + } + } + } + pub mod constants { + use super::runtime_types; + pub struct ConstantsApi; + impl ConstantsApi { + #[doc = " Identifier from which the internal Pot is generated."] + pub fn pallet_id( + &self, + ) -> ::subxt::constants::Address { + ::subxt::constants::Address::new_static( + "Broker", + "PalletId", + [ + 56u8, 243u8, 53u8, 83u8, 154u8, 179u8, 170u8, 80u8, 133u8, 173u8, 61u8, + 161u8, 47u8, 225u8, 146u8, 21u8, 50u8, 229u8, 248u8, 27u8, 104u8, 58u8, + 129u8, 197u8, 102u8, 160u8, 168u8, 205u8, 154u8, 42u8, 217u8, 53u8, + ], + ) + } + #[doc = " Number of Relay-chain blocks per timeslice."] + pub fn timeslice_period( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Broker", + "TimeslicePeriod", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Maximum number of legacy leases."] + pub fn max_leased_cores( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Broker", + "MaxLeasedCores", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + #[doc = " Maximum number of system cores."] + pub fn max_reserved_cores( + &self, + ) -> ::subxt::constants::Address<::core::primitive::u32> { + ::subxt::constants::Address::new_static( + "Broker", + "MaxReservedCores", + [ + 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, + 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, + 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, + 145u8, + ], + ) + } + } + } + } + pub mod sudo { + use super::root_mod; + use super::runtime_types; + #[doc = "Error for the Sudo pallet."] + pub type Error = runtime_types::pallet_sudo::pallet::Error; + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub type Call = runtime_types::pallet_sudo::pallet::Call; + pub mod calls { + use super::root_mod; + use super::runtime_types; + type DispatchError = runtime_types::sp_runtime::DispatchError; + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Sudo { + pub call: + ::std::boxed::Box, + } + impl ::subxt::blocks::StaticExtrinsic for Sudo { + const PALLET: &'static str = "Sudo"; + const CALL: &'static str = "sudo"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SudoUncheckedWeight { + pub call: + ::std::boxed::Box, + pub weight: runtime_types::sp_weights::weight_v2::Weight, + } + impl ::subxt::blocks::StaticExtrinsic for SudoUncheckedWeight { + const PALLET: &'static str = "Sudo"; + const CALL: &'static str = "sudo_unchecked_weight"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SetKey { + pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + } + impl ::subxt::blocks::StaticExtrinsic for SetKey { + const PALLET: &'static str = "Sudo"; + const CALL: &'static str = "set_key"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SudoAs { + pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + pub call: + ::std::boxed::Box, + } + impl ::subxt::blocks::StaticExtrinsic for SudoAs { + const PALLET: &'static str = "Sudo"; + const CALL: &'static str = "sudo_as"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoveKey; + impl ::subxt::blocks::StaticExtrinsic for RemoveKey { + const PALLET: &'static str = "Sudo"; + const CALL: &'static str = "remove_key"; + } + } + pub struct TransactionApi; + impl TransactionApi { + #[doc = "See [`Pallet::sudo`]."] + pub fn sudo( + &self, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Sudo", + "sudo", + types::Sudo { call: ::std::boxed::Box::new(call) }, + [ + 41u8, 23u8, 149u8, 206u8, 108u8, 62u8, 70u8, 168u8, 244u8, 16u8, 168u8, + 159u8, 122u8, 103u8, 32u8, 146u8, 180u8, 215u8, 7u8, 163u8, 102u8, + 243u8, 125u8, 59u8, 3u8, 110u8, 165u8, 65u8, 4u8, 53u8, 119u8, 111u8, + ], + ) + } + #[doc = "See [`Pallet::sudo_unchecked_weight`]."] + pub fn sudo_unchecked_weight( + &self, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + weight: runtime_types::sp_weights::weight_v2::Weight, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Sudo", + "sudo_unchecked_weight", + types::SudoUncheckedWeight { call: ::std::boxed::Box::new(call), weight }, + [ + 141u8, 64u8, 170u8, 4u8, 89u8, 149u8, 62u8, 1u8, 203u8, 56u8, 131u8, + 201u8, 8u8, 108u8, 213u8, 253u8, 101u8, 187u8, 26u8, 39u8, 246u8, + 185u8, 39u8, 3u8, 113u8, 211u8, 223u8, 198u8, 195u8, 81u8, 35u8, 90u8, + ], + ) + } + #[doc = "See [`Pallet::set_key`]."] + pub fn set_key( + &self, + new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Sudo", + "set_key", + types::SetKey { new }, + [ + 9u8, 73u8, 39u8, 205u8, 188u8, 127u8, 143u8, 54u8, 128u8, 94u8, 8u8, + 227u8, 197u8, 44u8, 70u8, 93u8, 228u8, 196u8, 64u8, 165u8, 226u8, + 158u8, 101u8, 192u8, 22u8, 193u8, 102u8, 84u8, 21u8, 35u8, 92u8, 198u8, + ], + ) + } + #[doc = "See [`Pallet::sudo_as`]."] + pub fn sudo_as( + &self, + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + call: runtime_types::coretime_rococo_runtime::RuntimeCall, + ) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Sudo", + "sudo_as", + types::SudoAs { who, call: ::std::boxed::Box::new(call) }, + [ + 202u8, 135u8, 76u8, 156u8, 213u8, 15u8, 106u8, 60u8, 139u8, 153u8, + 152u8, 67u8, 89u8, 46u8, 122u8, 149u8, 139u8, 226u8, 189u8, 19u8, + 248u8, 220u8, 26u8, 196u8, 246u8, 244u8, 124u8, 25u8, 169u8, 181u8, + 119u8, 96u8, + ], + ) + } + #[doc = "See [`Pallet::remove_key`]."] + pub fn remove_key(&self) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "Sudo", + "remove_key", + types::RemoveKey {}, + [ + 133u8, 253u8, 54u8, 175u8, 202u8, 239u8, 5u8, 198u8, 180u8, 138u8, + 25u8, 28u8, 109u8, 40u8, 30u8, 56u8, 126u8, 100u8, 52u8, 205u8, 250u8, + 191u8, 61u8, 195u8, 172u8, 142u8, 184u8, 239u8, 247u8, 10u8, 211u8, + 79u8, + ], + ) + } + } + } + #[doc = "The `Event` enum of this pallet"] + pub type Event = runtime_types::pallet_sudo::pallet::Event; + pub mod events { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A sudo call just took place."] + pub struct Sudid { + pub sudo_result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for Sudid { + const PALLET: &'static str = "Sudo"; + const EVENT: &'static str = "Sudid"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The sudo key has been updated."] + pub struct KeyChanged { + pub old: ::core::option::Option<::subxt::utils::AccountId32>, + pub new: ::subxt::utils::AccountId32, + } + impl ::subxt::events::StaticEvent for KeyChanged { + const PALLET: &'static str = "Sudo"; + const EVENT: &'static str = "KeyChanged"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The key was permanently removed."] + pub struct KeyRemoved; + impl ::subxt::events::StaticEvent for KeyRemoved { + const PALLET: &'static str = "Sudo"; + const EVENT: &'static str = "KeyRemoved"; + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "A [sudo_as](Pallet::sudo_as) call just took place."] + pub struct SudoAsDone { + pub sudo_result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + } + impl ::subxt::events::StaticEvent for SudoAsDone { + const PALLET: &'static str = "Sudo"; + const EVENT: &'static str = "SudoAsDone"; + } + } + pub mod storage { + use super::runtime_types; + pub struct StorageApi; + impl StorageApi { + #[doc = " The `AccountId` of the sudo key."] + pub fn key( + &self, + ) -> ::subxt::storage::address::Address< + ::subxt::storage::address::StaticStorageMapKey, + ::subxt::utils::AccountId32, + ::subxt::storage::address::Yes, + (), + (), + > { + ::subxt::storage::address::Address::new_static( + "Sudo", + "Key", + vec![], + [ + 72u8, 14u8, 225u8, 162u8, 205u8, 247u8, 227u8, 105u8, 116u8, 57u8, 4u8, + 31u8, 84u8, 137u8, 227u8, 228u8, 133u8, 245u8, 206u8, 227u8, 117u8, + 36u8, 252u8, 151u8, 107u8, 15u8, 180u8, 4u8, 4u8, 152u8, 195u8, 144u8, + ], + ) + } + } + } + } + pub mod runtime_types { + use super::runtime_types; + pub mod bounded_collections { + use super::runtime_types; + pub mod bounded_btree_set { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BoundedBTreeSet<_0>(pub ::std::vec::Vec<_0>); + } + pub mod bounded_vec { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BoundedVec<_0>(pub ::std::vec::Vec<_0>); + } + pub mod weak_bounded_vec { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WeakBoundedVec<_0>(pub ::std::vec::Vec<_0>); + } + } + pub mod coretime_rococo_runtime { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum OriginCaller { + #[codec(index = 0)] + system( + runtime_types::frame_support::dispatch::RawOrigin<::subxt::utils::AccountId32>, + ), + #[codec(index = 31)] + PolkadotXcm(runtime_types::pallet_xcm::pallet::Origin), + #[codec(index = 32)] + CumulusXcm(runtime_types::cumulus_pallet_xcm::pallet::Origin), + #[codec(index = 3)] + Void(runtime_types::sp_core::Void), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Runtime; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum RuntimeCall { + #[codec(index = 0)] + System(runtime_types::frame_system::pallet::Call), + #[codec(index = 1)] + ParachainSystem(runtime_types::cumulus_pallet_parachain_system::pallet::Call), + #[codec(index = 3)] + Timestamp(runtime_types::pallet_timestamp::pallet::Call), + #[codec(index = 4)] + ParachainInfo(runtime_types::staging_parachain_info::pallet::Call), + #[codec(index = 10)] + Balances(runtime_types::pallet_balances::pallet::Call), + #[codec(index = 21)] + CollatorSelection(runtime_types::pallet_collator_selection::pallet::Call), + #[codec(index = 22)] + Session(runtime_types::pallet_session::pallet::Call), + #[codec(index = 30)] + XcmpQueue(runtime_types::cumulus_pallet_xcmp_queue::pallet::Call), + #[codec(index = 31)] + PolkadotXcm(runtime_types::pallet_xcm::pallet::Call), + #[codec(index = 32)] + CumulusXcm(runtime_types::cumulus_pallet_xcm::pallet::Call), + #[codec(index = 34)] + MessageQueue(runtime_types::pallet_message_queue::pallet::Call), + #[codec(index = 40)] + Utility(runtime_types::pallet_utility::pallet::Call), + #[codec(index = 41)] + Multisig(runtime_types::pallet_multisig::pallet::Call), + #[codec(index = 50)] + Broker(runtime_types::pallet_broker::pallet::Call), + #[codec(index = 100)] + Sudo(runtime_types::pallet_sudo::pallet::Call), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum RuntimeError { + #[codec(index = 0)] + System(runtime_types::frame_system::pallet::Error), + #[codec(index = 1)] + ParachainSystem(runtime_types::cumulus_pallet_parachain_system::pallet::Error), + #[codec(index = 10)] + Balances(runtime_types::pallet_balances::pallet::Error), + #[codec(index = 21)] + CollatorSelection(runtime_types::pallet_collator_selection::pallet::Error), + #[codec(index = 22)] + Session(runtime_types::pallet_session::pallet::Error), + #[codec(index = 30)] + XcmpQueue(runtime_types::cumulus_pallet_xcmp_queue::pallet::Error), + #[codec(index = 31)] + PolkadotXcm(runtime_types::pallet_xcm::pallet::Error), + #[codec(index = 34)] + MessageQueue(runtime_types::pallet_message_queue::pallet::Error), + #[codec(index = 40)] + Utility(runtime_types::pallet_utility::pallet::Error), + #[codec(index = 41)] + Multisig(runtime_types::pallet_multisig::pallet::Error), + #[codec(index = 50)] + Broker(runtime_types::pallet_broker::pallet::Error), + #[codec(index = 100)] + Sudo(runtime_types::pallet_sudo::pallet::Error), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum RuntimeEvent { + #[codec(index = 0)] + System(runtime_types::frame_system::pallet::Event), + #[codec(index = 1)] + ParachainSystem(runtime_types::cumulus_pallet_parachain_system::pallet::Event), + #[codec(index = 10)] + Balances(runtime_types::pallet_balances::pallet::Event), + #[codec(index = 11)] + TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), + #[codec(index = 21)] + CollatorSelection(runtime_types::pallet_collator_selection::pallet::Event), + #[codec(index = 22)] + Session(runtime_types::pallet_session::pallet::Event), + #[codec(index = 30)] + XcmpQueue(runtime_types::cumulus_pallet_xcmp_queue::pallet::Event), + #[codec(index = 31)] + PolkadotXcm(runtime_types::pallet_xcm::pallet::Event), + #[codec(index = 32)] + CumulusXcm(runtime_types::cumulus_pallet_xcm::pallet::Event), + #[codec(index = 34)] + MessageQueue(runtime_types::pallet_message_queue::pallet::Event), + #[codec(index = 40)] + Utility(runtime_types::pallet_utility::pallet::Event), + #[codec(index = 41)] + Multisig(runtime_types::pallet_multisig::pallet::Event), + #[codec(index = 50)] + Broker(runtime_types::pallet_broker::pallet::Event), + #[codec(index = 100)] + Sudo(runtime_types::pallet_sudo::pallet::Event), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum RuntimeHoldReason {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SessionKeys { + pub aura: runtime_types::sp_consensus_aura::sr25519::app_sr25519::Public, + } + } + pub mod cumulus_pallet_parachain_system { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + # [codec (index = 0)] # [doc = "See [`Pallet::set_validation_data`]."] set_validation_data { data : runtime_types :: cumulus_primitives_parachain_inherent :: ParachainInherentData , } , # [codec (index = 1)] # [doc = "See [`Pallet::sudo_send_upward_message`]."] sudo_send_upward_message { message : :: std :: vec :: Vec < :: core :: primitive :: u8 > , } , # [codec (index = 2)] # [doc = "See [`Pallet::authorize_upgrade`]."] authorize_upgrade { code_hash : :: subxt :: utils :: H256 , check_version : :: core :: primitive :: bool , } , # [codec (index = 3)] # [doc = "See [`Pallet::enact_authorized_upgrade`]."] enact_authorized_upgrade { code : :: std :: vec :: Vec < :: core :: primitive :: u8 > , } , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "Attempt to upgrade validation function while existing upgrade pending."] + OverlappingUpgrades, + #[codec(index = 1)] + #[doc = "Polkadot currently prohibits this parachain from upgrading its validation function."] + ProhibitedByPolkadot, + #[codec(index = 2)] + #[doc = "The supplied validation function has compiled into a blob larger than Polkadot is"] + #[doc = "willing to run."] + TooBig, + #[codec(index = 3)] + #[doc = "The inherent which supplies the validation data did not run this block."] + ValidationDataNotAvailable, + #[codec(index = 4)] + #[doc = "The inherent which supplies the host configuration did not run this block."] + HostConfigurationNotAvailable, + #[codec(index = 5)] + #[doc = "No validation function upgrade is currently scheduled."] + NotScheduled, + #[codec(index = 6)] + #[doc = "No code upgrade has been authorized."] + NothingAuthorized, + #[codec(index = 7)] + #[doc = "The given code upgrade has not been authorized."] + Unauthorized, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "The validation function has been scheduled to apply."] + ValidationFunctionStored, + #[codec(index = 1)] + #[doc = "The validation function was applied as of the contained relay chain block number."] + ValidationFunctionApplied { relay_chain_block_num: ::core::primitive::u32 }, + #[codec(index = 2)] + #[doc = "The relay-chain aborted the upgrade process."] + ValidationFunctionDiscarded, + #[codec(index = 3)] + #[doc = "Some downward messages have been received and will be processed."] + DownwardMessagesReceived { count: ::core::primitive::u32 }, + #[codec(index = 4)] + #[doc = "Downward messages were processed using the given weight."] + DownwardMessagesProcessed { + weight_used: runtime_types::sp_weights::weight_v2::Weight, + dmq_head: ::subxt::utils::H256, + }, + #[codec(index = 5)] + #[doc = "An upward message was sent to the relay chain."] + UpwardMessageSent { + message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, + }, + } + } + pub mod relay_state_snapshot { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MessagingStateSnapshot { pub dmq_mqc_head : :: subxt :: utils :: H256 , pub relay_dispatch_queue_remaining_capacity : runtime_types :: cumulus_pallet_parachain_system :: relay_state_snapshot :: RelayDispatchQueueRemainingCapacity , pub ingress_channels : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: v6 :: AbridgedHrmpChannel ,) > , pub egress_channels : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: v6 :: AbridgedHrmpChannel ,) > , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RelayDispatchQueueRemainingCapacity { + pub remaining_count: ::core::primitive::u32, + pub remaining_size: ::core::primitive::u32, + } + } + pub mod unincluded_segment { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Ancestor < _0 > { pub used_bandwidth : runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: UsedBandwidth , pub para_head_hash : :: core :: option :: Option < _0 > , pub consumed_go_ahead_signal : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v6 :: UpgradeGoAhead > , } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HrmpChannelUpdate { + pub msg_count: ::core::primitive::u32, + pub total_bytes: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SegmentTracker < _0 > { pub used_bandwidth : runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: UsedBandwidth , pub hrmp_watermark : :: core :: option :: Option < :: core :: primitive :: u32 > , pub consumed_go_ahead_signal : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v6 :: UpgradeGoAhead > , # [codec (skip)] pub __subxt_unused_type_params : :: core :: marker :: PhantomData < _0 > } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct UsedBandwidth { pub ump_msg_count : :: core :: primitive :: u32 , pub ump_total_bytes : :: core :: primitive :: u32 , pub hrmp_outgoing : :: subxt :: utils :: KeyedVec < runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: HrmpChannelUpdate > , } + } + } + pub mod cumulus_pallet_xcm { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call {} + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "Downward message is invalid XCM."] + #[doc = "\\[ id \\]"] + InvalidFormat([::core::primitive::u8; 32usize]), + #[codec(index = 1)] + #[doc = "Downward message is unsupported version of XCM."] + #[doc = "\\[ id \\]"] + UnsupportedVersion([::core::primitive::u8; 32usize]), + #[codec(index = 2)] + #[doc = "Downward message executed with the given outcome."] + #[doc = "\\[ id, outcome \\]"] + ExecutedDownward( + [::core::primitive::u8; 32usize], + runtime_types::staging_xcm::v4::traits::Outcome, + ), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Origin { + #[codec(index = 0)] + Relay, + #[codec(index = 1)] + SiblingParachain(runtime_types::polkadot_parachain_primitives::primitives::Id), + } + } + } + pub mod cumulus_pallet_xcmp_queue { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 1)] + #[doc = "See [`Pallet::suspend_xcm_execution`]."] + suspend_xcm_execution, + #[codec(index = 2)] + #[doc = "See [`Pallet::resume_xcm_execution`]."] + resume_xcm_execution, + #[codec(index = 3)] + #[doc = "See [`Pallet::update_suspend_threshold`]."] + update_suspend_threshold { new: ::core::primitive::u32 }, + #[codec(index = 4)] + #[doc = "See [`Pallet::update_drop_threshold`]."] + update_drop_threshold { new: ::core::primitive::u32 }, + #[codec(index = 5)] + #[doc = "See [`Pallet::update_resume_threshold`]."] + update_resume_threshold { new: ::core::primitive::u32 }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "Setting the queue config failed since one of its values was invalid."] + BadQueueConfig, + #[codec(index = 1)] + #[doc = "The execution is already suspended."] + AlreadySuspended, + #[codec(index = 2)] + #[doc = "The execution is already resumed."] + AlreadyResumed, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "An HRMP message was sent to a sibling parachain."] + XcmpMessageSent { message_hash: [::core::primitive::u8; 32usize] }, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OutboundChannelDetails { + pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, + pub state: runtime_types::cumulus_pallet_xcmp_queue::OutboundState, + pub signals_exist: ::core::primitive::bool, + pub first_index: ::core::primitive::u16, + pub last_index: ::core::primitive::u16, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum OutboundState { + #[codec(index = 0)] + Ok, + #[codec(index = 1)] + Suspended, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueueConfigData { + pub suspend_threshold: ::core::primitive::u32, + pub drop_threshold: ::core::primitive::u32, + pub resume_threshold: ::core::primitive::u32, + } + } + pub mod cumulus_primitives_core { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AggregateMessageOrigin { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + Parent, + #[codec(index = 2)] + Sibling(runtime_types::polkadot_parachain_primitives::primitives::Id), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CollationInfo { + pub upward_messages: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + pub horizontal_messages: ::std::vec::Vec< + runtime_types::polkadot_core_primitives::OutboundHrmpMessage< + runtime_types::polkadot_parachain_primitives::primitives::Id, + >, + >, + pub new_validation_code: ::core::option::Option< + runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, + >, + pub processed_downward_messages: ::core::primitive::u32, + pub hrmp_watermark: ::core::primitive::u32, + pub head_data: runtime_types::polkadot_parachain_primitives::primitives::HeadData, + } + } + pub mod cumulus_primitives_parachain_inherent { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MessageQueueChain(pub ::subxt::utils::H256); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ParachainInherentData { + pub validation_data: + runtime_types::polkadot_primitives::v6::PersistedValidationData< + ::subxt::utils::H256, + ::core::primitive::u32, + >, + pub relay_chain_state: runtime_types::sp_trie::storage_proof::StorageProof, + pub downward_messages: ::std::vec::Vec< + runtime_types::polkadot_core_primitives::InboundDownwardMessage< + ::core::primitive::u32, + >, + >, + pub horizontal_messages: ::subxt::utils::KeyedVec< + runtime_types::polkadot_parachain_primitives::primitives::Id, + ::std::vec::Vec< + runtime_types::polkadot_core_primitives::InboundHrmpMessage< + ::core::primitive::u32, + >, + >, + >, + } + } + pub mod frame_support { + use super::runtime_types; + pub mod dispatch { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum DispatchClass { + #[codec(index = 0)] + Normal, + #[codec(index = 1)] + Operational, + #[codec(index = 2)] + Mandatory, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DispatchInfo { + pub weight: runtime_types::sp_weights::weight_v2::Weight, + pub class: runtime_types::frame_support::dispatch::DispatchClass, + pub pays_fee: runtime_types::frame_support::dispatch::Pays, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Pays { + #[codec(index = 0)] + Yes, + #[codec(index = 1)] + No, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PerDispatchClass<_0> { + pub normal: _0, + pub operational: _0, + pub mandatory: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum RawOrigin<_0> { + #[codec(index = 0)] + Root, + #[codec(index = 1)] + Signed(_0), + #[codec(index = 2)] + None, + } + } + pub mod traits { + use super::runtime_types; + pub mod messages { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum ProcessMessageError { + #[codec(index = 0)] + BadFormat, + #[codec(index = 1)] + Corrupt, + #[codec(index = 2)] + Unsupported, + #[codec(index = 3)] + Overweight(runtime_types::sp_weights::weight_v2::Weight), + #[codec(index = 4)] + Yield, + } + } + pub mod tokens { + use super::runtime_types; + pub mod misc { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum BalanceStatus { + #[codec(index = 0)] + Free, + #[codec(index = 1)] + Reserved, + } + } + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PalletId(pub [::core::primitive::u8; 8usize]); + } + pub mod frame_system { + use super::runtime_types; + pub mod extensions { + use super::runtime_types; + pub mod check_genesis { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckGenesis; + } + pub mod check_mortality { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckMortality(pub runtime_types::sp_runtime::generic::era::Era); + } + pub mod check_non_zero_sender { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckNonZeroSender; + } + pub mod check_nonce { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckNonce(#[codec(compact)] pub ::core::primitive::u32); + } + pub mod check_spec_version { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckSpecVersion; + } + pub mod check_tx_version { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckTxVersion; + } + pub mod check_weight { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckWeight; + } + } + pub mod limits { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BlockLength { + pub max: runtime_types::frame_support::dispatch::PerDispatchClass< + ::core::primitive::u32, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BlockWeights { + pub base_block: runtime_types::sp_weights::weight_v2::Weight, + pub max_block: runtime_types::sp_weights::weight_v2::Weight, + pub per_class: runtime_types::frame_support::dispatch::PerDispatchClass< + runtime_types::frame_system::limits::WeightsPerClass, + >, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct WeightsPerClass { + pub base_extrinsic: runtime_types::sp_weights::weight_v2::Weight, + pub max_extrinsic: + ::core::option::Option, + pub max_total: + ::core::option::Option, + pub reserved: + ::core::option::Option, + } + } + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::remark`]."] + remark { remark: ::std::vec::Vec<::core::primitive::u8> }, + #[codec(index = 1)] + #[doc = "See [`Pallet::set_heap_pages`]."] + set_heap_pages { pages: ::core::primitive::u64 }, + #[codec(index = 2)] + #[doc = "See [`Pallet::set_code`]."] + set_code { code: ::std::vec::Vec<::core::primitive::u8> }, + #[codec(index = 3)] + #[doc = "See [`Pallet::set_code_without_checks`]."] + set_code_without_checks { code: ::std::vec::Vec<::core::primitive::u8> }, + #[codec(index = 4)] + #[doc = "See [`Pallet::set_storage`]."] + set_storage { + items: ::std::vec::Vec<( + ::std::vec::Vec<::core::primitive::u8>, + ::std::vec::Vec<::core::primitive::u8>, + )>, + }, + #[codec(index = 5)] + #[doc = "See [`Pallet::kill_storage`]."] + kill_storage { keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>> }, + #[codec(index = 6)] + #[doc = "See [`Pallet::kill_prefix`]."] + kill_prefix { + prefix: ::std::vec::Vec<::core::primitive::u8>, + subkeys: ::core::primitive::u32, + }, + #[codec(index = 7)] + #[doc = "See [`Pallet::remark_with_event`]."] + remark_with_event { remark: ::std::vec::Vec<::core::primitive::u8> }, + #[codec(index = 9)] + #[doc = "See [`Pallet::authorize_upgrade`]."] + authorize_upgrade { code_hash: ::subxt::utils::H256 }, + #[codec(index = 10)] + #[doc = "See [`Pallet::authorize_upgrade_without_checks`]."] + authorize_upgrade_without_checks { code_hash: ::subxt::utils::H256 }, + #[codec(index = 11)] + #[doc = "See [`Pallet::apply_authorized_upgrade`]."] + apply_authorized_upgrade { code: ::std::vec::Vec<::core::primitive::u8> }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Error for the System pallet"] + pub enum Error { + #[codec(index = 0)] + #[doc = "The name of specification does not match between the current runtime"] + #[doc = "and the new runtime."] + InvalidSpecName, + #[codec(index = 1)] + #[doc = "The specification version is not allowed to decrease between the current runtime"] + #[doc = "and the new runtime."] + SpecVersionNeedsToIncrease, + #[codec(index = 2)] + #[doc = "Failed to extract the runtime version from the new runtime."] + #[doc = ""] + #[doc = "Either calling `Core_version` or decoding `RuntimeVersion` failed."] + FailedToExtractRuntimeVersion, + #[codec(index = 3)] + #[doc = "Suicide called when the account has non-default composite data."] + NonDefaultComposite, + #[codec(index = 4)] + #[doc = "There is a non-zero reference count preventing the account from being purged."] + NonZeroRefCount, + #[codec(index = 5)] + #[doc = "The origin filter prevent the call to be dispatched."] + CallFiltered, + #[codec(index = 6)] + #[doc = "No upgrade authorized."] + NothingAuthorized, + #[codec(index = 7)] + #[doc = "The submitted code is not authorized."] + Unauthorized, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Event for the System pallet."] + pub enum Event { + #[codec(index = 0)] + #[doc = "An extrinsic completed successfully."] + ExtrinsicSuccess { + dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + }, + #[codec(index = 1)] + #[doc = "An extrinsic failed."] + ExtrinsicFailed { + dispatch_error: runtime_types::sp_runtime::DispatchError, + dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + }, + #[codec(index = 2)] + #[doc = "`:code` was updated."] + CodeUpdated, + #[codec(index = 3)] + #[doc = "A new account was created."] + NewAccount { account: ::subxt::utils::AccountId32 }, + #[codec(index = 4)] + #[doc = "An account was reaped."] + KilledAccount { account: ::subxt::utils::AccountId32 }, + #[codec(index = 5)] + #[doc = "On on-chain remark happened."] + Remarked { sender: ::subxt::utils::AccountId32, hash: ::subxt::utils::H256 }, + #[codec(index = 6)] + #[doc = "An upgrade was authorized."] + UpgradeAuthorized { + code_hash: ::subxt::utils::H256, + check_version: ::core::primitive::bool, + }, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AccountInfo<_0, _1> { + pub nonce: _0, + pub consumers: ::core::primitive::u32, + pub providers: ::core::primitive::u32, + pub sufficients: ::core::primitive::u32, + pub data: _1, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CodeUpgradeAuthorization { + pub code_hash: ::subxt::utils::H256, + pub check_version: ::core::primitive::bool, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct EventRecord<_0, _1> { + pub phase: runtime_types::frame_system::Phase, + pub event: _0, + pub topics: ::std::vec::Vec<_1>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LastRuntimeUpgradeInfo { + #[codec(compact)] + pub spec_version: ::core::primitive::u32, + pub spec_name: ::std::string::String, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Phase { + #[codec(index = 0)] + ApplyExtrinsic(::core::primitive::u32), + #[codec(index = 1)] + Finalization, + #[codec(index = 2)] + Initialization, + } + } + pub mod pallet_balances { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::transfer_allow_death`]."] + transfer_allow_death { + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + value: ::core::primitive::u128, + }, + #[codec(index = 2)] + #[doc = "See [`Pallet::force_transfer`]."] + force_transfer { + source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + value: ::core::primitive::u128, + }, + #[codec(index = 3)] + #[doc = "See [`Pallet::transfer_keep_alive`]."] + transfer_keep_alive { + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + value: ::core::primitive::u128, + }, + #[codec(index = 4)] + #[doc = "See [`Pallet::transfer_all`]."] + transfer_all { + dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + keep_alive: ::core::primitive::bool, + }, + #[codec(index = 5)] + #[doc = "See [`Pallet::force_unreserve`]."] + force_unreserve { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + #[doc = "See [`Pallet::upgrade_accounts`]."] + upgrade_accounts { who: ::std::vec::Vec<::subxt::utils::AccountId32> }, + #[codec(index = 8)] + #[doc = "See [`Pallet::force_set_balance`]."] + force_set_balance { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + #[codec(compact)] + new_free: ::core::primitive::u128, + }, + #[codec(index = 9)] + #[doc = "See [`Pallet::force_adjust_total_issuance`]."] + force_adjust_total_issuance { + direction: runtime_types::pallet_balances::types::AdjustmentDirection, + #[codec(compact)] + delta: ::core::primitive::u128, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "Vesting balance too high to send value."] + VestingBalance, + #[codec(index = 1)] + #[doc = "Account liquidity restrictions prevent withdrawal."] + LiquidityRestrictions, + #[codec(index = 2)] + #[doc = "Balance too low to send value."] + InsufficientBalance, + #[codec(index = 3)] + #[doc = "Value too low to create account due to existential deposit."] + ExistentialDeposit, + #[codec(index = 4)] + #[doc = "Transfer/payment would kill account."] + Expendability, + #[codec(index = 5)] + #[doc = "A vesting schedule already exists for this account."] + ExistingVestingSchedule, + #[codec(index = 6)] + #[doc = "Beneficiary account must pre-exist."] + DeadAccount, + #[codec(index = 7)] + #[doc = "Number of named reserves exceed `MaxReserves`."] + TooManyReserves, + #[codec(index = 8)] + #[doc = "Number of holds exceed `VariantCountOf`."] + TooManyHolds, + #[codec(index = 9)] + #[doc = "Number of freezes exceed `MaxFreezes`."] + TooManyFreezes, + #[codec(index = 10)] + #[doc = "The issuance cannot be modified since it is already deactivated."] + IssuanceDeactivated, + #[codec(index = 11)] + #[doc = "The delta cannot be zero."] + DeltaZero, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "An account was created with some free balance."] + Endowed { + account: ::subxt::utils::AccountId32, + free_balance: ::core::primitive::u128, + }, + #[codec(index = 1)] + #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] + #[doc = "resulting in an outright loss."] + DustLost { + account: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + #[doc = "Transfer succeeded."] + Transfer { + from: ::subxt::utils::AccountId32, + to: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + #[doc = "A balance was set by root."] + BalanceSet { who: ::subxt::utils::AccountId32, free: ::core::primitive::u128 }, + #[codec(index = 4)] + #[doc = "Some balance was reserved (moved from free to reserved)."] + Reserved { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 5)] + #[doc = "Some balance was unreserved (moved from reserved to free)."] + Unreserved { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 6)] + #[doc = "Some balance was moved from the reserve of the first account to the second account."] + #[doc = "Final argument indicates the destination balance type."] + ReserveRepatriated { + from: ::subxt::utils::AccountId32, + to: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + destination_status: + runtime_types::frame_support::traits::tokens::misc::BalanceStatus, + }, + #[codec(index = 7)] + #[doc = "Some amount was deposited (e.g. for transaction fees)."] + Deposit { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 8)] + #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] + Withdraw { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 9)] + #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] + Slashed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 10)] + #[doc = "Some amount was minted into an account."] + Minted { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 11)] + #[doc = "Some amount was burned from an account."] + Burned { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 12)] + #[doc = "Some amount was suspended from an account (it can be restored later)."] + Suspended { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 13)] + #[doc = "Some amount was restored into an account."] + Restored { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 14)] + #[doc = "An account was upgraded."] + Upgraded { who: ::subxt::utils::AccountId32 }, + #[codec(index = 15)] + #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] + Issued { amount: ::core::primitive::u128 }, + #[codec(index = 16)] + #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] + Rescinded { amount: ::core::primitive::u128 }, + #[codec(index = 17)] + #[doc = "Some balance was locked."] + Locked { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 18)] + #[doc = "Some balance was unlocked."] + Unlocked { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 19)] + #[doc = "Some balance was frozen."] + Frozen { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 20)] + #[doc = "Some balance was thawed."] + Thawed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 21)] + #[doc = "The `TotalIssuance` was forcefully changed."] + TotalIssuanceForced { + old: ::core::primitive::u128, + new: ::core::primitive::u128, + }, + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AccountData<_0> { + pub free: _0, + pub reserved: _0, + pub frozen: _0, + pub flags: runtime_types::pallet_balances::types::ExtraFlags, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AdjustmentDirection { + #[codec(index = 0)] + Increase, + #[codec(index = 1)] + Decrease, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BalanceLock<_0> { + pub id: [::core::primitive::u8; 8usize], + pub amount: _0, + pub reasons: runtime_types::pallet_balances::types::Reasons, + } + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ExtraFlags(pub ::core::primitive::u128); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct IdAmount<_0, _1> { + pub id: _0, + pub amount: _1, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Reasons { + #[codec(index = 0)] + Fee, + #[codec(index = 1)] + Misc, + #[codec(index = 2)] + All, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ReserveData<_0, _1> { + pub id: _0, + pub amount: _1, + } + } + } + pub mod pallet_broker { + use super::runtime_types; + pub mod core_mask { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CoreMask(pub [::core::primitive::u8; 10usize]); + } + pub mod coretime_interface { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum CoreAssignment { + #[codec(index = 0)] + Idle, + #[codec(index = 1)] + Pool, + #[codec(index = 2)] + Task(::core::primitive::u32), + } + } + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::configure`]."] + configure { + config: runtime_types::pallet_broker::types::ConfigRecord< + ::core::primitive::u32, + ::core::primitive::u32, + >, + }, + #[codec(index = 1)] + #[doc = "See [`Pallet::reserve`]."] + reserve { + workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + }, + #[codec(index = 2)] + #[doc = "See [`Pallet::unreserve`]."] + unreserve { item_index: ::core::primitive::u32 }, + #[codec(index = 3)] + #[doc = "See [`Pallet::set_lease`]."] + set_lease { task: ::core::primitive::u32, until: ::core::primitive::u32 }, + #[codec(index = 4)] + #[doc = "See [`Pallet::start_sales`]."] + start_sales { + initial_price: ::core::primitive::u128, + core_count: ::core::primitive::u16, + }, + #[codec(index = 5)] + #[doc = "See [`Pallet::purchase`]."] + purchase { price_limit: ::core::primitive::u128 }, + #[codec(index = 6)] + #[doc = "See [`Pallet::renew`]."] + renew { core: ::core::primitive::u16 }, + #[codec(index = 7)] + #[doc = "See [`Pallet::transfer`]."] + transfer { + region_id: runtime_types::pallet_broker::types::RegionId, + new_owner: ::subxt::utils::AccountId32, + }, + #[codec(index = 8)] + #[doc = "See [`Pallet::partition`]."] + partition { + region_id: runtime_types::pallet_broker::types::RegionId, + pivot: ::core::primitive::u32, + }, + #[codec(index = 9)] + #[doc = "See [`Pallet::interlace`]."] + interlace { + region_id: runtime_types::pallet_broker::types::RegionId, + pivot: runtime_types::pallet_broker::core_mask::CoreMask, + }, + #[codec(index = 10)] + #[doc = "See [`Pallet::assign`]."] + assign { + region_id: runtime_types::pallet_broker::types::RegionId, + task: ::core::primitive::u32, + finality: runtime_types::pallet_broker::types::Finality, + }, + #[codec(index = 11)] + #[doc = "See [`Pallet::pool`]."] + pool { + region_id: runtime_types::pallet_broker::types::RegionId, + payee: ::subxt::utils::AccountId32, + finality: runtime_types::pallet_broker::types::Finality, + }, + #[codec(index = 12)] + #[doc = "See [`Pallet::claim_revenue`]."] + claim_revenue { + region_id: runtime_types::pallet_broker::types::RegionId, + max_timeslices: ::core::primitive::u32, + }, + #[codec(index = 13)] + #[doc = "See [`Pallet::purchase_credit`]."] + purchase_credit { + amount: ::core::primitive::u128, + beneficiary: ::subxt::utils::AccountId32, + }, + #[codec(index = 14)] + #[doc = "See [`Pallet::drop_region`]."] + drop_region { region_id: runtime_types::pallet_broker::types::RegionId }, + #[codec(index = 15)] + #[doc = "See [`Pallet::drop_contribution`]."] + drop_contribution { region_id: runtime_types::pallet_broker::types::RegionId }, + #[codec(index = 16)] + #[doc = "See [`Pallet::drop_history`]."] + drop_history { when: ::core::primitive::u32 }, + #[codec(index = 17)] + #[doc = "See [`Pallet::drop_renewal`]."] + drop_renewal { core: ::core::primitive::u16, when: ::core::primitive::u32 }, + #[codec(index = 18)] + #[doc = "See [`Pallet::request_core_count`]."] + request_core_count { core_count: ::core::primitive::u16 }, + #[codec(index = 19)] + #[doc = "See [`Pallet::notify_core_count`]."] + notify_core_count { core_count: ::core::primitive::u16 }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "The given region identity is not known."] + UnknownRegion, + #[codec(index = 1)] + #[doc = "The owner of the region is not the origin."] + NotOwner, + #[codec(index = 2)] + #[doc = "The pivot point of the partition at or after the end of the region."] + PivotTooLate, + #[codec(index = 3)] + #[doc = "The pivot point of the partition at the beginning of the region."] + PivotTooEarly, + #[codec(index = 4)] + #[doc = "The pivot mask for the interlacing is not contained within the region's interlace mask."] + ExteriorPivot, + #[codec(index = 5)] + #[doc = "The pivot mask for the interlacing is void (and therefore unschedulable)."] + VoidPivot, + #[codec(index = 6)] + #[doc = "The pivot mask for the interlacing is complete (and therefore not a strict subset)."] + CompletePivot, + #[codec(index = 7)] + #[doc = "The workplan of the pallet's state is invalid. This indicates a state corruption."] + CorruptWorkplan, + #[codec(index = 8)] + #[doc = "There is no sale happening currently."] + NoSales, + #[codec(index = 9)] + #[doc = "The price limit is exceeded."] + Overpriced, + #[codec(index = 10)] + #[doc = "There are no cores available."] + Unavailable, + #[codec(index = 11)] + #[doc = "The sale limit has been reached."] + SoldOut, + #[codec(index = 12)] + #[doc = "The renewal operation is not valid at the current time (it may become valid in the next"] + #[doc = "sale)."] + WrongTime, + #[codec(index = 13)] + #[doc = "Invalid attempt to renew."] + NotAllowed, + #[codec(index = 14)] + #[doc = "This pallet has not yet been initialized."] + Uninitialized, + #[codec(index = 15)] + #[doc = "The purchase cannot happen yet as the sale period is yet to begin."] + TooEarly, + #[codec(index = 16)] + #[doc = "There is no work to be done."] + NothingToDo, + #[codec(index = 17)] + #[doc = "The maximum amount of reservations has already been reached."] + TooManyReservations, + #[codec(index = 18)] + #[doc = "The maximum amount of leases has already been reached."] + TooManyLeases, + #[codec(index = 19)] + #[doc = "The revenue for the Instantaneous Core Sales of this period is not (yet) known and thus"] + #[doc = "this operation cannot proceed."] + UnknownRevenue, + #[codec(index = 20)] + #[doc = "The identified contribution to the Instantaneous Core Pool is unknown."] + UnknownContribution, + #[codec(index = 21)] + #[doc = "The workload assigned for renewal is incomplete. This is unexpected and indicates a"] + #[doc = "logic error."] + IncompleteAssignment, + #[codec(index = 22)] + #[doc = "An item cannot be dropped because it is still valid."] + StillValid, + #[codec(index = 23)] + #[doc = "The history item does not exist."] + NoHistory, + #[codec(index = 24)] + #[doc = "No reservation of the given index exists."] + UnknownReservation, + #[codec(index = 25)] + #[doc = "The renewal record cannot be found."] + UnknownRenewal, + #[codec(index = 26)] + #[doc = "The lease expiry time has already passed."] + AlreadyExpired, + #[codec(index = 27)] + #[doc = "The configuration could not be applied because it is invalid."] + InvalidConfig, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "A Region of Bulk Coretime has been purchased."] + Purchased { + who: ::subxt::utils::AccountId32, + region_id: runtime_types::pallet_broker::types::RegionId, + price: ::core::primitive::u128, + duration: ::core::primitive::u32, + }, + #[codec(index = 1)] + #[doc = "The workload of a core has become renewable."] + Renewable { + core: ::core::primitive::u16, + price: ::core::primitive::u128, + begin: ::core::primitive::u32, + workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + }, + #[codec(index = 2)] + #[doc = "A workload has been renewed."] + Renewed { + who: ::subxt::utils::AccountId32, + price: ::core::primitive::u128, + old_core: ::core::primitive::u16, + core: ::core::primitive::u16, + begin: ::core::primitive::u32, + duration: ::core::primitive::u32, + workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + }, + #[codec(index = 3)] + #[doc = "Ownership of a Region has been transferred."] + Transferred { + region_id: runtime_types::pallet_broker::types::RegionId, + duration: ::core::primitive::u32, + old_owner: ::subxt::utils::AccountId32, + owner: ::subxt::utils::AccountId32, + }, + #[codec(index = 4)] + #[doc = "A Region has been split into two non-overlapping Regions."] + Partitioned { + old_region_id: runtime_types::pallet_broker::types::RegionId, + new_region_ids: ( + runtime_types::pallet_broker::types::RegionId, + runtime_types::pallet_broker::types::RegionId, + ), + }, + #[codec(index = 5)] + #[doc = "A Region has been converted into two overlapping Regions each of lesser regularity."] + Interlaced { + old_region_id: runtime_types::pallet_broker::types::RegionId, + new_region_ids: ( + runtime_types::pallet_broker::types::RegionId, + runtime_types::pallet_broker::types::RegionId, + ), + }, + #[codec(index = 6)] + #[doc = "A Region has been assigned to a particular task."] + Assigned { + region_id: runtime_types::pallet_broker::types::RegionId, + duration: ::core::primitive::u32, + task: ::core::primitive::u32, + }, + #[codec(index = 7)] + #[doc = "A Region has been added to the Instantaneous Coretime Pool."] + Pooled { + region_id: runtime_types::pallet_broker::types::RegionId, + duration: ::core::primitive::u32, + }, + #[codec(index = 8)] + #[doc = "A new number of cores has been requested."] + CoreCountRequested { core_count: ::core::primitive::u16 }, + #[codec(index = 9)] + #[doc = "The number of cores available for scheduling has changed."] + CoreCountChanged { core_count: ::core::primitive::u16 }, + #[codec(index = 10)] + #[doc = "There is a new reservation for a workload."] + ReservationMade { + index: ::core::primitive::u32, + workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + }, + #[codec(index = 11)] + #[doc = "A reservation for a workload has been cancelled."] + ReservationCancelled { + index: ::core::primitive::u32, + workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + }, + #[codec(index = 12)] + #[doc = "A new sale has been initialized."] + SaleInitialized { + sale_start: ::core::primitive::u32, + leadin_length: ::core::primitive::u32, + start_price: ::core::primitive::u128, + regular_price: ::core::primitive::u128, + region_begin: ::core::primitive::u32, + region_end: ::core::primitive::u32, + ideal_cores_sold: ::core::primitive::u16, + cores_offered: ::core::primitive::u16, + }, + #[codec(index = 13)] + #[doc = "A new lease has been created."] + Leased { task: ::core::primitive::u32, until: ::core::primitive::u32 }, + #[codec(index = 14)] + #[doc = "A lease is about to end."] + LeaseEnding { task: ::core::primitive::u32, when: ::core::primitive::u32 }, + #[codec(index = 15)] + #[doc = "The sale rotation has been started and a new sale is imminent."] + SalesStarted { + price: ::core::primitive::u128, + core_count: ::core::primitive::u16, + }, + #[codec(index = 16)] + #[doc = "The act of claiming revenue has begun."] + RevenueClaimBegun { + region: runtime_types::pallet_broker::types::RegionId, + max_timeslices: ::core::primitive::u32, + }, + #[codec(index = 17)] + #[doc = "A particular timeslice has a non-zero claim."] + RevenueClaimItem { + when: ::core::primitive::u32, + amount: ::core::primitive::u128, + }, + #[codec(index = 18)] + #[doc = "A revenue claim has (possibly only in part) been paid."] + RevenueClaimPaid { + who: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + next: ::core::option::Option, + }, + #[codec(index = 19)] + #[doc = "Some Instantaneous Coretime Pool credit has been purchased."] + CreditPurchased { + who: ::subxt::utils::AccountId32, + beneficiary: ::subxt::utils::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 20)] + #[doc = "A Region has been dropped due to being out of date."] + RegionDropped { + region_id: runtime_types::pallet_broker::types::RegionId, + duration: ::core::primitive::u32, + }, + #[codec(index = 21)] + #[doc = "Some historical Instantaneous Core Pool contribution record has been dropped."] + ContributionDropped { region_id: runtime_types::pallet_broker::types::RegionId }, + #[codec(index = 22)] + #[doc = "Some historical Instantaneous Core Pool payment record has been initialized."] + HistoryInitialized { + when: ::core::primitive::u32, + private_pool_size: ::core::primitive::u32, + system_pool_size: ::core::primitive::u32, + }, + #[codec(index = 23)] + #[doc = "Some historical Instantaneous Core Pool payment record has been dropped."] + HistoryDropped { + when: ::core::primitive::u32, + revenue: ::core::primitive::u128, + }, + #[codec(index = 24)] + #[doc = "Some historical Instantaneous Core Pool payment record has been ignored because the"] + #[doc = "timeslice was already known. Governance may need to intervene."] + HistoryIgnored { + when: ::core::primitive::u32, + revenue: ::core::primitive::u128, + }, + #[codec(index = 25)] + #[doc = "Some historical Instantaneous Core Pool Revenue is ready for payout claims."] + ClaimsReady { + when: ::core::primitive::u32, + system_payout: ::core::primitive::u128, + private_payout: ::core::primitive::u128, + }, + #[codec(index = 26)] + #[doc = "A Core has been assigned to one or more tasks and/or the Pool on the Relay-chain."] + CoreAssigned { + core: ::core::primitive::u16, + when: ::core::primitive::u32, + assignment: ::std::vec::Vec<( + runtime_types::pallet_broker::coretime_interface::CoreAssignment, + ::core::primitive::u16, + )>, + }, + #[codec(index = 27)] + #[doc = "Some historical Instantaneous Core Pool payment record has been dropped."] + AllowedRenewalDropped { + when: ::core::primitive::u32, + core: ::core::primitive::u16, + }, + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AllowedRenewalId { + pub core: ::core::primitive::u16, + pub when: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AllowedRenewalRecord<_0> { + pub price: _0, + pub completion: runtime_types::pallet_broker::types::CompletionStatus, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum CompletionStatus { + #[codec(index = 0)] + Partial(runtime_types::pallet_broker::core_mask::CoreMask), + #[codec(index = 1)] + Complete( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::pallet_broker::types::ScheduleItem, + >, + ), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ConfigRecord<_0, _1> { + pub advance_notice: _1, + pub interlude_length: _0, + pub leadin_length: _0, + pub region_length: ::core::primitive::u32, + pub ideal_bulk_proportion: runtime_types::sp_arithmetic::per_things::Perbill, + pub limit_cores_offered: ::core::option::Option<::core::primitive::u16>, + pub renewal_bump: runtime_types::sp_arithmetic::per_things::Perbill, + pub contribution_timeout: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ContributionRecord<_0> { + pub length: ::core::primitive::u32, + pub payee: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Finality { + #[codec(index = 0)] + Provisional, + #[codec(index = 1)] + Final, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InstaPoolHistoryRecord<_0> { + pub private_contributions: ::core::primitive::u32, + pub system_contributions: ::core::primitive::u32, + pub maybe_payout: ::core::option::Option<_0>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct LeaseRecordItem { + pub until: ::core::primitive::u32, + pub task: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PoolIoRecord { + pub private: ::core::primitive::i32, + pub system: ::core::primitive::i32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RegionId { + pub begin: ::core::primitive::u32, + pub core: ::core::primitive::u16, + pub mask: runtime_types::pallet_broker::core_mask::CoreMask, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RegionRecord<_0, _1> { + pub end: ::core::primitive::u32, + pub owner: _0, + pub paid: ::core::option::Option<_1>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SaleInfoRecord<_0, _1> { + pub sale_start: _1, + pub leadin_length: _1, + pub price: _0, + pub region_begin: ::core::primitive::u32, + pub region_end: ::core::primitive::u32, + pub ideal_cores_sold: ::core::primitive::u16, + pub cores_offered: ::core::primitive::u16, + pub first_core: ::core::primitive::u16, + pub sellout_price: ::core::option::Option<_0>, + pub cores_sold: ::core::primitive::u16, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ScheduleItem { + pub mask: runtime_types::pallet_broker::core_mask::CoreMask, + pub assignment: + runtime_types::pallet_broker::coretime_interface::CoreAssignment, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct StatusRecord { + pub core_count: ::core::primitive::u16, + pub private_pool_size: ::core::primitive::u32, + pub system_pool_size: ::core::primitive::u32, + pub last_committed_timeslice: ::core::primitive::u32, + pub last_timeslice: ::core::primitive::u32, + } + } + } + pub mod pallet_collator_selection { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::set_invulnerables`]."] + set_invulnerables { new: ::std::vec::Vec<::subxt::utils::AccountId32> }, + #[codec(index = 1)] + #[doc = "See [`Pallet::set_desired_candidates`]."] + set_desired_candidates { max: ::core::primitive::u32 }, + #[codec(index = 2)] + #[doc = "See [`Pallet::set_candidacy_bond`]."] + set_candidacy_bond { bond: ::core::primitive::u128 }, + #[codec(index = 3)] + #[doc = "See [`Pallet::register_as_candidate`]."] + register_as_candidate, + #[codec(index = 4)] + #[doc = "See [`Pallet::leave_intent`]."] + leave_intent, + #[codec(index = 5)] + #[doc = "See [`Pallet::add_invulnerable`]."] + add_invulnerable { who: ::subxt::utils::AccountId32 }, + #[codec(index = 6)] + #[doc = "See [`Pallet::remove_invulnerable`]."] + remove_invulnerable { who: ::subxt::utils::AccountId32 }, + #[codec(index = 7)] + #[doc = "See [`Pallet::update_bond`]."] + update_bond { new_deposit: ::core::primitive::u128 }, + #[codec(index = 8)] + #[doc = "See [`Pallet::take_candidate_slot`]."] + take_candidate_slot { + deposit: ::core::primitive::u128, + target: ::subxt::utils::AccountId32, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CandidateInfo<_0, _1> { + pub who: _0, + pub deposit: _1, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "The pallet has too many candidates."] + TooManyCandidates, + #[codec(index = 1)] + #[doc = "Leaving would result in too few candidates."] + TooFewEligibleCollators, + #[codec(index = 2)] + #[doc = "Account is already a candidate."] + AlreadyCandidate, + #[codec(index = 3)] + #[doc = "Account is not a candidate."] + NotCandidate, + #[codec(index = 4)] + #[doc = "There are too many Invulnerables."] + TooManyInvulnerables, + #[codec(index = 5)] + #[doc = "Account is already an Invulnerable."] + AlreadyInvulnerable, + #[codec(index = 6)] + #[doc = "Account is not an Invulnerable."] + NotInvulnerable, + #[codec(index = 7)] + #[doc = "Account has no associated validator ID."] + NoAssociatedValidatorId, + #[codec(index = 8)] + #[doc = "Validator ID is not yet registered."] + ValidatorNotRegistered, + #[codec(index = 9)] + #[doc = "Could not insert in the candidate list."] + InsertToCandidateListFailed, + #[codec(index = 10)] + #[doc = "Could not remove from the candidate list."] + RemoveFromCandidateListFailed, + #[codec(index = 11)] + #[doc = "New deposit amount would be below the minimum candidacy bond."] + DepositTooLow, + #[codec(index = 12)] + #[doc = "Could not update the candidate list."] + UpdateCandidateListFailed, + #[codec(index = 13)] + #[doc = "Deposit amount is too low to take the target's slot in the candidate list."] + InsufficientBond, + #[codec(index = 14)] + #[doc = "The target account to be replaced in the candidate list is not a candidate."] + TargetIsNotCandidate, + #[codec(index = 15)] + #[doc = "The updated deposit amount is equal to the amount already reserved."] + IdenticalDeposit, + #[codec(index = 16)] + #[doc = "Cannot lower candidacy bond while occupying a future collator slot in the list."] + InvalidUnreserve, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "New Invulnerables were set."] + NewInvulnerables { invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32> }, + #[codec(index = 1)] + #[doc = "A new Invulnerable was added."] + InvulnerableAdded { account_id: ::subxt::utils::AccountId32 }, + #[codec(index = 2)] + #[doc = "An Invulnerable was removed."] + InvulnerableRemoved { account_id: ::subxt::utils::AccountId32 }, + #[codec(index = 3)] + #[doc = "The number of desired candidates was set."] + NewDesiredCandidates { desired_candidates: ::core::primitive::u32 }, + #[codec(index = 4)] + #[doc = "The candidacy bond was set."] + NewCandidacyBond { bond_amount: ::core::primitive::u128 }, + #[codec(index = 5)] + #[doc = "A new candidate joined."] + CandidateAdded { + account_id: ::subxt::utils::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 6)] + #[doc = "Bond of a candidate updated."] + CandidateBondUpdated { + account_id: ::subxt::utils::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 7)] + #[doc = "A candidate was removed."] + CandidateRemoved { account_id: ::subxt::utils::AccountId32 }, + #[codec(index = 8)] + #[doc = "An account was replaced in the candidate list by another one."] + CandidateReplaced { + old: ::subxt::utils::AccountId32, + new: ::subxt::utils::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 9)] + #[doc = "An account was unable to be added to the Invulnerables because they did not have keys"] + #[doc = "registered. Other Invulnerables may have been set."] + InvalidInvulnerableSkipped { account_id: ::subxt::utils::AccountId32 }, + } + } + } + pub mod pallet_message_queue { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::reap_page`]."] + reap_page { + message_origin: + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + page_index: ::core::primitive::u32, + }, + #[codec(index = 1)] + #[doc = "See [`Pallet::execute_overweight`]."] + execute_overweight { + message_origin: + runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + page: ::core::primitive::u32, + index: ::core::primitive::u32, + weight_limit: runtime_types::sp_weights::weight_v2::Weight, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "Page is not reapable because it has items remaining to be processed and is not old"] + #[doc = "enough."] + NotReapable, + #[codec(index = 1)] + #[doc = "Page to be reaped does not exist."] + NoPage, + #[codec(index = 2)] + #[doc = "The referenced message could not be found."] + NoMessage, + #[codec(index = 3)] + #[doc = "The message was already processed and cannot be processed again."] + AlreadyProcessed, + #[codec(index = 4)] + #[doc = "The message is queued for future execution."] + Queued, + #[codec(index = 5)] + #[doc = "There is temporarily not enough weight to continue servicing messages."] + InsufficientWeight, + #[codec(index = 6)] + #[doc = "This message is temporarily unprocessable."] + #[doc = ""] + #[doc = "Such errors are expected, but not guaranteed, to resolve themselves eventually through"] + #[doc = "retrying."] + TemporarilyUnprocessable, + #[codec(index = 7)] + #[doc = "The queue is paused and no message can be executed from it."] + #[doc = ""] + #[doc = "This can change at any time and may resolve in the future by re-trying."] + QueuePaused, + #[codec(index = 8)] + #[doc = "Another call is in progress and needs to finish before this call can happen."] + RecursiveDisallowed, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "Message discarded due to an error in the `MessageProcessor` (usually a format error)."] + ProcessingFailed { + id: ::subxt::utils::H256, + origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + error: runtime_types::frame_support::traits::messages::ProcessMessageError, + }, + #[codec(index = 1)] + #[doc = "Message is processed."] + Processed { + id: ::subxt::utils::H256, + origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + weight_used: runtime_types::sp_weights::weight_v2::Weight, + success: ::core::primitive::bool, + }, + #[codec(index = 2)] + #[doc = "Message placed in overweight queue."] + OverweightEnqueued { + id: [::core::primitive::u8; 32usize], + origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + page_index: ::core::primitive::u32, + message_index: ::core::primitive::u32, + }, + #[codec(index = 3)] + #[doc = "This page was reaped."] + PageReaped { + origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, + index: ::core::primitive::u32, + }, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct BookState<_0> { + pub begin: ::core::primitive::u32, + pub end: ::core::primitive::u32, + pub count: ::core::primitive::u32, + pub ready_neighbours: + ::core::option::Option>, + pub message_count: ::core::primitive::u64, + pub size: ::core::primitive::u64, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Neighbours<_0> { + pub prev: _0, + pub next: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Page<_0> { + pub remaining: _0, + pub remaining_size: _0, + pub first_index: _0, + pub first: _0, + pub last: _0, + pub heap: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + } + } + pub mod pallet_multisig { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::as_multi_threshold_1`]."] + as_multi_threshold_1 { + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + call: + ::std::boxed::Box, + }, + #[codec(index = 1)] + #[doc = "See [`Pallet::as_multi`]."] + as_multi { + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + call: + ::std::boxed::Box, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 2)] + #[doc = "See [`Pallet::approve_as_multi`]."] + approve_as_multi { + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + maybe_timepoint: ::core::option::Option< + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + >, + call_hash: [::core::primitive::u8; 32usize], + max_weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 3)] + #[doc = "See [`Pallet::cancel_as_multi`]."] + cancel_as_multi { + threshold: ::core::primitive::u16, + other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + call_hash: [::core::primitive::u8; 32usize], + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "Threshold must be 2 or greater."] + MinimumThreshold, + #[codec(index = 1)] + #[doc = "Call is already approved by this signatory."] + AlreadyApproved, + #[codec(index = 2)] + #[doc = "Call doesn't need any (more) approvals."] + NoApprovalsNeeded, + #[codec(index = 3)] + #[doc = "There are too few signatories in the list."] + TooFewSignatories, + #[codec(index = 4)] + #[doc = "There are too many signatories in the list."] + TooManySignatories, + #[codec(index = 5)] + #[doc = "The signatories were provided out of order; they should be ordered."] + SignatoriesOutOfOrder, + #[codec(index = 6)] + #[doc = "The sender was contained in the other signatories; it shouldn't be."] + SenderInSignatories, + #[codec(index = 7)] + #[doc = "Multisig operation not found when attempting to cancel."] + NotFound, + #[codec(index = 8)] + #[doc = "Only the account that originally created the multisig is able to cancel it."] + NotOwner, + #[codec(index = 9)] + #[doc = "No timepoint was given, yet the multisig operation is already underway."] + NoTimepoint, + #[codec(index = 10)] + #[doc = "A different timepoint was given to the multisig operation that is underway."] + WrongTimepoint, + #[codec(index = 11)] + #[doc = "A timepoint was given, yet no multisig operation is underway."] + UnexpectedTimepoint, + #[codec(index = 12)] + #[doc = "The maximum weight information provided was too low."] + MaxWeightTooLow, + #[codec(index = 13)] + #[doc = "The data to be stored is already stored."] + AlreadyStored, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "A new multisig operation has begun."] + NewMultisig { + approving: ::subxt::utils::AccountId32, + multisig: ::subxt::utils::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 1)] + #[doc = "A multisig operation has been approved by someone."] + MultisigApproval { + approving: ::subxt::utils::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::subxt::utils::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + #[doc = "A multisig operation has been executed."] + MultisigExecuted { + approving: ::subxt::utils::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::subxt::utils::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 3)] + #[doc = "A multisig operation has been cancelled."] + MultisigCancelled { + cancelling: ::subxt::utils::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::subxt::utils::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Multisig<_0, _1, _2> { + pub when: runtime_types::pallet_multisig::Timepoint<_0>, + pub deposit: _1, + pub depositor: _2, + pub approvals: runtime_types::bounded_collections::bounded_vec::BoundedVec<_2>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Timepoint<_0> { + pub height: _0, + pub index: ::core::primitive::u32, + } + } + pub mod pallet_session { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::set_keys`]."] + set_keys { + keys: runtime_types::coretime_rococo_runtime::SessionKeys, + proof: ::std::vec::Vec<::core::primitive::u8>, + }, + #[codec(index = 1)] + #[doc = "See [`Pallet::purge_keys`]."] + purge_keys, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Error for the session pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "Invalid ownership proof."] + InvalidProof, + #[codec(index = 1)] + #[doc = "No associated validator ID for account."] + NoAssociatedValidatorId, + #[codec(index = 2)] + #[doc = "Registered duplicate key."] + DuplicatedKey, + #[codec(index = 3)] + #[doc = "No keys are associated with this account."] + NoKeys, + #[codec(index = 4)] + #[doc = "Key setting account is not live, so it's impossible to associate keys."] + NoAccount, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "New session has happened. Note that the argument is the session index, not the"] + #[doc = "block number as the type might suggest."] + NewSession { session_index: ::core::primitive::u32 }, + } + } + } + pub mod pallet_sudo { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::sudo`]."] + sudo { + call: + ::std::boxed::Box, + }, + #[codec(index = 1)] + #[doc = "See [`Pallet::sudo_unchecked_weight`]."] + sudo_unchecked_weight { + call: + ::std::boxed::Box, + weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 2)] + #[doc = "See [`Pallet::set_key`]."] + set_key { new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()> }, + #[codec(index = 3)] + #[doc = "See [`Pallet::sudo_as`]."] + sudo_as { + who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, + call: + ::std::boxed::Box, + }, + #[codec(index = 4)] + #[doc = "See [`Pallet::remove_key`]."] + remove_key, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Error for the Sudo pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "Sender must be the Sudo account."] + RequireSudo, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "A sudo call just took place."] + Sudid { + sudo_result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 1)] + #[doc = "The sudo key has been updated."] + KeyChanged { + old: ::core::option::Option<::subxt::utils::AccountId32>, + new: ::subxt::utils::AccountId32, + }, + #[codec(index = 2)] + #[doc = "The key was permanently removed."] + KeyRemoved, + #[codec(index = 3)] + #[doc = "A [sudo_as](Pallet::sudo_as) call just took place."] + SudoAsDone { + sudo_result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + } + } + } + pub mod pallet_timestamp { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::set`]."] + set { + #[codec(compact)] + now: ::core::primitive::u64, + }, + } + } + } + pub mod pallet_transaction_payment { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] + #[doc = "has been paid by `who`."] + TransactionFeePaid { + who: ::subxt::utils::AccountId32, + actual_fee: ::core::primitive::u128, + tip: ::core::primitive::u128, + }, + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct FeeDetails<_0> { + pub inclusion_fee: ::core::option::Option< + runtime_types::pallet_transaction_payment::types::InclusionFee<_0>, + >, + pub tip: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InclusionFee<_0> { + pub base_fee: _0, + pub len_fee: _0, + pub adjusted_weight_fee: _0, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RuntimeDispatchInfo<_0, _1> { + pub weight: _1, + pub class: runtime_types::frame_support::dispatch::DispatchClass, + pub partial_fee: _0, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ChargeTransactionPayment(#[codec(compact)] pub ::core::primitive::u128); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Releases { + #[codec(index = 0)] + V1Ancient, + #[codec(index = 1)] + V2, + } + } + pub mod pallet_utility { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::batch`]."] + batch { + calls: ::std::vec::Vec, + }, + #[codec(index = 1)] + #[doc = "See [`Pallet::as_derivative`]."] + as_derivative { + index: ::core::primitive::u16, + call: + ::std::boxed::Box, + }, + #[codec(index = 2)] + #[doc = "See [`Pallet::batch_all`]."] + batch_all { + calls: ::std::vec::Vec, + }, + #[codec(index = 3)] + #[doc = "See [`Pallet::dispatch_as`]."] + dispatch_as { + as_origin: + ::std::boxed::Box, + call: + ::std::boxed::Box, + }, + #[codec(index = 4)] + #[doc = "See [`Pallet::force_batch`]."] + force_batch { + calls: ::std::vec::Vec, + }, + #[codec(index = 5)] + #[doc = "See [`Pallet::with_weight`]."] + with_weight { + call: + ::std::boxed::Box, + weight: runtime_types::sp_weights::weight_v2::Weight, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "Too many calls batched."] + TooManyCalls, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] + #[doc = "well as the error."] + BatchInterrupted { + index: ::core::primitive::u32, + error: runtime_types::sp_runtime::DispatchError, + }, + #[codec(index = 1)] + #[doc = "Batch of dispatches completed fully with no error."] + BatchCompleted, + #[codec(index = 2)] + #[doc = "Batch of dispatches completed but has errors."] + BatchCompletedWithErrors, + #[codec(index = 3)] + #[doc = "A single item within a Batch of dispatches has completed with no error."] + ItemCompleted, + #[codec(index = 4)] + #[doc = "A single item within a Batch of dispatches has completed with error."] + ItemFailed { error: runtime_types::sp_runtime::DispatchError }, + #[codec(index = 5)] + #[doc = "A call was dispatched."] + DispatchedAs { + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + } + } + } + pub mod pallet_xcm { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call { + #[codec(index = 0)] + #[doc = "See [`Pallet::send`]."] + send { + dest: ::std::boxed::Box, + message: ::std::boxed::Box, + }, + #[codec(index = 1)] + #[doc = "See [`Pallet::teleport_assets`]."] + teleport_assets { + dest: ::std::boxed::Box, + beneficiary: ::std::boxed::Box, + assets: ::std::boxed::Box, + fee_asset_item: ::core::primitive::u32, + }, + #[codec(index = 2)] + #[doc = "See [`Pallet::reserve_transfer_assets`]."] + reserve_transfer_assets { + dest: ::std::boxed::Box, + beneficiary: ::std::boxed::Box, + assets: ::std::boxed::Box, + fee_asset_item: ::core::primitive::u32, + }, + #[codec(index = 3)] + #[doc = "See [`Pallet::execute`]."] + execute { + message: ::std::boxed::Box, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 4)] + #[doc = "See [`Pallet::force_xcm_version`]."] + force_xcm_version { + location: + ::std::boxed::Box, + version: ::core::primitive::u32, + }, + #[codec(index = 5)] + #[doc = "See [`Pallet::force_default_xcm_version`]."] + force_default_xcm_version { + maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, + }, + #[codec(index = 6)] + #[doc = "See [`Pallet::force_subscribe_version_notify`]."] + force_subscribe_version_notify { + location: ::std::boxed::Box, + }, + #[codec(index = 7)] + #[doc = "See [`Pallet::force_unsubscribe_version_notify`]."] + force_unsubscribe_version_notify { + location: ::std::boxed::Box, + }, + #[codec(index = 8)] + #[doc = "See [`Pallet::limited_reserve_transfer_assets`]."] + limited_reserve_transfer_assets { + dest: ::std::boxed::Box, + beneficiary: ::std::boxed::Box, + assets: ::std::boxed::Box, + fee_asset_item: ::core::primitive::u32, + weight_limit: runtime_types::xcm::v3::WeightLimit, + }, + #[codec(index = 9)] + #[doc = "See [`Pallet::limited_teleport_assets`]."] + limited_teleport_assets { + dest: ::std::boxed::Box, + beneficiary: ::std::boxed::Box, + assets: ::std::boxed::Box, + fee_asset_item: ::core::primitive::u32, + weight_limit: runtime_types::xcm::v3::WeightLimit, + }, + #[codec(index = 10)] + #[doc = "See [`Pallet::force_suspension`]."] + force_suspension { suspended: ::core::primitive::bool }, + #[codec(index = 11)] + #[doc = "See [`Pallet::transfer_assets`]."] + transfer_assets { + dest: ::std::boxed::Box, + beneficiary: ::std::boxed::Box, + assets: ::std::boxed::Box, + fee_asset_item: ::core::primitive::u32, + weight_limit: runtime_types::xcm::v3::WeightLimit, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Error` enum of this pallet."] + pub enum Error { + #[codec(index = 0)] + #[doc = "The desired destination was unreachable, generally because there is a no way of routing"] + #[doc = "to it."] + Unreachable, + #[codec(index = 1)] + #[doc = "There was some other issue (i.e. not to do with routing) in sending the message."] + #[doc = "Perhaps a lack of space for buffering the message."] + SendFailure, + #[codec(index = 2)] + #[doc = "The message execution fails the filter."] + Filtered, + #[codec(index = 3)] + #[doc = "The message's weight could not be determined."] + UnweighableMessage, + #[codec(index = 4)] + #[doc = "The destination `Location` provided cannot be inverted."] + DestinationNotInvertible, + #[codec(index = 5)] + #[doc = "The assets to be sent are empty."] + Empty, + #[codec(index = 6)] + #[doc = "Could not re-anchor the assets to declare the fees for the destination chain."] + CannotReanchor, + #[codec(index = 7)] + #[doc = "Too many assets have been attempted for transfer."] + TooManyAssets, + #[codec(index = 8)] + #[doc = "Origin is invalid for sending."] + InvalidOrigin, + #[codec(index = 9)] + #[doc = "The version of the `Versioned` value used is not able to be interpreted."] + BadVersion, + #[codec(index = 10)] + #[doc = "The given location could not be used (e.g. because it cannot be expressed in the"] + #[doc = "desired version of XCM)."] + BadLocation, + #[codec(index = 11)] + #[doc = "The referenced subscription could not be found."] + NoSubscription, + #[codec(index = 12)] + #[doc = "The location is invalid since it already has a subscription from us."] + AlreadySubscribed, + #[codec(index = 13)] + #[doc = "Could not check-out the assets for teleportation to the destination chain."] + CannotCheckOutTeleport, + #[codec(index = 14)] + #[doc = "The owner does not own (all) of the asset that they wish to do the operation on."] + LowBalance, + #[codec(index = 15)] + #[doc = "The asset owner has too many locks on the asset."] + TooManyLocks, + #[codec(index = 16)] + #[doc = "The given account is not an identifiable sovereign account for any location."] + AccountNotSovereign, + #[codec(index = 17)] + #[doc = "The operation required fees to be paid which the initiator could not meet."] + FeesNotMet, + #[codec(index = 18)] + #[doc = "A remote lock with the corresponding data could not be found."] + LockNotFound, + #[codec(index = 19)] + #[doc = "The unlock operation cannot succeed because there are still consumers of the lock."] + InUse, + #[codec(index = 20)] + #[doc = "Invalid non-concrete asset."] + InvalidAssetNotConcrete, + #[codec(index = 21)] + #[doc = "Invalid asset, reserve chain could not be determined for it."] + InvalidAssetUnknownReserve, + #[codec(index = 22)] + #[doc = "Invalid asset, do not support remote asset reserves with different fees reserves."] + InvalidAssetUnsupportedReserve, + #[codec(index = 23)] + #[doc = "Too many assets with different reserve locations have been attempted for transfer."] + TooManyReserves, + #[codec(index = 24)] + #[doc = "Local XCM execution incomplete."] + LocalExecutionIncomplete, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "The `Event` enum of this pallet"] + pub enum Event { + #[codec(index = 0)] + #[doc = "Execution of an XCM message was attempted."] + Attempted { outcome: runtime_types::staging_xcm::v4::traits::Outcome }, + #[codec(index = 1)] + #[doc = "A XCM message was sent."] + Sent { + origin: runtime_types::staging_xcm::v4::location::Location, + destination: runtime_types::staging_xcm::v4::location::Location, + message: runtime_types::staging_xcm::v4::Xcm, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + #[doc = "Query response received which does not match a registered query. This may be because a"] + #[doc = "matching query was never registered, it may be because it is a duplicate response, or"] + #[doc = "because the query timed out."] + UnexpectedResponse { + origin: runtime_types::staging_xcm::v4::location::Location, + query_id: ::core::primitive::u64, + }, + #[codec(index = 3)] + #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] + #[doc = "no registered notification call."] + ResponseReady { + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v4::Response, + }, + #[codec(index = 4)] + #[doc = "Query response has been received and query is removed. The registered notification has"] + #[doc = "been dispatched and executed successfully."] + Notified { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 5)] + #[doc = "Query response has been received and query is removed. The registered notification"] + #[doc = "could not be dispatched because the dispatch weight is greater than the maximum weight"] + #[doc = "originally budgeted by this runtime for the query result."] + NotifyOverweight { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + actual_weight: runtime_types::sp_weights::weight_v2::Weight, + max_budgeted_weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 6)] + #[doc = "Query response has been received and query is removed. There was a general error with"] + #[doc = "dispatching the notification call."] + NotifyDispatchError { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 7)] + #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] + #[doc = "decoded into a `Call`; this might be due to dispatch function having a signature which"] + #[doc = "is not `(origin, QueryId, Response)`."] + NotifyDecodeFailed { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 8)] + #[doc = "Expected query response has been received but the origin location of the response does"] + #[doc = "not match that expected. The query remains registered for a later, valid, response to"] + #[doc = "be received and acted upon."] + InvalidResponder { + origin: runtime_types::staging_xcm::v4::location::Location, + query_id: ::core::primitive::u64, + expected_location: ::core::option::Option< + runtime_types::staging_xcm::v4::location::Location, + >, + }, + #[codec(index = 9)] + #[doc = "Expected query response has been received but the expected origin location placed in"] + #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] + #[doc = ""] + #[doc = "This is unexpected (since a location placed in storage in a previously executing"] + #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] + #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] + #[doc = "needed."] + InvalidResponderVersion { + origin: runtime_types::staging_xcm::v4::location::Location, + query_id: ::core::primitive::u64, + }, + #[codec(index = 10)] + #[doc = "Received query response has been read and removed."] + ResponseTaken { query_id: ::core::primitive::u64 }, + #[codec(index = 11)] + #[doc = "Some assets have been placed in an asset trap."] + AssetsTrapped { + hash: ::subxt::utils::H256, + origin: runtime_types::staging_xcm::v4::location::Location, + assets: runtime_types::xcm::VersionedAssets, + }, + #[codec(index = 12)] + #[doc = "An XCM version change notification message has been attempted to be sent."] + #[doc = ""] + #[doc = "The cost of sending it (borne by the chain) is included."] + VersionChangeNotified { + destination: runtime_types::staging_xcm::v4::location::Location, + result: ::core::primitive::u32, + cost: runtime_types::staging_xcm::v4::asset::Assets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 13)] + #[doc = "The supported version of a location has been changed. This might be through an"] + #[doc = "automatic notification or a manual intervention."] + SupportedVersionChanged { + location: runtime_types::staging_xcm::v4::location::Location, + version: ::core::primitive::u32, + }, + #[codec(index = 14)] + #[doc = "A given location which had a version change subscription was dropped owing to an error"] + #[doc = "sending the notification to it."] + NotifyTargetSendFail { + location: runtime_types::staging_xcm::v4::location::Location, + query_id: ::core::primitive::u64, + error: runtime_types::xcm::v3::traits::Error, + }, + #[codec(index = 15)] + #[doc = "A given location which had a version change subscription was dropped owing to an error"] + #[doc = "migrating the location to our new XCM format."] + NotifyTargetMigrationFail { + location: runtime_types::xcm::VersionedLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 16)] + #[doc = "Expected query response has been received but the expected querier location placed in"] + #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] + #[doc = ""] + #[doc = "This is unexpected (since a location placed in storage in a previously executing"] + #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] + #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] + #[doc = "needed."] + InvalidQuerierVersion { + origin: runtime_types::staging_xcm::v4::location::Location, + query_id: ::core::primitive::u64, + }, + #[codec(index = 17)] + #[doc = "Expected query response has been received but the querier location of the response does"] + #[doc = "not match the expected. The query remains registered for a later, valid, response to"] + #[doc = "be received and acted upon."] + InvalidQuerier { + origin: runtime_types::staging_xcm::v4::location::Location, + query_id: ::core::primitive::u64, + expected_querier: runtime_types::staging_xcm::v4::location::Location, + maybe_actual_querier: ::core::option::Option< + runtime_types::staging_xcm::v4::location::Location, + >, + }, + #[codec(index = 18)] + #[doc = "A remote has requested XCM version change notification from us and we have honored it."] + #[doc = "A version information message is sent to them and its cost is included."] + VersionNotifyStarted { + destination: runtime_types::staging_xcm::v4::location::Location, + cost: runtime_types::staging_xcm::v4::asset::Assets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 19)] + #[doc = "We have requested that a remote chain send us XCM version change notifications."] + VersionNotifyRequested { + destination: runtime_types::staging_xcm::v4::location::Location, + cost: runtime_types::staging_xcm::v4::asset::Assets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 20)] + #[doc = "We have requested that a remote chain stops sending us XCM version change"] + #[doc = "notifications."] + VersionNotifyUnrequested { + destination: runtime_types::staging_xcm::v4::location::Location, + cost: runtime_types::staging_xcm::v4::asset::Assets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 21)] + #[doc = "Fees were paid from a location for an operation (often for using `SendXcm`)."] + FeesPaid { + paying: runtime_types::staging_xcm::v4::location::Location, + fees: runtime_types::staging_xcm::v4::asset::Assets, + }, + #[codec(index = 22)] + #[doc = "Some assets have been claimed from an asset trap"] + AssetsClaimed { + hash: ::subxt::utils::H256, + origin: runtime_types::staging_xcm::v4::location::Location, + assets: runtime_types::xcm::VersionedAssets, + }, + #[codec(index = 23)] + #[doc = "A XCM version migration finished."] + VersionMigrationFinished { version: ::core::primitive::u32 }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Origin { + #[codec(index = 0)] + Xcm(runtime_types::staging_xcm::v4::location::Location), + #[codec(index = 1)] + Response(runtime_types::staging_xcm::v4::location::Location), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum QueryStatus<_0> { + #[codec(index = 0)] + Pending { + responder: runtime_types::xcm::VersionedLocation, + maybe_match_querier: + ::core::option::Option, + maybe_notify: + ::core::option::Option<(::core::primitive::u8, ::core::primitive::u8)>, + timeout: _0, + }, + #[codec(index = 1)] + VersionNotifier { + origin: runtime_types::xcm::VersionedLocation, + is_active: ::core::primitive::bool, + }, + #[codec(index = 2)] + Ready { response: runtime_types::xcm::VersionedResponse, at: _0 }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RemoteLockedFungibleRecord<_0> { + pub amount: ::core::primitive::u128, + pub owner: runtime_types::xcm::VersionedLocation, + pub locker: runtime_types::xcm::VersionedLocation, + pub consumers: runtime_types::bounded_collections::bounded_vec::BoundedVec<( + _0, + ::core::primitive::u128, + )>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum VersionMigrationStage { + #[codec(index = 0)] + MigrateSupportedVersion, + #[codec(index = 1)] + MigrateVersionNotifiers, + #[codec(index = 2)] + NotifyCurrentTargets( + ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, + ), + #[codec(index = 3)] + MigrateAndNotifyOldTargets, + } + } + } + pub mod polkadot_core_primitives { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InboundDownwardMessage<_0> { + pub sent_at: _0, + pub msg: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InboundHrmpMessage<_0> { + pub sent_at: _0, + pub data: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OutboundHrmpMessage<_0> { + pub recipient: _0, + pub data: ::std::vec::Vec<::core::primitive::u8>, + } + } + pub mod polkadot_parachain_primitives { + use super::runtime_types; + pub mod primitives { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct HeadData(pub ::std::vec::Vec<::core::primitive::u8>); + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Id(pub ::core::primitive::u32); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidationCode(pub ::std::vec::Vec<::core::primitive::u8>); + } + } + pub mod polkadot_primitives { + use super::runtime_types; + pub mod v6 { + use super::runtime_types; + pub mod async_backing { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AsyncBackingParams { + pub max_candidate_depth: ::core::primitive::u32, + pub allowed_ancestry_len: ::core::primitive::u32, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AbridgedHostConfiguration { + pub max_code_size: ::core::primitive::u32, + pub max_head_data_size: ::core::primitive::u32, + pub max_upward_queue_count: ::core::primitive::u32, + pub max_upward_queue_size: ::core::primitive::u32, + pub max_upward_message_size: ::core::primitive::u32, + pub max_upward_message_num_per_candidate: ::core::primitive::u32, + pub hrmp_max_message_num_per_candidate: ::core::primitive::u32, + pub validation_upgrade_cooldown: ::core::primitive::u32, + pub validation_upgrade_delay: ::core::primitive::u32, + pub async_backing_params: + runtime_types::polkadot_primitives::v6::async_backing::AsyncBackingParams, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AbridgedHrmpChannel { + pub max_capacity: ::core::primitive::u32, + pub max_total_size: ::core::primitive::u32, + pub max_message_size: ::core::primitive::u32, + pub msg_count: ::core::primitive::u32, + pub total_size: ::core::primitive::u32, + pub mqc_head: ::core::option::Option<::subxt::utils::H256>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PersistedValidationData<_0, _1> { + pub parent_head: + runtime_types::polkadot_parachain_primitives::primitives::HeadData, + pub relay_parent_number: _1, + pub relay_parent_storage_root: _0, + pub max_pov_size: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum UpgradeGoAhead { + #[codec(index = 0)] + Abort, + #[codec(index = 1)] + GoAhead, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum UpgradeRestriction { + #[codec(index = 0)] + Present, + } + } + } + pub mod sp_arithmetic { + use super::runtime_types; + pub mod fixed_point { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct FixedU128(pub ::core::primitive::u128); + } + pub mod per_things { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Perbill(pub ::core::primitive::u32); + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum ArithmeticError { + #[codec(index = 0)] + Underflow, + #[codec(index = 1)] + Overflow, + #[codec(index = 2)] + DivisionByZero, + } + } + pub mod sp_consensus_aura { + use super::runtime_types; + pub mod sr25519 { + use super::runtime_types; + pub mod app_sr25519 { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Public(pub runtime_types::sp_core::sr25519::Public); + } + } + } + pub mod sp_consensus_slots { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Slot(pub ::core::primitive::u64); + #[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct SlotDuration(pub ::core::primitive::u64); + } + pub mod sp_core { + use super::runtime_types; + pub mod crypto { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); + } + pub mod ecdsa { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Signature(pub [::core::primitive::u8; 65usize]); + } + pub mod ed25519 { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Signature(pub [::core::primitive::u8; 64usize]); + } + pub mod sr25519 { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Public(pub [::core::primitive::u8; 32usize]); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Signature(pub [::core::primitive::u8; 64usize]); + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct OpaqueMetadata(pub ::std::vec::Vec<::core::primitive::u8>); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Void {} + } + pub mod sp_inherents { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct CheckInherentsResult { + pub okay: ::core::primitive::bool, + pub fatal_error: ::core::primitive::bool, + pub errors: runtime_types::sp_inherents::InherentData, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct InherentData { + pub data: ::subxt::utils::KeyedVec< + [::core::primitive::u8; 8usize], + ::std::vec::Vec<::core::primitive::u8>, + >, + } + } + pub mod sp_runtime { + use super::runtime_types; + pub mod generic { + use super::runtime_types; + pub mod block { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Block<_0, _1> { + pub header: _0, + pub extrinsics: ::std::vec::Vec<_1>, + } + } + pub mod digest { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Digest { + pub logs: + ::std::vec::Vec, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum DigestItem { + #[codec(index = 6)] + PreRuntime( + [::core::primitive::u8; 4usize], + ::std::vec::Vec<::core::primitive::u8>, + ), + #[codec(index = 4)] + Consensus( + [::core::primitive::u8; 4usize], + ::std::vec::Vec<::core::primitive::u8>, + ), + #[codec(index = 5)] + Seal( + [::core::primitive::u8; 4usize], + ::std::vec::Vec<::core::primitive::u8>, + ), + #[codec(index = 0)] + Other(::std::vec::Vec<::core::primitive::u8>), + #[codec(index = 8)] + RuntimeEnvironmentUpdated, + } + } + pub mod era { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Era { + #[codec(index = 0)] + Immortal, + #[codec(index = 1)] + Mortal1(::core::primitive::u8), + #[codec(index = 2)] + Mortal2(::core::primitive::u8), + #[codec(index = 3)] + Mortal3(::core::primitive::u8), + #[codec(index = 4)] + Mortal4(::core::primitive::u8), + #[codec(index = 5)] + Mortal5(::core::primitive::u8), + #[codec(index = 6)] + Mortal6(::core::primitive::u8), + #[codec(index = 7)] + Mortal7(::core::primitive::u8), + #[codec(index = 8)] + Mortal8(::core::primitive::u8), + #[codec(index = 9)] + Mortal9(::core::primitive::u8), + #[codec(index = 10)] + Mortal10(::core::primitive::u8), + #[codec(index = 11)] + Mortal11(::core::primitive::u8), + #[codec(index = 12)] + Mortal12(::core::primitive::u8), + #[codec(index = 13)] + Mortal13(::core::primitive::u8), + #[codec(index = 14)] + Mortal14(::core::primitive::u8), + #[codec(index = 15)] + Mortal15(::core::primitive::u8), + #[codec(index = 16)] + Mortal16(::core::primitive::u8), + #[codec(index = 17)] + Mortal17(::core::primitive::u8), + #[codec(index = 18)] + Mortal18(::core::primitive::u8), + #[codec(index = 19)] + Mortal19(::core::primitive::u8), + #[codec(index = 20)] + Mortal20(::core::primitive::u8), + #[codec(index = 21)] + Mortal21(::core::primitive::u8), + #[codec(index = 22)] + Mortal22(::core::primitive::u8), + #[codec(index = 23)] + Mortal23(::core::primitive::u8), + #[codec(index = 24)] + Mortal24(::core::primitive::u8), + #[codec(index = 25)] + Mortal25(::core::primitive::u8), + #[codec(index = 26)] + Mortal26(::core::primitive::u8), + #[codec(index = 27)] + Mortal27(::core::primitive::u8), + #[codec(index = 28)] + Mortal28(::core::primitive::u8), + #[codec(index = 29)] + Mortal29(::core::primitive::u8), + #[codec(index = 30)] + Mortal30(::core::primitive::u8), + #[codec(index = 31)] + Mortal31(::core::primitive::u8), + #[codec(index = 32)] + Mortal32(::core::primitive::u8), + #[codec(index = 33)] + Mortal33(::core::primitive::u8), + #[codec(index = 34)] + Mortal34(::core::primitive::u8), + #[codec(index = 35)] + Mortal35(::core::primitive::u8), + #[codec(index = 36)] + Mortal36(::core::primitive::u8), + #[codec(index = 37)] + Mortal37(::core::primitive::u8), + #[codec(index = 38)] + Mortal38(::core::primitive::u8), + #[codec(index = 39)] + Mortal39(::core::primitive::u8), + #[codec(index = 40)] + Mortal40(::core::primitive::u8), + #[codec(index = 41)] + Mortal41(::core::primitive::u8), + #[codec(index = 42)] + Mortal42(::core::primitive::u8), + #[codec(index = 43)] + Mortal43(::core::primitive::u8), + #[codec(index = 44)] + Mortal44(::core::primitive::u8), + #[codec(index = 45)] + Mortal45(::core::primitive::u8), + #[codec(index = 46)] + Mortal46(::core::primitive::u8), + #[codec(index = 47)] + Mortal47(::core::primitive::u8), + #[codec(index = 48)] + Mortal48(::core::primitive::u8), + #[codec(index = 49)] + Mortal49(::core::primitive::u8), + #[codec(index = 50)] + Mortal50(::core::primitive::u8), + #[codec(index = 51)] + Mortal51(::core::primitive::u8), + #[codec(index = 52)] + Mortal52(::core::primitive::u8), + #[codec(index = 53)] + Mortal53(::core::primitive::u8), + #[codec(index = 54)] + Mortal54(::core::primitive::u8), + #[codec(index = 55)] + Mortal55(::core::primitive::u8), + #[codec(index = 56)] + Mortal56(::core::primitive::u8), + #[codec(index = 57)] + Mortal57(::core::primitive::u8), + #[codec(index = 58)] + Mortal58(::core::primitive::u8), + #[codec(index = 59)] + Mortal59(::core::primitive::u8), + #[codec(index = 60)] + Mortal60(::core::primitive::u8), + #[codec(index = 61)] + Mortal61(::core::primitive::u8), + #[codec(index = 62)] + Mortal62(::core::primitive::u8), + #[codec(index = 63)] + Mortal63(::core::primitive::u8), + #[codec(index = 64)] + Mortal64(::core::primitive::u8), + #[codec(index = 65)] + Mortal65(::core::primitive::u8), + #[codec(index = 66)] + Mortal66(::core::primitive::u8), + #[codec(index = 67)] + Mortal67(::core::primitive::u8), + #[codec(index = 68)] + Mortal68(::core::primitive::u8), + #[codec(index = 69)] + Mortal69(::core::primitive::u8), + #[codec(index = 70)] + Mortal70(::core::primitive::u8), + #[codec(index = 71)] + Mortal71(::core::primitive::u8), + #[codec(index = 72)] + Mortal72(::core::primitive::u8), + #[codec(index = 73)] + Mortal73(::core::primitive::u8), + #[codec(index = 74)] + Mortal74(::core::primitive::u8), + #[codec(index = 75)] + Mortal75(::core::primitive::u8), + #[codec(index = 76)] + Mortal76(::core::primitive::u8), + #[codec(index = 77)] + Mortal77(::core::primitive::u8), + #[codec(index = 78)] + Mortal78(::core::primitive::u8), + #[codec(index = 79)] + Mortal79(::core::primitive::u8), + #[codec(index = 80)] + Mortal80(::core::primitive::u8), + #[codec(index = 81)] + Mortal81(::core::primitive::u8), + #[codec(index = 82)] + Mortal82(::core::primitive::u8), + #[codec(index = 83)] + Mortal83(::core::primitive::u8), + #[codec(index = 84)] + Mortal84(::core::primitive::u8), + #[codec(index = 85)] + Mortal85(::core::primitive::u8), + #[codec(index = 86)] + Mortal86(::core::primitive::u8), + #[codec(index = 87)] + Mortal87(::core::primitive::u8), + #[codec(index = 88)] + Mortal88(::core::primitive::u8), + #[codec(index = 89)] + Mortal89(::core::primitive::u8), + #[codec(index = 90)] + Mortal90(::core::primitive::u8), + #[codec(index = 91)] + Mortal91(::core::primitive::u8), + #[codec(index = 92)] + Mortal92(::core::primitive::u8), + #[codec(index = 93)] + Mortal93(::core::primitive::u8), + #[codec(index = 94)] + Mortal94(::core::primitive::u8), + #[codec(index = 95)] + Mortal95(::core::primitive::u8), + #[codec(index = 96)] + Mortal96(::core::primitive::u8), + #[codec(index = 97)] + Mortal97(::core::primitive::u8), + #[codec(index = 98)] + Mortal98(::core::primitive::u8), + #[codec(index = 99)] + Mortal99(::core::primitive::u8), + #[codec(index = 100)] + Mortal100(::core::primitive::u8), + #[codec(index = 101)] + Mortal101(::core::primitive::u8), + #[codec(index = 102)] + Mortal102(::core::primitive::u8), + #[codec(index = 103)] + Mortal103(::core::primitive::u8), + #[codec(index = 104)] + Mortal104(::core::primitive::u8), + #[codec(index = 105)] + Mortal105(::core::primitive::u8), + #[codec(index = 106)] + Mortal106(::core::primitive::u8), + #[codec(index = 107)] + Mortal107(::core::primitive::u8), + #[codec(index = 108)] + Mortal108(::core::primitive::u8), + #[codec(index = 109)] + Mortal109(::core::primitive::u8), + #[codec(index = 110)] + Mortal110(::core::primitive::u8), + #[codec(index = 111)] + Mortal111(::core::primitive::u8), + #[codec(index = 112)] + Mortal112(::core::primitive::u8), + #[codec(index = 113)] + Mortal113(::core::primitive::u8), + #[codec(index = 114)] + Mortal114(::core::primitive::u8), + #[codec(index = 115)] + Mortal115(::core::primitive::u8), + #[codec(index = 116)] + Mortal116(::core::primitive::u8), + #[codec(index = 117)] + Mortal117(::core::primitive::u8), + #[codec(index = 118)] + Mortal118(::core::primitive::u8), + #[codec(index = 119)] + Mortal119(::core::primitive::u8), + #[codec(index = 120)] + Mortal120(::core::primitive::u8), + #[codec(index = 121)] + Mortal121(::core::primitive::u8), + #[codec(index = 122)] + Mortal122(::core::primitive::u8), + #[codec(index = 123)] + Mortal123(::core::primitive::u8), + #[codec(index = 124)] + Mortal124(::core::primitive::u8), + #[codec(index = 125)] + Mortal125(::core::primitive::u8), + #[codec(index = 126)] + Mortal126(::core::primitive::u8), + #[codec(index = 127)] + Mortal127(::core::primitive::u8), + #[codec(index = 128)] + Mortal128(::core::primitive::u8), + #[codec(index = 129)] + Mortal129(::core::primitive::u8), + #[codec(index = 130)] + Mortal130(::core::primitive::u8), + #[codec(index = 131)] + Mortal131(::core::primitive::u8), + #[codec(index = 132)] + Mortal132(::core::primitive::u8), + #[codec(index = 133)] + Mortal133(::core::primitive::u8), + #[codec(index = 134)] + Mortal134(::core::primitive::u8), + #[codec(index = 135)] + Mortal135(::core::primitive::u8), + #[codec(index = 136)] + Mortal136(::core::primitive::u8), + #[codec(index = 137)] + Mortal137(::core::primitive::u8), + #[codec(index = 138)] + Mortal138(::core::primitive::u8), + #[codec(index = 139)] + Mortal139(::core::primitive::u8), + #[codec(index = 140)] + Mortal140(::core::primitive::u8), + #[codec(index = 141)] + Mortal141(::core::primitive::u8), + #[codec(index = 142)] + Mortal142(::core::primitive::u8), + #[codec(index = 143)] + Mortal143(::core::primitive::u8), + #[codec(index = 144)] + Mortal144(::core::primitive::u8), + #[codec(index = 145)] + Mortal145(::core::primitive::u8), + #[codec(index = 146)] + Mortal146(::core::primitive::u8), + #[codec(index = 147)] + Mortal147(::core::primitive::u8), + #[codec(index = 148)] + Mortal148(::core::primitive::u8), + #[codec(index = 149)] + Mortal149(::core::primitive::u8), + #[codec(index = 150)] + Mortal150(::core::primitive::u8), + #[codec(index = 151)] + Mortal151(::core::primitive::u8), + #[codec(index = 152)] + Mortal152(::core::primitive::u8), + #[codec(index = 153)] + Mortal153(::core::primitive::u8), + #[codec(index = 154)] + Mortal154(::core::primitive::u8), + #[codec(index = 155)] + Mortal155(::core::primitive::u8), + #[codec(index = 156)] + Mortal156(::core::primitive::u8), + #[codec(index = 157)] + Mortal157(::core::primitive::u8), + #[codec(index = 158)] + Mortal158(::core::primitive::u8), + #[codec(index = 159)] + Mortal159(::core::primitive::u8), + #[codec(index = 160)] + Mortal160(::core::primitive::u8), + #[codec(index = 161)] + Mortal161(::core::primitive::u8), + #[codec(index = 162)] + Mortal162(::core::primitive::u8), + #[codec(index = 163)] + Mortal163(::core::primitive::u8), + #[codec(index = 164)] + Mortal164(::core::primitive::u8), + #[codec(index = 165)] + Mortal165(::core::primitive::u8), + #[codec(index = 166)] + Mortal166(::core::primitive::u8), + #[codec(index = 167)] + Mortal167(::core::primitive::u8), + #[codec(index = 168)] + Mortal168(::core::primitive::u8), + #[codec(index = 169)] + Mortal169(::core::primitive::u8), + #[codec(index = 170)] + Mortal170(::core::primitive::u8), + #[codec(index = 171)] + Mortal171(::core::primitive::u8), + #[codec(index = 172)] + Mortal172(::core::primitive::u8), + #[codec(index = 173)] + Mortal173(::core::primitive::u8), + #[codec(index = 174)] + Mortal174(::core::primitive::u8), + #[codec(index = 175)] + Mortal175(::core::primitive::u8), + #[codec(index = 176)] + Mortal176(::core::primitive::u8), + #[codec(index = 177)] + Mortal177(::core::primitive::u8), + #[codec(index = 178)] + Mortal178(::core::primitive::u8), + #[codec(index = 179)] + Mortal179(::core::primitive::u8), + #[codec(index = 180)] + Mortal180(::core::primitive::u8), + #[codec(index = 181)] + Mortal181(::core::primitive::u8), + #[codec(index = 182)] + Mortal182(::core::primitive::u8), + #[codec(index = 183)] + Mortal183(::core::primitive::u8), + #[codec(index = 184)] + Mortal184(::core::primitive::u8), + #[codec(index = 185)] + Mortal185(::core::primitive::u8), + #[codec(index = 186)] + Mortal186(::core::primitive::u8), + #[codec(index = 187)] + Mortal187(::core::primitive::u8), + #[codec(index = 188)] + Mortal188(::core::primitive::u8), + #[codec(index = 189)] + Mortal189(::core::primitive::u8), + #[codec(index = 190)] + Mortal190(::core::primitive::u8), + #[codec(index = 191)] + Mortal191(::core::primitive::u8), + #[codec(index = 192)] + Mortal192(::core::primitive::u8), + #[codec(index = 193)] + Mortal193(::core::primitive::u8), + #[codec(index = 194)] + Mortal194(::core::primitive::u8), + #[codec(index = 195)] + Mortal195(::core::primitive::u8), + #[codec(index = 196)] + Mortal196(::core::primitive::u8), + #[codec(index = 197)] + Mortal197(::core::primitive::u8), + #[codec(index = 198)] + Mortal198(::core::primitive::u8), + #[codec(index = 199)] + Mortal199(::core::primitive::u8), + #[codec(index = 200)] + Mortal200(::core::primitive::u8), + #[codec(index = 201)] + Mortal201(::core::primitive::u8), + #[codec(index = 202)] + Mortal202(::core::primitive::u8), + #[codec(index = 203)] + Mortal203(::core::primitive::u8), + #[codec(index = 204)] + Mortal204(::core::primitive::u8), + #[codec(index = 205)] + Mortal205(::core::primitive::u8), + #[codec(index = 206)] + Mortal206(::core::primitive::u8), + #[codec(index = 207)] + Mortal207(::core::primitive::u8), + #[codec(index = 208)] + Mortal208(::core::primitive::u8), + #[codec(index = 209)] + Mortal209(::core::primitive::u8), + #[codec(index = 210)] + Mortal210(::core::primitive::u8), + #[codec(index = 211)] + Mortal211(::core::primitive::u8), + #[codec(index = 212)] + Mortal212(::core::primitive::u8), + #[codec(index = 213)] + Mortal213(::core::primitive::u8), + #[codec(index = 214)] + Mortal214(::core::primitive::u8), + #[codec(index = 215)] + Mortal215(::core::primitive::u8), + #[codec(index = 216)] + Mortal216(::core::primitive::u8), + #[codec(index = 217)] + Mortal217(::core::primitive::u8), + #[codec(index = 218)] + Mortal218(::core::primitive::u8), + #[codec(index = 219)] + Mortal219(::core::primitive::u8), + #[codec(index = 220)] + Mortal220(::core::primitive::u8), + #[codec(index = 221)] + Mortal221(::core::primitive::u8), + #[codec(index = 222)] + Mortal222(::core::primitive::u8), + #[codec(index = 223)] + Mortal223(::core::primitive::u8), + #[codec(index = 224)] + Mortal224(::core::primitive::u8), + #[codec(index = 225)] + Mortal225(::core::primitive::u8), + #[codec(index = 226)] + Mortal226(::core::primitive::u8), + #[codec(index = 227)] + Mortal227(::core::primitive::u8), + #[codec(index = 228)] + Mortal228(::core::primitive::u8), + #[codec(index = 229)] + Mortal229(::core::primitive::u8), + #[codec(index = 230)] + Mortal230(::core::primitive::u8), + #[codec(index = 231)] + Mortal231(::core::primitive::u8), + #[codec(index = 232)] + Mortal232(::core::primitive::u8), + #[codec(index = 233)] + Mortal233(::core::primitive::u8), + #[codec(index = 234)] + Mortal234(::core::primitive::u8), + #[codec(index = 235)] + Mortal235(::core::primitive::u8), + #[codec(index = 236)] + Mortal236(::core::primitive::u8), + #[codec(index = 237)] + Mortal237(::core::primitive::u8), + #[codec(index = 238)] + Mortal238(::core::primitive::u8), + #[codec(index = 239)] + Mortal239(::core::primitive::u8), + #[codec(index = 240)] + Mortal240(::core::primitive::u8), + #[codec(index = 241)] + Mortal241(::core::primitive::u8), + #[codec(index = 242)] + Mortal242(::core::primitive::u8), + #[codec(index = 243)] + Mortal243(::core::primitive::u8), + #[codec(index = 244)] + Mortal244(::core::primitive::u8), + #[codec(index = 245)] + Mortal245(::core::primitive::u8), + #[codec(index = 246)] + Mortal246(::core::primitive::u8), + #[codec(index = 247)] + Mortal247(::core::primitive::u8), + #[codec(index = 248)] + Mortal248(::core::primitive::u8), + #[codec(index = 249)] + Mortal249(::core::primitive::u8), + #[codec(index = 250)] + Mortal250(::core::primitive::u8), + #[codec(index = 251)] + Mortal251(::core::primitive::u8), + #[codec(index = 252)] + Mortal252(::core::primitive::u8), + #[codec(index = 253)] + Mortal253(::core::primitive::u8), + #[codec(index = 254)] + Mortal254(::core::primitive::u8), + #[codec(index = 255)] + Mortal255(::core::primitive::u8), + } + } + pub mod header { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Header<_0> { + pub parent_hash: ::subxt::utils::H256, + #[codec(compact)] + pub number: _0, + pub state_root: ::subxt::utils::H256, + pub extrinsics_root: ::subxt::utils::H256, + pub digest: runtime_types::sp_runtime::generic::digest::Digest, + } + } + } + pub mod transaction_validity { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum InvalidTransaction { + #[codec(index = 0)] + Call, + #[codec(index = 1)] + Payment, + #[codec(index = 2)] + Future, + #[codec(index = 3)] + Stale, + #[codec(index = 4)] + BadProof, + #[codec(index = 5)] + AncientBirthBlock, + #[codec(index = 6)] + ExhaustsResources, + #[codec(index = 7)] + Custom(::core::primitive::u8), + #[codec(index = 8)] + BadMandatory, + #[codec(index = 9)] + MandatoryValidation, + #[codec(index = 10)] + BadSigner, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum TransactionSource { + #[codec(index = 0)] + InBlock, + #[codec(index = 1)] + Local, + #[codec(index = 2)] + External, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum TransactionValidityError { + #[codec(index = 0)] + Invalid(runtime_types::sp_runtime::transaction_validity::InvalidTransaction), + #[codec(index = 1)] + Unknown(runtime_types::sp_runtime::transaction_validity::UnknownTransaction), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum UnknownTransaction { + #[codec(index = 0)] + CannotLookup, + #[codec(index = 1)] + NoUnsignedValidator, + #[codec(index = 2)] + Custom(::core::primitive::u8), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ValidTransaction { + pub priority: ::core::primitive::u64, + pub requires: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + pub provides: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + pub longevity: ::core::primitive::u64, + pub propagate: ::core::primitive::bool, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum DispatchError { + #[codec(index = 0)] + Other, + #[codec(index = 1)] + CannotLookup, + #[codec(index = 2)] + BadOrigin, + #[codec(index = 3)] + Module(runtime_types::sp_runtime::ModuleError), + #[codec(index = 4)] + ConsumerRemaining, + #[codec(index = 5)] + NoProviders, + #[codec(index = 6)] + TooManyConsumers, + #[codec(index = 7)] + Token(runtime_types::sp_runtime::TokenError), + #[codec(index = 8)] + Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), + #[codec(index = 9)] + Transactional(runtime_types::sp_runtime::TransactionalError), + #[codec(index = 10)] + Exhausted, + #[codec(index = 11)] + Corruption, + #[codec(index = 12)] + Unavailable, + #[codec(index = 13)] + RootNotAllowed, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct ModuleError { + pub index: ::core::primitive::u8, + pub error: [::core::primitive::u8; 4usize], + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MultiSignature { + #[codec(index = 0)] + Ed25519(runtime_types::sp_core::ed25519::Signature), + #[codec(index = 1)] + Sr25519(runtime_types::sp_core::sr25519::Signature), + #[codec(index = 2)] + Ecdsa(runtime_types::sp_core::ecdsa::Signature), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum TokenError { + #[codec(index = 0)] + FundsUnavailable, + #[codec(index = 1)] + OnlyProvider, + #[codec(index = 2)] + BelowMinimum, + #[codec(index = 3)] + CannotCreate, + #[codec(index = 4)] + UnknownAsset, + #[codec(index = 5)] + Frozen, + #[codec(index = 6)] + Unsupported, + #[codec(index = 7)] + CannotCreateHold, + #[codec(index = 8)] + NotExpendable, + #[codec(index = 9)] + Blocked, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum TransactionalError { + #[codec(index = 0)] + LimitReached, + #[codec(index = 1)] + NoLayer, + } + } + pub mod sp_trie { + use super::runtime_types; + pub mod storage_proof { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct StorageProof { + pub trie_nodes: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, + } + } + } + pub mod sp_version { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RuntimeVersion { + pub spec_name: ::std::string::String, + pub impl_name: ::std::string::String, + pub authoring_version: ::core::primitive::u32, + pub spec_version: ::core::primitive::u32, + pub impl_version: ::core::primitive::u32, + pub apis: + ::std::vec::Vec<([::core::primitive::u8; 8usize], ::core::primitive::u32)>, + pub transaction_version: ::core::primitive::u32, + pub state_version: ::core::primitive::u8, + } + } + pub mod sp_weights { + use super::runtime_types; + pub mod weight_v2 { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Weight { + #[codec(compact)] + pub ref_time: ::core::primitive::u64, + #[codec(compact)] + pub proof_size: ::core::primitive::u64, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct RuntimeDbWeight { + pub read: ::core::primitive::u64, + pub write: ::core::primitive::u64, + } + } + pub mod staging_parachain_info { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] + pub enum Call {} + } + } + pub mod staging_xcm { + use super::runtime_types; + pub mod v3 { + use super::runtime_types; + pub mod multilocation { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiLocation { + pub parents: ::core::primitive::u8, + pub interior: runtime_types::xcm::v3::junctions::Junctions, + } + } + } + pub mod v4 { + use super::runtime_types; + pub mod asset { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Asset { + pub id: runtime_types::staging_xcm::v4::asset::AssetId, + pub fun: runtime_types::staging_xcm::v4::asset::Fungibility, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AssetFilter { + #[codec(index = 0)] + Definite(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 1)] + Wild(runtime_types::staging_xcm::v4::asset::WildAsset), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct AssetId(pub runtime_types::staging_xcm::v4::location::Location); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AssetInstance { + #[codec(index = 0)] + Undefined, + #[codec(index = 1)] + Index(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 2)] + Array4([::core::primitive::u8; 4usize]), + #[codec(index = 3)] + Array8([::core::primitive::u8; 8usize]), + #[codec(index = 4)] + Array16([::core::primitive::u8; 16usize]), + #[codec(index = 5)] + Array32([::core::primitive::u8; 32usize]), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Assets( + pub ::std::vec::Vec, + ); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Fungibility { + #[codec(index = 0)] + Fungible(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 1)] + NonFungible(runtime_types::staging_xcm::v4::asset::AssetInstance), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WildAsset { + #[codec(index = 0)] + All, + #[codec(index = 1)] + AllOf { + id: runtime_types::staging_xcm::v4::asset::AssetId, + fun: runtime_types::staging_xcm::v4::asset::WildFungibility, + }, + #[codec(index = 2)] + AllCounted(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + AllOfCounted { + id: runtime_types::staging_xcm::v4::asset::AssetId, + fun: runtime_types::staging_xcm::v4::asset::WildFungibility, + #[codec(compact)] + count: ::core::primitive::u32, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WildFungibility { + #[codec(index = 0)] + Fungible, + #[codec(index = 1)] + NonFungible, + } + } + pub mod junction { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Junction { + #[codec(index = 0)] + Parachain(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 1)] + AccountId32 { + network: ::core::option::Option< + runtime_types::staging_xcm::v4::junction::NetworkId, + >, + id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + AccountIndex64 { + network: ::core::option::Option< + runtime_types::staging_xcm::v4::junction::NetworkId, + >, + #[codec(compact)] + index: ::core::primitive::u64, + }, + #[codec(index = 3)] + AccountKey20 { + network: ::core::option::Option< + runtime_types::staging_xcm::v4::junction::NetworkId, + >, + key: [::core::primitive::u8; 20usize], + }, + #[codec(index = 4)] + PalletInstance(::core::primitive::u8), + #[codec(index = 5)] + GeneralIndex(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 6)] + GeneralKey { + length: ::core::primitive::u8, + data: [::core::primitive::u8; 32usize], + }, + #[codec(index = 7)] + OnlyChild, + #[codec(index = 8)] + Plurality { + id: runtime_types::xcm::v3::junction::BodyId, + part: runtime_types::xcm::v3::junction::BodyPart, + }, + #[codec(index = 9)] + GlobalConsensus(runtime_types::staging_xcm::v4::junction::NetworkId), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum NetworkId { + #[codec(index = 0)] + ByGenesis([::core::primitive::u8; 32usize]), + #[codec(index = 1)] + ByFork { + block_number: ::core::primitive::u64, + block_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + Polkadot, + #[codec(index = 3)] + Kusama, + #[codec(index = 4)] + Westend, + #[codec(index = 5)] + Rococo, + #[codec(index = 6)] + Wococo, + #[codec(index = 7)] + Ethereum { + #[codec(compact)] + chain_id: ::core::primitive::u64, + }, + #[codec(index = 8)] + BitcoinCore, + #[codec(index = 9)] + BitcoinCash, + #[codec(index = 10)] + PolkadotBulletin, + } + } + pub mod junctions { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Junctions { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + X1([runtime_types::staging_xcm::v4::junction::Junction; 1usize]), + #[codec(index = 2)] + X2([runtime_types::staging_xcm::v4::junction::Junction; 2usize]), + #[codec(index = 3)] + X3([runtime_types::staging_xcm::v4::junction::Junction; 3usize]), + #[codec(index = 4)] + X4([runtime_types::staging_xcm::v4::junction::Junction; 4usize]), + #[codec(index = 5)] + X5([runtime_types::staging_xcm::v4::junction::Junction; 5usize]), + #[codec(index = 6)] + X6([runtime_types::staging_xcm::v4::junction::Junction; 6usize]), + #[codec(index = 7)] + X7([runtime_types::staging_xcm::v4::junction::Junction; 7usize]), + #[codec(index = 8)] + X8([runtime_types::staging_xcm::v4::junction::Junction; 8usize]), + } + } + pub mod location { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Location { + pub parents: ::core::primitive::u8, + pub interior: runtime_types::staging_xcm::v4::junctions::Junctions, + } + } + pub mod traits { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Outcome { + #[codec(index = 0)] + Complete { used: runtime_types::sp_weights::weight_v2::Weight }, + #[codec(index = 1)] + Incomplete { + used: runtime_types::sp_weights::weight_v2::Weight, + error: runtime_types::xcm::v3::traits::Error, + }, + #[codec(index = 2)] + Error { error: runtime_types::xcm::v3::traits::Error }, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Instruction { + #[codec(index = 0)] + WithdrawAsset(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v4::Response, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + querier: ::core::option::Option< + runtime_types::staging_xcm::v4::location::Location, + >, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::staging_xcm::v4::asset::Assets, + beneficiary: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::staging_xcm::v4::asset::Assets, + dest: runtime_types::staging_xcm::v4::location::Location, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_kind: runtime_types::xcm::v2::OriginKind, + require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, + call: runtime_types::xcm::double_encoded::DoubleEncoded, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::staging_xcm::v4::junctions::Junctions), + #[codec(index = 12)] + ReportError(runtime_types::staging_xcm::v4::QueryResponseInfo), + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + beneficiary: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + dest: runtime_types::staging_xcm::v4::location::Location, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::staging_xcm::v4::asset::AssetFilter, + want: runtime_types::staging_xcm::v4::asset::Assets, + maximal: ::core::primitive::bool, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + reserve: runtime_types::staging_xcm::v4::location::Location, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + dest: runtime_types::staging_xcm::v4::location::Location, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 18)] + ReportHolding { + response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::staging_xcm::v4::asset::Asset, + weight_limit: runtime_types::xcm::v3::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::staging_xcm::v4::Xcm), + #[codec(index = 22)] + SetAppendix(runtime_types::staging_xcm::v4::Xcm), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::staging_xcm::v4::asset::Assets, + ticket: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + max_response_weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 27)] + UnsubscribeVersion, + #[codec(index = 28)] + BurnAsset(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 29)] + ExpectAsset(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 30)] + ExpectOrigin( + ::core::option::Option, + ), + #[codec(index = 31)] + ExpectError( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v3::traits::Error, + )>, + ), + #[codec(index = 32)] + ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), + #[codec(index = 33)] + QueryPallet { + module_name: ::std::vec::Vec<::core::primitive::u8>, + response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, + }, + #[codec(index = 34)] + ExpectPallet { + #[codec(compact)] + index: ::core::primitive::u32, + name: ::std::vec::Vec<::core::primitive::u8>, + module_name: ::std::vec::Vec<::core::primitive::u8>, + #[codec(compact)] + crate_major: ::core::primitive::u32, + #[codec(compact)] + min_crate_minor: ::core::primitive::u32, + }, + #[codec(index = 35)] + ReportTransactStatus(runtime_types::staging_xcm::v4::QueryResponseInfo), + #[codec(index = 36)] + ClearTransactStatus, + #[codec(index = 37)] + UniversalOrigin(runtime_types::staging_xcm::v4::junction::Junction), + #[codec(index = 38)] + ExportMessage { + network: runtime_types::staging_xcm::v4::junction::NetworkId, + destination: runtime_types::staging_xcm::v4::junctions::Junctions, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 39)] + LockAsset { + asset: runtime_types::staging_xcm::v4::asset::Asset, + unlocker: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 40)] + UnlockAsset { + asset: runtime_types::staging_xcm::v4::asset::Asset, + target: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 41)] + NoteUnlockable { + asset: runtime_types::staging_xcm::v4::asset::Asset, + owner: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 42)] + RequestUnlock { + asset: runtime_types::staging_xcm::v4::asset::Asset, + locker: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 43)] + SetFeesMode { jit_withdraw: ::core::primitive::bool }, + #[codec(index = 44)] + SetTopic([::core::primitive::u8; 32usize]), + #[codec(index = 45)] + ClearTopic, + #[codec(index = 46)] + AliasOrigin(runtime_types::staging_xcm::v4::location::Location), + #[codec(index = 47)] + UnpaidExecution { + weight_limit: runtime_types::xcm::v3::WeightLimit, + check_origin: ::core::option::Option< + runtime_types::staging_xcm::v4::location::Location, + >, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Instruction2 { + #[codec(index = 0)] + WithdrawAsset(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v4::Response, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + querier: ::core::option::Option< + runtime_types::staging_xcm::v4::location::Location, + >, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::staging_xcm::v4::asset::Assets, + beneficiary: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::staging_xcm::v4::asset::Assets, + dest: runtime_types::staging_xcm::v4::location::Location, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_kind: runtime_types::xcm::v2::OriginKind, + require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, + call: runtime_types::xcm::double_encoded::DoubleEncoded2, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::staging_xcm::v4::junctions::Junctions), + #[codec(index = 12)] + ReportError(runtime_types::staging_xcm::v4::QueryResponseInfo), + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + beneficiary: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + dest: runtime_types::staging_xcm::v4::location::Location, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::staging_xcm::v4::asset::AssetFilter, + want: runtime_types::staging_xcm::v4::asset::Assets, + maximal: ::core::primitive::bool, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + reserve: runtime_types::staging_xcm::v4::location::Location, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + dest: runtime_types::staging_xcm::v4::location::Location, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 18)] + ReportHolding { + response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, + assets: runtime_types::staging_xcm::v4::asset::AssetFilter, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::staging_xcm::v4::asset::Asset, + weight_limit: runtime_types::xcm::v3::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::staging_xcm::v4::Xcm2), + #[codec(index = 22)] + SetAppendix(runtime_types::staging_xcm::v4::Xcm2), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::staging_xcm::v4::asset::Assets, + ticket: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + max_response_weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 27)] + UnsubscribeVersion, + #[codec(index = 28)] + BurnAsset(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 29)] + ExpectAsset(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 30)] + ExpectOrigin( + ::core::option::Option, + ), + #[codec(index = 31)] + ExpectError( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v3::traits::Error, + )>, + ), + #[codec(index = 32)] + ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), + #[codec(index = 33)] + QueryPallet { + module_name: ::std::vec::Vec<::core::primitive::u8>, + response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, + }, + #[codec(index = 34)] + ExpectPallet { + #[codec(compact)] + index: ::core::primitive::u32, + name: ::std::vec::Vec<::core::primitive::u8>, + module_name: ::std::vec::Vec<::core::primitive::u8>, + #[codec(compact)] + crate_major: ::core::primitive::u32, + #[codec(compact)] + min_crate_minor: ::core::primitive::u32, + }, + #[codec(index = 35)] + ReportTransactStatus(runtime_types::staging_xcm::v4::QueryResponseInfo), + #[codec(index = 36)] + ClearTransactStatus, + #[codec(index = 37)] + UniversalOrigin(runtime_types::staging_xcm::v4::junction::Junction), + #[codec(index = 38)] + ExportMessage { + network: runtime_types::staging_xcm::v4::junction::NetworkId, + destination: runtime_types::staging_xcm::v4::junctions::Junctions, + xcm: runtime_types::staging_xcm::v4::Xcm, + }, + #[codec(index = 39)] + LockAsset { + asset: runtime_types::staging_xcm::v4::asset::Asset, + unlocker: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 40)] + UnlockAsset { + asset: runtime_types::staging_xcm::v4::asset::Asset, + target: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 41)] + NoteUnlockable { + asset: runtime_types::staging_xcm::v4::asset::Asset, + owner: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 42)] + RequestUnlock { + asset: runtime_types::staging_xcm::v4::asset::Asset, + locker: runtime_types::staging_xcm::v4::location::Location, + }, + #[codec(index = 43)] + SetFeesMode { jit_withdraw: ::core::primitive::bool }, + #[codec(index = 44)] + SetTopic([::core::primitive::u8; 32usize]), + #[codec(index = 45)] + ClearTopic, + #[codec(index = 46)] + AliasOrigin(runtime_types::staging_xcm::v4::location::Location), + #[codec(index = 47)] + UnpaidExecution { + weight_limit: runtime_types::xcm::v3::WeightLimit, + check_origin: ::core::option::Option< + runtime_types::staging_xcm::v4::location::Location, + >, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PalletInfo { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + #[codec(compact)] + pub major: ::core::primitive::u32, + #[codec(compact)] + pub minor: ::core::primitive::u32, + #[codec(compact)] + pub patch: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryResponseInfo { + pub destination: runtime_types::staging_xcm::v4::location::Location, + #[codec(compact)] + pub query_id: ::core::primitive::u64, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Response { + #[codec(index = 0)] + Null, + #[codec(index = 1)] + Assets(runtime_types::staging_xcm::v4::asset::Assets), + #[codec(index = 2)] + ExecutionResult( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v3::traits::Error, + )>, + ), + #[codec(index = 3)] + Version(::core::primitive::u32), + #[codec(index = 4)] + PalletsInfo( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::staging_xcm::v4::PalletInfo, + >, + ), + #[codec(index = 5)] + DispatchResult(runtime_types::xcm::v3::MaybeErrorCode), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Xcm(pub ::std::vec::Vec); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Xcm2(pub ::std::vec::Vec); + } + } + pub mod xcm { + use super::runtime_types; + pub mod double_encoded { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DoubleEncoded { + pub encoded: ::std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct DoubleEncoded2 { + pub encoded: ::std::vec::Vec<::core::primitive::u8>, + } + } + pub mod v2 { + use super::runtime_types; + pub mod junction { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Junction { + #[codec(index = 0)] + Parachain(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 1)] + AccountId32 { + network: runtime_types::xcm::v2::NetworkId, + id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + AccountIndex64 { + network: runtime_types::xcm::v2::NetworkId, + #[codec(compact)] + index: ::core::primitive::u64, + }, + #[codec(index = 3)] + AccountKey20 { + network: runtime_types::xcm::v2::NetworkId, + key: [::core::primitive::u8; 20usize], + }, + #[codec(index = 4)] + PalletInstance(::core::primitive::u8), + #[codec(index = 5)] + GeneralIndex(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 6)] + GeneralKey( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 7)] + OnlyChild, + #[codec(index = 8)] + Plurality { + id: runtime_types::xcm::v2::BodyId, + part: runtime_types::xcm::v2::BodyPart, + }, + } + } + pub mod multiasset { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AssetId { + #[codec(index = 0)] + Concrete(runtime_types::xcm::v2::multilocation::MultiLocation), + #[codec(index = 1)] + Abstract(::std::vec::Vec<::core::primitive::u8>), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AssetInstance { + #[codec(index = 0)] + Undefined, + #[codec(index = 1)] + Index(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 2)] + Array4([::core::primitive::u8; 4usize]), + #[codec(index = 3)] + Array8([::core::primitive::u8; 8usize]), + #[codec(index = 4)] + Array16([::core::primitive::u8; 16usize]), + #[codec(index = 5)] + Array32([::core::primitive::u8; 32usize]), + #[codec(index = 6)] + Blob(::std::vec::Vec<::core::primitive::u8>), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Fungibility { + #[codec(index = 0)] + Fungible(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 1)] + NonFungible(runtime_types::xcm::v2::multiasset::AssetInstance), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiAsset { + pub id: runtime_types::xcm::v2::multiasset::AssetId, + pub fun: runtime_types::xcm::v2::multiasset::Fungibility, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MultiAssetFilter { + #[codec(index = 0)] + Definite(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + Wild(runtime_types::xcm::v2::multiasset::WildMultiAsset), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiAssets( + pub ::std::vec::Vec, + ); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WildFungibility { + #[codec(index = 0)] + Fungible, + #[codec(index = 1)] + NonFungible, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WildMultiAsset { + #[codec(index = 0)] + All, + #[codec(index = 1)] + AllOf { + id: runtime_types::xcm::v2::multiasset::AssetId, + fun: runtime_types::xcm::v2::multiasset::WildFungibility, + }, + } + } + pub mod multilocation { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Junctions { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + X1(runtime_types::xcm::v2::junction::Junction), + #[codec(index = 2)] + X2( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 3)] + X3( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 4)] + X4( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 5)] + X5( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 6)] + X6( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 7)] + X7( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + #[codec(index = 8)] + X8( + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + runtime_types::xcm::v2::junction::Junction, + ), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiLocation { + pub parents: ::core::primitive::u8, + pub interior: runtime_types::xcm::v2::multilocation::Junctions, + } + } + pub mod traits { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Error { + #[codec(index = 0)] + Overflow, + #[codec(index = 1)] + Unimplemented, + #[codec(index = 2)] + UntrustedReserveLocation, + #[codec(index = 3)] + UntrustedTeleportLocation, + #[codec(index = 4)] + MultiLocationFull, + #[codec(index = 5)] + MultiLocationNotInvertible, + #[codec(index = 6)] + BadOrigin, + #[codec(index = 7)] + InvalidLocation, + #[codec(index = 8)] + AssetNotFound, + #[codec(index = 9)] + FailedToTransactAsset, + #[codec(index = 10)] + NotWithdrawable, + #[codec(index = 11)] + LocationCannotHold, + #[codec(index = 12)] + ExceedsMaxMessageSize, + #[codec(index = 13)] + DestinationUnsupported, + #[codec(index = 14)] + Transport, + #[codec(index = 15)] + Unroutable, + #[codec(index = 16)] + UnknownClaim, + #[codec(index = 17)] + FailedToDecode, + #[codec(index = 18)] + MaxWeightInvalid, + #[codec(index = 19)] + NotHoldingFees, + #[codec(index = 20)] + TooExpensive, + #[codec(index = 21)] + Trap(::core::primitive::u64), + #[codec(index = 22)] + UnhandledXcmVersion, + #[codec(index = 23)] + WeightLimitReached(::core::primitive::u64), + #[codec(index = 24)] + Barrier, + #[codec(index = 25)] + WeightNotComputable, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum BodyId { + #[codec(index = 0)] + Unit, + #[codec(index = 1)] + Named( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Index(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + Executive, + #[codec(index = 4)] + Technical, + #[codec(index = 5)] + Legislative, + #[codec(index = 6)] + Judicial, + #[codec(index = 7)] + Defense, + #[codec(index = 8)] + Administration, + #[codec(index = 9)] + Treasury, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum BodyPart { + #[codec(index = 0)] + Voice, + #[codec(index = 1)] + Members { + #[codec(compact)] + count: ::core::primitive::u32, + }, + #[codec(index = 2)] + Fraction { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 3)] + AtLeastProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 4)] + MoreThanProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Instruction { + #[codec(index = 0)] + WithdrawAsset(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::xcm::v2::Response, + #[codec(compact)] + max_weight: ::core::primitive::u64, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_type: runtime_types::xcm::v2::OriginKind, + #[codec(compact)] + require_weight_at_most: ::core::primitive::u64, + call: runtime_types::xcm::double_encoded::DoubleEncoded, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::xcm::v2::multilocation::Junctions), + #[codec(index = 12)] + ReportError { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + receive: runtime_types::xcm::v2::multiasset::MultiAssets, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + reserve: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 18)] + QueryHolding { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::xcm::v2::multiasset::MultiAsset, + weight_limit: runtime_types::xcm::v2::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::xcm::v2::Xcm), + #[codec(index = 22)] + SetAppendix(runtime_types::xcm::v2::Xcm), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + ticket: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 27)] + UnsubscribeVersion, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Instruction2 { + #[codec(index = 0)] + WithdrawAsset(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::xcm::v2::Response, + #[codec(compact)] + max_weight: ::core::primitive::u64, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_type: runtime_types::xcm::v2::OriginKind, + #[codec(compact)] + require_weight_at_most: ::core::primitive::u64, + call: runtime_types::xcm::double_encoded::DoubleEncoded2, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::xcm::v2::multilocation::Junctions), + #[codec(index = 12)] + ReportError { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + receive: runtime_types::xcm::v2::multiasset::MultiAssets, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + reserve: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::xcm::v2::Xcm, + }, + #[codec(index = 18)] + QueryHolding { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::xcm::v2::multilocation::MultiLocation, + assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::xcm::v2::multiasset::MultiAsset, + weight_limit: runtime_types::xcm::v2::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::xcm::v2::Xcm2), + #[codec(index = 22)] + SetAppendix(runtime_types::xcm::v2::Xcm2), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::xcm::v2::multiasset::MultiAssets, + ticket: runtime_types::xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 27)] + UnsubscribeVersion, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum NetworkId { + #[codec(index = 0)] + Any, + #[codec(index = 1)] + Named( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Polkadot, + #[codec(index = 3)] + Kusama, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum OriginKind { + #[codec(index = 0)] + Native, + #[codec(index = 1)] + SovereignAccount, + #[codec(index = 2)] + Superuser, + #[codec(index = 3)] + Xcm, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Response { + #[codec(index = 0)] + Null, + #[codec(index = 1)] + Assets(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ExecutionResult( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v2::traits::Error, + )>, + ), + #[codec(index = 3)] + Version(::core::primitive::u32), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WeightLimit { + #[codec(index = 0)] + Unlimited, + #[codec(index = 1)] + Limited(#[codec(compact)] ::core::primitive::u64), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Xcm(pub ::std::vec::Vec); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Xcm2(pub ::std::vec::Vec); + } + pub mod v3 { + use super::runtime_types; + pub mod junction { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum BodyId { + #[codec(index = 0)] + Unit, + #[codec(index = 1)] + Moniker([::core::primitive::u8; 4usize]), + #[codec(index = 2)] + Index(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + Executive, + #[codec(index = 4)] + Technical, + #[codec(index = 5)] + Legislative, + #[codec(index = 6)] + Judicial, + #[codec(index = 7)] + Defense, + #[codec(index = 8)] + Administration, + #[codec(index = 9)] + Treasury, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum BodyPart { + #[codec(index = 0)] + Voice, + #[codec(index = 1)] + Members { + #[codec(compact)] + count: ::core::primitive::u32, + }, + #[codec(index = 2)] + Fraction { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 3)] + AtLeastProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 4)] + MoreThanProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Junction { + #[codec(index = 0)] + Parachain(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 1)] + AccountId32 { + network: + ::core::option::Option, + id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + AccountIndex64 { + network: + ::core::option::Option, + #[codec(compact)] + index: ::core::primitive::u64, + }, + #[codec(index = 3)] + AccountKey20 { + network: + ::core::option::Option, + key: [::core::primitive::u8; 20usize], + }, + #[codec(index = 4)] + PalletInstance(::core::primitive::u8), + #[codec(index = 5)] + GeneralIndex(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 6)] + GeneralKey { + length: ::core::primitive::u8, + data: [::core::primitive::u8; 32usize], + }, + #[codec(index = 7)] + OnlyChild, + #[codec(index = 8)] + Plurality { + id: runtime_types::xcm::v3::junction::BodyId, + part: runtime_types::xcm::v3::junction::BodyPart, + }, + #[codec(index = 9)] + GlobalConsensus(runtime_types::xcm::v3::junction::NetworkId), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum NetworkId { + #[codec(index = 0)] + ByGenesis([::core::primitive::u8; 32usize]), + #[codec(index = 1)] + ByFork { + block_number: ::core::primitive::u64, + block_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + Polkadot, + #[codec(index = 3)] + Kusama, + #[codec(index = 4)] + Westend, + #[codec(index = 5)] + Rococo, + #[codec(index = 6)] + Wococo, + #[codec(index = 7)] + Ethereum { + #[codec(compact)] + chain_id: ::core::primitive::u64, + }, + #[codec(index = 8)] + BitcoinCore, + #[codec(index = 9)] + BitcoinCash, + #[codec(index = 10)] + PolkadotBulletin, + } + } + pub mod junctions { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Junctions { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + X1(runtime_types::xcm::v3::junction::Junction), + #[codec(index = 2)] + X2( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), + #[codec(index = 3)] + X3( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), + #[codec(index = 4)] + X4( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), + #[codec(index = 5)] + X5( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), + #[codec(index = 6)] + X6( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), + #[codec(index = 7)] + X7( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), + #[codec(index = 8)] + X8( + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + runtime_types::xcm::v3::junction::Junction, + ), + } + } + pub mod multiasset { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AssetId { + #[codec(index = 0)] + Concrete(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + #[codec(index = 1)] + Abstract([::core::primitive::u8; 32usize]), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum AssetInstance { + #[codec(index = 0)] + Undefined, + #[codec(index = 1)] + Index(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 2)] + Array4([::core::primitive::u8; 4usize]), + #[codec(index = 3)] + Array8([::core::primitive::u8; 8usize]), + #[codec(index = 4)] + Array16([::core::primitive::u8; 16usize]), + #[codec(index = 5)] + Array32([::core::primitive::u8; 32usize]), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Fungibility { + #[codec(index = 0)] + Fungible(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 1)] + NonFungible(runtime_types::xcm::v3::multiasset::AssetInstance), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiAsset { + pub id: runtime_types::xcm::v3::multiasset::AssetId, + pub fun: runtime_types::xcm::v3::multiasset::Fungibility, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MultiAssetFilter { + #[codec(index = 0)] + Definite(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 1)] + Wild(runtime_types::xcm::v3::multiasset::WildMultiAsset), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct MultiAssets( + pub ::std::vec::Vec, + ); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WildFungibility { + #[codec(index = 0)] + Fungible, + #[codec(index = 1)] + NonFungible, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WildMultiAsset { + #[codec(index = 0)] + All, + #[codec(index = 1)] + AllOf { + id: runtime_types::xcm::v3::multiasset::AssetId, + fun: runtime_types::xcm::v3::multiasset::WildFungibility, + }, + #[codec(index = 2)] + AllCounted(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + AllOfCounted { + id: runtime_types::xcm::v3::multiasset::AssetId, + fun: runtime_types::xcm::v3::multiasset::WildFungibility, + #[codec(compact)] + count: ::core::primitive::u32, + }, + } + } + pub mod traits { + use super::runtime_types; + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Error { + #[codec(index = 0)] + Overflow, + #[codec(index = 1)] + Unimplemented, + #[codec(index = 2)] + UntrustedReserveLocation, + #[codec(index = 3)] + UntrustedTeleportLocation, + #[codec(index = 4)] + LocationFull, + #[codec(index = 5)] + LocationNotInvertible, + #[codec(index = 6)] + BadOrigin, + #[codec(index = 7)] + InvalidLocation, + #[codec(index = 8)] + AssetNotFound, + #[codec(index = 9)] + FailedToTransactAsset, + #[codec(index = 10)] + NotWithdrawable, + #[codec(index = 11)] + LocationCannotHold, + #[codec(index = 12)] + ExceedsMaxMessageSize, + #[codec(index = 13)] + DestinationUnsupported, + #[codec(index = 14)] + Transport, + #[codec(index = 15)] + Unroutable, + #[codec(index = 16)] + UnknownClaim, + #[codec(index = 17)] + FailedToDecode, + #[codec(index = 18)] + MaxWeightInvalid, + #[codec(index = 19)] + NotHoldingFees, + #[codec(index = 20)] + TooExpensive, + #[codec(index = 21)] + Trap(::core::primitive::u64), + #[codec(index = 22)] + ExpectationFalse, + #[codec(index = 23)] + PalletNotFound, + #[codec(index = 24)] + NameMismatch, + #[codec(index = 25)] + VersionIncompatible, + #[codec(index = 26)] + HoldingWouldOverflow, + #[codec(index = 27)] + ExportError, + #[codec(index = 28)] + ReanchorFailed, + #[codec(index = 29)] + NoDeal, + #[codec(index = 30)] + FeesNotMet, + #[codec(index = 31)] + LockError, + #[codec(index = 32)] + NoPermission, + #[codec(index = 33)] + Unanchored, + #[codec(index = 34)] + NotDepositable, + #[codec(index = 35)] + UnhandledXcmVersion, + #[codec(index = 36)] + WeightLimitReached(runtime_types::sp_weights::weight_v2::Weight), + #[codec(index = 37)] + Barrier, + #[codec(index = 38)] + WeightNotComputable, + #[codec(index = 39)] + ExceedsStackLimit, + } + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Instruction { + #[codec(index = 0)] + WithdrawAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::xcm::v3::Response, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + querier: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_kind: runtime_types::xcm::v2::OriginKind, + require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, + call: runtime_types::xcm::double_encoded::DoubleEncoded, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::xcm::v3::junctions::Junctions), + #[codec(index = 12)] + ReportError(runtime_types::xcm::v3::QueryResponseInfo), + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + want: runtime_types::xcm::v3::multiasset::MultiAssets, + maximal: ::core::primitive::bool, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 18)] + ReportHolding { + response_info: runtime_types::xcm::v3::QueryResponseInfo, + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::xcm::v3::multiasset::MultiAsset, + weight_limit: runtime_types::xcm::v3::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::xcm::v3::Xcm), + #[codec(index = 22)] + SetAppendix(runtime_types::xcm::v3::Xcm), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + max_response_weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 27)] + UnsubscribeVersion, + #[codec(index = 28)] + BurnAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 29)] + ExpectAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 30)] + ExpectOrigin( + ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + ), + #[codec(index = 31)] + ExpectError( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v3::traits::Error, + )>, + ), + #[codec(index = 32)] + ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), + #[codec(index = 33)] + QueryPallet { + module_name: ::std::vec::Vec<::core::primitive::u8>, + response_info: runtime_types::xcm::v3::QueryResponseInfo, + }, + #[codec(index = 34)] + ExpectPallet { + #[codec(compact)] + index: ::core::primitive::u32, + name: ::std::vec::Vec<::core::primitive::u8>, + module_name: ::std::vec::Vec<::core::primitive::u8>, + #[codec(compact)] + crate_major: ::core::primitive::u32, + #[codec(compact)] + min_crate_minor: ::core::primitive::u32, + }, + #[codec(index = 35)] + ReportTransactStatus(runtime_types::xcm::v3::QueryResponseInfo), + #[codec(index = 36)] + ClearTransactStatus, + #[codec(index = 37)] + UniversalOrigin(runtime_types::xcm::v3::junction::Junction), + #[codec(index = 38)] + ExportMessage { + network: runtime_types::xcm::v3::junction::NetworkId, + destination: runtime_types::xcm::v3::junctions::Junctions, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 39)] + LockAsset { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 40)] + UnlockAsset { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 41)] + NoteUnlockable { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 42)] + RequestUnlock { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 43)] + SetFeesMode { jit_withdraw: ::core::primitive::bool }, + #[codec(index = 44)] + SetTopic([::core::primitive::u8; 32usize]), + #[codec(index = 45)] + ClearTopic, + #[codec(index = 46)] + AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + #[codec(index = 47)] + UnpaidExecution { + weight_limit: runtime_types::xcm::v3::WeightLimit, + check_origin: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Instruction2 { + #[codec(index = 0)] + WithdrawAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::xcm::v3::Response, + max_weight: runtime_types::sp_weights::weight_v2::Weight, + querier: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_kind: runtime_types::xcm::v2::OriginKind, + require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, + call: runtime_types::xcm::double_encoded::DoubleEncoded2, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::xcm::v3::junctions::Junctions), + #[codec(index = 12)] + ReportError(runtime_types::xcm::v3::QueryResponseInfo), + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + want: runtime_types::xcm::v3::multiasset::MultiAssets, + maximal: ::core::primitive::bool, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 18)] + ReportHolding { + response_info: runtime_types::xcm::v3::QueryResponseInfo, + assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::xcm::v3::multiasset::MultiAsset, + weight_limit: runtime_types::xcm::v3::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::xcm::v3::Xcm2), + #[codec(index = 22)] + SetAppendix(runtime_types::xcm::v3::Xcm2), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::xcm::v3::multiasset::MultiAssets, + ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + max_response_weight: runtime_types::sp_weights::weight_v2::Weight, + }, + #[codec(index = 27)] + UnsubscribeVersion, + #[codec(index = 28)] + BurnAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 29)] + ExpectAsset(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 30)] + ExpectOrigin( + ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + ), + #[codec(index = 31)] + ExpectError( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v3::traits::Error, + )>, + ), + #[codec(index = 32)] + ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), + #[codec(index = 33)] + QueryPallet { + module_name: ::std::vec::Vec<::core::primitive::u8>, + response_info: runtime_types::xcm::v3::QueryResponseInfo, + }, + #[codec(index = 34)] + ExpectPallet { + #[codec(compact)] + index: ::core::primitive::u32, + name: ::std::vec::Vec<::core::primitive::u8>, + module_name: ::std::vec::Vec<::core::primitive::u8>, + #[codec(compact)] + crate_major: ::core::primitive::u32, + #[codec(compact)] + min_crate_minor: ::core::primitive::u32, + }, + #[codec(index = 35)] + ReportTransactStatus(runtime_types::xcm::v3::QueryResponseInfo), + #[codec(index = 36)] + ClearTransactStatus, + #[codec(index = 37)] + UniversalOrigin(runtime_types::xcm::v3::junction::Junction), + #[codec(index = 38)] + ExportMessage { + network: runtime_types::xcm::v3::junction::NetworkId, + destination: runtime_types::xcm::v3::junctions::Junctions, + xcm: runtime_types::xcm::v3::Xcm, + }, + #[codec(index = 39)] + LockAsset { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 40)] + UnlockAsset { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 41)] + NoteUnlockable { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 42)] + RequestUnlock { + asset: runtime_types::xcm::v3::multiasset::MultiAsset, + locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 43)] + SetFeesMode { jit_withdraw: ::core::primitive::bool }, + #[codec(index = 44)] + SetTopic([::core::primitive::u8; 32usize]), + #[codec(index = 45)] + ClearTopic, + #[codec(index = 46)] + AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + #[codec(index = 47)] + UnpaidExecution { + weight_limit: runtime_types::xcm::v3::WeightLimit, + check_origin: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum MaybeErrorCode { + #[codec(index = 0)] + Success, + #[codec(index = 1)] + Error( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + TruncatedError( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct PalletInfo { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + #[codec(compact)] + pub major: ::core::primitive::u32, + #[codec(compact)] + pub minor: ::core::primitive::u32, + #[codec(compact)] + pub patch: ::core::primitive::u32, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct QueryResponseInfo { + pub destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + #[codec(compact)] + pub query_id: ::core::primitive::u64, + pub max_weight: runtime_types::sp_weights::weight_v2::Weight, + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum Response { + #[codec(index = 0)] + Null, + #[codec(index = 1)] + Assets(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 2)] + ExecutionResult( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::xcm::v3::traits::Error, + )>, + ), + #[codec(index = 3)] + Version(::core::primitive::u32), + #[codec(index = 4)] + PalletsInfo( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::xcm::v3::PalletInfo, + >, + ), + #[codec(index = 5)] + DispatchResult(runtime_types::xcm::v3::MaybeErrorCode), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum WeightLimit { + #[codec(index = 0)] + Unlimited, + #[codec(index = 1)] + Limited(runtime_types::sp_weights::weight_v2::Weight), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Xcm(pub ::std::vec::Vec); + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub struct Xcm2(pub ::std::vec::Vec); + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum VersionedAssetId { + #[codec(index = 3)] + V3(runtime_types::xcm::v3::multiasset::AssetId), + #[codec(index = 4)] + V4(runtime_types::staging_xcm::v4::asset::AssetId), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum VersionedAssets { + #[codec(index = 1)] + V2(runtime_types::xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + V3(runtime_types::xcm::v3::multiasset::MultiAssets), + #[codec(index = 4)] + V4(runtime_types::staging_xcm::v4::asset::Assets), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum VersionedLocation { + #[codec(index = 1)] + V2(runtime_types::xcm::v2::multilocation::MultiLocation), + #[codec(index = 3)] + V3(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + #[codec(index = 4)] + V4(runtime_types::staging_xcm::v4::location::Location), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum VersionedResponse { + #[codec(index = 2)] + V2(runtime_types::xcm::v2::Response), + #[codec(index = 3)] + V3(runtime_types::xcm::v3::Response), + #[codec(index = 4)] + V4(runtime_types::staging_xcm::v4::Response), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum VersionedXcm { + #[codec(index = 2)] + V2(runtime_types::xcm::v2::Xcm), + #[codec(index = 3)] + V3(runtime_types::xcm::v3::Xcm), + #[codec(index = 4)] + V4(runtime_types::staging_xcm::v4::Xcm), + } + #[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + )] + # [codec (crate = :: subxt :: ext :: codec)] + #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] + #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] + pub enum VersionedXcm2 { + #[codec(index = 2)] + V2(runtime_types::xcm::v2::Xcm2), + #[codec(index = 3)] + V3(runtime_types::xcm::v3::Xcm2), + #[codec(index = 4)] + V4(runtime_types::staging_xcm::v4::Xcm2), + } + } + } +} diff --git a/node/Cargo.toml b/node/Cargo.toml index 13560cd..a9024a1 100644 --- a/node/Cargo.toml +++ b/node/Cargo.toml @@ -33,6 +33,7 @@ magnet-primitives-order = { path = "../primitives/order"} magnet-client-consensus-aura = {path ="../client/consensus/aura"} pallet-pot-rpc = { path = "../pallets/pot/rpc" } mp-system = { path = "../primitives/system"} +magnet-client-coretime-bulk = {path ="../client/coretime/bulk"} # Substrate frame-benchmarking = { workspace = true } diff --git a/node/src/service.rs b/node/src/service.rs index 41340a7..ed725d0 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -24,6 +24,7 @@ use cumulus_relay_chain_interface::{OverseerHandle, RelayChainInterface}; // Substrate Imports use frame_benchmarking_cli::SUBSTRATE_REFERENCE_HARDWARE; +use magnet_client_coretime_bulk::spawn_bulk_task; use sc_client_api::Backend; use sc_consensus::ImportQueue; use sc_executor::{ @@ -478,6 +479,7 @@ async fn start_node_impl( order_record.clone(), rpc_address, )?; + spawn_bulk_task(client.clone(), para_id, relay_chain_interface.clone(), &task_manager)?; start_consensus( client.clone(), block_import, From 0b07e013b0cb5233cee8ca771e675331036f5784 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Tue, 18 Jun 2024 22:21:16 +0800 Subject: [PATCH 03/44] Add get purchase event --- client/coretime/bulk/src/lib.rs | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 7de61d0..44f8682 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -43,21 +43,19 @@ where let parachain = parachain.clone(); async move { - let api = OnlineClient::::from_url("127.0.0.1:8855").await.unwrap(); + let api = + OnlineClient::::from_url("ws://127.0.0.1:8855").await.unwrap(); loop { let events = api.events().at_latest().await.unwrap(); - // We can dynamically decode events: - println!("Dynamic event details:"); - for event in events.iter() { - let event = event.unwrap(); - - let pallet = event.pallet_name(); - let variant = event.variant_name(); - let field_values = event.field_values().unwrap(); - - println!("{pallet}::{variant}: {field_values}"); + let purchase_event = + events.find_first::().unwrap(); + if let Some(ev) = purchase_event { + println!( + "Purchased success: value: {:?},{:?},{:?},{:?}", + ev.who, ev.region_id, ev.price, ev.duration + ); } } } From 99884e04d03fb0bdf299e4abf2e55f4a4949a118 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Thu, 20 Jun 2024 23:01:15 +0800 Subject: [PATCH 04/44] add read proof from coretime parachain --- Cargo.lock | 16 +++ Cargo.toml | 4 +- client/coretime/bulk/Cargo.toml | 6 + client/coretime/bulk/src/lib.rs | 25 +++- primitives/chain-state-snapshot/Cargo.toml | 24 ++++ primitives/chain-state-snapshot/src/lib.rs | 141 +++++++++++++++++++++ primitives/order/Cargo.toml | 3 + primitives/order/src/well_known_keys.rs | 14 +- 8 files changed, 228 insertions(+), 5 deletions(-) create mode 100644 primitives/chain-state-snapshot/Cargo.toml create mode 100644 primitives/chain-state-snapshot/src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index a2a128e..2f04642 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2885,6 +2885,17 @@ version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "75b325c5dbd37f80359721ad39aca5a29fb04c89279657cffdda8736d0c0b9d2" +[[package]] +name = "dp-chain-state-snapshot" +version = "0.1.0" +dependencies = [ + "cumulus-primitives-core", + "parity-scale-codec", + "sp-runtime 31.0.1", + "sp-state-machine 0.35.0", + "sp-trie 29.0.0", +] + [[package]] name = "dtoa" version = "1.0.9" @@ -6008,8 +6019,11 @@ dependencies = [ "cumulus-primitives-core", "cumulus-primitives-parachain-inherent", "cumulus-relay-chain-interface", + "dp-chain-state-snapshot", "futures", "log", + "magnet-primitives-order", + "pallet-broker", "parity-scale-codec", "polkadot-node-primitives", "polkadot-node-subsystem", @@ -6034,6 +6048,7 @@ dependencies = [ "sp-keystore 0.34.0", "sp-runtime 31.0.1", "sp-state-machine 0.35.0", + "sp-storage 19.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", "sp-timestamp", "substrate-prometheus-endpoint", "subxt", @@ -6049,6 +6064,7 @@ dependencies = [ "cumulus-relay-chain-interface", "hex-literal", "log", + "pallet-broker", "parity-scale-codec", "scale-info", "sp-api", diff --git a/Cargo.toml b/Cargo.toml index 1dcf507..3914fc6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -111,8 +111,8 @@ sp-transaction-pool = { git = "https://github.com/paritytech/polkadot-sdk", bran sp-trie = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } sp-version = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } sp-weights = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } - - +pallet-broker = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } +sp-storage = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } # Substrate FRAME frame-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } diff --git a/client/coretime/bulk/Cargo.toml b/client/coretime/bulk/Cargo.toml index bc5a7c1..b46df04 100644 --- a/client/coretime/bulk/Cargo.toml +++ b/client/coretime/bulk/Cargo.toml @@ -17,6 +17,10 @@ schnellru = { workspace = true } log = { workspace = true } subxt = { workspace = true, features = ["substrate-compat"]} +# Local +dp-chain-state-snapshot = { path = "../../../primitives/chain-state-snapshot"} +magnet-primitives-order = { path = "../../../primitives/order"} + # Substrate sc-client-api = { workspace = true } sc-consensus = { workspace = true } @@ -38,6 +42,8 @@ sp-timestamp = { workspace = true } sp-state-machine = { workspace = true } substrate-prometheus-endpoint = { workspace = true } sc-service = { workspace = true } +pallet-broker = { workspace = true} +sp-storage = { workspace = true } # Cumulus cumulus-client-consensus-common = { workspace = true } diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 44f8682..289cdfe 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -22,9 +22,15 @@ use sp_api::ProvideRuntimeApi; use std::error::Error; use std::sync::Arc; mod metadata; +use magnet_primitives_order::{self, well_known_keys::broker_regions}; +use pallet_broker::{CoreMask, RegionId}; +use sp_storage::StorageKey; use subxt::client::OfflineClientT; use subxt::{ - config::polkadot::PolkadotExtrinsicParamsBuilder as Params, tx::Signer, utils::MultiSignature, + backend::{legacy::LegacyRpcMethods, rpc::RpcClient}, + config::polkadot::PolkadotExtrinsicParamsBuilder as Params, + tx::Signer, + utils::MultiSignature, Config, OnlineClient, PolkadotConfig, }; @@ -43,8 +49,9 @@ where let parachain = parachain.clone(); async move { + let rpc_client = RpcClient::from_url("ws://127.0.0.1:9944").await.unwrap(); let api = - OnlineClient::::from_url("ws://127.0.0.1:8855").await.unwrap(); + OnlineClient::::from_url("ws://127.0.0.1:9944").await.unwrap(); loop { let events = api.events().at_latest().await.unwrap(); @@ -56,6 +63,20 @@ where "Purchased success: value: {:?},{:?},{:?},{:?}", ev.who, ev.region_id, ev.price, ev.duration ); + let rpc = LegacyRpcMethods::::new(rpc_client.clone()); + // let xxx = ev.region_id.mask.0.into(); + // let coreMask = CoreMask::from(xxx); + // let region_id =RegionId{ + // begin:ev.region_id.begin, + // core:ev.region_id.core, + // mask:coreMask, + // }; + // let key = broker_regions(region_id); + // let mut relevant_keys = Vec::new(); + // relevant_keys.push(key.as_slice()); + // // let storage_keys: Vec = relevant_keys.into_iter().map(StorageKey).collect(); + // let proof = rpc.state_get_read_proof(relevant_keys, Some(events.block_hash())).await; + // println!("{:?}", proof); } } } diff --git a/primitives/chain-state-snapshot/Cargo.toml b/primitives/chain-state-snapshot/Cargo.toml new file mode 100644 index 0000000..eb20666 --- /dev/null +++ b/primitives/chain-state-snapshot/Cargo.toml @@ -0,0 +1,24 @@ +[package] +name = "dp-chain-state-snapshot" +authors = { workspace = true } +description = "Primitives related to chain state snapshot" +edition = "2021" +license = "GPL-3.0-only" +version = "0.1.0" + +[package.metadata.docs.rs] +targets = [ "x86_64-unknown-linux-gnu" ] +[dependencies] + +# Substrate +parity-scale-codec = { workspace = true } +sp-runtime = { workspace = true } +sp-state-machine = { workspace = true } +sp-trie = { workspace = true } + +# Cumulus +cumulus-primitives-core = { workspace = true } + +[features] +default = [ "std" ] +std = [ "cumulus-primitives-core/std", "parity-scale-codec/std", "sp-runtime/std", "sp-state-machine/std", "sp-trie/std" ] diff --git a/primitives/chain-state-snapshot/src/lib.rs b/primitives/chain-state-snapshot/src/lib.rs new file mode 100644 index 0000000..30ce68a --- /dev/null +++ b/primitives/chain-state-snapshot/src/lib.rs @@ -0,0 +1,141 @@ +// Copyright (C) Moondance Labs Ltd. +// This file is part of Tanssi. + +// Tanssi is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Tanssi is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Tanssi. If not, see + +//! # Chain Snapshot Primitives +//! +//! This crate defines those primitives to retrieve keys from a defined Backend + +#![cfg_attr(not(feature = "std"), no_std)] + +use { + parity_scale_codec::Decode, + sp_runtime::traits::HashingFor, + sp_state_machine::{Backend, TrieBackend, TrieBackendBuilder}, + sp_trie::{HashDBT, MemoryDB, StorageProof, EMPTY_PREFIX}, +}; + +#[derive(Debug)] +pub enum ReadEntryErr { + /// The value cannot be extracted from the proof. + Proof, + /// The value cannot be decoded. + Decode, + /// The value is expected to be present on the relay chain, but it doesn't exist. + Absent, + /// The proof provided does not match the root provided + RootMismatch, +} + +/// Read an entry given by the key and try to decode it. If the value specified by the key according +/// to the proof is empty, the `fallback` value will be returned. +/// +/// Returns `Err` in case the backend can't return the value under the specific key (likely due to +/// a malformed proof), in case the decoding fails, or in case where the value is empty in the relay +/// chain state and no fallback was provided. +fn read_entry(backend: &B, key: &[u8], fallback: Option) -> Result +where + T: Decode, + B: Backend>, + Block: sp_runtime::traits::Block, +{ + backend + .storage(key) + .map_err(|_| ReadEntryErr::Proof)? + .map(|raw_entry| T::decode(&mut &raw_entry[..]).map_err(|_| ReadEntryErr::Decode)) + .transpose()? + .or(fallback) + .ok_or(ReadEntryErr::Absent) +} + +/// Read an optional entry given by the key and try to decode it. +/// Returns `None` if the value specified by the key according to the proof is empty. +/// +/// Returns `Err` in case the backend can't return the value under the specific key (likely due to +/// a malformed proof) or if the value couldn't be decoded. +fn read_optional_entry(backend: &B, key: &[u8]) -> Result, ReadEntryErr> +where + T: Decode, + B: Backend>, + Block: sp_runtime::traits::Block, +{ + match read_entry::(backend, key, None) { + Ok(v) => Ok(Some(v)), + Err(ReadEntryErr::Absent) => Ok(None), + Err(err) => Err(err), + } +} + +/// A state proof extracted from the relay chain. +/// +/// This state proof is extracted from the relay chain block we are building on top of. +pub struct GenericStateProof { + trie_backend: TrieBackend>, HashingFor>, +} + +impl GenericStateProof { + /// Create a new instance of `Self`. + /// + /// Returns an error if the given `relay_parent_storage_root` is not the root of the given + /// `proof`. + pub fn new( + relay_parent_storage_root: Block::Hash, + proof: StorageProof, + ) -> Result { + // Retrieve whether the proof is empty + let proof_empty = proof.is_empty(); + + let db = proof.into_memory_db::>(); + // If the proof is empty we should not compare against any root, but rather, expect that the pallet + // will dot he job when looking for certain keys + if !db.contains(&relay_parent_storage_root, EMPTY_PREFIX) && !proof_empty { + return Err(ReadEntryErr::RootMismatch); + } + let trie_backend = TrieBackendBuilder::new(db, relay_parent_storage_root).build(); + + Ok(Self { trie_backend }) + } + + /// Read an entry given by the key and try to decode it. If the value specified by the key according + /// to the proof is empty, the `fallback` value will be returned. + /// + /// Returns `Err` in case the backend can't return the value under the specific key (likely due to + /// a malformed proof), in case the decoding fails, or in case where the value is empty in the relay + /// chain state and no fallback was provided. + pub fn read_entry(&self, key: &[u8], fallback: Option) -> Result + where + T: Decode, + { + read_entry::>, HashingFor>, Block>( + &self.trie_backend, + key, + fallback, + ) + } + + /// Read an optional entry given by the key and try to decode it. + /// + /// Returns `Err` in case the backend can't return the value under the specific key (likely due to + /// a malformed proof) or if the value couldn't be decoded. + pub fn read_optional_entry(&self, key: &[u8]) -> Result, ReadEntryErr> + where + T: Decode, + { + read_optional_entry::>, HashingFor>, Block>( + &self.trie_backend, + key, + ) + } +} diff --git a/primitives/order/Cargo.toml b/primitives/order/Cargo.toml index 2a9c3f4..bf0256d 100644 --- a/primitives/order/Cargo.toml +++ b/primitives/order/Cargo.toml @@ -28,6 +28,8 @@ sp-std = { workspace = true, default-features = false } sp-weights = { workspace = true, default-features = false } sp-session = { workspace = true, default-features = false } sp-consensus-grandpa = { workspace = true, default-features = false } +pallet-broker = { workspace = true, default-features = false } + [features] default = [ "std" ] @@ -49,4 +51,5 @@ std = [ "sp-weights/std", "sp-session/std", "sp-consensus-grandpa/std", + "pallet-broker/std", ] \ No newline at end of file diff --git a/primitives/order/src/well_known_keys.rs b/primitives/order/src/well_known_keys.rs index d591e3b..2429eee 100644 --- a/primitives/order/src/well_known_keys.rs +++ b/primitives/order/src/well_known_keys.rs @@ -20,8 +20,9 @@ use cumulus_primitives_core::relay_chain::CoreIndex; use { cumulus_primitives_core::ParaId, + pallet_broker::RegionId, sp_core::Encode, - sp_io::hashing::{twox_256, twox_64}, + sp_io::hashing::{blake2_128, twox_256, twox_64}, sp_std::vec::Vec, }; @@ -72,3 +73,14 @@ pub fn paras_core_descriptors(core_index: CoreIndex) -> Vec { CORE_DESCRIPTORS.iter().chain(twox_256(core_index).iter()).cloned().collect() }) } + +// XXHash a String:Broker Regions +pub const REGIONS: &[u8] = + &hex_literal::hex!["4dcb50595177a3177648411a42aca0f53dc63b0b76ffd6f80704a090da6f8719"]; + +/// assigner coretime storage CoreDescriptors +pub fn broker_regions(region_id: RegionId) -> Vec { + region_id.using_encoded(|core_index: &[u8]| { + REGIONS.iter().chain(blake2_128(core_index).iter()).cloned().collect() + }) +} From 2cc47ac9a9d431f86cb21d52fecc22c7f133551b Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Fri, 21 Jun 2024 23:07:12 +0800 Subject: [PATCH 05/44] read proof of purchase then verify success --- client/coretime/bulk/src/lib.rs | 98 +++++++++++++++++++------ primitives/order/src/well_known_keys.rs | 7 +- 2 files changed, 80 insertions(+), 25 deletions(-) diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 289cdfe..87954e1 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -16,14 +16,21 @@ use cumulus_primitives_core::BlockT; use cumulus_primitives_core::ParaId; use cumulus_relay_chain_interface::RelayChainInterface; +use polkadot_primitives::AccountId; +use polkadot_primitives::Balance; use sc_client_api::UsageProvider; use sc_service::TaskManager; use sp_api::ProvideRuntimeApi; use std::error::Error; use std::sync::Arc; mod metadata; +use dp_chain_state_snapshot::GenericStateProof; +use magnet_primitives_order::well_known_keys::REGIONS; use magnet_primitives_order::{self, well_known_keys::broker_regions}; +use metadata::api::{runtime_types, runtime_types::coretime_rococo_runtime as polakdot_runtime}; +use pallet_broker::RegionRecord; use pallet_broker::{CoreMask, RegionId}; +use sp_state_machine::StorageProof; use sp_storage::StorageKey; use subxt::client::OfflineClientT; use subxt::{ @@ -34,6 +41,14 @@ use subxt::{ Config, OnlineClient, PolkadotConfig, }; +fn u8_array_to_u128(array: [u8; 10]) -> u128 { + let mut result: u128 = 0; + for &byte in &array { + result = (result << 8) | byte as u128; + } + result +} + pub fn spawn_bulk_task( parachain: Arc, para_id: ParaId, @@ -49,34 +64,69 @@ where let parachain = parachain.clone(); async move { - let rpc_client = RpcClient::from_url("ws://127.0.0.1:9944").await.unwrap(); + let rpc_client = RpcClient::from_url("ws://127.0.0.1:8855").await.unwrap(); let api = - OnlineClient::::from_url("ws://127.0.0.1:9944").await.unwrap(); + OnlineClient::::from_url("ws://127.0.0.1:8855").await.unwrap(); loop { - let events = api.events().at_latest().await.unwrap(); + let mut blocks_sub = api.blocks().subscribe_finalized().await.unwrap(); + + // For each block, print a bunch of information about it: + while let Some(block) = blocks_sub.next().await { + let block = block.unwrap(); + + let block_number = block.header().number; + let block_hash = block.hash(); - let purchase_event = - events.find_first::().unwrap(); - if let Some(ev) = purchase_event { - println!( - "Purchased success: value: {:?},{:?},{:?},{:?}", - ev.who, ev.region_id, ev.price, ev.duration - ); - let rpc = LegacyRpcMethods::::new(rpc_client.clone()); - // let xxx = ev.region_id.mask.0.into(); - // let coreMask = CoreMask::from(xxx); - // let region_id =RegionId{ - // begin:ev.region_id.begin, - // core:ev.region_id.core, - // mask:coreMask, - // }; - // let key = broker_regions(region_id); - // let mut relevant_keys = Vec::new(); - // relevant_keys.push(key.as_slice()); - // // let storage_keys: Vec = relevant_keys.into_iter().map(StorageKey).collect(); - // let proof = rpc.state_get_read_proof(relevant_keys, Some(events.block_hash())).await; - // println!("{:?}", proof); + println!("Block #{block_number}:"); + println!(" Hash: {block_hash}"); + println!(" Extrinsics:"); + let extrinsics = block.extrinsics().await.unwrap(); + for ext in extrinsics.iter() { + let ext = ext.unwrap(); + let events = ext.events().await.unwrap(); + let purchase_event = events + .find_first::() + .unwrap(); + if let Some(ev) = purchase_event { + println!( + "Purchased success: value: {:?},{:?},{:?},{:?}", + ev.who, ev.region_id, ev.price, ev.duration + ); + let rpc = LegacyRpcMethods::::new(rpc_client.clone()); + let mask = u8_array_to_u128(ev.region_id.mask.0); + let core_mask = CoreMask::from(mask); + let region_id = RegionId { + begin: ev.region_id.begin, + core: ev.region_id.core, + mask: core_mask, + }; + println!("region_id:{:?}", region_id); + let key = broker_regions(region_id); + println!("key:{:?}", key); + let mut relevant_keys = Vec::new(); + relevant_keys.push(key.as_slice()); + let proof = rpc + .state_get_read_proof(relevant_keys, Some(events.block_hash())) + .await + .unwrap(); + let storage_proof = StorageProof::new( + proof.proof.into_iter().map(|bytes| bytes.to_vec()), + ); + println!("{:?}", storage_proof); + let storage_root = block.header().state_root; + let relay_storage_rooted_proof: GenericStateProof< + cumulus_primitives_core::relay_chain::Block, + > = GenericStateProof::new(storage_root, storage_proof).unwrap(); + let head_data = relay_storage_rooted_proof + .read_entry::>( + key.as_slice(), + None, + ) + .ok(); + println!("head_data:{:?}", head_data); + } + } } } } diff --git a/primitives/order/src/well_known_keys.rs b/primitives/order/src/well_known_keys.rs index 2429eee..a1a4424 100644 --- a/primitives/order/src/well_known_keys.rs +++ b/primitives/order/src/well_known_keys.rs @@ -81,6 +81,11 @@ pub const REGIONS: &[u8] = /// assigner coretime storage CoreDescriptors pub fn broker_regions(region_id: RegionId) -> Vec { region_id.using_encoded(|core_index: &[u8]| { - REGIONS.iter().chain(blake2_128(core_index).iter()).cloned().collect() + REGIONS + .iter() + .chain(blake2_128(core_index).iter()) + .chain(core_index.iter()) + .cloned() + .collect() }) } From a887360742a29abfdbafb21099478af59d550a07 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sun, 23 Jun 2024 21:18:19 +0800 Subject: [PATCH 06/44] 1.complete bulk mode basic code 2. reconstruct code --- Cargo.lock | 259 +- Cargo.toml | 3 +- client/coretime/bulk/Cargo.toml | 7 +- client/coretime/bulk/src/lib.rs | 201 +- .../aura => coretime/common}/Cargo.toml | 14 +- client/coretime/common/src/lib.rs | 64 + node/Cargo.toml | 8 +- node/src/chain_spec.rs | 8 +- node/src/main.rs | 4 +- node/src/on_demand_order.rs | 662 -- node/src/service.rs | 128 +- node/src/submit_order.rs | 143 - pallets/{order => bulk}/Cargo.toml | 12 +- pallets/{order => bulk}/README.md | 0 pallets/bulk/src/benchmarking.rs | 40 + pallets/bulk/src/lib.rs | 205 + pallets/bulk/src/mock.rs | 183 + pallets/bulk/src/proof_data.rs | 29 + pallets/bulk/src/tests.rs | 82 + pallets/{order => bulk}/src/weights.rs | 0 pallets/liquidation/Cargo.toml | 4 +- pallets/liquidation/src/lib.rs | 25 +- pallets/order/src/benchmarking.rs | 40 - pallets/order/src/lib.rs | 489 -- pallets/order/src/mock.rs | 183 - pallets/order/src/proof_data.rs | 29 - pallets/order/src/tests.rs | 82 - .../{order => coretime/bulk}/Cargo.toml | 4 +- .../coretime/bulk/src/inherent_client.rs | 89 + primitives/coretime/bulk/src/lib.rs | 65 + .../coretime/bulk/src/well_known_keys.rs | 43 + primitives/coretime/common/Cargo.toml | 53 + primitives/coretime/common/src/lib.rs | 30 + .../coretime/common/src/well_known_keys.rs | 50 +- primitives/order/src/inherent_client.rs | 89 - primitives/order/src/lib.rs | 111 - primitives/order/src/metadata.rs | 5350 ----------------- primitives/order/src/well_known_keys.rs | 91 - runtime/Cargo.toml | 11 +- runtime/src/lib.rs | 158 +- 40 files changed, 1408 insertions(+), 7640 deletions(-) rename client/{consensus/aura => coretime/common}/Cargo.toml (82%) create mode 100644 client/coretime/common/src/lib.rs delete mode 100644 node/src/on_demand_order.rs delete mode 100644 node/src/submit_order.rs rename pallets/{order => bulk}/Cargo.toml (87%) rename pallets/{order => bulk}/README.md (100%) create mode 100644 pallets/bulk/src/benchmarking.rs create mode 100644 pallets/bulk/src/lib.rs create mode 100644 pallets/bulk/src/mock.rs create mode 100644 pallets/bulk/src/proof_data.rs create mode 100644 pallets/bulk/src/tests.rs rename pallets/{order => bulk}/src/weights.rs (100%) delete mode 100644 pallets/order/src/benchmarking.rs delete mode 100644 pallets/order/src/lib.rs delete mode 100644 pallets/order/src/mock.rs delete mode 100644 pallets/order/src/proof_data.rs delete mode 100644 pallets/order/src/tests.rs rename primitives/{order => coretime/bulk}/Cargo.toml (94%) create mode 100644 primitives/coretime/bulk/src/inherent_client.rs create mode 100644 primitives/coretime/bulk/src/lib.rs create mode 100644 primitives/coretime/bulk/src/well_known_keys.rs create mode 100644 primitives/coretime/common/Cargo.toml create mode 100644 primitives/coretime/common/src/lib.rs rename client/consensus/aura/src/lib.rs => primitives/coretime/common/src/well_known_keys.rs (51%) delete mode 100644 primitives/order/src/inherent_client.rs delete mode 100644 primitives/order/src/lib.rs delete mode 100644 primitives/order/src/metadata.rs delete mode 100644 primitives/order/src/well_known_keys.rs diff --git a/Cargo.lock b/Cargo.lock index 2f04642..9e123f2 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -5961,7 +5961,53 @@ dependencies = [ ] [[package]] -name = "magnet-client-consensus-aura" +name = "maplit" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3e2e65a1a2e43cfcb47a895c4c8b10d1f4a61097f9f254f183aee60cad9c651d" + +[[package]] +name = "match_cfg" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ffbee8634e0d45d258acb448e7eaab3fce7a0a467395d4d9f228e3c1f01fb2e4" + +[[package]] +name = "matchers" +version = "0.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f099785f7595cc4b4553a174ce30dd7589ef93391ff414dbb67f62392b9e0ce1" +dependencies = [ + "regex-automata 0.1.10", +] + +[[package]] +name = "matchers" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" +dependencies = [ + "regex-automata 0.1.10", +] + +[[package]] +name = "matches" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" + +[[package]] +name = "matrixmultiply" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7574c1cf36da4798ab73da5b215bbf444f50718207754cb522201d78d1cd0ff2" +dependencies = [ + "autocfg", + "rawpointer", +] + +[[package]] +name = "mc-coretime-bulk" version = "0.1.0" dependencies = [ "async-trait", @@ -5974,9 +6020,12 @@ dependencies = [ "cumulus-primitives-core", "cumulus-primitives-parachain-inherent", "cumulus-relay-chain-interface", + "dp-chain-state-snapshot", "futures", "log", - "magnet-primitives-order", + "mc-coretime-common", + "mp-coretime-bulk", + "pallet-broker", "parity-scale-codec", "polkadot-node-primitives", "polkadot-node-subsystem", @@ -5987,6 +6036,7 @@ dependencies = [ "sc-consensus-aura", "sc-consensus-babe", "sc-consensus-slots", + "sc-service", "sc-telemetry", "schnellru", "sp-api", @@ -6000,13 +6050,15 @@ dependencies = [ "sp-keystore 0.34.0", "sp-runtime 31.0.1", "sp-state-machine 0.35.0", + "sp-storage 19.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", "sp-timestamp", "substrate-prometheus-endpoint", + "subxt", "tracing", ] [[package]] -name = "magnet-client-coretime-bulk" +name = "mc-coretime-common" version = "0.1.0" dependencies = [ "async-trait", @@ -6019,16 +6071,16 @@ dependencies = [ "cumulus-primitives-core", "cumulus-primitives-parachain-inherent", "cumulus-relay-chain-interface", - "dp-chain-state-snapshot", "futures", "log", - "magnet-primitives-order", + "mp-coretime-common", "pallet-broker", "parity-scale-codec", "polkadot-node-primitives", "polkadot-node-subsystem", "polkadot-overseer", "polkadot-primitives", + "polkadot-runtime-parachains", "sc-client-api", "sc-consensus", "sc-consensus-aura", @@ -6055,78 +6107,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "magnet-primitives-order" -version = "0.2.0" -dependencies = [ - "async-trait", - "cumulus-primitives-core", - "cumulus-relay-chain-interface", - "hex-literal", - "log", - "pallet-broker", - "parity-scale-codec", - "scale-info", - "sp-api", - "sp-consensus-aura", - "sp-consensus-grandpa", - "sp-core 28.0.0", - "sp-inherents", - "sp-io 30.0.0", - "sp-runtime 31.0.1", - "sp-session", - "sp-state-machine 0.35.0", - "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", - "sp-trie 29.0.0", - "sp-weights 27.0.0", -] - -[[package]] -name = "maplit" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e2e65a1a2e43cfcb47a895c4c8b10d1f4a61097f9f254f183aee60cad9c651d" - -[[package]] -name = "match_cfg" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffbee8634e0d45d258acb448e7eaab3fce7a0a467395d4d9f228e3c1f01fb2e4" - -[[package]] -name = "matchers" -version = "0.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f099785f7595cc4b4553a174ce30dd7589ef93391ff414dbb67f62392b9e0ce1" -dependencies = [ - "regex-automata 0.1.10", -] - -[[package]] -name = "matchers" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" -dependencies = [ - "regex-automata 0.1.10", -] - -[[package]] -name = "matches" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" - -[[package]] -name = "matrixmultiply" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7574c1cf36da4798ab73da5b215bbf444f50718207754cb522201d78d1cd0ff2" -dependencies = [ - "autocfg", - "rawpointer", -] - [[package]] name = "memchr" version = "2.7.2" @@ -6325,6 +6305,57 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "mp-coretime-bulk" +version = "0.2.0" +dependencies = [ + "async-trait", + "cumulus-primitives-core", + "cumulus-relay-chain-interface", + "hex-literal", + "log", + "pallet-broker", + "parity-scale-codec", + "scale-info", + "sp-api", + "sp-consensus-aura", + "sp-consensus-grandpa", + "sp-core 28.0.0", + "sp-inherents", + "sp-io 30.0.0", + "sp-runtime 31.0.1", + "sp-session", + "sp-state-machine 0.35.0", + "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", + "sp-trie 29.0.0", + "sp-weights 27.0.0", +] + +[[package]] +name = "mp-coretime-common" +version = "0.2.0" +dependencies = [ + "async-trait", + "cumulus-primitives-core", + "cumulus-relay-chain-interface", + "hex-literal", + "log", + "parity-scale-codec", + "scale-info", + "sp-api", + "sp-consensus-aura", + "sp-consensus-grandpa", + "sp-core 28.0.0", + "sp-inherents", + "sp-io 30.0.0", + "sp-runtime 31.0.1", + "sp-session", + "sp-state-machine 0.35.0", + "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", + "sp-trie 29.0.0", + "sp-weights 27.0.0", +] + [[package]] name = "mp-system" version = "0.1.0" @@ -7263,6 +7294,39 @@ dependencies = [ "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", ] +[[package]] +name = "pallet-bulk" +version = "0.2.0" +dependencies = [ + "cumulus-pallet-parachain-system", + "cumulus-primitives-core", + "dp-chain-state-snapshot", + "frame-benchmarking", + "frame-support", + "frame-system", + "hex", + "hex-literal", + "log", + "mp-coretime-bulk", + "pallet-balances", + "pallet-broker", + "pallet-collective", + "pallet-society", + "pallet-xcm", + "parachains-common", + "parity-scale-codec", + "polkadot-primitives", + "polkadot-runtime-parachains", + "scale-info", + "serde", + "sp-consensus-aura", + "sp-core 28.0.0", + "sp-io 30.0.0", + "sp-runtime 31.0.1", + "sp-trie 29.0.0", + "staging-xcm-builder", +] + [[package]] name = "pallet-child-bounties" version = "27.0.0" @@ -7726,7 +7790,6 @@ dependencies = [ "mp-system", "pallet-assets", "pallet-balances", - "pallet-order", "pallet-pot", "pallet-transaction-payment", "pallet-utility", @@ -7922,37 +7985,6 @@ dependencies = [ "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", ] -[[package]] -name = "pallet-order" -version = "0.2.0" -dependencies = [ - "cumulus-pallet-parachain-system", - "cumulus-primitives-core", - "frame-benchmarking", - "frame-support", - "frame-system", - "hex", - "hex-literal", - "log", - "magnet-primitives-order", - "pallet-balances", - "pallet-collective", - "pallet-society", - "pallet-xcm", - "parachains-common", - "parity-scale-codec", - "polkadot-primitives", - "polkadot-runtime-parachains", - "scale-info", - "serde", - "sp-consensus-aura", - "sp-core 28.0.0", - "sp-io 30.0.0", - "sp-runtime 31.0.1", - "sp-trie 29.0.0", - "staging-xcm-builder", -] - [[package]] name = "pallet-pot" version = "0.1.0" @@ -8521,9 +8553,8 @@ dependencies = [ "hex-literal", "jsonrpsee", "log", - "magnet-client-consensus-aura", - "magnet-client-coretime-bulk", - "magnet-primitives-order", + "mc-coretime-bulk", + "mp-coretime-bulk", "mp-system", "pallet-balances", "pallet-pot-rpc", @@ -8574,6 +8605,7 @@ dependencies = [ "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", "sp-timestamp", "sp-transaction-pool", + "sp-trie 29.0.0", "staging-xcm", "substrate-build-script-utils", "substrate-frame-rpc-system", @@ -8610,7 +8642,6 @@ dependencies = [ "frame-try-runtime", "hex-literal", "log", - "magnet-primitives-order", "mp-system", "pallet-assets", "pallet-assets-bridge", @@ -8619,6 +8650,7 @@ dependencies = [ "pallet-authorship", "pallet-balances", "pallet-base-fee", + "pallet-bulk", "pallet-collator-selection", "pallet-collective", "pallet-contracts", @@ -8635,7 +8667,6 @@ dependencies = [ "pallet-insecure-randomness-collective-flip", "pallet-liquidation", "pallet-message-queue", - "pallet-order", "pallet-pot", "pallet-pot-runtime-api", "pallet-precompile-substrate-utils", diff --git a/Cargo.toml b/Cargo.toml index 3914fc6..c3c54cb 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,7 +17,8 @@ overflow-checks = true members = [ "node", "runtime", - "pallets/order", +# "pallets/order", + "pallets/bulk", "primitives/system", "pallets/evm-utils", "pallets/evm/precompile/substrate-utils", diff --git a/client/coretime/bulk/Cargo.toml b/client/coretime/bulk/Cargo.toml index b46df04..0691b3e 100644 --- a/client/coretime/bulk/Cargo.toml +++ b/client/coretime/bulk/Cargo.toml @@ -1,7 +1,7 @@ [package] -name = "magnet-client-coretime-bulk" +name = "mc-coretime-bulk" authors = ["Anonymous"] -description = "magnet-coretime" +description = "client of magnet coretime bulk mode" license = "Apache License 2.0" homepage = "https://magnet.magport.io/" repository.workspace = true @@ -19,7 +19,8 @@ subxt = { workspace = true, features = ["substrate-compat"]} # Local dp-chain-state-snapshot = { path = "../../../primitives/chain-state-snapshot"} -magnet-primitives-order = { path = "../../../primitives/order"} +mp-coretime-bulk = { path = "../../../primitives/coretime/bulk"} +mc-coretime-common = { path = "../common"} # Substrate sc-client-api = { workspace = true } diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 87954e1..fd5deb8 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -21,17 +21,29 @@ use polkadot_primitives::Balance; use sc_client_api::UsageProvider; use sc_service::TaskManager; use sp_api::ProvideRuntimeApi; +use sp_core::ByteArray; use std::error::Error; use std::sync::Arc; mod metadata; +use codec::{Codec, Decode}; use dp_chain_state_snapshot::GenericStateProof; -use magnet_primitives_order::well_known_keys::REGIONS; -use magnet_primitives_order::{self, well_known_keys::broker_regions}; +use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; +use mc_coretime_common::is_parathread; use metadata::api::{runtime_types, runtime_types::coretime_rococo_runtime as polakdot_runtime}; +use mp_coretime_bulk::well_known_keys::REGIONS; +use mp_coretime_bulk::BulkMemRecord; +use mp_coretime_bulk::{self, well_known_keys::broker_regions}; use pallet_broker::RegionRecord; use pallet_broker::{CoreMask, RegionId}; +use sp_application_crypto::AppPublic; +use sp_core::{crypto::Pair, H256}; +use sp_runtime::{ + codec::Encode, + traits::{AtLeast32BitUnsigned, Header as HeaderT, MaybeDisplay, Member}, +}; use sp_state_machine::StorageProof; use sp_storage::StorageKey; +use std::fmt::Debug; use subxt::client::OfflineClientT; use subxt::{ backend::{legacy::LegacyRpcMethods, rpc::RpcClient}, @@ -49,87 +61,130 @@ fn u8_array_to_u128(array: [u8; 10]) -> u128 { result } +pub async fn coretime_bulk_task( + relay_chain: R, + p_hash: H256, + para_id: ParaId, + bulk_record: Arc>, +) -> Result<(), Box> +where + R: RelayChainInterface + Clone, +{ + // Determine whether it is a parathread + let parathread = is_parathread(relay_chain, p_hash, para_id).await?; + if !parathread { + return Ok(()); + } + // Query CoreAssigned Event + let api = OnlineClient::::from_url("ws://127.0.0.1:8855").await?; + let block = api.blocks().at_latest().await?; + let events = block.events().await?; + for event in events.iter() { + let event = event?; + let pallet = event.pallet_name(); + let variant = event.variant_name(); + let field_values = event.field_values()?; + log::info!("{:?},{:?},{:?}", pallet, variant, field_values); + let event_detail = event.as_event::(); + if let Ok(assigned_event) = event_detail { + if let Some(ev) = assigned_event { + log::info!("{:?},{:?},{:?}", ev.region_id, ev.task, ev.duration); + let pid: u32 = para_id.into(); + if ev.task == pid { + // + let rpc_client = RpcClient::from_url("ws://127.0.0.1:8855").await?; + let rpc = LegacyRpcMethods::::new(rpc_client.clone()); + let mask = u8_array_to_u128(ev.region_id.mask.0); + let core_mask = CoreMask::from(mask); + let region_id = RegionId { + begin: ev.region_id.begin, + core: ev.region_id.core, + mask: core_mask, + }; + println!("region_id:{:?}", region_id); + let key = broker_regions(region_id); + println!("key:{:?}", key); + let mut relevant_keys = Vec::new(); + relevant_keys.push(key.as_slice()); + let proof = rpc + .state_get_read_proof(relevant_keys, Some(events.block_hash())) + .await + .unwrap(); + let storage_proof = + StorageProof::new(proof.proof.into_iter().map(|bytes| bytes.to_vec())); + println!("{:?}", storage_proof); + let storage_root = block.header().state_root; + let relay_storage_rooted_proof: GenericStateProof< + cumulus_primitives_core::relay_chain::Block, + > = GenericStateProof::new(storage_root, storage_proof.clone()).unwrap(); + let head_data = relay_storage_rooted_proof + .read_entry::>(key.as_slice(), None) + .ok(); + println!("head_data:{:?}", head_data); + if let Some(region_record) = head_data { + let mut bulk_record_local = bulk_record.lock().await; + bulk_record_local.storage_proof = storage_proof; + bulk_record_local.storage_root = storage_root; + bulk_record_local.region_id = region_id; + } + } + } + } + } + Ok(()) +} + +pub async fn run_coretime_bulk_task( + relay_chain: R, + para_id: ParaId, + bulk_record: Arc>, +) where + R: RelayChainInterface + Clone, +{ + let relay_chain_notification = async move { + let new_best_heads = relay_chain + .new_best_notification_stream() + .await? + .filter_map(move |n| async move { Some((n.number, n.hash())) }) + .fuse(); + pin_mut!(new_best_heads); + loop { + select! { + h = new_best_heads.next() => { + match h { + Some((height, hash)) => { + log::info!("{:?},{:?}",height, hash); + coretime_bulk_task(relay_chain.clone(), hash, para_id, bulk_record.clone()).await?; + }, + None => { + return Ok::<(), Box>(()); + } + } + } + } + } + }; + select! { + _ = relay_chain_notification.fuse() => {}, + } +} + pub fn spawn_bulk_task( parachain: Arc, para_id: ParaId, relay_chain: R, task_manager: &TaskManager, + bulk_record: Arc>, ) -> sc_service::error::Result<()> where Block: BlockT, R: RelayChainInterface + Clone + 'static, T: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, { - task_manager.spawn_essential_handle().spawn("bulk task", "magport", { - let parachain = parachain.clone(); - - async move { - let rpc_client = RpcClient::from_url("ws://127.0.0.1:8855").await.unwrap(); - let api = - OnlineClient::::from_url("ws://127.0.0.1:8855").await.unwrap(); - - loop { - let mut blocks_sub = api.blocks().subscribe_finalized().await.unwrap(); - - // For each block, print a bunch of information about it: - while let Some(block) = blocks_sub.next().await { - let block = block.unwrap(); - - let block_number = block.header().number; - let block_hash = block.hash(); - - println!("Block #{block_number}:"); - println!(" Hash: {block_hash}"); - println!(" Extrinsics:"); - let extrinsics = block.extrinsics().await.unwrap(); - for ext in extrinsics.iter() { - let ext = ext.unwrap(); - let events = ext.events().await.unwrap(); - let purchase_event = events - .find_first::() - .unwrap(); - if let Some(ev) = purchase_event { - println!( - "Purchased success: value: {:?},{:?},{:?},{:?}", - ev.who, ev.region_id, ev.price, ev.duration - ); - let rpc = LegacyRpcMethods::::new(rpc_client.clone()); - let mask = u8_array_to_u128(ev.region_id.mask.0); - let core_mask = CoreMask::from(mask); - let region_id = RegionId { - begin: ev.region_id.begin, - core: ev.region_id.core, - mask: core_mask, - }; - println!("region_id:{:?}", region_id); - let key = broker_regions(region_id); - println!("key:{:?}", key); - let mut relevant_keys = Vec::new(); - relevant_keys.push(key.as_slice()); - let proof = rpc - .state_get_read_proof(relevant_keys, Some(events.block_hash())) - .await - .unwrap(); - let storage_proof = StorageProof::new( - proof.proof.into_iter().map(|bytes| bytes.to_vec()), - ); - println!("{:?}", storage_proof); - let storage_root = block.header().state_root; - let relay_storage_rooted_proof: GenericStateProof< - cumulus_primitives_core::relay_chain::Block, - > = GenericStateProof::new(storage_root, storage_proof).unwrap(); - let head_data = relay_storage_rooted_proof - .read_entry::>( - key.as_slice(), - None, - ) - .ok(); - println!("head_data:{:?}", head_data); - } - } - } - } - } - }); + let coretime_bulk_task = + run_coretime_bulk_task(relay_chain.clone(), para_id, bulk_record.clone()); + task_manager + .spawn_essential_handle() + .spawn("bulk task", "magport", coretime_bulk_task); Ok(()) } diff --git a/client/consensus/aura/Cargo.toml b/client/coretime/common/Cargo.toml similarity index 82% rename from client/consensus/aura/Cargo.toml rename to client/coretime/common/Cargo.toml index ddc6edb..ef8b15c 100644 --- a/client/consensus/aura/Cargo.toml +++ b/client/coretime/common/Cargo.toml @@ -1,7 +1,7 @@ [package] -name = "magnet-client-consensus-aura" +name = "mc-coretime-common" authors = ["Anonymous"] -description = "magnet-consensus" +description = "magnet-coretime" license = "Apache License 2.0" homepage = "https://magnet.magport.io/" repository.workspace = true @@ -15,9 +15,9 @@ futures = { workspace = true } tracing = { workspace = true } schnellru = { workspace = true } log = { workspace = true } +subxt = { workspace = true, features = ["substrate-compat"]} -# Local -magnet-primitives-order = { path = "../../../primitives/order"} +mp-coretime-common = { path = "../../../primitives/coretime/common"} # Substrate sc-client-api = { workspace = true } @@ -39,6 +39,9 @@ sp-runtime = { workspace = true } sp-timestamp = { workspace = true } sp-state-machine = { workspace = true } substrate-prometheus-endpoint = { workspace = true } +sc-service = { workspace = true } +pallet-broker = { workspace = true} +sp-storage = { workspace = true } # Cumulus cumulus-client-consensus-common = { workspace = true } @@ -50,8 +53,9 @@ cumulus-primitives-core = { workspace = true } cumulus-primitives-parachain-inherent = { workspace = true } cumulus-client-collator = { workspace = true } cumulus-client-consensus-aura= { workspace = true } +runtime-parachains = { workspace = true } # Polkadot polkadot-primitives = { workspace = true } polkadot-node-primitives = { workspace = true } polkadot-node-subsystem = { workspace = true } -polkadot-overseer = { workspace = true } \ No newline at end of file +polkadot-overseer = { workspace = true } diff --git a/client/coretime/common/src/lib.rs b/client/coretime/common/src/lib.rs new file mode 100644 index 0000000..462d57c --- /dev/null +++ b/client/coretime/common/src/lib.rs @@ -0,0 +1,64 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . +use codec::{Codec, Decode}; +use cumulus_primitives_core::BlockT; +use cumulus_primitives_core::ParaId; +use cumulus_relay_chain_interface::RelayChainInterface; +use mp_coretime_common::well_known_keys::paras_para_lifecycles; +use pallet_broker::RegionRecord; +use pallet_broker::{CoreMask, RegionId}; +use polkadot_primitives::AccountId; +use polkadot_primitives::Balance; +use runtime_parachains::{configuration::HostConfiguration, paras::ParaLifecycle}; +use sc_client_api::UsageProvider; +use sc_service::TaskManager; +use sp_api::ProvideRuntimeApi; +use sp_core::H256; +use sp_state_machine::StorageProof; +use sp_storage::StorageKey; +use std::error::Error; +use std::sync::Arc; +use subxt::client::OfflineClientT; +use subxt::{ + backend::{legacy::LegacyRpcMethods, rpc::RpcClient}, + config::polkadot::PolkadotExtrinsicParamsBuilder as Params, + tx::Signer, + utils::MultiSignature, + Config, OnlineClient, PolkadotConfig, +}; + +pub async fn is_parathread( + relay_chain: impl RelayChainInterface + Clone, + p_hash: H256, + para_id: ParaId, +) -> Result> { + let para_lifecycles_storage = relay_chain + .get_storage_by_key(p_hash, paras_para_lifecycles(para_id).as_slice()) + .await?; + let para_lifecycles = para_lifecycles_storage + .map(|raw| ::decode(&mut &raw[..])) + .transpose()?; + let is_parathread = match para_lifecycles { + Some(lifecycles) => matches!( + lifecycles, + ParaLifecycle::Parathread + | ParaLifecycle::UpgradingParathread + | ParaLifecycle::OffboardingParathread + ), + None => false, + }; + Ok(is_parathread) +} diff --git a/node/Cargo.toml b/node/Cargo.toml index a9024a1..89aac85 100644 --- a/node/Cargo.toml +++ b/node/Cargo.toml @@ -29,11 +29,12 @@ subxt-signer = { workspace = true } # Local parachain-magnet-runtime = { path = "../runtime" } -magnet-primitives-order = { path = "../primitives/order"} -magnet-client-consensus-aura = {path ="../client/consensus/aura"} +#magnet-primitives-order = { path = "../primitives/order"} +#magnet-client-consensus-aura = {path ="../client/consensus/aura"} pallet-pot-rpc = { path = "../pallets/pot/rpc" } mp-system = { path = "../primitives/system"} -magnet-client-coretime-bulk = {path ="../client/coretime/bulk"} +mc-coretime-bulk = {path ="../client/coretime/bulk"} +mp-coretime-bulk = { path = "../primitives/coretime/bulk"} # Substrate frame-benchmarking = { workspace = true } @@ -78,6 +79,7 @@ frame-system = { workspace = true } pallet-transaction-payment = { workspace = true } sp-application-crypto= { workspace = true } sp-std = { workspace = true } +sp-trie = { workspace = true } # Polkadot polkadot-cli = { workspace = true, features = ["rococo-native"] } diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index 2527bc8..238d32d 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -75,7 +75,7 @@ pub fn development_config() -> ChainSpec { Extensions { relay_chain: "rococo-local".into(), // You MUST set this to the correct network! - para_id: 1000, + para_id: 2000, }, ) .with_name("Development") @@ -108,7 +108,7 @@ pub fn development_config() -> ChainSpec { get_account_id_from_seed::("Ferdie//stash"), ], get_account_id_from_seed::("Alice"), - 1000.into(), + 2000.into(), )) .build() } @@ -126,7 +126,7 @@ pub fn local_testnet_config() -> ChainSpec { Extensions { relay_chain: "rococo-local".into(), // You MUST set this to the correct network! - para_id: 1000, + para_id: 2000, }, ) .with_name("Local Testnet") @@ -159,7 +159,7 @@ pub fn local_testnet_config() -> ChainSpec { get_account_id_from_seed::("Ferdie//stash"), ], get_account_id_from_seed::("Alice"), - 1000.into(), + 2000.into(), )) .with_protocol_id("magnet-local") .with_properties(properties) diff --git a/node/src/main.rs b/node/src/main.rs index 86543b7..8fdc1de 100644 --- a/node/src/main.rs +++ b/node/src/main.rs @@ -10,9 +10,9 @@ mod client; mod command; mod eth; mod metadata; -mod on_demand_order; +// mod on_demand_order; mod rpc; -mod submit_order; +// mod submit_order; fn main() -> sc_cli::Result<()> { command::run() diff --git a/node/src/on_demand_order.rs b/node/src/on_demand_order.rs deleted file mode 100644 index dd51960..0000000 --- a/node/src/on_demand_order.rs +++ /dev/null @@ -1,662 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -//! Ondemand order Spawner -//! -//! The logic of placing an order to purchase core is as follows. -//! Every time a relay chain block is received, check whether the parachain is in parallel thread mode. -//! If so, read the events of the relay chain to see if there is an order to purchase core. , if there is a purchase, -//! record the purchase information. If not, then determine whether it is necessary to purchase core, such as whether -//! the transactions in the mempool reach a certain threshold. -//! -use crate::{ - metadata::api::runtime_types::pallet_broker::coretime_interface::CoreAssignment, - submit_order::{build_rpc_for_submit_order, SubmitOrderError}, -}; -use codec::{Codec, Decode}; - -use crate::metadata::api::runtime_types::polkadot_runtime_parachains::assigner_coretime::CoreDescriptor; -use cumulus_primitives_core::{ - relay_chain::BlockNumber as RelayBlockNumber, ParaId, PersistedValidationData, -}; -use cumulus_relay_chain_interface::{RelayChainInterface, RelayChainResult}; -use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; -use magnet_primitives_order::{ - self, - well_known_keys::{paras_core_descriptors, paras_para_lifecycles}, - well_known_keys::{ACTIVE_CONFIG, ON_DEMAND_QUEUE, SPOT_TRAFFIC, SYSTEM_EVENTS}, - OrderRecord, OrderRuntimeApi, OrderStatus, -}; -use mp_system::OnRelayChainApi; -pub use pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi; -use polkadot_primitives::OccupiedCoreAssumption; -use runtime_parachains::{configuration::HostConfiguration, paras::ParaLifecycle}; -use sc_client_api::UsageProvider; -use sc_service::TaskManager; -use sc_transaction_pool_api::{InPoolTransaction, MaintainedTransactionPool}; -use sp_api::ProvideRuntimeApi; -use sp_application_crypto::AppPublic; -use sp_consensus_aura::AuraApi; -use sp_core::ByteArray; -use sp_core::{crypto::Pair, H256}; -use sp_keystore::KeystorePtr; -use sp_runtime::{ - codec::Encode, - traits::{ - AtLeast32BitUnsigned, Block as BlockT, Header as HeaderT, MaybeDisplay, Member, - SaturatedConversion, - }, - FixedPointNumber, FixedU128, -}; -use std::cmp::Ordering; -use std::{convert::TryFrom, error::Error, fmt::Debug, sync::Arc}; - -#[derive(Encode, Decode, Debug, PartialEq, Clone)] -struct EnqueuedOrder { - /// Parachain ID - pub para_id: ParaId, -} - -/// Order type -#[derive(Clone, PartialEq)] -pub enum OrderType { - /// The mem pool gas reaches the threshold. - Normal, - /// Reaching the forced block threshold. - Force, - /// Receive xcm transaction from relay chain. - XCMEvent, -} - -/// Get the spot price of the relay chain. -async fn get_spot_price( - relay_chain: impl RelayChainInterface + Clone, - hash: H256, -) -> Option -where - Balance: Codec + MaybeDisplay + 'static + Debug + From, -{ - let spot_traffic_storage = relay_chain.get_storage_by_key(hash, SPOT_TRAFFIC).await.ok()?; - let p_spot_traffic = spot_traffic_storage - .map(|raw| ::decode(&mut &raw[..])) - .transpose() - .ok()?; - let active_config_storage = relay_chain.get_storage_by_key(hash, ACTIVE_CONFIG).await.ok()?; - let p_active_config = active_config_storage - .map(|raw| >::decode(&mut &raw[..])) - .transpose() - .ok()?; - if p_spot_traffic.is_some() && p_active_config.is_some() { - let spot_traffic = p_spot_traffic.unwrap(); - let active_config = p_active_config.unwrap(); - let spot_price = spot_traffic - .saturating_mul_int(active_config.on_demand_base_fee.saturated_into::()); - Some(Balance::from(spot_price)) - } else { - None - } -} - -/// Whether the relay chain has ondemand function enabled. -async fn start_on_demand( - relay_chain: impl RelayChainInterface + Clone, - hash: H256, - para_id: ParaId, -) -> Option { - let active_config_storage = relay_chain.get_storage_by_key(hash, ACTIVE_CONFIG).await.ok()?; - let p_active_config = active_config_storage - .map(|raw| >::decode(&mut &raw[..])) - .transpose() - .ok()?; - if p_active_config.is_some() { - let mut result = false; - let cores = p_active_config.unwrap().coretime_cores; - for core in 0..cores { - let key = paras_core_descriptors(polkadot_primitives::CoreIndex(core)); - let core_descriptors_storage = - relay_chain.get_storage_by_key(hash, key.as_slice()).await.ok()?; - let p_core_descriptors = core_descriptors_storage - .map(|raw| >::decode(&mut &raw[..])) - .transpose() - .ok()?; - if p_core_descriptors.is_some() { - let p_current_work = p_core_descriptors?.current_work; - if p_current_work.is_some() { - let current_work = p_current_work?; - for (assign, _) in current_work.assignments { - if assign == CoreAssignment::Task(para_id.into()) { - return Some(false); - } else if assign == CoreAssignment::Pool { - result = true - } - } - } - } - } - Some(result) - } else { - None - } -} - -/// Create an order to purchase core. -async fn try_place_order( - hash: H256, - keystore: KeystorePtr, - para_id: ParaId, - url: String, - max_amount: Balance, - slot_block: u32, - height: RelayBlockNumber, - relay_chain: impl RelayChainInterface + Clone, - number: u32, -) -> Result<(), SubmitOrderError> -where - Balance: Codec + MaybeDisplay + 'static + Debug + Into, - ParaId: From, -{ - let max_amount_128 = max_amount.into(); - build_rpc_for_submit_order( - &url, - para_id, - max_amount_128, - hash, - keystore, - slot_block, - height, - relay_chain, - number, - ) - .await -} - -/// Whether the mem pool reaches the threshold for purchasing cores. -async fn reach_txpool_threshold( - parachain: &P, - transaction_pool: Arc, - height: RelayBlockNumber, - snap_txs: Vec, -) -> Option<(bool, OrderType)> -where - Block: BlockT, - P: ProvideRuntimeApi + UsageProvider, - Balance: Codec + MaybeDisplay + 'static + Debug + AtLeast32BitUnsigned + Copy, - P::Api: TransactionPaymentApi - + OrderRuntimeApi - + OnRelayChainApi, - ExPool: MaintainedTransactionPool::Hash> + 'static, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, -{ - let mut pending_iterator = transaction_pool.ready(); - let mut is_place_order = false; - let mut all_gas_value = Balance::from(0u32); - let block_hash = parachain.usage_info().chain.best_hash; - let mut back_txs: Vec = vec![]; - loop { - let pending_tx = - if let Some(pending_tx) = pending_iterator.next() { pending_tx } else { break }; - let pending_tx_data = pending_tx.data().clone(); - let utx_length = pending_tx_data.encode().len() as u32; - let query_fee = parachain - .runtime_api() - .query_fee_details(block_hash, pending_tx_data, utx_length) - .ok()?; - all_gas_value = query_fee.final_fee().add(all_gas_value); - if transaction_pool.status().ready != 0 { - is_place_order = - parachain.runtime_api().reach_txpool_threshold(block_hash, all_gas_value).ok()?; - } - log::info!( - "tx_fee:{:?},all_fee:{:?},can_order:{:?},status:{:?}", - query_fee.final_fee(), - all_gas_value, - is_place_order, - transaction_pool.status() - ); - back_txs.push(H256::from_slice(pending_tx.hash().as_ref())); - } - let mut order_type = OrderType::Normal; - if !is_place_order { - //check is need force bid coretime - let force_bid = parachain.runtime_api().on_relaychain(block_hash, height).ok()?; - if all_gas_value.cmp(&Balance::from(0u32)) == Ordering::Greater && force_bid == 1 { - is_place_order = true; - order_type = OrderType::Force; - } - } - if is_place_order { - if back_txs == snap_txs { - is_place_order = false; - } - } - log::info!("back_txs:{:?}", back_txs); - log::info!("snap_txs:{:?}", snap_txs); - Some((is_place_order, order_type)) -} - -/// Whether the xcm transaction event of the relay chain is received. -async fn relay_chain_xcm_event( - relay_chain_interface: impl RelayChainInterface + Clone, - para_id: ParaId, - relay_parent: H256, -) -> Option<(bool, OrderType)> { - let downward_messages = - relay_chain_interface.retrieve_dmq_contents(para_id, relay_parent).await.ok()?; - let horizontal_messages = relay_chain_interface - .retrieve_all_inbound_hrmp_channel_contents(para_id, relay_parent) - .await - .ok()?; - let can_order = downward_messages.len() > 0 || horizontal_messages.len() > 0; - return Some((can_order, OrderType::XCMEvent)); -} - -/// Get the transactions in the ready queue in the mem pool -async fn get_txs(transaction_pool: Arc) -> Vec -where - Block: BlockT, - ExPool: MaintainedTransactionPool::Hash> + 'static, -{ - let mut pending_iterator = transaction_pool.ready(); - let mut back_txs: Vec = vec![]; - loop { - let pending_tx = - if let Some(pending_tx) = pending_iterator.next() { pending_tx } else { break }; - back_txs.push(H256::from_slice(pending_tx.hash().as_ref())); - } - return back_txs; -} - -/// The main processing logic of purchasing core. -async fn handle_new_best_parachain_head( - validation_data: PersistedValidationData, - height: RelayBlockNumber, - parachain: &P, - keystore: KeystorePtr, - relay_chain: impl RelayChainInterface + Clone, - p_hash: H256, - para_id: ParaId, - order_record: Arc>>, - transaction_pool: Arc, - url: String, -) -> Result<(), Box> -where - Block: BlockT, - P: ProvideRuntimeApi + UsageProvider, - Balance: Codec - + MaybeDisplay - + 'static - + Debug - + Into - + AtLeast32BitUnsigned - + Copy - + From, - P::Api: AuraApi - + OrderRuntimeApi - + TransactionPaymentApi - + OnRelayChainApi, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, - ExPool: MaintainedTransactionPool::Hash> + 'static, -{ - let para_lifecycles_storage = relay_chain - .get_storage_by_key(p_hash, paras_para_lifecycles(para_id).as_slice()) - .await?; - let para_lifecycles = para_lifecycles_storage - .map(|raw| ::decode(&mut &raw[..])) - .transpose()?; - let is_parathread = match para_lifecycles { - Some(lifecycles) => matches!( - lifecycles, - ParaLifecycle::Parathread - | ParaLifecycle::UpgradingParathread - | ParaLifecycle::OffboardingParathread - ), - None => false, - }; - if !is_parathread { - //parachain mode - let mut order_record_local = order_record.lock().await; - order_record_local.validation_data = None; - order_record_local.author_pub = None; - order_record_local.relay_parent = None; - return Ok(()); - } else { - //parathread - let p_on_demand = start_on_demand(relay_chain.clone(), p_hash, para_id).await; - if p_on_demand.is_some() { - let on_demand = p_on_demand.unwrap(); - if !on_demand { - return Ok(()); - } - } - let order_record_local = order_record.lock().await; - if order_record_local.relay_height == height { - return Ok(()); - } - } - let head = validation_data.clone().parent_head.0; - let parachain_head = match <::Header>::decode(&mut &head[..]) { - Ok(header) => header, - Err(err) => return Err(format!("get parachain head error:{:?}", err).into()), - }; - - let hash = parachain_head.hash(); - let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; - let slot_width = parachain.runtime_api().slot_width(hash)?; - let auth_len = authorities.len() as u32; - let idx = (height >> slot_width) % auth_len; - let collator_public = - magnet_client_consensus_aura::order_slot::(idx, &authorities, &keystore).await; - let base = 2 as u32; - let slot_block = base.pow(slot_width); - if height % slot_block == 0 { - let mut order_record_local = order_record.lock().await; - order_record_local.relay_base = p_hash; - order_record_local.relay_base_height = height; - order_record_local.order_status = OrderStatus::Init; - } - let mut relevant_keys = Vec::new(); - //System Events - relevant_keys.push(SYSTEM_EVENTS.to_vec()); - let storage_proof = relay_chain.prove_read(p_hash, &relevant_keys).await?; - let order_placed = parachain.runtime_api().order_placed( - hash, - storage_proof, - validation_data.clone(), - para_id, - )?; - match order_placed { - Some(author) => { - let mut order_record_local = order_record.lock().await; - order_record_local.relay_parent = Some(p_hash); - order_record_local.relay_height = height; - order_record_local.validation_data = Some(validation_data); - order_record_local.author_pub = Some(author); - order_record_local.para_id = para_id; - let sequence_number = parachain.runtime_api().sequence_number(hash)?; - order_record_local.sequence_number = sequence_number; - order_record_local.txs = get_txs(transaction_pool.clone()).await; - }, - None => { - let sequence_number = parachain.runtime_api().sequence_number(hash)?; - let order_executed = parachain.runtime_api().order_executed(hash, sequence_number)?; - if order_executed { - return Ok(()); - } - let mut order_record_local = order_record.lock().await; - if collator_public.is_some() { - //your turn - let reached = reach_txpool_threshold::<_, _, _, _, PB>( - parachain, - transaction_pool, - height, - order_record_local.txs.clone(), - ) - .await; - let mut can_order = false; - let mut order_type = OrderType::Normal; - if let Some((reach, o_t)) = reached { - if reach { - order_type = o_t; - let mut exist_order = false; - // key = OnDemandAssignmentProvider OnDemandQueue - let on_demand_queue_storage = - relay_chain.get_storage_by_key(p_hash, ON_DEMAND_QUEUE).await?; - let on_demand_queue = on_demand_queue_storage - .map(|raw| >::decode(&mut &raw[..])) - .transpose()?; - if let Some(vvs) = on_demand_queue.clone() { - for vv in vvs.into_iter() { - if vv.para_id == para_id { - exist_order = true; - break; - } - } - } - if !exist_order { - can_order = true; - } - } else { - let trig_xcm_event = - relay_chain_xcm_event(relay_chain.clone(), para_id, p_hash).await; - if let Some((trig_flag, o_t)) = trig_xcm_event { - can_order = trig_flag; - order_type = o_t; - } - } - } - if can_order { - if height - order_record_local.relay_height > slot_block { - if order_record_local.order_status == OrderStatus::Init { - let max_amount = parachain.runtime_api().order_max_amount(hash)?; - let p_spot_price = - get_spot_price::(relay_chain.clone(), p_hash).await; - let spot_price; - if p_spot_price.is_some() { - spot_price = p_spot_price.unwrap(); - } else { - spot_price = max_amount; - } - match order_type { - OrderType::Normal => { - log::info!( - "============normal place order======================" - ); - }, - OrderType::Force => { - log::info!( - "============force place order======================" - ); - }, - OrderType::XCMEvent => { - log::info!("============xcm place order======================"); - }, - } - let order_result = try_place_order::( - order_record_local.relay_base, - keystore, - para_id, - url, - spot_price, - slot_block, - height, - relay_chain.clone(), - order_record_local.relay_base_height, - ) - .await; - log::info!("===========place order completed==============",); - order_record_local.order_status = OrderStatus::Order; - if order_result.is_err() { - log::info!( - "===========place_order error:=============={:?}", - order_result - ); - } - } - } - } - } - }, - } - Ok(()) -} - -async fn new_best_heads( - relay_chain: impl RelayChainInterface + Clone, - para_id: ParaId, -) -> RelayChainResult> { - let new_best_notification_stream = - relay_chain.new_best_notification_stream().await?.filter_map(move |n| { - let relay_chain = relay_chain.clone(); - async move { - let relay_head: PersistedValidationData = relay_chain - .persisted_validation_data(n.hash(), para_id, OccupiedCoreAssumption::TimedOut) - .await - .map(|s| s.map(|s| s)) - .ok() - .flatten()?; - Some((n.number, relay_head, n.hash())) - } - }); - - Ok(new_best_notification_stream) -} -async fn relay_chain_notification( - para_id: ParaId, - parachain: Arc

, - relay_chain: R, - keystore: KeystorePtr, - order_record: Arc>>, - transaction_pool: Arc, - url: String, -) where - R: RelayChainInterface + Clone, - Block: BlockT, - Balance: Codec - + MaybeDisplay - + 'static - + Debug - + Into - + AtLeast32BitUnsigned - + Copy - + From, - P: ProvideRuntimeApi + UsageProvider, - P::Api: AuraApi - + OrderRuntimeApi - + TransactionPaymentApi - + OnRelayChainApi, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, - ExPool: MaintainedTransactionPool::Hash> + 'static, -{ - let new_best_heads = match new_best_heads(relay_chain.clone(), para_id).await { - Ok(best_heads_stream) => best_heads_stream.fuse(), - Err(_err) => { - return; - }, - }; - pin_mut!(new_best_heads); - loop { - select! { - h = new_best_heads.next() => { - match h { - Some((height, head, hash)) => { - let _ = handle_new_best_parachain_head::<_,_,PB,_,_>(head,height, &*parachain,keystore.clone(), relay_chain.clone(), hash, para_id, order_record.clone(),transaction_pool.clone(), url.clone()).await; - }, - None => { - return; - } - } - }, - } - } -} - -pub async fn run_on_demand_task( - para_id: ParaId, - parachain: Arc

, - relay_chain: R, - keystore: KeystorePtr, - order_record: Arc>>, - transaction_pool: Arc, - url: String, -) where - R: RelayChainInterface + Clone, - Block: BlockT, - P: ProvideRuntimeApi + UsageProvider, - Balance: Codec - + MaybeDisplay - + 'static - + Debug - + Into - + AtLeast32BitUnsigned - + Copy - + From, - P::Api: AuraApi - + OrderRuntimeApi - + TransactionPaymentApi - + OnRelayChainApi, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, - ExPool: MaintainedTransactionPool::Hash> + 'static, -{ - let relay_chain_notification = relay_chain_notification::<_, _, _, PB, _, _>( - para_id, - parachain.clone(), - relay_chain, - keystore, - order_record, - transaction_pool, - url, - ); - select! { - _ = relay_chain_notification.fuse() => {}, - } -} - -pub fn spawn_on_demand_order( - parachain: Arc, - para_id: ParaId, - relay_chain: R, - transaction_pool: Arc, - task_manager: &TaskManager, - keystore: KeystorePtr, - order_record: Arc>>, - url: String, -) -> sc_service::error::Result<()> -where - Block: BlockT, - R: RelayChainInterface + Clone + 'static, - Balance: Codec - + MaybeDisplay - + 'static - + Debug - + Send - + Into - + AtLeast32BitUnsigned - + Copy - + From, - T: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, - ExPool: MaintainedTransactionPool::Hash> + 'static, - T::Api: AuraApi - + OrderRuntimeApi - + TransactionPaymentApi - + OnRelayChainApi, - PB: Pair + 'static, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, -{ - let on_demand_order_task = run_on_demand_task::<_, _, _, PB, _, _>( - para_id, - parachain.clone(), - relay_chain.clone(), - keystore, - order_record, - transaction_pool.clone(), - url, - ); - task_manager.spawn_essential_handle().spawn_blocking( - "on_demand_order_task", - None, - on_demand_order_task, - ); - Ok(()) -} diff --git a/node/src/service.rs b/node/src/service.rs index ed725d0..f3244b4 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -24,7 +24,6 @@ use cumulus_relay_chain_interface::{OverseerHandle, RelayChainInterface}; // Substrate Imports use frame_benchmarking_cli::SUBSTRATE_REFERENCE_HARDWARE; -use magnet_client_coretime_bulk::spawn_bulk_task; use sc_client_api::Backend; use sc_consensus::ImportQueue; use sc_executor::{ @@ -47,9 +46,14 @@ use crate::eth::{ FrontierBlockImport as TFrontierBlockImport, FrontierPartialComponents, }; -use crate::on_demand_order::spawn_on_demand_order; +// use crate::on_demand_order::spawn_on_demand_order; use futures::lock::Mutex; -use magnet_primitives_order::{OrderRecord, OrderStatus}; +// use magnet_primitives_order::{OrderRecord, OrderStatus}; +use mc_coretime_bulk::spawn_bulk_task; +use mp_coretime_bulk::BulkMemRecord; +use sp_core::ByteArray; +use sp_runtime::AccountId32; +use sp_trie::StorageProof; /// Native executor type. pub struct ParachainNativeExecutor; @@ -456,30 +460,41 @@ async fn start_node_impl( sync_service: sync_service.clone(), })?; if validator { - let order_record = - Arc::new(Mutex::new(OrderRecord:: { - relay_parent: None, - relay_height: 0, - relay_base: Default::default(), - relay_base_height: 0, - order_status: OrderStatus::Init, - validation_data: None, - para_id, - sequence_number: 0, - author_pub: None, - txs: vec![], - })); - spawn_on_demand_order::<_, _, _, _, sp_consensus_aura::sr25519::AuthorityPair, _>( + // let order_record = + // Arc::new(Mutex::new(OrderRecord:: { + // relay_parent: None, + // relay_height: 0, + // relay_base: Default::default(), + // relay_base_height: 0, + // order_status: OrderStatus::Init, + // validation_data: None, + // para_id, + // sequence_number: 0, + // author_pub: None, + // txs: vec![], + // })); + // spawn_on_demand_order::<_, _, _, _, sp_consensus_aura::sr25519::AuthorityPair, _>( + // client.clone(), + // para_id, + // relay_chain_interface.clone(), + // transaction_pool.clone(), + // &task_manager, + // params.keystore_container.keystore(), + // order_record.clone(), + // rpc_address, + // )?; + let bulk_mem_record = Arc::new(Mutex::new(BulkMemRecord { + storage_proof: StorageProof::empty(), + storage_root: Default::default(), + region_id: 0u128.into(), + })); + spawn_bulk_task( client.clone(), para_id, relay_chain_interface.clone(), - transaction_pool.clone(), &task_manager, - params.keystore_container.keystore(), - order_record.clone(), - rpc_address, + bulk_mem_record.clone(), )?; - spawn_bulk_task(client.clone(), para_id, relay_chain_interface.clone(), &task_manager)?; start_consensus( client.clone(), block_import, @@ -495,7 +510,8 @@ async fn start_node_impl( collator_key.expect("Command line arguments do not allow this. qed"), overseer_handle, announce_block, - order_record, + // order_record, + bulk_mem_record, )?; } @@ -550,7 +566,8 @@ fn start_consensus( collator_key: CollatorPair, overseer_handle: OverseerHandle, announce_block: Arc>) + Send + Sync>, - order_record: Arc>>, + // order_record: Arc>>, + bulk_mem_record: Arc>, ) -> Result<(), sc_service::Error> { use cumulus_client_consensus_aura::collators::basic::{ self as basic_aura, Params as BasicAuraParams, @@ -584,38 +601,51 @@ fn start_consensus( let params = BasicAuraParams { // create_inherent_data_providers: move |_, ()| async move { Ok(()) }, create_inherent_data_providers: move |_, ()| { - let relay_chain_interface = relay_chain_interface.clone(); - let order_record_clone = order_record.clone(); + // let relay_chain_interface = relay_chain_interface.clone(); + let bulk_mem_record_clone = bulk_mem_record.clone(); async move { - let parent_hash = relay_chain_interface.best_block_hash().await?; - let (relay_parent, validation_data, sequence_number, author_pub) = { - let order_record_local = order_record_clone.lock().await; - if order_record_local.validation_data.is_none() { - (parent_hash, None, order_record_local.sequence_number, None) - } else { - ( - order_record_local.relay_parent.expect("can not get relay_parent hash"), - order_record_local.validation_data.clone(), - order_record_local.sequence_number, - order_record_local.author_pub.clone(), - ) - } - }; - let order_inherent = magnet_primitives_order::OrderInherentData::create_at( - relay_parent, - &relay_chain_interface, - &validation_data, - para_id, - sequence_number, - &author_pub, + // let parent_hash = relay_chain_interface.best_block_hash().await?; + // let (relay_parent, validation_data, sequence_number, author_pub) = { + // let order_record_local = order_record_clone.lock().await; + // if order_record_local.validation_data.is_none() { + // (parent_hash, None, order_record_local.sequence_number, None) + // } else { + // ( + // order_record_local.relay_parent.expect("can not get relay_parent hash"), + // order_record_local.validation_data.clone(), + // order_record_local.sequence_number, + // order_record_local.author_pub.clone(), + // ) + // } + // }; + // let order_inherent = magnet_primitives_order::OrderInherentData::create_at( + // relay_parent, + // &relay_chain_interface, + // &validation_data, + // para_id, + // sequence_number, + // &author_pub, + // ) + // .await; + // let order_inherent = order_inherent.ok_or_else(|| { + // Box::::from( + // "Failed to create order inherent", + // ) + // })?; + // Ok(order_inherent) + let bulk_mem_record_clone_local = bulk_mem_record_clone.lock().await; + let bulk_inherent = mp_coretime_bulk::BulkInherentData::create_at( + &bulk_mem_record_clone_local.storage_proof, + bulk_mem_record_clone_local.storage_root, + bulk_mem_record_clone_local.region_id, ) .await; - let order_inherent = order_inherent.ok_or_else(|| { + let bulk_inherent = bulk_inherent.ok_or_else(|| { Box::::from( "Failed to create order inherent", ) })?; - Ok(order_inherent) + Ok(bulk_inherent) } }, block_import, diff --git a/node/src/submit_order.rs b/node/src/submit_order.rs deleted file mode 100644 index eb639e4..0000000 --- a/node/src/submit_order.rs +++ /dev/null @@ -1,143 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -//! The code here is implemented, constructing a transaction from the parachain and sending it to the relay chain to purchase core. -//! -//! Subxt is used here to construct and submit the transaction. -//! -use crate::metadata; -use cumulus_primitives_core::{ - relay_chain::BlockId, relay_chain::BlockNumber as RelayBlockNumber, ParaId, -}; -use cumulus_relay_chain_interface::{RelayChainInterface, RelayChainResult}; -use sp_application_crypto::AppCrypto; -use sp_core::ByteArray; -use sp_core::H256; -use sp_keystore::KeystorePtr; -use sp_runtime::{ - traits::{IdentifyAccount, Verify}, - MultiSignature as SpMultiSignature, -}; -use subxt::client::OfflineClientT; -use subxt::{ - config::polkadot::PolkadotExtrinsicParamsBuilder as Params, tx::Signer, utils::MultiSignature, - Config, OnlineClient, PolkadotConfig, -}; - -#[derive(Debug)] -pub enum SubmitOrderError { - RPCUrlError, - RPCConnectError, - RPCCallException, - NonceGetError, - StorageGetError, - GetBlockError, - GetHeadError, -} - -#[derive(Clone, Copy, PartialEq, Eq)] -pub struct Signature(pub [u8; 64]); - -impl From for MultiSignature { - fn from(value: Signature) -> Self { - MultiSignature::Sr25519(value.0) - } -} -pub struct SignerKeystore { - /// Account ID - account_id: T::AccountId, - /// Keystore of node - keystore: KeystorePtr, -} -impl SignerKeystore -where - T: Config, - T::AccountId: From<[u8; 32]>, -{ - pub fn new(keystore: KeystorePtr) -> Self { - let pub_key = - keystore.sr25519_public_keys(sp_consensus_aura::sr25519::AuthorityPair::ID)[0]; - - let binding = ::Signer::from(pub_key).into_account().clone(); - - let account_id = binding.as_slice(); - let mut r = [0u8; 32]; - r.copy_from_slice(account_id); - let acc = T::AccountId::try_from(r).ok().unwrap(); - Self { account_id: acc.clone(), keystore } - } -} -impl Signer for SignerKeystore -where - T: Config, - T::AccountId: From<[u8; 32]>, - T::Signature: From, -{ - fn account_id(&self) -> T::AccountId { - self.account_id.clone() - } - - fn address(&self) -> T::Address { - self.account_id.clone().into() - } - - /// Use aura's key to sign - /// TODO:Modify to other keys, or load the key in some way. - fn sign(&self, signer_payload: &[u8]) -> T::Signature { - let pub_key = - self.keystore.sr25519_public_keys(sp_consensus_aura::sr25519::AuthorityPair::ID)[0]; - - let signature = self - .keystore - .sr25519_sign(sp_consensus_aura::sr25519::AuthorityPair::ID, &pub_key, signer_payload) - .unwrap() - .unwrap(); - - Signature(signature.0).into() - } -} - -/// Construct the transaction and sign it, and then submit the transaction through the rpc interface. -pub async fn build_rpc_for_submit_order( - url: &str, - para_id: ParaId, - max_amount: u128, - hash: H256, - keystore: KeystorePtr, - slot_block: u32, - height: RelayBlockNumber, - relay_chain: impl RelayChainInterface + Clone, - number: u32, -) -> Result<(), SubmitOrderError> { - let client = OnlineClient::::from_url(url) - .await - .map_err(|_e| SubmitOrderError::RPCConnectError)?; - - let place_order = metadata::api::tx().on_demand_assignment_provider().place_order_allow_death( - max_amount, - metadata::api::runtime_types::polkadot_parachain_primitives::primitives::Id(para_id.into()), - ); - - let signer_keystore = SignerKeystore::::new(keystore.clone()); - - // let tx_params = Params::new().mortal_unchecked(number.into(), hash , slot_block.into()).build(); - - let submit_result = client.tx().sign_and_submit_default(&place_order, &signer_keystore).await; - log::info!("submit_result:{:?},{:?},{:?}", submit_result, height, hash); - submit_result.map_err(|_e| SubmitOrderError::RPCCallException)?; - - Ok(()) -} diff --git a/pallets/order/Cargo.toml b/pallets/bulk/Cargo.toml similarity index 87% rename from pallets/order/Cargo.toml rename to pallets/bulk/Cargo.toml index 7537d41..f139818 100644 --- a/pallets/order/Cargo.toml +++ b/pallets/bulk/Cargo.toml @@ -1,7 +1,7 @@ [package] -name = "pallet-order" +name = "pallet-bulk" authors = ["Anonymous"] -description = "On demand order runtime logic." +description = "bulk mode runtime logic." version = "0.2.0" license = "Apache-2.0" homepage = "https://magnet.magport.io/" @@ -18,7 +18,8 @@ log = { workspace = true, default-features = false } hex-literal = { workspace = true } # Local -magnet-primitives-order = { path = "../../primitives/order", default-features = false } +mp-coretime-bulk = { path = "../../primitives/coretime/bulk", default-features = false } +dp-chain-state-snapshot = { path = "../../primitives/chain-state-snapshot", default-features = false} # Cumulus cumulus-pallet-parachain-system = { workspace = true, default-features = false} @@ -37,6 +38,7 @@ sp-runtime = { workspace = true, default-features = false} sp-trie = { workspace = true, default-features = false } pallet-balances = { workspace = true, default-features = false } sp-core = { workspace = true , default-features = false} +pallet-broker = { workspace = true, default-features = false } [dev-dependencies] serde = { workspace = true } @@ -73,7 +75,7 @@ std = [ "sp-core/std", "sp-io/std", "sp-runtime/std", - "magnet-primitives-order/std", + "mp-coretime-bulk/std", "log/std", "cumulus-pallet-parachain-system/std", "cumulus-primitives-core/std", @@ -82,6 +84,8 @@ std = [ "sp-trie/std", "pallet-balances/std", "sp-core/std", + "dp-chain-state-snapshot/std", + "pallet-broker/std", ] try-runtime = [ "frame-support/try-runtime", diff --git a/pallets/order/README.md b/pallets/bulk/README.md similarity index 100% rename from pallets/order/README.md rename to pallets/bulk/README.md diff --git a/pallets/bulk/src/benchmarking.rs b/pallets/bulk/src/benchmarking.rs new file mode 100644 index 0000000..3abea2f --- /dev/null +++ b/pallets/bulk/src/benchmarking.rs @@ -0,0 +1,40 @@ +// // Copyright (C) Magnet. +// // This file is part of Magnet. + +// // Magnet is free software: you can redistribute it and/or modify +// // it under the terms of the GNU General Public License as published by +// // the Free Software Foundation, either version 3 of the License, or +// // (at your option) any later version. + +// // Magnet is distributed in the hope that it will be useful, +// // but WITHOUT ANY WARRANTY; without even the implied warranty of +// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// // GNU General Public License for more details. + +// // You should have received a copy of the GNU General Public License +// // along with Magnet. If not, see . + +// //! Benchmarking setup for pallet-order + +// use super::*; + +// #[allow(unused)] +// use crate::Pallet as Order; +// use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller}; +// use frame_system::RawOrigin; + +// benchmarks! { +// set_parameter { +// let s in 0 .. 100; +// let caller: T::AccountId = whitelisted_caller(); +// let test_balance = BalanceOf::::from(200000000 as u32); +// let test_threshold = BalanceOf::::from(3000000000 as u32); +// }: _(RawOrigin::Root, Some(4), Some(test_balance), Some(test_threshold)) +// verify { +// assert_eq!(SlotWidth::::get(), 4); +// assert_eq!(OrderMaxAmount::::get(), test_balance); +// assert_eq!(TxPoolThreshold::::get(), test_threshold); +// } +// } + +// impl_benchmark_test_suite!(Order, crate::mock::ExtBuilder::default().build(), crate::mock::Test,); diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs new file mode 100644 index 0000000..6b44f41 --- /dev/null +++ b/pallets/bulk/src/lib.rs @@ -0,0 +1,205 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! # Order Pallet +//! +//! This pallet implements the recording and query functions of purchasing ondemand core. +//! +//! By obtaining the inherent nature of the block, parsing it out of the validation_data of the relaychain, +//! and querying whether there is an OnDemandOrderPlaced event, obtaining the order account and price from the event, +//! and then writing this record to the blockchain. +//! +//! Provides many query methods for node or other pallets to use, such as querying the gas consumed by placing an order in a certain block, +//! whether the order has been executed, whether the order threshold has been reached, etc. + +#![cfg_attr(not(feature = "std"), no_std)] +use codec::{Decode, MaxEncodedLen}; +use cumulus_pallet_parachain_system::{ + relay_state_snapshot::Error as Relay_Error, RelayChainStateProof, +}; +use frame_support::{ + dispatch::DispatchResultWithPostInfo, dispatch::PostDispatchInfo, pallet_prelude::*, + traits::Currency, +}; +use frame_system::pallet_prelude::*; +use frame_system::{self, EventRecord}; +use mp_coretime_bulk::well_known_keys::{broker_regions, REGIONS}; +pub use pallet::*; +use primitives::Balance; +use primitives::{Id as ParaId, PersistedValidationData}; +use sp_runtime::sp_std::{prelude::*, vec}; +use sp_runtime::{traits::Member, RuntimeAppPublic}; +pub mod weights; +use dp_chain_state_snapshot::GenericStateProof; +use pallet_broker::RegionRecord; +use sp_core::crypto::ByteArray; +use weights::WeightInfo; +// #[cfg(test)] +// mod mock; + +// #[cfg(test)] +// mod tests; + +// #[cfg(any(test, feature = "runtime-benchmarks"))] +// mod benchmarking; +// mod proof_data; + +type BalanceOf = + <::Currency as Currency<::AccountId>>::Balance; + +/// ondemand order information. +#[derive(Encode, Decode, Default, Clone, Copy, TypeInfo, MaxEncodedLen, Debug)] +pub struct BulkRecord { + /// Account for purchase. + pub purchaser: AuthorityId, + /// Purchase price. + pub price: Balance, + /// Purchase duration. + pub duration: u32, +} +#[frame_support::pallet] +pub mod pallet { + use super::*; + + /// Configure the pallet by specifying the parameters and types on which it depends. + #[pallet::config] + pub trait Config: frame_system::Config { + /// Because this pallet emits events, it depends on the runtime's definition of an event. + type RuntimeEvent: From> + IsType<::RuntimeEvent>; + + type Currency: Currency; + + type AuthorityId: Member + + Parameter + + RuntimeAppPublic + + MaybeSerializeDeserialize + + MaxEncodedLen + + for<'a> TryFrom<&'a [u8]>; + + type UpdateOrigin: EnsureOrigin; + + type WeightInfo: WeightInfo; + } + + #[pallet::pallet] + pub struct Pallet(PhantomData); + + #[pallet::type_value] + pub fn RecordIndexOnEmpty() -> u32 { + 0 + } + + #[pallet::storage] + #[pallet::getter(fn record_index)] + pub type RecordIndex = StorageValue<_, u32, ValueQuery, RecordIndexOnEmpty>; + + /// Order Information Map. + #[pallet::storage] + #[pallet::getter(fn bulk_records)] + pub type BulkRecords = + StorageMap<_, Twox64Concat, u32, BulkRecord, T::AuthorityId>, OptionQuery>; + + #[pallet::event] + #[pallet::generate_deposit(pub(super) fn deposit_event)] + pub enum Event { + /// Create order event. + OrderCreate { sequence_number: u64, orderer: T::AuthorityId }, + } + + #[pallet::error] + pub enum Error { + /// Error reading data. + FailedReading, + } + + #[pallet::hooks] + impl Hooks> for Pallet { + fn on_finalize(block_number: BlockNumberFor) {} + } + + #[pallet::inherent] + impl ProvideInherent for Pallet { + type Call = Call; + type Error = MakeFatalError<()>; + + const INHERENT_IDENTIFIER: InherentIdentifier = mp_coretime_bulk::INHERENT_IDENTIFIER; + + fn create_inherent(data: &InherentData) -> Option { + let data = data.get_data(&mp_coretime_bulk::INHERENT_IDENTIFIER).ok().flatten(); + match data { + Some(data) => Some(Call::create_record { data }), + None => None, + } + } + fn is_inherent(call: &Self::Call) -> bool { + matches!(call, Call::create_record { .. }) + } + } + + #[pallet::call] + impl Pallet { + /// Create an order, which is called by the pallet. + /// Users cannot actively call this function. + /// Obtain order information by parsing inherited data. + /// + /// Parameters: + /// - `data`: The inherent data. + #[pallet::call_index(0)] + #[pallet::weight((0, DispatchClass::Mandatory))] + pub fn create_record( + origin: OriginFor, + data: mp_coretime_bulk::BulkInherentData, + ) -> DispatchResultWithPostInfo { + ensure_none(origin)?; + + let mp_coretime_bulk::BulkInherentData { storage_proof, storage_root, region_id } = + data; + let relay_storage_rooted_proof: GenericStateProof< + cumulus_primitives_core::relay_chain::Block, + > = GenericStateProof::new(storage_root, storage_proof).unwrap(); + let key = broker_regions(region_id); + let region_record_data = relay_storage_rooted_proof + .read_entry::>>(key.as_slice(), None) + .ok(); + if let Some(region_record) = region_record_data { + let old_record_index = RecordIndex::::get(); + BulkRecords::::insert( + old_record_index, + BulkRecord::, T::AuthorityId> { + purchaser: region_record.owner, + price: region_record.paid.unwrap(), + duration: region_record.end, + }, + ); + } + + let total_weight = T::DbWeight::get().reads_writes(2, 1); + Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) + } + } +} + +impl Pallet {} + +// pub trait OrderGasCost { +// /// Gas consumed by placing an order in a certain block. +// /// +// /// Parameters: +// /// - `block_number`: The block number of para chain. +// fn gas_cost( +// block_number: BlockNumberFor, +// ) -> Result, DispatchError>; +// } diff --git a/pallets/bulk/src/mock.rs b/pallets/bulk/src/mock.rs new file mode 100644 index 0000000..71fa00d --- /dev/null +++ b/pallets/bulk/src/mock.rs @@ -0,0 +1,183 @@ +// // Copyright (C) Magnet. +// // This file is part of Magnet. + +// // Magnet is free software: you can redistribute it and/or modify +// // it under the terms of the GNU General Public License as published by +// // the Free Software Foundation, either version 3 of the License, or +// // (at your option) any later version. + +// // Magnet is distributed in the hope that it will be useful, +// // but WITHOUT ANY WARRANTY; without even the implied warranty of +// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// // GNU General Public License for more details. + +// // You should have received a copy of the GNU General Public License +// // along with Magnet. If not, see . + +// use crate::{self as order_pallet, OrderGasCost}; +// use codec::Encode; +// pub use frame_support::{ +// construct_runtime, derive_impl, parameter_types, +// traits::{Everything, Hooks}, +// }; +// use frame_system as system; +// use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; +// pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; +// use sp_core::{crypto::AccountId32, H256}; +// use sp_runtime::{ +// traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, +// BuildStorage, MultiSignature, +// }; + +// type Block = frame_system::mocking::MockBlock; +// type Signature = MultiSignature; +// type AccountId = <::Signer as IdentifyAccount>::AccountId; +// type Balance = u128; +// // Configure a mock runtime to test the pallet. +// construct_runtime!( +// pub enum Test +// { +// System: frame_system::{Pallet, Call, Config, Storage, Event}, +// Balances: pallet_balances::{Pallet, Call, Event}, +// OrderPallet: order_pallet::{Pallet, Call, Storage, Event}, +// MockPallet: mock_pallet, +// } +// ); + +// parameter_types! { +// pub const BlockHashCount: u64 = 250; +// pub const SS58Prefix: u8 = 42; +// } + +// #[derive_impl(frame_system::config_preludes::ParaChainDefaultConfig as frame_system::DefaultConfig)] +// impl system::Config for Test { +// type BaseCallFilter = Everything; +// type BlockWeights = (); +// type BlockLength = (); +// type DbWeight = (); +// type RuntimeOrigin = RuntimeOrigin; +// type RuntimeCall = RuntimeCall; +// type Nonce = u64; +// type Hash = H256; +// type Hashing = BlakeTwo256; +// type AccountId = AccountId32; +// type Lookup = IdentityLookup; +// type Block = Block; +// type RuntimeEvent = RuntimeEvent; +// type BlockHashCount = BlockHashCount; +// type Version = (); +// type PalletInfo = PalletInfo; +// type AccountData = pallet_balances::AccountData; +// type OnNewAccount = (); +// type OnKilledAccount = (); +// type SystemWeightInfo = (); +// type SS58Prefix = SS58Prefix; +// type OnSetCode = (); +// type MaxConsumers = frame_support::traits::ConstU32<16>; +// } +// parameter_types! { +// pub const ExistentialDeposit: u64 = 5; +// } +// impl pallet_balances::Config for Test { +// type MaxLocks = (); +// type MaxReserves = (); +// type ReserveIdentifier = [u8; 8]; +// type Balance = u128; +// type RuntimeEvent = RuntimeEvent; +// type DustRemoval = (); +// type ExistentialDeposit = ExistentialDeposit; +// type AccountStore = System; +// type WeightInfo = (); +// type FreezeIdentifier = (); +// type MaxFreezes = (); +// type RuntimeHoldReason = (); +// type RuntimeFreezeReason = (); +// } +// parameter_types! { +// pub const SlotWidth: u32 = 2; +// pub const OrderMaxAmount:Balance = 200000000; +// pub const TxPoolThreshold:Balance = 3000000000; +// } +// impl crate::Config for Test { +// type RuntimeEvent = RuntimeEvent; +// type AuthorityId = AuraId; +// type UpdateOrigin = EnsureRoot; +// type Currency = Balances; +// type OrderMaxAmount = OrderMaxAmount; +// type SlotWidth = SlotWidth; +// type TxPoolThreshold = TxPoolThreshold; +// type WeightInfo = (); +// } +// pub struct OrderGasCostHandler(); + +// impl OrderGasCost for OrderGasCostHandler +// where +// T: crate::Config, +// T::AccountId: From<[u8; 32]>, +// { +// fn gas_cost( +// block_number: BlockNumberFor, +// ) -> Result, sp_runtime::DispatchError> { +// let sequece_number = >::block_2_sequence(block_number); +// if sequece_number.is_none() { +// return Ok(None); +// } +// let order = >::order_map( +// sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, +// ) +// .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; +// let mut r = [0u8; 32]; +// r.copy_from_slice(order.orderer.encode().as_slice()); +// let account = T::AccountId::try_from(r) +// .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; +// Ok(Some((account, order.price))) +// } +// } + +// #[frame_support::pallet] +// pub mod mock_pallet { +// use super::*; +// #[pallet::config] +// pub trait Config: frame_system::Config { +// type OrderGasCost: OrderGasCost; +// } + +// #[pallet::call] +// impl Pallet {} + +// #[pallet::pallet] +// #[pallet::without_storage_info] +// pub struct Pallet(_); + +// impl Pallet { +// pub fn get_gas_cost(block_number: BlockNumberFor) -> Option<(T::AccountId, Balance)> { +// T::OrderGasCost::gas_cost(block_number).unwrap() +// } +// } +// } + +// impl mock_pallet::Config for Test { +// type OrderGasCost = OrderGasCostHandler; +// } +// pub struct ExtBuilder { +// balances: Vec<(AccountId32, u128)>, +// } + +// impl Default for ExtBuilder { +// fn default() -> Self { +// Self { balances: Default::default() } +// } +// } + +// impl ExtBuilder { +// pub fn build(self) -> sp_io::TestExternalities { +// // Build genesis storage according to the mock runtime. +// let mut t = frame_system::GenesisConfig::::default().build_storage().unwrap(); +// pallet_balances::GenesisConfig:: { balances: self.balances } +// .assimilate_storage(&mut t) +// .unwrap(); +// let mut ext = sp_io::TestExternalities::new(t); +// ext.execute_with(|| System::set_block_number(1)); +// ext +// } +// } diff --git a/pallets/bulk/src/proof_data.rs b/pallets/bulk/src/proof_data.rs new file mode 100644 index 0000000..5239a0f --- /dev/null +++ b/pallets/bulk/src/proof_data.rs @@ -0,0 +1,29 @@ +// // Copyright (C) Magnet. +// // This file is part of Magnet. + +// // Magnet is free software: you can redistribute it and/or modify +// // it under the terms of the GNU General Public License as published by +// // the Free Software Foundation, either version 3 of the License, or +// // (at your option) any later version. + +// // Magnet is distributed in the hope that it will be useful, +// // but WITHOUT ANY WARRANTY; without even the implied warranty of +// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// // GNU General Public License for more details. + +// // You should have received a copy of the GNU General Public License +// // along with Magnet. If not, see . + +// #[allow(dead_code)] +// pub const ENCODED_PROOFS: &[(&str, &[&str])] = &[ +// ("6b7db61c1bee66952742baa01b5a16efe3b6dbc015db0bbbc0d50349eb86279e",&[ +// "2000000000000000a2e9b53d55170200000001000000000007c09b001b01390202000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d809698000000000000000000000000000000020000004200e8030000809698000000000000000000000000000000020000000407fe65717dad0447d715f660a0a58411de509b42e6efb8375f562f58a554d5860ee96725030000000000000000000000000000020000002100d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000000000000000000000000000000000000200000000001a037449c93a000000", +// "3ed41e5e16056765bc8461851072c9d74259dee8a67b8efa0538928edcd6d3dc677e250771c8f75fa2e6cc8942f06f84", +// "800104801a93e89e41a278828d5caad67eb07073bca1b6cccc49807dbb0476cb27dced8b80c11c1757f8dc26ef0d97db7c703034b9a9001ad382ed9e1ff900f6ac927cea97", +// "80c19c8040ccdfa3ac9b91388fa827571930b3c1e805eb35304412ff42cc6df33ca548ee806bd20dcb3f9e7c87137961ace69ccd74eb92eb3ca730ea10fc736b7f261cbd7380257442a3193ebf64fb8a0019b2d9fc1d97734011eb5a8d2ea414f5ff9a27952b804a061d1ed9340acbb3bfeeb8dd6662b24e093240981c068dafa7044ed379307f80c692d333d8a2af1468e95d1583f2ff2dcde7a5607f9490af0e17dff8a1330cc48005beaee4aeb1f362f62d090d987e09cee98c4bbafd8042732406115019b3b6b2809c048073a3a4c42b9174519d6fdac372683ca85cc3b0cac1a1a9ddaf243b59b1", +// "80ffff805f00b947f4aaec99e6613e9511e9cda57d739ea73a0f2db02c08509a021ac7c180c63e2c041524586654422f91098a9b35e5d0ea88d44c334c4ffa6112e7aa696f80f40031d9a794a6cd84c0d942827d55968e796a5350b0df1d18c410b8903ce59980b8acbbf86a4082fb580470e18b67d0099be087b38e04c862e8d2ad2b4b984f68801c8066816a9737e80e67d14190ebabfe1f77c68975a57867a3e721759387b16f800cb049cc6bc5b79fb79d7da92aadb3c7d5df71e403364142445ab1e212424b7c80c0c6776ecc8630ecc28971e2155751cdeead63676a6d5313771f902a26a528a0805b682132c52908705526057f73ab7fccab4af6d72a9805634dd8d3cc53f130d18012b1a0dc047d3b9d5e8792fb372059a04d44300f0f667a2a14a8777ccfe7fdff80de00eff4d3f779a7434826e0d0f3a1ec71dd4028c42e90718c657e3f1c2ed23680af18bd988a60b703c96993f291b836fe5f6df4ea5a7d36c9d1e65cd44bc1c5a98037af338c5d64d1babf36777405396255681f8bef661a6cd600052dceffba87ab80f4429c1b9ec6915b41ad4f0b3aa4f0fcf7ef80690cab6590739ce7e415f4e966800117ab1066009e6ab3db03ed63038d60ed339fccef41d35668e22d99ba0a7142806bfdbbf0e0bedcb993b65c9cea1e929a56d78a3b7bc53d1b7ca6fc488e2295ee8011cf4cd49d702989ad1e066e4983740ef04216f8945156021e524d97b57e240a", +// "9eaa394eea5630e07c48ae0c9558cef7398f80a506ec64a470c01c9ac42ea190d29a5f5d900256035bd485a0563a428f7d0369809aea767c8a069c1f1759636c9f4672b4483e36cc35d06881c141bd5e4c40d75e505f0e7b9012096b41c4eb3aaf947f6ea4290800004c5f0684a022a34dd8bfa2baaf44f172b71004018004952dfbd3c381037ea2a1ddd3c7252f15de49dd55db9697c7513fd0750e1ca980a22e4b0da2642d6cda7bd1dc00e5fd760e4d6e18684676b9612f3045023088cf80809890dfdabf4da4f92e0ffab00c1cedd68369e0cc3ce4432de6f8abe9220b5380690a57078e6f7e247b25365dad04c1fef7b0d5401cad9087216ca0f33d7788a06c5f09cce9c888469bb1a0dceaa129672ef824599318726f636f636f" +// ]) +// ]; +// #[allow(dead_code)] +// pub const HEAD_DATA:&[&str] = &["00000000000000000000000000000000000000000000000000000000000000000070049f18759406809dc703bba5534cd06df7453974b4599e08d6709db651e0a203170a2e7597b7b7e3d84c05391d139a62b157e78786d8c082f29dcf4c11131400"]; diff --git a/pallets/bulk/src/tests.rs b/pallets/bulk/src/tests.rs new file mode 100644 index 0000000..f12f8c5 --- /dev/null +++ b/pallets/bulk/src/tests.rs @@ -0,0 +1,82 @@ +// // Copyright (C) Magnet. +// // This file is part of Magnet. + +// // Magnet is free software: you can redistribute it and/or modify +// // it under the terms of the GNU General Public License as published by +// // the Free Software Foundation, either version 3 of the License, or +// // (at your option) any later version. + +// // Magnet is distributed in the hope that it will be useful, +// // but WITHOUT ANY WARRANTY; without even the implied warranty of +// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// // GNU General Public License for more details. + +// // You should have received a copy of the GNU General Public License +// // along with Magnet. If not, see . + +// use crate::mock::*; +// use codec::Decode; +// use cumulus_primitives_core::{ParaId, PersistedValidationData}; +// use frame_support::{ +// inherent::{InherentData, ProvideInherent}, +// traits::UnfilteredDispatchable, +// }; +// use frame_system::RawOrigin; +// use parachains_common::AccountId; +// use primitives::HeadData; +// use sp_trie::StorageProof; + +// use crate::proof_data::{ENCODED_PROOFS, HEAD_DATA}; +// #[test] +// fn order_default_value() { +// ExtBuilder::default().build().execute_with(|| { +// assert_eq!(OrderPallet::slot_width(), 2); +// }); +// } + +// #[test] +// fn order_normal_test() { +// ExtBuilder::default().build().execute_with(|| { +// System::set_block_number(1); + +// let encoded = ENCODED_PROOFS[0]; +// let root = hex::decode(encoded.0).unwrap(); +// let relay_chain_state_proof = +// StorageProof::new(encoded.1.iter().map(|s| hex::decode(s).unwrap())); +// let relay_root: cumulus_primitives_core::relay_chain::Hash = +// <[u8; 32]>::try_from(root).unwrap().into(); +// let mut inherent_data = InherentData::default(); +// let head_data = hex::decode(HEAD_DATA[0]).unwrap(); +// let perist_data = PersistedValidationData { +// parent_head: HeadData::decode(&mut head_data.as_slice()).unwrap(), +// relay_parent_number: 29, +// relay_parent_storage_root: relay_root, +// max_pov_size: 5242880 as u32, +// }; +// let order_inherent_data = magnet_primitives_order::OrderInherentData { +// relay_storage_proof: relay_chain_state_proof, +// validation_data: Some(perist_data), +// para_id: ParaId::from(1000), +// sequence_number: 0, +// author_pub: Some(AccountId::from(hex_literal::hex!( +// "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" +// ))), +// }; +// inherent_data +// .put_data(magnet_primitives_order::INHERENT_IDENTIFIER, &order_inherent_data) +// .expect("failed to put VFP inherent"); +// OrderPallet::create_inherent(&inherent_data) +// .expect("got an inherent") +// .dispatch_bypass_filter(RawOrigin::None.into()) +// .expect("dispatch succeeded"); +// OrderPallet::on_finalize(1); +// assert_eq!(OrderPallet::sequence_number(), 1); +// let gas_cost = MockPallet::get_gas_cost(1).unwrap(); +// assert_eq!( +// gas_cost.0, +// AccountId::from(hex_literal::hex!( +// "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" +// )) +// ); +// }); +// } diff --git a/pallets/order/src/weights.rs b/pallets/bulk/src/weights.rs similarity index 100% rename from pallets/order/src/weights.rs rename to pallets/bulk/src/weights.rs diff --git a/pallets/liquidation/Cargo.toml b/pallets/liquidation/Cargo.toml index 0ec4b1a..f43018b 100644 --- a/pallets/liquidation/Cargo.toml +++ b/pallets/liquidation/Cargo.toml @@ -19,7 +19,7 @@ log = {workspace = true, default-features = false} scale-info = { workspace = true, default-features = false, features = ["derive"] } smallvec = { workspace = true } -pallet-order = {path = "../order", default-features = false} +#pallet-order = {path = "../order", default-features = false} pallet-pot = {path = "../pot", default-features = false} mp-system = { path = "../../primitives/system", default-features = false } @@ -58,7 +58,7 @@ std = [ "frame-system/std", "pallet-balances/std", "pallet-assets/std", - "pallet-order/std", +# "pallet-order/std", "pallet-pot/std", "mp-system/std", "pallet-utility/std", diff --git a/pallets/liquidation/src/lib.rs b/pallets/liquidation/src/lib.rs index 2ca4b5a..135ee0e 100644 --- a/pallets/liquidation/src/lib.rs +++ b/pallets/liquidation/src/lib.rs @@ -41,8 +41,17 @@ pub mod pallet { use super::*; use frame_support::pallet_prelude::*; use pallet_balances; - use pallet_order::OrderGasCost; + // use pallet_order::OrderGasCost; use pallet_utility; + pub trait OrderGasCost { + /// Gas consumed by placing an order in a certain block. + /// + /// Parameters: + /// - `block_number`: The block number of para chain. + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, DispatchError>; + } #[pallet::pallet] #[pallet::without_storage_info] @@ -52,7 +61,7 @@ pub mod pallet { #[pallet::config] pub trait Config: frame_system::Config - + pallet_order::Config + // + pallet_order::Config + pallet_pot::Config + pallet_balances::Config + pallet_utility::Config @@ -482,3 +491,15 @@ pub mod pallet { } } } + +impl OrderGasCost for () +where + T: frame_system::Config, + T::AccountId: From<[u8; 32]>, +{ + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError> { + Ok(None) + } +} diff --git a/pallets/order/src/benchmarking.rs b/pallets/order/src/benchmarking.rs deleted file mode 100644 index 545e8a1..0000000 --- a/pallets/order/src/benchmarking.rs +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -//! Benchmarking setup for pallet-order - -use super::*; - -#[allow(unused)] -use crate::Pallet as Order; -use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller}; -use frame_system::RawOrigin; - -benchmarks! { - set_parameter { - let s in 0 .. 100; - let caller: T::AccountId = whitelisted_caller(); - let test_balance = BalanceOf::::from(200000000 as u32); - let test_threshold = BalanceOf::::from(3000000000 as u32); - }: _(RawOrigin::Root, Some(4), Some(test_balance), Some(test_threshold)) - verify { - assert_eq!(SlotWidth::::get(), 4); - assert_eq!(OrderMaxAmount::::get(), test_balance); - assert_eq!(TxPoolThreshold::::get(), test_threshold); - } -} - -impl_benchmark_test_suite!(Order, crate::mock::ExtBuilder::default().build(), crate::mock::Test,); diff --git a/pallets/order/src/lib.rs b/pallets/order/src/lib.rs deleted file mode 100644 index 287bdcb..0000000 --- a/pallets/order/src/lib.rs +++ /dev/null @@ -1,489 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -//! # Order Pallet -//! -//! This pallet implements the recording and query functions of purchasing ondemand core. -//! -//! By obtaining the inherent nature of the block, parsing it out of the validation_data of the relaychain, -//! and querying whether there is an OnDemandOrderPlaced event, obtaining the order account and price from the event, -//! and then writing this record to the blockchain. -//! -//! Provides many query methods for node or other pallets to use, such as querying the gas consumed by placing an order in a certain block, -//! whether the order has been executed, whether the order threshold has been reached, etc. - -#![cfg_attr(not(feature = "std"), no_std)] -use codec::{Decode, MaxEncodedLen}; -use cumulus_pallet_parachain_system::{ - relay_state_snapshot::Error as Relay_Error, RelayChainStateProof, -}; -use frame_support::{ - dispatch::DispatchResultWithPostInfo, dispatch::PostDispatchInfo, pallet_prelude::*, - traits::Currency, -}; -use frame_system::pallet_prelude::*; -use frame_system::{self, EventRecord}; -use magnet_primitives_order::{ - metadata::api::{runtime_types, runtime_types::rococo_runtime as polakdot_runtime}, - well_known_keys::SYSTEM_EVENTS, -}; -pub use pallet::*; -use primitives::Balance; -use primitives::{Id as ParaId, PersistedValidationData}; -use sp_runtime::sp_std::{prelude::*, vec}; -use sp_runtime::{traits::Member, RuntimeAppPublic}; -pub mod weights; -use sp_core::crypto::ByteArray; -use weights::WeightInfo; -#[cfg(test)] -mod mock; - -#[cfg(test)] -mod tests; - -#[cfg(any(test, feature = "runtime-benchmarks"))] -mod benchmarking; -mod proof_data; - -type BalanceOf = - <::Currency as Currency<::AccountId>>::Balance; - -/// ondemand order information. -#[derive(Encode, Decode, Default, Clone, Copy, TypeInfo, MaxEncodedLen, Debug)] -pub struct Order { - /// The number used to record the order, incremented each time. - pub sequence_number: u64, - // relaychain_block_hash:Hash, - // relaychain_block_height:u32, - /// Account for placing order. - pub orderer: AuthorityId, - /// Order price. - pub price: Balance, - /// Whether the order was executed. - pub executed: bool, -} -#[frame_support::pallet] -pub mod pallet { - use super::*; - - /// Configure the pallet by specifying the parameters and types on which it depends. - #[pallet::config] - pub trait Config: frame_system::Config { - /// Because this pallet emits events, it depends on the runtime's definition of an event. - type RuntimeEvent: From> + IsType<::RuntimeEvent>; - - type Currency: Currency; - - type AuthorityId: Member - + Parameter - + RuntimeAppPublic - + MaybeSerializeDeserialize - + MaxEncodedLen - + for<'a> TryFrom<&'a [u8]>; - - type UpdateOrigin: EnsureOrigin; - - type WeightInfo: WeightInfo; - /// The default value of w. - #[pallet::constant] - type SlotWidth: Get; - - /// The max value of place order. - #[pallet::constant] - type OrderMaxAmount: Get>; - - /// The gas threshold required to place an order. - #[pallet::constant] - type TxPoolThreshold: Get>; - } - - #[pallet::pallet] - pub struct Pallet(PhantomData); - - /// Sequence number,number of each order. - #[pallet::storage] - #[pallet::getter(fn sequence_number)] - pub type SequenceNumber = StorageValue<_, u64, ValueQuery>; - - /// Record the relaychain block height of the latest order - #[pallet::storage] - #[pallet::getter(fn current_relay_height)] - pub type CurrentRelayHeight = StorageValue<_, u32, ValueQuery>; - - #[pallet::type_value] - pub fn SlotWidthOnEmpty() -> u32 { - T::SlotWidth::get() - } - #[pallet::type_value] - pub fn OrderMaxAmountOnEmpty() -> BalanceOf { - T::OrderMaxAmount::get() - } - #[pallet::type_value] - pub fn TxPoolThresholdOnEmpty() -> BalanceOf { - T::TxPoolThreshold::get() - } - - /// The order interval is 2^slotwidth. - #[pallet::storage] - #[pallet::getter(fn slot_width)] - pub(super) type SlotWidth = StorageValue<_, u32, ValueQuery, SlotWidthOnEmpty>; - - /// The maximum price the user is willing to pay when placing an order. - #[pallet::storage] - #[pallet::getter(fn order_max_amount)] - pub(super) type OrderMaxAmount = - StorageValue<_, BalanceOf, ValueQuery, OrderMaxAmountOnEmpty>; - - /// Gas threshold that triggers order placement. - #[pallet::storage] - #[pallet::getter(fn txpool_threshold)] - pub(super) type TxPoolThreshold = - StorageValue<_, BalanceOf, ValueQuery, TxPoolThresholdOnEmpty>; - - /// Order Information Map. - #[pallet::storage] - #[pallet::getter(fn order_map)] - pub type OrderMap = - StorageMap<_, Twox64Concat, u64, Order, OptionQuery>; - - /// Convert block height to sequence number. - #[pallet::storage] - #[pallet::getter(fn block_2_sequence)] - pub type Block2Sequence = - StorageMap<_, Twox64Concat, BlockNumberFor, u64, OptionQuery>; - - #[pallet::event] - #[pallet::generate_deposit(pub(super) fn deposit_event)] - pub enum Event { - /// Create order event. - OrderCreate { sequence_number: u64, orderer: T::AuthorityId }, - } - - #[pallet::error] - pub enum Error { - /// Error reading data. - FailedReading, - /// Order already exists. - OrderExist, - /// Failed to create order. - CreateOrderFail, - /// Invalid Validation data. - InvalidValidation, - /// Incorrect sequence number - WrongSequenceNumber, - } - - #[pallet::hooks] - impl Hooks> for Pallet { - /// Called at the end of each block to check whether an order has been placed. - /// If so, modify the execution status and increase the sequencer number. - fn on_finalize(block_number: BlockNumberFor) { - let old_sequence_number = SequenceNumber::::get(); - let order = OrderMap::::get(old_sequence_number); - if let Some(t_order) = order { - let orderer = t_order.orderer; - OrderMap::::remove(old_sequence_number); - OrderMap::::insert( - old_sequence_number, - Order:: { - sequence_number: old_sequence_number, - orderer: orderer.clone(), - price: t_order.price, - executed: true, - }, - ); - SequenceNumber::::set(old_sequence_number + 1); - Block2Sequence::::insert(block_number, old_sequence_number); - Self::deposit_event(Event::OrderCreate { - sequence_number: old_sequence_number, - orderer, - }); - } - } - } - - #[pallet::inherent] - impl ProvideInherent for Pallet { - type Call = Call; - type Error = MakeFatalError<()>; - - const INHERENT_IDENTIFIER: InherentIdentifier = - magnet_primitives_order::INHERENT_IDENTIFIER; - fn create_inherent(data: &InherentData) -> Option { - let data: magnet_primitives_order::OrderInherentData = data - .get_data(&magnet_primitives_order::INHERENT_IDENTIFIER) - .ok() - .flatten() - .expect("there is not data to be posted; qed"); - if data.validation_data.is_some() { - Some(Call::create_order { data }) - } else { - None - } - } - fn is_inherent(call: &Self::Call) -> bool { - matches!(call, Call::create_order { .. }) - } - } - - #[pallet::call] - impl Pallet { - /// Create an order, which is called by the pallet. - /// Users cannot actively call this function. - /// Obtain order information by parsing inherited data. - /// - /// Parameters: - /// - `data`: The inherent data. - #[pallet::call_index(0)] - #[pallet::weight((0, DispatchClass::Mandatory))] - pub fn create_order( - origin: OriginFor, - data: magnet_primitives_order::OrderInherentData, - ) -> DispatchResultWithPostInfo { - ensure_none(origin)?; - - let magnet_primitives_order::OrderInherentData { - relay_storage_proof, - validation_data, - sequence_number, - para_id, - author_pub, - } = data; - let total_weight = match validation_data { - Some(validation_data) => { - let (_, price) = Self::check_order_proof( - relay_storage_proof, - validation_data.clone(), - author_pub.clone(), - para_id, - ) - .ok_or(Error::::CreateOrderFail)?; - let old_sequence_number = SequenceNumber::::get(); - let order = OrderMap::::get(old_sequence_number); - if sequence_number != old_sequence_number { - // In the worst-case scenario, if there are multiple orders at the same - // time, it may be due to system issues or it may be due to human - // intervention. Currently, we only support running one order at the same - // time Err(Error::::WrongSequenceNumber)?; - // Continuing to produce blocks, recording errors - log::info!("========WrongSequenceNumber:{:?}========", sequence_number); - } - if order.is_none() { - OrderMap::::insert( - old_sequence_number, - Order:: { - sequence_number: old_sequence_number, - orderer: author_pub.unwrap(), - price, - executed: false, - }, - ); - CurrentRelayHeight::::set(validation_data.relay_parent_number); - } else { - Err(Error::::OrderExist)?; - } - T::DbWeight::get().reads_writes(2, 1) - }, - None => T::DbWeight::get().reads_writes(0, 0), - }; - Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) - } - - /// Order pallet parameter settings. - /// It can only be called by accounts with sudo privileges or authorized organization members. - /// - /// Parameters: - /// - `slot_width`: The order interval is 2^slotwidth.. - /// - `order_max_amount`: The maximum price the user is willing to pay when placing an order. - /// - `tx_pool_threshold`: Gas threshold that triggers order placement. - #[pallet::call_index(1)] - #[pallet::weight(T::WeightInfo::set_parameter(*slot_width))] - pub fn set_parameter( - origin: OriginFor, - slot_width: Option, - order_max_amount: Option>, - tx_pool_threshold: Option>, - ) -> DispatchResultWithPostInfo { - T::UpdateOrigin::ensure_origin(origin)?; - - if let Some(t_slot_width) = slot_width { - >::put(t_slot_width); - } - if let Some(t_order_max_amount) = order_max_amount { - >::put(t_order_max_amount); - } - if let Some(t_tx_pool_threshold) = tx_pool_threshold { - >::put(t_tx_pool_threshold); - } - Ok(().into()) - } - } -} - -impl Pallet { - /// Obtain the order account and price from the relaychain's validation. - /// - /// Parameters: - /// - `relay_storage_proof`: The proof of relay chain storage. - ///- `validation_data`: The validation data. - /// - `para_id`: ID of parachain. - fn get_author_from_proof( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - para_id: ParaId, - ) -> Option<(T::AuthorityId, Balance)> { - let relay_storage_root = validation_data.relay_parent_storage_root; - let relay_storage_rooted_proof = - RelayChainStateProof::new(para_id, relay_storage_root, relay_storage_proof) - .expect("Invalid relay chain state proof"); - let head_data = relay_storage_rooted_proof - .read_entry::>>>( - SYSTEM_EVENTS, - None, - ) - .ok()?; - let v_price: Vec = head_data - .iter() - .filter_map(|item| { - if let polakdot_runtime::RuntimeEvent::OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event::OnDemandOrderPlaced{ - para_id: pid, - spot_price: sprice, - }) = &item.event - { - if pid.encode() == para_id.encode() { - Some(*sprice) - } else { - None - } - } else { - None - } - }) - .collect(); - let orderer: Vec<(T::AuthorityId, u128)> = v_price - .iter() - .filter_map(|item| { - let mut orderer = None; - let _: Vec<_> = head_data - .iter() - .filter_map(|event| { - if let polakdot_runtime::RuntimeEvent::Balances( - runtime_types::pallet_balances::pallet::Event::Withdraw { - who: ref order, - amount: eprice, - }, - ) = event.event - { - if eprice == *item { - orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { - Ok(order) => Some((order, eprice)), - Err(_) => None, - }; - Some(()) - } else { - None - } - } else { - None - } - }) - .collect(); - orderer - }) - .collect(); - if orderer.len() > 0 { - Some(orderer[0].clone()) - } else { - None - } - } - - /// Check whether the account is in the validation of relaychain. - /// - /// Parameters: - /// - `relay_storage_proof`: The proof of relay chain storage. - /// - `validation_data`: The validation data. - /// - `author_pub`: Account. - /// - `para_id`: ID of parachain. - fn check_order_proof( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - author_pub: Option, - para_id: ParaId, - ) -> Option<(T::AuthorityId, Balance)> { - let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); - match op_author { - Some((author, spot_price)) => { - if author_pub == Some(author.clone()) { - Some((author, spot_price)) - } else { - None - } - }, - None => None, - } - } - - /// Check whether there is an order event in the validation of relaychain. - /// - /// Parameters: - /// - `relay_storage_proof`: The proof of relay chain storage. - /// - `validation_data`: The validation data. - /// - `para_id`: ID of parachain. - pub fn order_placed( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - para_id: ParaId, - ) -> Option { - let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); - match op_author { - Some((author, _)) => Some(author), - None => None, - } - } - - /// Whether the gas threshold for placing an order has been reached. - /// - /// Parameters: - /// - `gas_balance`: The total gas. - pub fn reach_txpool_threshold(gas_balance: BalanceOf) -> bool { - let txpool_threshold = TxPoolThreshold::::get(); - gas_balance > txpool_threshold - } - - /// Whether the order with the specified sequence number is executed. - /// - /// Parameters: - /// - `sequence_number`: The sequence number. - pub fn order_executed(sequence_number: u64) -> bool { - let order_map = OrderMap::::get(sequence_number); - match order_map { - Some(order) => order.executed, - None => false, - } - } -} - -pub trait OrderGasCost { - /// Gas consumed by placing an order in a certain block. - /// - /// Parameters: - /// - `block_number`: The block number of para chain. - fn gas_cost( - block_number: BlockNumberFor, - ) -> Result, DispatchError>; -} diff --git a/pallets/order/src/mock.rs b/pallets/order/src/mock.rs deleted file mode 100644 index ff681f3..0000000 --- a/pallets/order/src/mock.rs +++ /dev/null @@ -1,183 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -use crate::{self as order_pallet, OrderGasCost}; -use codec::Encode; -pub use frame_support::{ - construct_runtime, derive_impl, parameter_types, - traits::{Everything, Hooks}, -}; -use frame_system as system; -use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; -pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; -use sp_core::{crypto::AccountId32, H256}; -use sp_runtime::{ - traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, - BuildStorage, MultiSignature, -}; - -type Block = frame_system::mocking::MockBlock; -type Signature = MultiSignature; -type AccountId = <::Signer as IdentifyAccount>::AccountId; -type Balance = u128; -// Configure a mock runtime to test the pallet. -construct_runtime!( - pub enum Test - { - System: frame_system::{Pallet, Call, Config, Storage, Event}, - Balances: pallet_balances::{Pallet, Call, Event}, - OrderPallet: order_pallet::{Pallet, Call, Storage, Event}, - MockPallet: mock_pallet, - } -); - -parameter_types! { - pub const BlockHashCount: u64 = 250; - pub const SS58Prefix: u8 = 42; -} - -#[derive_impl(frame_system::config_preludes::ParaChainDefaultConfig as frame_system::DefaultConfig)] -impl system::Config for Test { - type BaseCallFilter = Everything; - type BlockWeights = (); - type BlockLength = (); - type DbWeight = (); - type RuntimeOrigin = RuntimeOrigin; - type RuntimeCall = RuntimeCall; - type Nonce = u64; - type Hash = H256; - type Hashing = BlakeTwo256; - type AccountId = AccountId32; - type Lookup = IdentityLookup; - type Block = Block; - type RuntimeEvent = RuntimeEvent; - type BlockHashCount = BlockHashCount; - type Version = (); - type PalletInfo = PalletInfo; - type AccountData = pallet_balances::AccountData; - type OnNewAccount = (); - type OnKilledAccount = (); - type SystemWeightInfo = (); - type SS58Prefix = SS58Prefix; - type OnSetCode = (); - type MaxConsumers = frame_support::traits::ConstU32<16>; -} -parameter_types! { - pub const ExistentialDeposit: u64 = 5; -} -impl pallet_balances::Config for Test { - type MaxLocks = (); - type MaxReserves = (); - type ReserveIdentifier = [u8; 8]; - type Balance = u128; - type RuntimeEvent = RuntimeEvent; - type DustRemoval = (); - type ExistentialDeposit = ExistentialDeposit; - type AccountStore = System; - type WeightInfo = (); - type FreezeIdentifier = (); - type MaxFreezes = (); - type RuntimeHoldReason = (); - type RuntimeFreezeReason = (); -} -parameter_types! { - pub const SlotWidth: u32 = 2; - pub const OrderMaxAmount:Balance = 200000000; - pub const TxPoolThreshold:Balance = 3000000000; -} -impl crate::Config for Test { - type RuntimeEvent = RuntimeEvent; - type AuthorityId = AuraId; - type UpdateOrigin = EnsureRoot; - type Currency = Balances; - type OrderMaxAmount = OrderMaxAmount; - type SlotWidth = SlotWidth; - type TxPoolThreshold = TxPoolThreshold; - type WeightInfo = (); -} -pub struct OrderGasCostHandler(); - -impl OrderGasCost for OrderGasCostHandler -where - T: crate::Config, - T::AccountId: From<[u8; 32]>, -{ - fn gas_cost( - block_number: BlockNumberFor, - ) -> Result, sp_runtime::DispatchError> { - let sequece_number = >::block_2_sequence(block_number); - if sequece_number.is_none() { - return Ok(None); - } - let order = >::order_map( - sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, - ) - .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; - let mut r = [0u8; 32]; - r.copy_from_slice(order.orderer.encode().as_slice()); - let account = T::AccountId::try_from(r) - .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; - Ok(Some((account, order.price))) - } -} - -#[frame_support::pallet] -pub mod mock_pallet { - use super::*; - #[pallet::config] - pub trait Config: frame_system::Config { - type OrderGasCost: OrderGasCost; - } - - #[pallet::call] - impl Pallet {} - - #[pallet::pallet] - #[pallet::without_storage_info] - pub struct Pallet(_); - - impl Pallet { - pub fn get_gas_cost(block_number: BlockNumberFor) -> Option<(T::AccountId, Balance)> { - T::OrderGasCost::gas_cost(block_number).unwrap() - } - } -} - -impl mock_pallet::Config for Test { - type OrderGasCost = OrderGasCostHandler; -} -pub struct ExtBuilder { - balances: Vec<(AccountId32, u128)>, -} - -impl Default for ExtBuilder { - fn default() -> Self { - Self { balances: Default::default() } - } -} - -impl ExtBuilder { - pub fn build(self) -> sp_io::TestExternalities { - // Build genesis storage according to the mock runtime. - let mut t = frame_system::GenesisConfig::::default().build_storage().unwrap(); - pallet_balances::GenesisConfig:: { balances: self.balances } - .assimilate_storage(&mut t) - .unwrap(); - let mut ext = sp_io::TestExternalities::new(t); - ext.execute_with(|| System::set_block_number(1)); - ext - } -} diff --git a/pallets/order/src/proof_data.rs b/pallets/order/src/proof_data.rs deleted file mode 100644 index 4777a2a..0000000 --- a/pallets/order/src/proof_data.rs +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -#[allow(dead_code)] -pub const ENCODED_PROOFS: &[(&str, &[&str])] = &[ - ("6b7db61c1bee66952742baa01b5a16efe3b6dbc015db0bbbc0d50349eb86279e",&[ -"2000000000000000a2e9b53d55170200000001000000000007c09b001b01390202000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d809698000000000000000000000000000000020000004200e8030000809698000000000000000000000000000000020000000407fe65717dad0447d715f660a0a58411de509b42e6efb8375f562f58a554d5860ee96725030000000000000000000000000000020000002100d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000000000000000000000000000000000000200000000001a037449c93a000000", -"3ed41e5e16056765bc8461851072c9d74259dee8a67b8efa0538928edcd6d3dc677e250771c8f75fa2e6cc8942f06f84", -"800104801a93e89e41a278828d5caad67eb07073bca1b6cccc49807dbb0476cb27dced8b80c11c1757f8dc26ef0d97db7c703034b9a9001ad382ed9e1ff900f6ac927cea97", -"80c19c8040ccdfa3ac9b91388fa827571930b3c1e805eb35304412ff42cc6df33ca548ee806bd20dcb3f9e7c87137961ace69ccd74eb92eb3ca730ea10fc736b7f261cbd7380257442a3193ebf64fb8a0019b2d9fc1d97734011eb5a8d2ea414f5ff9a27952b804a061d1ed9340acbb3bfeeb8dd6662b24e093240981c068dafa7044ed379307f80c692d333d8a2af1468e95d1583f2ff2dcde7a5607f9490af0e17dff8a1330cc48005beaee4aeb1f362f62d090d987e09cee98c4bbafd8042732406115019b3b6b2809c048073a3a4c42b9174519d6fdac372683ca85cc3b0cac1a1a9ddaf243b59b1", -"80ffff805f00b947f4aaec99e6613e9511e9cda57d739ea73a0f2db02c08509a021ac7c180c63e2c041524586654422f91098a9b35e5d0ea88d44c334c4ffa6112e7aa696f80f40031d9a794a6cd84c0d942827d55968e796a5350b0df1d18c410b8903ce59980b8acbbf86a4082fb580470e18b67d0099be087b38e04c862e8d2ad2b4b984f68801c8066816a9737e80e67d14190ebabfe1f77c68975a57867a3e721759387b16f800cb049cc6bc5b79fb79d7da92aadb3c7d5df71e403364142445ab1e212424b7c80c0c6776ecc8630ecc28971e2155751cdeead63676a6d5313771f902a26a528a0805b682132c52908705526057f73ab7fccab4af6d72a9805634dd8d3cc53f130d18012b1a0dc047d3b9d5e8792fb372059a04d44300f0f667a2a14a8777ccfe7fdff80de00eff4d3f779a7434826e0d0f3a1ec71dd4028c42e90718c657e3f1c2ed23680af18bd988a60b703c96993f291b836fe5f6df4ea5a7d36c9d1e65cd44bc1c5a98037af338c5d64d1babf36777405396255681f8bef661a6cd600052dceffba87ab80f4429c1b9ec6915b41ad4f0b3aa4f0fcf7ef80690cab6590739ce7e415f4e966800117ab1066009e6ab3db03ed63038d60ed339fccef41d35668e22d99ba0a7142806bfdbbf0e0bedcb993b65c9cea1e929a56d78a3b7bc53d1b7ca6fc488e2295ee8011cf4cd49d702989ad1e066e4983740ef04216f8945156021e524d97b57e240a", -"9eaa394eea5630e07c48ae0c9558cef7398f80a506ec64a470c01c9ac42ea190d29a5f5d900256035bd485a0563a428f7d0369809aea767c8a069c1f1759636c9f4672b4483e36cc35d06881c141bd5e4c40d75e505f0e7b9012096b41c4eb3aaf947f6ea4290800004c5f0684a022a34dd8bfa2baaf44f172b71004018004952dfbd3c381037ea2a1ddd3c7252f15de49dd55db9697c7513fd0750e1ca980a22e4b0da2642d6cda7bd1dc00e5fd760e4d6e18684676b9612f3045023088cf80809890dfdabf4da4f92e0ffab00c1cedd68369e0cc3ce4432de6f8abe9220b5380690a57078e6f7e247b25365dad04c1fef7b0d5401cad9087216ca0f33d7788a06c5f09cce9c888469bb1a0dceaa129672ef824599318726f636f636f" -]) -]; -#[allow(dead_code)] -pub const HEAD_DATA:&[&str] = &["00000000000000000000000000000000000000000000000000000000000000000070049f18759406809dc703bba5534cd06df7453974b4599e08d6709db651e0a203170a2e7597b7b7e3d84c05391d139a62b157e78786d8c082f29dcf4c11131400"]; diff --git a/pallets/order/src/tests.rs b/pallets/order/src/tests.rs deleted file mode 100644 index 793f8e1..0000000 --- a/pallets/order/src/tests.rs +++ /dev/null @@ -1,82 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -use crate::mock::*; -use codec::Decode; -use cumulus_primitives_core::{ParaId, PersistedValidationData}; -use frame_support::{ - inherent::{InherentData, ProvideInherent}, - traits::UnfilteredDispatchable, -}; -use frame_system::RawOrigin; -use parachains_common::AccountId; -use primitives::HeadData; -use sp_trie::StorageProof; - -use crate::proof_data::{ENCODED_PROOFS, HEAD_DATA}; -#[test] -fn order_default_value() { - ExtBuilder::default().build().execute_with(|| { - assert_eq!(OrderPallet::slot_width(), 2); - }); -} - -#[test] -fn order_normal_test() { - ExtBuilder::default().build().execute_with(|| { - System::set_block_number(1); - - let encoded = ENCODED_PROOFS[0]; - let root = hex::decode(encoded.0).unwrap(); - let relay_chain_state_proof = - StorageProof::new(encoded.1.iter().map(|s| hex::decode(s).unwrap())); - let relay_root: cumulus_primitives_core::relay_chain::Hash = - <[u8; 32]>::try_from(root).unwrap().into(); - let mut inherent_data = InherentData::default(); - let head_data = hex::decode(HEAD_DATA[0]).unwrap(); - let perist_data = PersistedValidationData { - parent_head: HeadData::decode(&mut head_data.as_slice()).unwrap(), - relay_parent_number: 29, - relay_parent_storage_root: relay_root, - max_pov_size: 5242880 as u32, - }; - let order_inherent_data = magnet_primitives_order::OrderInherentData { - relay_storage_proof: relay_chain_state_proof, - validation_data: Some(perist_data), - para_id: ParaId::from(1000), - sequence_number: 0, - author_pub: Some(AccountId::from(hex_literal::hex!( - "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" - ))), - }; - inherent_data - .put_data(magnet_primitives_order::INHERENT_IDENTIFIER, &order_inherent_data) - .expect("failed to put VFP inherent"); - OrderPallet::create_inherent(&inherent_data) - .expect("got an inherent") - .dispatch_bypass_filter(RawOrigin::None.into()) - .expect("dispatch succeeded"); - OrderPallet::on_finalize(1); - assert_eq!(OrderPallet::sequence_number(), 1); - let gas_cost = MockPallet::get_gas_cost(1).unwrap(); - assert_eq!( - gas_cost.0, - AccountId::from(hex_literal::hex!( - "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" - )) - ); - }); -} diff --git a/primitives/order/Cargo.toml b/primitives/coretime/bulk/Cargo.toml similarity index 94% rename from primitives/order/Cargo.toml rename to primitives/coretime/bulk/Cargo.toml index bf0256d..b1719ce 100644 --- a/primitives/order/Cargo.toml +++ b/primitives/coretime/bulk/Cargo.toml @@ -1,7 +1,7 @@ [package] -name = "magnet-primitives-order" +name = "mp-coretime-bulk" authors.workspace = true -description = "Runtime API definition of magnet-primitives-order" +description = "primitives related to bulk inherent" edition.workspace = true license = "Unlicense" version = "0.2.0" diff --git a/primitives/coretime/bulk/src/inherent_client.rs b/primitives/coretime/bulk/src/inherent_client.rs new file mode 100644 index 0000000..72fb223 --- /dev/null +++ b/primitives/coretime/bulk/src/inherent_client.rs @@ -0,0 +1,89 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +use crate::well_known_keys::broker_regions; +use cumulus_primitives_core::relay_chain::Balance; +use pallet_broker::RegionId; +use sp_consensus_aura::sr25519::AuthorityId; +use { + crate::BulkInherentData, + cumulus_primitives_core::{ParaId, PersistedValidationData}, + cumulus_relay_chain_interface::{PHash, RelayChainInterface}, +}; + +/// Collect the relevant coretime para chain state in form of a proof +/// for putting it into the bulk inherent. +// async fn collect_coretime_parachain_storage_proof( +// region_id: RegionId, +// ) -> Option { +// let mut relevant_keys = Vec::new(); +// //Broker Regions +// relevant_keys.push(broker_regions(region_id)); + +// // let relay_storage_proof = relay_chain_interface.prove_read(relay_parent, &relevant_keys).await; +// // match relay_storage_proof { +// // Ok(proof) => Some(proof), +// // Err(err) => { +// // log::info!("RelayChainError:{:?}", err); +// // None +// // }, +// // } +// None +// } + +impl BulkInherentData { + /// Create the [`BulkInherentData`] at the given `relay_parent`. + /// + /// Returns `None` if the creation failed. + pub async fn create_at( + // relay_parent: PHash, + // author_pub: &AuthorityId, + // region_id: RegionId, + storage_proof: &sp_trie::StorageProof, + storage_root: PHash, + region_id: RegionId, + ) -> Option { + // let storage_proof = collect_coretime_parachain_storage_proof(region_id).await?; + + Some(BulkInherentData { + storage_proof: storage_proof.clone(), + storage_root, + region_id, + // purchaser: author_pub.clone(), + // price: 0, + // duration: 0, + }) + } +} + +// Implementation of InherentDataProvider +#[async_trait::async_trait] +impl sp_inherents::InherentDataProvider for BulkInherentData { + async fn provide_inherent_data( + &self, + inherent_data: &mut sp_inherents::InherentData, + ) -> Result<(), sp_inherents::Error> { + inherent_data.put_data(crate::INHERENT_IDENTIFIER, &self) + } + + async fn try_handle_error( + &self, + _: &sp_inherents::InherentIdentifier, + _: &[u8], + ) -> Option> { + None + } +} diff --git a/primitives/coretime/bulk/src/lib.rs b/primitives/coretime/bulk/src/lib.rs new file mode 100644 index 0000000..4e82b34 --- /dev/null +++ b/primitives/coretime/bulk/src/lib.rs @@ -0,0 +1,65 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! # Order Inherent Primitives +//! +//! This crate defines those primitives that should be taken into account when building +//! the order pallet inherent +//! +#![cfg_attr(not(feature = "std"), no_std)] +use cumulus_primitives_core::{ + relay_chain::BlockNumber as RelayBlockNumber, relay_chain::Hash as PHash, ParaId, + PersistedValidationData, +}; +use sp_core::H256; +use sp_runtime::sp_std::vec::Vec; +use sp_runtime::traits::MaybeDisplay; +#[cfg(feature = "std")] +pub mod inherent_client; +pub mod well_known_keys; +use codec::{Codec, Decode, Encode}; +use pallet_broker::RegionId; +use {scale_info::TypeInfo, sp_inherents::InherentIdentifier}; + +#[derive(Encode, Decode, sp_core::RuntimeDebug, Clone, PartialEq, TypeInfo)] +pub struct BulkInherentData { + /// Proof of coretime parachain storage. + pub storage_proof: sp_trie::StorageProof, + /// Root of coretime parachain storage. + pub storage_root: PHash, + pub region_id: RegionId, +} + +#[derive(Clone)] +pub struct BulkMemRecord { + /// Proof of coretime parachain storage. + pub storage_proof: sp_trie::StorageProof, + /// Root of coretime parachain storage. + pub storage_root: PHash, + pub region_id: RegionId, +} +// Identifier of the order inherent +pub const INHERENT_IDENTIFIER: InherentIdentifier = *b"bulkihrt"; + +// sp_api::decl_runtime_apis! { +// #[api_version(2)] +// pub trait BulkRuntimeApi where +// Balance: Codec + MaybeDisplay, +// AuthorityId:Codec +// { + +// } +// } diff --git a/primitives/coretime/bulk/src/well_known_keys.rs b/primitives/coretime/bulk/src/well_known_keys.rs new file mode 100644 index 0000000..952c190 --- /dev/null +++ b/primitives/coretime/bulk/src/well_known_keys.rs @@ -0,0 +1,43 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! Keys of well known. +#![cfg_attr(not(feature = "std"), no_std)] + +use cumulus_primitives_core::relay_chain::CoreIndex; +use { + cumulus_primitives_core::ParaId, + pallet_broker::RegionId, + sp_core::Encode, + sp_io::hashing::{blake2_128, twox_256, twox_64}, + sp_std::vec::Vec, +}; + +// XXHash a String:Broker Regions +pub const REGIONS: &[u8] = + &hex_literal::hex!["4dcb50595177a3177648411a42aca0f53dc63b0b76ffd6f80704a090da6f8719"]; + +/// Broker Regions +pub fn broker_regions(region_id: RegionId) -> Vec { + region_id.using_encoded(|region_id_bytes: &[u8]| { + REGIONS + .iter() + .chain(blake2_128(region_id_bytes).iter()) + .chain(region_id_bytes.iter()) + .cloned() + .collect() + }) +} diff --git a/primitives/coretime/common/Cargo.toml b/primitives/coretime/common/Cargo.toml new file mode 100644 index 0000000..23822f4 --- /dev/null +++ b/primitives/coretime/common/Cargo.toml @@ -0,0 +1,53 @@ +[package] +name = "mp-coretime-common" +authors.workspace = true +description = "primitives related to coretime" +edition.workspace = true +license = "Unlicense" +version = "0.2.0" + +[dependencies] +log = { workspace = true, default-features = false } +hex-literal = { workspace = true } +async-trait = { workspace = true, optional = true } +scale-info = { workspace = true, default-features = false } +codec = { package = "parity-scale-codec", workspace = true, default-features = false, features = [ + "derive","full", "bit-vec" +] } +sp-api = { workspace = true, default-features = false} +sp-runtime = { workspace = true, default-features = false } +sp-inherents = { workspace = true, default-features = false } +sp-core = { workspace = true, default-features = false } +sp-trie = { workspace = true, default-features = false } +cumulus-relay-chain-interface = { workspace = true, default-features = false , optional = true } +sp-state-machine = { workspace = true, default-features = false } +cumulus-primitives-core = { workspace = true , default-features = false } +sp-consensus-aura= { workspace = true, default-features = false } +sp-io ={ workspace = true, default-features = false } +sp-std = { workspace = true, default-features = false } +sp-weights = { workspace = true, default-features = false } +sp-session = { workspace = true, default-features = false } +sp-consensus-grandpa = { workspace = true, default-features = false } + + +[features] +default = [ "std" ] +std = [ + "async-trait", + "codec/std", + "sp-api/std", + "sp-runtime/std", + "scale-info/std", + "sp-inherents/std", + "sp-core/std", + "sp-trie/std", + "cumulus-relay-chain-interface", + "sp-state-machine/std", + "cumulus-primitives-core/std", + "sp-consensus-aura/std", + "sp-io/std", + "sp-std/std", + "sp-weights/std", + "sp-session/std", + "sp-consensus-grandpa/std", +] \ No newline at end of file diff --git a/primitives/coretime/common/src/lib.rs b/primitives/coretime/common/src/lib.rs new file mode 100644 index 0000000..eea99a8 --- /dev/null +++ b/primitives/coretime/common/src/lib.rs @@ -0,0 +1,30 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! # Order Inherent Primitives +//! +//! This crate defines those primitives that should be taken into account when building +//! the order pallet inherent +//! +#![cfg_attr(not(feature = "std"), no_std)] +use cumulus_primitives_core::{ + relay_chain::BlockNumber as RelayBlockNumber, relay_chain::Hash as PHash, ParaId, + PersistedValidationData, +}; +use sp_core::H256; +use sp_runtime::sp_std::vec::Vec; +use sp_runtime::traits::MaybeDisplay; +pub mod well_known_keys; diff --git a/client/consensus/aura/src/lib.rs b/primitives/coretime/common/src/well_known_keys.rs similarity index 51% rename from client/consensus/aura/src/lib.rs rename to primitives/coretime/common/src/well_known_keys.rs index e71099a..269454c 100644 --- a/client/consensus/aura/src/lib.rs +++ b/primitives/coretime/common/src/well_known_keys.rs @@ -14,30 +14,28 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -const LOG_TARGET: &str = "on_demand_aura::magnet"; - -use sp_core::crypto::{ByteArray, Pair}; -use sp_keystore::KeystorePtr; - -type AuthorityId

=

::Public; - -pub async fn order_slot( - idx: u32, - authorities: &[AuthorityId

], - keystore: &KeystorePtr, -) -> Option { - if authorities.is_empty() { - return None; - } - - let expected_author = authorities.get(idx as usize).expect( - "authorities not empty; index constrained to list length;this is a valid index; qed", - ); - - if keystore.has_keys(&[(expected_author.to_raw_vec(), sp_application_crypto::key_types::AURA)]) - { - Some(expected_author.clone()) - } else { - None - } +//! Keys of well known. +#![cfg_attr(not(feature = "std"), no_std)] + +use cumulus_primitives_core::relay_chain::CoreIndex; +use { + cumulus_primitives_core::ParaId, + sp_core::Encode, + sp_io::hashing::{blake2_128, twox_256, twox_64}, + sp_std::vec::Vec, +}; + +pub const PARAS_PARA_LIFECYCLES: &[u8] = + &hex_literal::hex!["cd710b30bd2eab0352ddcc26417aa194281e0bfde17b36573208a06cb5cfba6b"]; + +// Paras pallet storage ParaLifecycles +pub fn paras_para_lifecycles(para_id: ParaId) -> Vec { + para_id.using_encoded(|para_id: &[u8]| { + PARAS_PARA_LIFECYCLES + .iter() + .chain(twox_64(para_id).iter()) + .chain(para_id.iter()) + .cloned() + .collect() + }) } diff --git a/primitives/order/src/inherent_client.rs b/primitives/order/src/inherent_client.rs deleted file mode 100644 index 84dd5d7..0000000 --- a/primitives/order/src/inherent_client.rs +++ /dev/null @@ -1,89 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -use sp_consensus_aura::sr25519::AuthorityId; -use { - crate::OrderInherentData, - cumulus_primitives_core::{ParaId, PersistedValidationData}, - cumulus_relay_chain_interface::{PHash, RelayChainInterface}, -}; - -/// Collect the relevant relay chain state in form of a proof -/// for putting it into the order inherent. -async fn collect_relay_storage_proof( - relay_chain_interface: &impl RelayChainInterface, - relay_parent: PHash, -) -> Option { - let mut relevant_keys = Vec::new(); - //System Events - relevant_keys.push( - hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7"] - .to_vec(), - ); - - let relay_storage_proof = relay_chain_interface.prove_read(relay_parent, &relevant_keys).await; - match relay_storage_proof { - Ok(proof) => Some(proof), - Err(err) => { - log::info!("RelayChainError:{:?}", err); - None - }, - } -} - -impl OrderInherentData { - /// Create the [`OrderInherentData`] at the given `relay_parent`. - /// - /// Returns `None` if the creation failed. - pub async fn create_at( - relay_parent: PHash, - relay_chain_interface: &impl RelayChainInterface, - validation_data: &Option, - para_id: ParaId, - sequence_number: u64, - author_pub: &Option, - ) -> Option> { - let relay_storage_proof = - collect_relay_storage_proof(relay_chain_interface, relay_parent).await?; - - Some(OrderInherentData { - relay_storage_proof: relay_storage_proof.clone(), - validation_data: validation_data.clone(), - para_id, - sequence_number, - author_pub: author_pub.clone(), - }) - } -} - -// Implementation of InherentDataProvider -#[async_trait::async_trait] -impl sp_inherents::InherentDataProvider for OrderInherentData { - async fn provide_inherent_data( - &self, - inherent_data: &mut sp_inherents::InherentData, - ) -> Result<(), sp_inherents::Error> { - inherent_data.put_data(crate::INHERENT_IDENTIFIER, &self) - } - - async fn try_handle_error( - &self, - _: &sp_inherents::InherentIdentifier, - _: &[u8], - ) -> Option> { - None - } -} diff --git a/primitives/order/src/lib.rs b/primitives/order/src/lib.rs deleted file mode 100644 index 87505dd..0000000 --- a/primitives/order/src/lib.rs +++ /dev/null @@ -1,111 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -//! # Order Inherent Primitives -//! -//! This crate defines those primitives that should be taken into account when building -//! the order pallet inherent -//! -#![cfg_attr(not(feature = "std"), no_std)] -use cumulus_primitives_core::{ - relay_chain::BlockNumber as RelayBlockNumber, relay_chain::Hash as PHash, ParaId, - PersistedValidationData, -}; -use sp_core::H256; -use sp_runtime::sp_std::vec::Vec; -use sp_runtime::traits::MaybeDisplay; -#[cfg(feature = "std")] -pub mod inherent_client; -pub mod metadata; -pub mod well_known_keys; -use codec::{Codec, Decode, Encode}; -use {scale_info::TypeInfo, sp_inherents::InherentIdentifier}; - -#[derive(Encode, Decode, sp_core::RuntimeDebug, Clone, PartialEq, TypeInfo)] -pub struct OrderInherentData { - /// Proof of relaychain storage. - pub relay_storage_proof: sp_trie::StorageProof, - /// Validation data. - pub validation_data: Option, - /// Parachain ID. - pub para_id: ParaId, - /// Sequence number of order. - pub sequence_number: u64, - /// Author of order. - pub author_pub: Option, -} - -// Identifier of the order inherent -pub const INHERENT_IDENTIFIER: InherentIdentifier = *b"orderiht"; - -#[derive(Clone, PartialEq)] -pub enum OrderStatus { - Init, - Order, - Execute, - Complete, -} - -#[derive(Clone)] -pub struct OrderRecord { - /// Hash of relaychain block. - pub relay_parent: Option, - /// Relaychain block height. - pub relay_height: RelayBlockNumber, - /// Hash of relaychain block,block number is special. - pub relay_base: PHash, - /// Relaychain block height,block number is special. - pub relay_base_height: RelayBlockNumber, - /// Order status - pub order_status: OrderStatus, - /// Validation data. - pub validation_data: Option, - /// Parachain ID. - pub para_id: ParaId, - /// Sequence number of order. - pub sequence_number: u64, - /// Author of order. - pub author_pub: Option, - /// Backup transactions hash. - pub txs: Vec, -} - -sp_api::decl_runtime_apis! { - #[api_version(2)] - pub trait OrderRuntimeApi where - Balance: Codec + MaybeDisplay, - AuthorityId:Codec - { - - fn slot_width()-> u32; - - fn sequence_number()-> u64; - - fn current_relay_height()->u32; - - fn order_max_amount() -> Balance; - - fn order_placed( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - para_id:ParaId, - )-> Option; - - fn reach_txpool_threshold(gas_balance:Balance) -> bool; - - fn order_executed(sequence_number:u64) -> bool ; - } -} diff --git a/primitives/order/src/metadata.rs b/primitives/order/src/metadata.rs deleted file mode 100644 index cfbd9bc..0000000 --- a/primitives/order/src/metadata.rs +++ /dev/null @@ -1,5350 +0,0 @@ -#[allow(dead_code, unused_imports, non_camel_case_types)] -#[allow(clippy::all)] -#[allow(rustdoc::broken_intra_doc_links)] -pub mod api { - #[allow(unused_imports)] - mod root_mod { - pub use super::*; - } - pub mod runtime_types { - use super::runtime_types; - pub mod rococo_runtime { - use super::runtime_types; - pub mod validator_manager { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ValidatorsRegistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), - #[codec(index = 1)] - ValidatorsDeregistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), - } - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ProxyType { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - NonTransfer, - #[codec(index = 2)] - Governance, - #[codec(index = 3)] - IdentityJudgement, - #[codec(index = 4)] - CancelProxy, - #[codec(index = 5)] - Auction, - #[codec(index = 6)] - Society, - #[codec(index = 7)] - OnDemandOrdering, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum RuntimeEvent { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Event), - #[codec(index = 3)] - Indices(runtime_types::pallet_indices::pallet::Event), - #[codec(index = 4)] - Balances(runtime_types::pallet_balances::pallet::Event), - #[codec(index = 33)] - TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), - #[codec(index = 7)] - Offences(runtime_types::pallet_offences::pallet::Event), - #[codec(index = 8)] - Session(runtime_types::pallet_session::pallet::Event), - #[codec(index = 10)] - Grandpa(runtime_types::pallet_grandpa::pallet::Event), - #[codec(index = 11)] - ImOnline(runtime_types::pallet_im_online::pallet::Event), - #[codec(index = 13)] - Democracy(runtime_types::pallet_democracy::pallet::Event), - #[codec(index = 14)] - Council(runtime_types::pallet_collective::pallet::Event), - #[codec(index = 15)] - TechnicalCommittee(runtime_types::pallet_collective::pallet::Event2), - #[codec(index = 16)] - PhragmenElection(runtime_types::pallet_elections_phragmen::pallet::Event), - #[codec(index = 17)] - TechnicalMembership(runtime_types::pallet_membership::pallet::Event), - #[codec(index = 18)] - Treasury(runtime_types::pallet_treasury::pallet::Event), - #[codec(index = 19)] - Claims(runtime_types::polkadot_runtime_common::claims::pallet::Event), - #[codec(index = 24)] - Utility(runtime_types::pallet_utility::pallet::Event), - #[codec(index = 25)] - Identity(runtime_types::pallet_identity::pallet::Event), - #[codec(index = 26)] - Society(runtime_types::pallet_society::pallet::Event), - #[codec(index = 27)] - Recovery(runtime_types::pallet_recovery::pallet::Event), - #[codec(index = 28)] - Vesting(runtime_types::pallet_vesting::pallet::Event), - #[codec(index = 29)] - Scheduler(runtime_types::pallet_scheduler::pallet::Event), - #[codec(index = 30)] - Proxy(runtime_types::pallet_proxy::pallet::Event), - #[codec(index = 31)] - Multisig(runtime_types::pallet_multisig::pallet::Event), - #[codec(index = 32)] - Preimage(runtime_types::pallet_preimage::pallet::Event), - #[codec(index = 35)] - Bounties(runtime_types::pallet_bounties::pallet::Event), - #[codec(index = 40)] - ChildBounties(runtime_types::pallet_child_bounties::pallet::Event), - #[codec(index = 36)] - Tips(runtime_types::pallet_tips::pallet::Event), - #[codec(index = 38)] - Nis(runtime_types::pallet_nis::pallet::Event), - #[codec(index = 45)] - NisCounterpartBalances(runtime_types::pallet_balances::pallet::Event2), - #[codec(index = 53)] - ParaInclusion(runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event), - #[codec(index = 56)] - Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Event), - #[codec(index = 60)] - Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event), - #[codec(index = 62)] - ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Event), - #[codec(index = 64)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Event), - #[codec(index = 66)] - OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event, - ), - #[codec(index = 70)] - Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event), - #[codec(index = 71)] - Slots(runtime_types::polkadot_runtime_common::slots::pallet::Event), - #[codec(index = 72)] - Auctions(runtime_types::polkadot_runtime_common::auctions::pallet::Event), - #[codec(index = 73)] - Crowdloan(runtime_types::polkadot_runtime_common::crowdloan::pallet::Event), - #[codec(index = 99)] - XcmPallet(runtime_types::pallet_xcm::pallet::Event), - #[codec(index = 251)] - AssignedSlots( - runtime_types::polkadot_runtime_common::assigned_slots::pallet::Event, - ), - #[codec(index = 252)] - ValidatorManager(runtime_types::rococo_runtime::validator_manager::pallet::Event), - #[codec(index = 254)] - StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::Event), - #[codec(index = 255)] - Sudo(runtime_types::pallet_sudo::pallet::Event), - } - } - pub mod pallet_indices { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - IndexAssigned { - who: ::sp_core::crypto::AccountId32, - index: ::core::primitive::u32, - }, - #[codec(index = 1)] - IndexFreed { index: ::core::primitive::u32 }, - #[codec(index = 2)] - IndexFrozen { - index: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - }, - } - } - } - pub mod pallet_transaction_payment { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - TransactionFeePaid { - who: ::sp_core::crypto::AccountId32, - actual_fee: ::core::primitive::u128, - tip: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_offences { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Offence { - kind: [::core::primitive::u8; 16usize], - timeslot: ::sp_std::vec::Vec<::core::primitive::u8>, - }, - } - } - } - pub mod pallet_session { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewSession { session_index: ::core::primitive::u32 }, - } - } - } - pub mod sp_consensus_grandpa { - use super::runtime_types; - pub mod app { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::ed25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); - } - } - pub mod pallet_grandpa { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewAuthorities { - authority_set: ::sp_std::vec::Vec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - }, - #[codec(index = 1)] - Paused, - #[codec(index = 2)] - Resumed, - } - } - } - pub mod pallet_im_online { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - HeartbeatReceived { - authority_id: runtime_types::pallet_im_online::sr25519::app_sr25519::Public, - }, - #[codec(index = 1)] - AllGood, - #[codec(index = 2)] - SomeOffline { - offline: ::sp_std::vec::Vec<(::sp_core::crypto::AccountId32, ())>, - }, - } - } - pub mod sr25519 { - use super::runtime_types; - pub mod app_sr25519 { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - } - } - } - pub mod pallet_democracy { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { - proposal_index: ::core::primitive::u32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 1)] - Tabled { - proposal_index: ::core::primitive::u32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 2)] - ExternalTabled, - #[codec(index = 3)] - Started { - ref_index: ::core::primitive::u32, - threshold: runtime_types::pallet_democracy::vote_threshold::VoteThreshold, - }, - #[codec(index = 4)] - Passed { ref_index: ::core::primitive::u32 }, - #[codec(index = 5)] - NotPassed { ref_index: ::core::primitive::u32 }, - #[codec(index = 6)] - Cancelled { ref_index: ::core::primitive::u32 }, - #[codec(index = 7)] - Delegated { - who: ::sp_core::crypto::AccountId32, - target: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 8)] - Undelegated { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 9)] - Vetoed { - who: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - until: ::core::primitive::u32, - }, - #[codec(index = 10)] - Blacklisted { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 11)] - Voted { - voter: ::sp_core::crypto::AccountId32, - ref_index: ::core::primitive::u32, - vote: runtime_types::pallet_democracy::vote::AccountVote< - ::core::primitive::u128, - >, - }, - #[codec(index = 12)] - Seconded { - seconder: ::sp_core::crypto::AccountId32, - prop_index: ::core::primitive::u32, - }, - #[codec(index = 13)] - ProposalCanceled { prop_index: ::core::primitive::u32 }, - #[codec(index = 14)] - MetadataSet { - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 15)] - MetadataCleared { - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 16)] - MetadataTransferred { - prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MetadataOwner { - #[codec(index = 0)] - External, - #[codec(index = 1)] - Proposal(::core::primitive::u32), - #[codec(index = 2)] - Referendum(::core::primitive::u32), - } - } - pub mod vote { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AccountVote<_0> { - #[codec(index = 0)] - Standard { vote: runtime_types::pallet_democracy::vote::Vote, balance: _0 }, - #[codec(index = 1)] - Split { aye: _0, nay: _0 }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Vote(pub ::core::primitive::u8); - } - pub mod vote_threshold { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VoteThreshold { - #[codec(index = 0)] - SuperMajorityApprove, - #[codec(index = 1)] - SuperMajorityAgainst, - #[codec(index = 2)] - SimpleMajority, - } - } - } - pub mod pallet_collective { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { - account: ::sp_core::crypto::AccountId32, - proposal_index: ::core::primitive::u32, - proposal_hash: runtime_types::primitive_types::H256, - threshold: ::core::primitive::u32, - }, - #[codec(index = 1)] - Voted { - account: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - voted: ::core::primitive::bool, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - #[codec(index = 2)] - Approved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 3)] - Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - Executed { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 5)] - MemberExecuted { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 6)] - Closed { - proposal_hash: runtime_types::primitive_types::H256, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event2 { - #[codec(index = 0)] - Proposed { - account: ::sp_core::crypto::AccountId32, - proposal_index: ::core::primitive::u32, - proposal_hash: runtime_types::primitive_types::H256, - threshold: ::core::primitive::u32, - }, - #[codec(index = 1)] - Voted { - account: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - voted: ::core::primitive::bool, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - #[codec(index = 2)] - Approved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 3)] - Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - Executed { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 5)] - MemberExecuted { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 6)] - Closed { - proposal_hash: runtime_types::primitive_types::H256, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - } - } - } - pub mod pallet_elections_phragmen { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewTerm { - new_members: ::sp_std::vec::Vec<( - ::sp_core::crypto::AccountId32, - ::core::primitive::u128, - )>, - }, - #[codec(index = 1)] - EmptyTerm, - #[codec(index = 2)] - ElectionError, - #[codec(index = 3)] - MemberKicked { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - Renounced { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - CandidateSlashed { - candidate: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - SeatHolderSlashed { - seat_holder: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_membership { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - MemberAdded, - #[codec(index = 1)] - MemberRemoved, - #[codec(index = 2)] - MembersSwapped, - #[codec(index = 3)] - MembersReset, - #[codec(index = 4)] - KeyChanged, - #[codec(index = 5)] - Dummy, - } - } - } - pub mod pallet_treasury { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { proposal_index: ::core::primitive::u32 }, - #[codec(index = 1)] - Spending { budget_remaining: ::core::primitive::u128 }, - #[codec(index = 2)] - Awarded { - proposal_index: ::core::primitive::u32, - award: ::core::primitive::u128, - account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Rejected { - proposal_index: ::core::primitive::u32, - slashed: ::core::primitive::u128, - }, - #[codec(index = 4)] - Burnt { burnt_funds: ::core::primitive::u128 }, - #[codec(index = 5)] - Rollover { rollover_balance: ::core::primitive::u128 }, - #[codec(index = 6)] - Deposit { value: ::core::primitive::u128 }, - #[codec(index = 7)] - SpendApproved { - proposal_index: ::core::primitive::u32, - amount: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 8)] - UpdatedInactive { - reactivated: ::core::primitive::u128, - deactivated: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_identity { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - IdentitySet { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - IdentityCleared { - who: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 2)] - IdentityKilled { - who: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 3)] - JudgementRequested { - who: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 4)] - JudgementUnrequested { - who: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 5)] - JudgementGiven { - target: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 6)] - RegistrarAdded { registrar_index: ::core::primitive::u32 }, - #[codec(index = 7)] - SubIdentityAdded { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 8)] - SubIdentityRemoved { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 9)] - SubIdentityRevoked { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_society { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Founded { founder: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - Bid { - candidate_id: ::sp_core::crypto::AccountId32, - offer: ::core::primitive::u128, - }, - #[codec(index = 2)] - Vouch { - candidate_id: ::sp_core::crypto::AccountId32, - offer: ::core::primitive::u128, - vouching: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - AutoUnbid { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - Unbid { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - Unvouch { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 6)] - Inducted { - primary: ::sp_core::crypto::AccountId32, - candidates: ::sp_std::vec::Vec<::sp_core::crypto::AccountId32>, - }, - #[codec(index = 7)] - SuspendedMemberJudgement { - who: ::sp_core::crypto::AccountId32, - judged: ::core::primitive::bool, - }, - #[codec(index = 8)] - CandidateSuspended { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 9)] - MemberSuspended { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 10)] - Challenged { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 11)] - Vote { - candidate: ::sp_core::crypto::AccountId32, - voter: ::sp_core::crypto::AccountId32, - vote: ::core::primitive::bool, - }, - #[codec(index = 12)] - DefenderVote { - voter: ::sp_core::crypto::AccountId32, - vote: ::core::primitive::bool, - }, - #[codec(index = 13)] - NewParams { - params: runtime_types::pallet_society::GroupParams<::core::primitive::u128>, - }, - #[codec(index = 14)] - Unfounded { founder: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Deposit { value: ::core::primitive::u128 }, - #[codec(index = 16)] - Elevated { - member: ::sp_core::crypto::AccountId32, - rank: ::core::primitive::u32, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct GroupParams<_0> { - pub max_members: ::core::primitive::u32, - pub max_intake: ::core::primitive::u32, - pub max_strikes: ::core::primitive::u32, - pub candidate_deposit: _0, - } - } - pub mod pallet_recovery { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - RecoveryCreated { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - RecoveryInitiated { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 2)] - RecoveryVouched { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - sender: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - RecoveryClosed { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 4)] - AccountRecovered { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 5)] - RecoveryRemoved { lost_account: ::sp_core::crypto::AccountId32 }, - } - } - } - pub mod pallet_utility { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BatchInterrupted { - index: ::core::primitive::u32, - error: runtime_types::sp_runtime::DispatchError, - }, - #[codec(index = 1)] - BatchCompleted, - #[codec(index = 2)] - BatchCompletedWithErrors, - #[codec(index = 3)] - ItemCompleted, - #[codec(index = 4)] - ItemFailed { error: runtime_types::sp_runtime::DispatchError }, - #[codec(index = 5)] - DispatchedAs { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod pallet_vesting { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - VestingUpdated { - account: ::sp_core::crypto::AccountId32, - unvested: ::core::primitive::u128, - }, - #[codec(index = 1)] - VestingCompleted { account: ::sp_core::crypto::AccountId32 }, - } - } - } - pub mod pallet_scheduler { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Scheduled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 1)] - Canceled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 2)] - Dispatched { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - CallUnavailable { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 4)] - PeriodicFailed { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 5)] - PermanentlyOverweight { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - } - } - } - pub mod pallet_proxy { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ProxyExecuted { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - PureCreated { - pure: ::sp_core::crypto::AccountId32, - who: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - disambiguation_index: ::core::primitive::u16, - }, - #[codec(index = 2)] - Announced { - real: ::sp_core::crypto::AccountId32, - proxy: ::sp_core::crypto::AccountId32, - call_hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 3)] - ProxyAdded { - delegator: ::sp_core::crypto::AccountId32, - delegatee: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - #[codec(index = 4)] - ProxyRemoved { - delegator: ::sp_core::crypto::AccountId32, - delegatee: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - } - } - } - pub mod pallet_multisig { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewMultisig { - approving: ::sp_core::crypto::AccountId32, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 1)] - MultisigApproval { - approving: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - MultisigExecuted { - approving: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - MultisigCancelled { - cancelling: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Timepoint<_0> { - pub height: _0, - pub index: ::core::primitive::u32, - } - } - pub mod pallet_preimage { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Noted { hash: runtime_types::primitive_types::H256 }, - #[codec(index = 1)] - Requested { hash: runtime_types::primitive_types::H256 }, - #[codec(index = 2)] - Cleared { hash: runtime_types::primitive_types::H256 }, - } - } - } - pub mod pallet_bounties { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BountyProposed { index: ::core::primitive::u32 }, - #[codec(index = 1)] - BountyRejected { index: ::core::primitive::u32, bond: ::core::primitive::u128 }, - #[codec(index = 2)] - BountyBecameActive { index: ::core::primitive::u32 }, - #[codec(index = 3)] - BountyAwarded { - index: ::core::primitive::u32, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 4)] - BountyClaimed { - index: ::core::primitive::u32, - payout: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 5)] - BountyCanceled { index: ::core::primitive::u32 }, - #[codec(index = 6)] - BountyExtended { index: ::core::primitive::u32 }, - } - } - } - pub mod pallet_child_bounties { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Added { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, - #[codec(index = 1)] - Awarded { - index: ::core::primitive::u32, - child_index: ::core::primitive::u32, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 2)] - Claimed { - index: ::core::primitive::u32, - child_index: ::core::primitive::u32, - payout: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Canceled { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, - } - } - } - pub mod pallet_tips { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewTip { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 1)] - TipClosing { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 2)] - TipClosed { - tip_hash: runtime_types::primitive_types::H256, - who: ::sp_core::crypto::AccountId32, - payout: ::core::primitive::u128, - }, - #[codec(index = 3)] - TipRetracted { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - TipSlashed { - tip_hash: runtime_types::primitive_types::H256, - finder: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_nis { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BidPlaced { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 1)] - BidRetracted { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 2)] - BidDropped { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 3)] - Issued { - index: ::core::primitive::u32, - expiry: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - Thawed { - index: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - amount: ::core::primitive::u128, - dropped: ::core::primitive::bool, - }, - #[codec(index = 5)] - Funded { deficit: ::core::primitive::u128 }, - #[codec(index = 6)] - Transferred { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - index: ::core::primitive::u32, - }, - } - } - } - pub mod polkadot_core_primitives { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateHash(pub runtime_types::primitive_types::H256); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct InboundDownwardMessage<_0> { - pub sent_at: _0, - pub msg: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct InboundHrmpMessage<_0> { - pub sent_at: _0, - pub data: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct OutboundHrmpMessage<_0> { - pub recipient: _0, - pub data: ::sp_std::vec::Vec<::core::primitive::u8>, - } - } - pub mod polkadot_primitives { - use super::runtime_types; - pub mod v5 { - use super::runtime_types; - // pub mod assignment_app { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Public(pub runtime_types::sp_core::sr25519::Public); - // } - pub mod collator_app { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - } - // pub mod executor_params { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ExecutorParam { - // #[codec(index = 1)] - // MaxMemoryPages(::core::primitive::u32), - // #[codec(index = 2)] - // StackLogicalMax(::core::primitive::u32), - // #[codec(index = 3)] - // StackNativeMax(::core::primitive::u32), - // #[codec(index = 4)] - // PrecheckingMaxMemory(::core::primitive::u64), - // #[codec(index = 5)] - // PvfPrepTimeout( - // runtime_types::polkadot_primitives::v5::PvfPrepTimeoutKind, - // ::core::primitive::u64, - // ), - // #[codec(index = 6)] - // PvfExecTimeout( - // runtime_types::polkadot_primitives::v5::PvfExecTimeoutKind, - // ::core::primitive::u64, - // ), - // #[codec(index = 7)] - // WasmExtBulkMemory, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ExecutorParams( - // pub ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::executor_params::ExecutorParam, - // >, - // ); - // } - // pub mod signed { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct UncheckedSigned<_0, _1> { - // pub payload: _0, - // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, - // pub signature: - // runtime_types::polkadot_primitives::v5::validator_app::Signature, - // #[codec(skip)] - // pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, - // } - // } - // pub mod slashing { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeProof { - // pub time_slot: - // runtime_types::polkadot_primitives::v5::slashing::DisputesTimeSlot, - // pub kind: - // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, - // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, - // pub validator_id: - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputesTimeSlot { - // pub session_index: ::core::primitive::u32, - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OpaqueKeyOwnershipProof(pub ::sp_std::vec::Vec<::core::primitive::u8>); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PendingSlashes { - // pub keys: ::subxt::utils::KeyedVec< - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // >, - // pub kind: - // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum SlashingOffenceKind { - // #[codec(index = 0)] - // ForInvalid, - // #[codec(index = 1)] - // AgainstValid, - // } - // } - // pub mod validator_app { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Public(pub runtime_types::sp_core::sr25519::Public); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Assignment { - // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AvailabilityBitfield( - // pub ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // ); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct BackedCandidate<_0> { - // pub candidate: - // runtime_types::polkadot_primitives::v5::CommittedCandidateReceipt<_0>, - // pub validity_votes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::ValidityAttestation, - // >, - // pub validator_indices: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidateCommitments<_0> { - // pub upward_messages: - // runtime_types::bounded_collections::bounded_vec::BoundedVec< - // ::sp_std::vec::Vec<::core::primitive::u8>, - // >, - // pub horizontal_messages: - // runtime_types::bounded_collections::bounded_vec::BoundedVec< - // runtime_types::polkadot_core_primitives::OutboundHrmpMessage< - // runtime_types::polkadot_parachain_primitives::primitives::Id, - // >, - // >, - // pub new_validation_code: ::core::option::Option< - // runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - // >, - // pub head_data: - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // pub processed_downward_messages: ::core::primitive::u32, - // pub hrmp_watermark: _0, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateDescriptor < _0 > { pub para_id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , pub relay_parent : _0 , pub collator : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Public , pub persisted_validation_data_hash : runtime_types::primitive_types::H256 , pub pov_hash : runtime_types::primitive_types::H256 , pub erasure_root : runtime_types::primitive_types::H256 , pub signature : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Signature , pub para_head : runtime_types::primitive_types::H256 , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CandidateEvent<_0> { - // #[codec(index = 0)] - // CandidateBacked( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ), - // #[codec(index = 1)] - // CandidateIncluded( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ), - // #[codec(index = 2)] - // CandidateTimedOut( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // ), - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateReceipt<_0> { - pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - pub commitments_hash: runtime_types::primitive_types::H256, - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CommittedCandidateReceipt<_0> { - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub commitments: runtime_types::polkadot_primitives::v5::CandidateCommitments< - // ::core::primitive::u32, - // >, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CoreIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CoreOccupied<_0> { - // #[codec(index = 0)] - // Free, - // #[codec(index = 1)] - // Paras(runtime_types::polkadot_primitives::v5::ParasEntry<_0>), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CoreState<_0, _1> { - // #[codec(index = 0)] - // Occupied(runtime_types::polkadot_primitives::v5::OccupiedCore<_0, _1>), - // #[codec(index = 1)] - // Scheduled(runtime_types::polkadot_primitives::v5::ScheduledCore), - // #[codec(index = 2)] - // Free, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeState<_0> { - // pub validators_for: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub validators_against: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub start: _0, - // pub concluded_at: ::core::option::Option<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum DisputeStatement { - // #[codec(index = 0)] - // Valid(runtime_types::polkadot_primitives::v5::ValidDisputeStatementKind), - // #[codec(index = 1)] - // Invalid(runtime_types::polkadot_primitives::v5::InvalidDisputeStatementKind), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeStatementSet { - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub session: ::core::primitive::u32, - // pub statements: ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::DisputeStatement, - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Signature, - // )>, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct GroupIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct GroupRotationInfo<_0> { - // pub session_start_block: _0, - // pub group_rotation_frequency: _0, - // pub now: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct IndexedVec<_0, _1>( - // pub ::sp_std::vec::Vec<_1>, - // #[codec(skip)] pub ::core::marker::PhantomData<_0>, - // ); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct InherentData<_0> { - // pub bitfields: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::signed::UncheckedSigned< - // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // >, - // >, - // pub backed_candidates: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::BackedCandidate< - // ::subxt::utils::H256, - // >, - // >, - // pub disputes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::DisputeStatementSet, - // >, - // pub parent_header: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum InvalidDisputeStatementKind { - // #[codec(index = 0)] - // Explicit, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OccupiedCore<_0, _1> { - // pub next_up_on_available: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::ScheduledCore, - // >, - // pub occupied_since: _1, - // pub time_out_at: _1, - // pub next_up_on_time_out: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::ScheduledCore, - // >, - // pub availability: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub group_responsible: runtime_types::polkadot_primitives::v5::GroupIndex, - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub candidate_descriptor: - // runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum OccupiedCoreAssumption { - // #[codec(index = 0)] - // Included, - // #[codec(index = 1)] - // TimedOut, - // #[codec(index = 2)] - // Free, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ParasEntry<_0> { - // pub assignment: runtime_types::polkadot_primitives::v5::Assignment, - // pub availability_timeouts: ::core::primitive::u32, - // pub ttl: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PersistedValidationData<_0, _1> { - // pub parent_head: - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // pub relay_parent_number: _1, - // pub relay_parent_storage_root: _0, - // pub max_pov_size: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PvfCheckStatement { pub accept : :: core :: primitive :: bool , pub subject : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub session_index : :: core :: primitive :: u32 , pub validator_index : runtime_types :: polkadot_primitives :: v5 :: ValidatorIndex , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum PvfExecTimeoutKind { - // #[codec(index = 0)] - // Backing, - // #[codec(index = 1)] - // Approval, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum PvfPrepTimeoutKind { - // #[codec(index = 0)] - // Precheck, - // #[codec(index = 1)] - // Lenient, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ScheduledCore { - // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - // pub collator: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::collator_app::Public, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ScrapedOnChainVotes<_0> { - // pub session: ::core::primitive::u32, - // pub backing_validators_per_candidate: ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::ValidityAttestation, - // )>, - // )>, - // pub disputes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::DisputeStatementSet, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct SessionInfo { - // pub active_validator_indices: - // ::sp_std::vec::Vec, - // pub random_seed: [::core::primitive::u8; 32usize], - // pub dispute_period: ::core::primitive::u32, - // pub validators: runtime_types::polkadot_primitives::v5::IndexedVec< - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // >, - // pub discovery_keys: - // ::sp_std::vec::Vec, - // pub assignment_keys: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::assignment_app::Public, - // >, - // pub validator_groups: runtime_types::polkadot_primitives::v5::IndexedVec< - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ::sp_std::vec::Vec, - // >, - // pub n_cores: ::core::primitive::u32, - // pub zeroth_delay_tranche_width: ::core::primitive::u32, - // pub relay_vrf_modulo_samples: ::core::primitive::u32, - // pub n_delay_tranches: ::core::primitive::u32, - // pub no_show_slots: ::core::primitive::u32, - // pub needed_approvals: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum UpgradeGoAhead { - // #[codec(index = 0)] - // Abort, - // #[codec(index = 1)] - // GoAhead, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum UpgradeRestriction { - // #[codec(index = 0)] - // Present, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ValidDisputeStatementKind { - // #[codec(index = 0)] - // Explicit, - // #[codec(index = 1)] - // BackingSeconded(::subxt::utils::H256), - // #[codec(index = 2)] - // BackingValid(::subxt::utils::H256), - // #[codec(index = 3)] - // ApprovalChecking, - // } - // #[derive( - // :: codec :: Decode, - // :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - // Clone, - // Debug, - // PartialEq, - // )] - // pub struct ValidatorIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ValidityAttestation { - // #[codec(index = 1)] - // Implicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), - // #[codec(index = 2)] - // Explicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), - // } - // } - // pub mod vstaging { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AsyncBackingParams { - // pub max_candidate_depth: ::core::primitive::u32, - // pub allowed_ancestry_len: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct BackingState<_0, _1> { - // pub constraints: runtime_types::polkadot_primitives::vstaging::Constraints<_1>, - // pub pending_availability: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::vstaging::CandidatePendingAvailability< - // _0, - // _1, - // >, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidatePendingAvailability<_0, _1> { - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub commitments: - // runtime_types::polkadot_primitives::v5::CandidateCommitments<_1>, - // pub relay_parent_number: _1, - // pub max_pov_size: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Constraints < _0 > { pub min_relay_parent_number : _0 , pub max_pov_size : :: core :: primitive :: u32 , pub max_code_size : :: core :: primitive :: u32 , pub ump_remaining : :: core :: primitive :: u32 , pub ump_remaining_bytes : :: core :: primitive :: u32 , pub max_ump_num_per_candidate : :: core :: primitive :: u32 , pub dmp_remaining_messages : :: std :: vec :: Vec < _0 > , pub hrmp_inbound : runtime_types :: polkadot_primitives :: vstaging :: InboundHrmpLimitations < _0 > , pub hrmp_channels_out : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: vstaging :: OutboundHrmpChannelLimitations ,) > , pub max_hrmp_num_per_candidate : :: core :: primitive :: u32 , pub required_parent : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub upgrade_restriction : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v5 :: UpgradeRestriction > , pub future_validation_code : :: core :: option :: Option < (_0 , runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash ,) > , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct InboundHrmpLimitations<_0> { - // pub valid_watermarks: ::sp_std::vec::Vec<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OutboundHrmpChannelLimitations { - // pub bytes_remaining: ::core::primitive::u32, - // pub messages_remaining: ::core::primitive::u32, - // } - } - } - pub mod sp_core { - use super::runtime_types; - pub mod crypto { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); - } - pub mod ecdsa { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 33usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 65usize]); - } - pub mod ed25519 { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - pub mod sr25519 { - use super::runtime_types; - pub mod vrf { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct VrfSignature { - pub output: [::core::primitive::u8; 32usize], - pub proof: [::core::primitive::u8; 64usize], - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct OpaqueMetadata(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Void {} - } - pub mod pallet_message_queue { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - # [codec (index = 0)] ProcessingFailed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , error : runtime_types :: frame_support :: traits :: messages :: ProcessMessageError , } , # [codec (index = 1)] Processed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , weight_used : :: sp_weights :: Weight , success : :: core :: primitive :: bool , } , # [codec (index = 2)] OverweightEnqueued { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , page_index : :: core :: primitive :: u32 , message_index : :: core :: primitive :: u32 , } , # [codec (index = 3)] PageReaped { origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , index : :: core :: primitive :: u32 , } , } - } - } - pub mod pallet_xcm { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Attempted { outcome: runtime_types::staging_xcm::v3::traits::Outcome }, - #[codec(index = 1)] - Sent { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - message: runtime_types::staging_xcm::v3::Xcm, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - UnexpectedResponse { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 3)] - ResponseReady { - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v3::Response, - }, - #[codec(index = 4)] - Notified { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 5)] - NotifyOverweight { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - actual_weight: ::sp_weights::Weight, - max_budgeted_weight: ::sp_weights::Weight, - }, - #[codec(index = 6)] - NotifyDispatchError { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 7)] - NotifyDecodeFailed { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 8)] - InvalidResponder { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - expected_location: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 9)] - InvalidResponderVersion { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 10)] - ResponseTaken { query_id: ::core::primitive::u64 }, - #[codec(index = 11)] - AssetsTrapped { - hash: runtime_types::primitive_types::H256, - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::VersionedMultiAssets, - }, - #[codec(index = 12)] - VersionChangeNotified { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - result: ::core::primitive::u32, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 13)] - SupportedVersionChanged { - location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - version: ::core::primitive::u32, - }, - #[codec(index = 14)] - NotifyTargetSendFail { - location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - error: runtime_types::staging_xcm::v3::traits::Error, - }, - #[codec(index = 15)] - NotifyTargetMigrationFail { - location: runtime_types::staging_xcm::VersionedMultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 16)] - InvalidQuerierVersion { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 17)] - InvalidQuerier { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - expected_querier: - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - maybe_actual_querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 18)] - VersionNotifyStarted { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 19)] - VersionNotifyRequested { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 20)] - VersionNotifyUnrequested { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 21)] - FeesPaid { - paying: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - fees: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - }, - #[codec(index = 22)] - AssetsClaimed { - hash: runtime_types::primitive_types::H256, - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::VersionedMultiAssets, - }, - } - } - } - pub mod staging_xcm { - use super::runtime_types; - pub mod double_encoded { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DoubleEncoded { - pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DoubleEncoded2 { - pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, - } - } - pub mod v2 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: runtime_types::staging_xcm::v2::NetworkId, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: runtime_types::staging_xcm::v2::NetworkId, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: runtime_types::staging_xcm::v2::NetworkId, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::staging_xcm::v2::BodyId, - part: runtime_types::staging_xcm::v2::BodyPart, - }, - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::staging_xcm::v2::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract(::sp_std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - #[codec(index = 6)] - Blob(::sp_std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::staging_xcm::v2::multiasset::AssetInstance), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAsset { - pub id: runtime_types::staging_xcm::v2::multiasset::AssetId, - pub fun: runtime_types::staging_xcm::v2::multiasset::Fungibility, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::staging_xcm::v2::multiasset::WildMultiAsset), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAssets( - pub ::sp_std::vec::Vec< - runtime_types::staging_xcm::v2::multiasset::MultiAsset, - >, - ); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::staging_xcm::v2::multiasset::AssetId, - fun: runtime_types::staging_xcm::v2::multiasset::WildFungibility, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::staging_xcm::v2::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::staging_xcm::v2::multilocation::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - MultiLocationFull, - #[codec(index = 5)] - MultiLocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - UnhandledXcmVersion, - #[codec(index = 23)] - WeightLimitReached(::core::primitive::u64), - #[codec(index = 24)] - Barrier, - #[codec(index = 25)] - WeightNotComputable, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::staging_xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v2::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v2::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::staging_xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v2::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v2::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum NetworkId { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum OriginKind { - #[codec(index = 0)] - Native, - #[codec(index = 1)] - SovereignAccount, - #[codec(index = 2)] - Superuser, - #[codec(index = 3)] - Xcm, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v2::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(#[codec(compact)] ::core::primitive::u64), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm(pub ::sp_std::vec::Vec); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm2( - pub ::sp_std::vec::Vec, - ); - } - pub mod v3 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Moniker([::core::primitive::u8; 4usize]), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey { - length: ::core::primitive::u8, - data: [::core::primitive::u8; 32usize], - }, - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::staging_xcm::v3::junction::BodyId, - part: runtime_types::staging_xcm::v3::junction::BodyPart, - }, - #[codec(index = 9)] - GlobalConsensus(runtime_types::staging_xcm::v3::junction::NetworkId), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum NetworkId { - #[codec(index = 0)] - ByGenesis([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - ByFork { - block_number: ::core::primitive::u64, - block_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - #[codec(index = 4)] - Westend, - #[codec(index = 5)] - Rococo, - #[codec(index = 6)] - Wococo, - #[codec(index = 7)] - Ethereum { - #[codec(compact)] - chain_id: ::core::primitive::u64, - }, - #[codec(index = 8)] - BitcoinCore, - #[codec(index = 9)] - BitcoinCash, - } - } - pub mod junctions { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::staging_xcm::v3::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract([::core::primitive::u8; 32usize]), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::staging_xcm::v3::multiasset::AssetInstance), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAsset { - pub id: runtime_types::staging_xcm::v3::multiasset::AssetId, - pub fun: runtime_types::staging_xcm::v3::multiasset::Fungibility, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::staging_xcm::v3::multiasset::WildMultiAsset), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAssets( - pub ::sp_std::vec::Vec< - runtime_types::staging_xcm::v3::multiasset::MultiAsset, - >, - ); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::staging_xcm::v3::multiasset::AssetId, - fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, - }, - #[codec(index = 2)] - AllCounted(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - AllOfCounted { - id: runtime_types::staging_xcm::v3::multiasset::AssetId, - fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, - #[codec(compact)] - count: ::core::primitive::u32, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::staging_xcm::v3::junctions::Junctions, - } - } - - pub mod traits { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - LocationFull, - #[codec(index = 5)] - LocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - ExpectationFalse, - #[codec(index = 23)] - PalletNotFound, - #[codec(index = 24)] - NameMismatch, - #[codec(index = 25)] - VersionIncompatible, - #[codec(index = 26)] - HoldingWouldOverflow, - #[codec(index = 27)] - ExportError, - #[codec(index = 28)] - ReanchorFailed, - #[codec(index = 29)] - NoDeal, - #[codec(index = 30)] - FeesNotMet, - #[codec(index = 31)] - LockError, - #[codec(index = 32)] - NoPermission, - #[codec(index = 33)] - Unanchored, - #[codec(index = 34)] - NotDepositable, - #[codec(index = 35)] - UnhandledXcmVersion, - #[codec(index = 36)] - WeightLimitReached(::sp_weights::Weight), - #[codec(index = 37)] - Barrier, - #[codec(index = 38)] - WeightNotComputable, - #[codec(index = 39)] - ExceedsStackLimit, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Outcome { - #[codec(index = 0)] - Complete(::sp_weights::Weight), - #[codec(index = 1)] - Incomplete( - ::sp_weights::Weight, - runtime_types::staging_xcm::v3::traits::Error, - ), - #[codec(index = 2)] - Error(runtime_types::staging_xcm::v3::traits::Error), - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v3::Response, - max_weight: ::sp_weights::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::staging_xcm::v2::OriginKind, - require_weight_at_most: ::sp_weights::Weight, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v3::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v3::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: ::sp_weights::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 29)] - ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::sp_std::vec::Vec<::core::primitive::u8>, - module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::staging_xcm::v3::junction::NetworkId, - destination: runtime_types::staging_xcm::v3::junctions::Junctions, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum Instruction2 { - // #[codec(index = 0)] - // WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 1)] - // ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 2)] - // ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 3)] - // QueryResponse { - // #[codec(compact)] - // query_id: ::core::primitive::u64, - // response: runtime_types::staging_xcm::v3::Response, - // max_weight: ::sp_weights::Weight, - // querier: ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // }, - // #[codec(index = 4)] - // TransferAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 5)] - // TransferReserveAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 6)] - // Transact { - // origin_kind: runtime_types::staging_xcm::v2::OriginKind, - // require_weight_at_most: ::sp_weights::Weight, - // call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, - // }, - // #[codec(index = 7)] - // HrmpNewChannelOpenRequest { - // #[codec(compact)] - // sender: ::core::primitive::u32, - // #[codec(compact)] - // max_message_size: ::core::primitive::u32, - // #[codec(compact)] - // max_capacity: ::core::primitive::u32, - // }, - // #[codec(index = 8)] - // HrmpChannelAccepted { - // #[codec(compact)] - // recipient: ::core::primitive::u32, - // }, - // #[codec(index = 9)] - // HrmpChannelClosing { - // #[codec(compact)] - // initiator: ::core::primitive::u32, - // #[codec(compact)] - // sender: ::core::primitive::u32, - // #[codec(compact)] - // recipient: ::core::primitive::u32, - // }, - // #[codec(index = 10)] - // ClearOrigin, - // #[codec(index = 11)] - // DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), - // #[codec(index = 12)] - // ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), - // #[codec(index = 13)] - // DepositAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 14)] - // DepositReserveAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 15)] - // ExchangeAsset { - // give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // maximal: ::core::primitive::bool, - // }, - // #[codec(index = 16)] - // InitiateReserveWithdraw { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 17)] - // InitiateTeleport { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 18)] - // ReportHolding { - // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // }, - // #[codec(index = 19)] - // BuyExecution { - // fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - // }, - // #[codec(index = 20)] - // RefundSurplus, - // #[codec(index = 21)] - // SetErrorHandler(runtime_types::staging_xcm::v3::Xcm2), - // #[codec(index = 22)] - // SetAppendix(runtime_types::staging_xcm::v3::Xcm2), - // #[codec(index = 23)] - // ClearError, - // #[codec(index = 24)] - // ClaimAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 25)] - // Trap(#[codec(compact)] ::core::primitive::u64), - // #[codec(index = 26)] - // SubscribeVersion { - // #[codec(compact)] - // query_id: ::core::primitive::u64, - // max_response_weight: ::sp_weights::Weight, - // }, - // #[codec(index = 27)] - // UnsubscribeVersion, - // #[codec(index = 28)] - // BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 29)] - // ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 30)] - // ExpectOrigin( - // ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // ), - // #[codec(index = 31)] - // ExpectError( - // ::core::option::Option<( - // ::core::primitive::u32, - // runtime_types::staging_xcm::v3::traits::Error, - // )>, - // ), - // #[codec(index = 32)] - // ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), - // #[codec(index = 33)] - // QueryPallet { - // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - // }, - // #[codec(index = 34)] - // ExpectPallet { - // #[codec(compact)] - // index: ::core::primitive::u32, - // name: ::sp_std::vec::Vec<::core::primitive::u8>, - // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - // #[codec(compact)] - // crate_major: ::core::primitive::u32, - // #[codec(compact)] - // min_crate_minor: ::core::primitive::u32, - // }, - // #[codec(index = 35)] - // ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), - // #[codec(index = 36)] - // ClearTransactStatus, - // #[codec(index = 37)] - // UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), - // #[codec(index = 38)] - // ExportMessage { - // network: runtime_types::staging_xcm::v3::junction::NetworkId, - // destination: runtime_types::staging_xcm::v3::junctions::Junctions, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 39)] - // LockAsset { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 40)] - // UnlockAsset { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 41)] - // NoteUnlockable { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 42)] - // RequestUnlock { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 43)] - // SetFeesMode { jit_withdraw: ::core::primitive::bool }, - // #[codec(index = 44)] - // SetTopic([::core::primitive::u8; 32usize]), - // #[codec(index = 45)] - // ClearTopic, - // #[codec(index = 46)] - // AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - // #[codec(index = 47)] - // UnpaidExecution { - // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - // check_origin: ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // }, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MaybeErrorCode { - #[codec(index = 0)] - Success, - #[codec(index = 1)] - Error( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - TruncatedError( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct PalletInfo { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - #[codec(compact)] - pub major: ::core::primitive::u32, - #[codec(compact)] - pub minor: ::core::primitive::u32, - #[codec(compact)] - pub patch: ::core::primitive::u32, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct QueryResponseInfo { - pub destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - #[codec(compact)] - pub query_id: ::core::primitive::u64, - pub max_weight: ::sp_weights::Weight, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v3::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - #[codec(index = 4)] - PalletsInfo( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::staging_xcm::v3::PalletInfo, - >, - ), - #[codec(index = 5)] - DispatchResult(runtime_types::staging_xcm::v3::MaybeErrorCode), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(::sp_weights::Weight), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm(pub ::sp_std::vec::Vec); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Xcm2(pub ::sp_std::vec::Vec); - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedAssetId { - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::multiasset::AssetId), - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VersionedMultiAssets { - #[codec(index = 1)] - V2(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - V3(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VersionedMultiLocation { - #[codec(index = 1)] - V2(runtime_types::staging_xcm::v2::multilocation::MultiLocation), - #[codec(index = 3)] - V3(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedResponse { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Response), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Response), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedXcm { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Xcm), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Xcm), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedXcm2 { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Xcm2), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Xcm2), - // } - } - - pub mod polkadot_runtime_common { - use super::runtime_types; - pub mod assigned_slots { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - PermanentSlotAssigned( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 1)] - TemporarySlotAssigned( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 2)] - MaxPermanentSlotsChanged { slots: ::core::primitive::u32 }, - #[codec(index = 3)] - MaxTemporarySlotsChanged { slots: ::core::primitive::u32 }, - } - } - } - pub mod auctions { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - AuctionStarted { - auction_index: ::core::primitive::u32, - lease_period: ::core::primitive::u32, - ending: ::core::primitive::u32, - }, - #[codec(index = 1)] - AuctionClosed { auction_index: ::core::primitive::u32 }, - #[codec(index = 2)] - Reserved { - bidder: ::sp_core::crypto::AccountId32, - extra_reserved: ::core::primitive::u128, - total_amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - Unreserved { - bidder: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - ReserveConfiscated { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - BidAccepted { - bidder: ::sp_core::crypto::AccountId32, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - first_slot: ::core::primitive::u32, - last_slot: ::core::primitive::u32, - }, - #[codec(index = 6)] - WinningOffset { - auction_index: ::core::primitive::u32, - block_number: ::core::primitive::u32, - }, - } - } - } - pub mod claims { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Claimed { - who: ::sp_core::crypto::AccountId32, - ethereum_address: - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - amount: ::core::primitive::u128, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct EthereumAddress(pub [::core::primitive::u8; 20usize]); - } - pub mod crowdloan { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Created { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 1)] - Contributed { - who: ::sp_core::crypto::AccountId32, - fund_index: - runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Withdrew { - who: ::sp_core::crypto::AccountId32, - fund_index: - runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - PartiallyRefunded { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 4)] - AllRefunded { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 5)] - Dissolved { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 6)] - HandleBidResult { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - result: ::core::result::Result< - (), - runtime_types::sp_runtime::DispatchError, - >, - }, - #[codec(index = 7)] - Edited { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 8)] - MemoUpdated { - who: ::sp_core::crypto::AccountId32, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - memo: ::sp_std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 9)] - AddedToNewRaise { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - } - } - pub mod paras_registrar { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Registered { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - manager: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 1)] - Deregistered { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 2)] - Reserved { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - who: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Swapped { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - other_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - } - } - pub mod slots { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewLeasePeriod { lease_period: ::core::primitive::u32 }, - #[codec(index = 1)] - Leased { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::sp_core::crypto::AccountId32, - period_begin: ::core::primitive::u32, - period_count: ::core::primitive::u32, - extra_reserved: ::core::primitive::u128, - total_amount: ::core::primitive::u128, - }, - } - } - } - } - - pub mod pallet_state_trie_migration { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - MaxSignedLimits, - #[codec(index = 1)] - KeyTooLong, - #[codec(index = 2)] - NotEnoughFunds, - #[codec(index = 3)] - BadWitness, - #[codec(index = 4)] - SignedMigrationNotAllowed, - #[codec(index = 5)] - BadChildRoot, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Migrated { - top: ::core::primitive::u32, - child: ::core::primitive::u32, - compute: - runtime_types::pallet_state_trie_migration::pallet::MigrationCompute, - }, - #[codec(index = 1)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 2)] - AutoMigrationFinished, - #[codec(index = 3)] - Halted { error: runtime_types::pallet_state_trie_migration::pallet::Error }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MigrationCompute { - #[codec(index = 0)] - Signed, - #[codec(index = 1)] - Auto, - } - } - } - pub mod bounded_collections { - use super::runtime_types; - pub mod bounded_vec { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct BoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); - } - pub mod weak_bounded_vec { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct WeakBoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); - } - } - pub mod primitive_types { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct H256(pub [::core::primitive::u8; 32usize]); - } - pub mod frame_system { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ExtrinsicSuccess { - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 1)] - ExtrinsicFailed { - dispatch_error: runtime_types::sp_runtime::DispatchError, - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 2)] - CodeUpdated, - #[codec(index = 3)] - NewAccount { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - KilledAccount { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - Remarked { - sender: ::sp_core::crypto::AccountId32, - hash: runtime_types::primitive_types::H256, - }, - } - } - } - pub mod frame_support { - use super::runtime_types; - pub mod dispatch { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DispatchClass { - #[codec(index = 0)] - Normal, - #[codec(index = 1)] - Operational, - #[codec(index = 2)] - Mandatory, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DispatchInfo { - pub weight: ::sp_weights::Weight, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub pays_fee: runtime_types::frame_support::dispatch::Pays, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Pays { - #[codec(index = 0)] - Yes, - #[codec(index = 1)] - No, - } - } - pub mod traits { - use super::runtime_types; - pub mod messages { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ProcessMessageError { - #[codec(index = 0)] - BadFormat, - #[codec(index = 1)] - Corrupt, - #[codec(index = 2)] - Unsupported, - #[codec(index = 3)] - Overweight(::sp_weights::Weight), - #[codec(index = 4)] - Yield, - } - } - pub mod tokens { - use super::runtime_types; - pub mod misc { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BalanceStatus { - #[codec(index = 0)] - Free, - #[codec(index = 1)] - Reserved, - } - } - } - } - } - pub mod pallet_balances { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Endowed { - account: ::sp_core::crypto::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - DustLost { - account: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Transfer { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - BalanceSet { - who: ::sp_core::crypto::AccountId32, - free: ::core::primitive::u128, - }, - #[codec(index = 4)] - Reserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - Unreserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - ReserveRepatriated { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - Withdraw { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - Suspended { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 13)] - Restored { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - Upgraded { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - Unlocked { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 19)] - Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event2 { - #[codec(index = 0)] - Endowed { - account: ::sp_core::crypto::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - DustLost { - account: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Transfer { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - BalanceSet { - who: ::sp_core::crypto::AccountId32, - free: ::core::primitive::u128, - }, - #[codec(index = 4)] - Reserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - Unreserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - ReserveRepatriated { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - Withdraw { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - Suspended { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 13)] - Restored { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - Upgraded { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - Unlocked { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 19)] - Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - } - } - } - pub mod polkadot_runtime_parachains { - use super::runtime_types; - pub mod assigner_on_demand { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - OnDemandOrderPlaced { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - spot_price: ::core::primitive::u128, - }, - #[codec(index = 1)] - SpotTrafficSet { - traffic: runtime_types::sp_arithmetic::fixed_point::FixedU128, - }, - } - } - } - pub mod inclusion { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - CandidateBacked( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - runtime_types::polkadot_primitives::v5::GroupIndex, - ), - #[codec(index = 1)] - CandidateIncluded( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - runtime_types::polkadot_primitives::v5::GroupIndex, - ), - #[codec(index = 2)] - CandidateTimedOut( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - ), - #[codec(index = 3)] - UpwardMessagesReceived { - from: runtime_types::polkadot_parachain_primitives::primitives::Id, - count: ::core::primitive::u32, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AggregateMessageOrigin { - #[codec(index = 0)] - Ump(runtime_types::polkadot_runtime_parachains::inclusion::UmpQueueId), - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AvailabilityBitfieldRecord<_0> { - // pub bitfield: runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // pub submitted_at: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidatePendingAvailability<_0, _1> { - // pub core: runtime_types::polkadot_primitives::v5::CoreIndex, - // pub hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub availability_votes: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub backers: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub relay_parent_number: _1, - // pub backed_in_number: _1, - // pub backing_group: runtime_types::polkadot_primitives::v5::GroupIndex, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum UmpQueueId { - #[codec(index = 0)] - Para(runtime_types::polkadot_parachain_primitives::primitives::Id), - } - } - pub mod paras { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - # [codec (index = 0)] CurrentCodeUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 1)] CurrentHeadUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 2)] CodeUpgradeScheduled (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 3)] NewHeadNoted (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 4)] ActionQueued (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , :: core :: primitive :: u32 ,) , # [codec (index = 5)] PvfCheckStarted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 6)] PvfCheckAccepted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 7)] PvfCheckRejected (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , } - } - } - pub mod hrmp { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - OpenChannelRequested( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - ::core::primitive::u32, - ), - #[codec(index = 1)] - OpenChannelCanceled( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - ), - #[codec(index = 2)] - OpenChannelAccepted( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 3)] - ChannelClosed( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - ), - #[codec(index = 4)] - HrmpChannelForceOpened( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - ::core::primitive::u32, - ), - } - } - } - pub mod disputes { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - DisputeInitiated( - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, - ), - #[codec(index = 1)] - DisputeConcluded( - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, - ), - #[codec(index = 2)] - Revert(::core::primitive::u32), - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DisputeLocation { - #[codec(index = 0)] - Local, - #[codec(index = 1)] - Remote, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DisputeResult { - #[codec(index = 0)] - Valid, - #[codec(index = 1)] - Invalid, - } - } - } - pub mod polkadot_parachain_primitives { - use super::runtime_types; - pub mod primitives { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct HeadData(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct HrmpChannelId { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Id(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ValidationCode(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ValidationCodeHash(pub runtime_types::primitive_types::H256); - } - } - pub mod pallet_sudo { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Sudid { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - KeyChanged { - old_sudoer: ::core::option::Option<::sp_core::crypto::AccountId32>, - }, - #[codec(index = 2)] - SudoAsDone { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod sp_arithmetic { - use super::runtime_types; - pub mod fixed_point { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct FixedU128(pub ::core::primitive::u128); - } - pub mod per_things { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Perbill(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Percent(pub ::core::primitive::u8); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Permill(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Perquintill(pub ::core::primitive::u64); - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ArithmeticError { - #[codec(index = 0)] - Underflow, - #[codec(index = 1)] - Overflow, - #[codec(index = 2)] - DivisionByZero, - } - } - pub mod sp_runtime { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DispatchError { - #[codec(index = 0)] - Other, - #[codec(index = 1)] - CannotLookup, - #[codec(index = 2)] - BadOrigin, - #[codec(index = 3)] - Module(runtime_types::sp_runtime::ModuleError), - #[codec(index = 4)] - ConsumerRemaining, - #[codec(index = 5)] - NoProviders, - #[codec(index = 6)] - TooManyConsumers, - #[codec(index = 7)] - Token(runtime_types::sp_runtime::TokenError), - #[codec(index = 8)] - Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), - #[codec(index = 9)] - Transactional(runtime_types::sp_runtime::TransactionalError), - #[codec(index = 10)] - Exhausted, - #[codec(index = 11)] - Corruption, - #[codec(index = 12)] - Unavailable, - #[codec(index = 13)] - RootNotAllowed, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ModuleError { - pub index: ::core::primitive::u8, - pub error: [::core::primitive::u8; 4usize], - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum TokenError { - #[codec(index = 0)] - FundsUnavailable, - #[codec(index = 1)] - OnlyProvider, - #[codec(index = 2)] - BelowMinimum, - #[codec(index = 3)] - CannotCreate, - #[codec(index = 4)] - UnknownAsset, - #[codec(index = 5)] - Frozen, - #[codec(index = 6)] - Unsupported, - #[codec(index = 7)] - CannotCreateHold, - #[codec(index = 8)] - NotExpendable, - #[codec(index = 9)] - Blocked, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum TransactionalError { - #[codec(index = 0)] - LimitReached, - #[codec(index = 1)] - NoLayer, - } - } - } -} diff --git a/primitives/order/src/well_known_keys.rs b/primitives/order/src/well_known_keys.rs deleted file mode 100644 index a1a4424..0000000 --- a/primitives/order/src/well_known_keys.rs +++ /dev/null @@ -1,91 +0,0 @@ -// Copyright (C) Magnet. -// This file is part of Magnet. - -// Magnet is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// Magnet is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with Magnet. If not, see . - -//! Keys of well known. -#![cfg_attr(not(feature = "std"), no_std)] - -use cumulus_primitives_core::relay_chain::CoreIndex; -use { - cumulus_primitives_core::ParaId, - pallet_broker::RegionId, - sp_core::Encode, - sp_io::hashing::{blake2_128, twox_256, twox_64}, - sp_std::vec::Vec, -}; - -pub const PARAS_PARA_LIFECYCLES: &[u8] = - &hex_literal::hex!["cd710b30bd2eab0352ddcc26417aa194281e0bfde17b36573208a06cb5cfba6b"]; - -// Paras pallet storage ParaLifecycles -pub fn paras_para_lifecycles(para_id: ParaId) -> Vec { - para_id.using_encoded(|para_id: &[u8]| { - PARAS_PARA_LIFECYCLES - .iter() - .chain(twox_64(para_id).iter()) - .chain(para_id.iter()) - .cloned() - .collect() - }) -} - -/// System pallet -pub const SYSTEM_BLOCKHASH: &[u8] = &hex_literal::hex![ - "26aa394eea5630e07c48ae0c9558cef7a44704b568d21667356a5a050c118746b4def25cfda6ef3a00000000" -]; - -pub const SYSTEM_ACCOUNT: &[u8] = - &hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da9"]; - -pub const SYSTEM_EVENTS: &[u8] = - &hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7"]; - -//OnDemandAssignmentProvider OnDemandQueue -pub const ON_DEMAND_QUEUE: &[u8] = - &hex_literal::hex!["8f32430b49607f8d60bfd3a003ddf4b53f35b69d817556cf6b886e5b4f01fbdc"]; - -//OnDemandAssignmentProvider SpotTraffic -pub const SPOT_TRAFFIC: &[u8] = - &hex_literal::hex!["8f32430b49607f8d60bfd3a003ddf4b5c9308a8e0e640735727536bd9069b11e"]; - -//Configuration ActiveConfig -pub const ACTIVE_CONFIG: &[u8] = - &hex_literal::hex!["06de3d8a54d27e44a9d5ce189618f22db4b49d95320d9021994c850f25b8e385"]; - -pub const CORE_DESCRIPTORS: &[u8] = - &hex_literal::hex!["638595eebaa445ce03a13547bece90e704e6ac775a3245623103ffec2cb2c92f"]; - -/// assigner coretime storage CoreDescriptors -pub fn paras_core_descriptors(core_index: CoreIndex) -> Vec { - core_index.using_encoded(|core_index: &[u8]| { - CORE_DESCRIPTORS.iter().chain(twox_256(core_index).iter()).cloned().collect() - }) -} - -// XXHash a String:Broker Regions -pub const REGIONS: &[u8] = - &hex_literal::hex!["4dcb50595177a3177648411a42aca0f53dc63b0b76ffd6f80704a090da6f8719"]; - -/// assigner coretime storage CoreDescriptors -pub fn broker_regions(region_id: RegionId) -> Vec { - region_id.using_encoded(|core_index: &[u8]| { - REGIONS - .iter() - .chain(blake2_128(core_index).iter()) - .chain(core_index.iter()) - .cloned() - .collect() - }) -} diff --git a/runtime/Cargo.toml b/runtime/Cargo.toml index 9c8c7ed..e4abff8 100644 --- a/runtime/Cargo.toml +++ b/runtime/Cargo.toml @@ -27,12 +27,11 @@ pallet-assets-bridge = { path = "../pallets/assets-bridge", default-features = f pallet-evm-utils = { path = "../pallets/evm-utils", default-features = false } pallet-precompile-substrate-utils = { path = "../pallets/evm/precompile/substrate-utils", default-features = false } pallet-precompile-transfer-to-magnet = { path = "../pallets/evm/precompile/transfer-to-magnet", default-features = false } -pallet-order = { path = "../pallets/order", default-features = false } -magnet-primitives-order = { path = "../primitives/order", default-features = false } pallet-pot = { path = "../pallets/pot", default-features = false } pallet-pot-runtime-api = { path = "../pallets/pot/runtime-api", default-features = false } pallet-assurance = { path = "../pallets/assurance", default-features = false } pallet-liquidation = {path = "../pallets/liquidation", default-features = false} +pallet-bulk = { path = "../pallets/bulk", default-features = false } # Substrate frame-benchmarking = { workspace = true, default-features = false, optional = true} @@ -191,8 +190,6 @@ std = [ "pallet-evm-utils/std", "pallet-precompile-substrate-utils/std", "pallet-precompile-transfer-to-magnet/std", - "magnet-primitives-order/std", - "pallet-order/std", "sp-trie/std", "cumulus-primitives-timestamp/std", "pallet-liquidation/std", @@ -206,7 +203,8 @@ std = [ "pallet-ranked-collective/std", "pallet-scheduler/std", "pallet-insecure-randomness-collective-flip/std", - "pallet-contracts/std", + "pallet-contracts/std", + "pallet-bulk/std", ] runtime-benchmarks = [ @@ -232,7 +230,7 @@ runtime-benchmarks = [ "pallet-evm-utils/runtime-benchmarks", "pallet-precompile-substrate-utils/runtime-benchmarks", "pallet-precompile-transfer-to-magnet/runtime-benchmarks", - "pallet-order/runtime-benchmarks", +# "pallet-order/runtime-benchmarks", "pallet-collective/runtime-benchmarks", "pallet-society/runtime-benchmarks", "pallet-evm/runtime-benchmarks", @@ -277,7 +275,6 @@ try-runtime = [ "pallet-evm-utils/try-runtime", "pallet-precompile-substrate-utils/try-runtime", "pallet-precompile-transfer-to-magnet/try-runtime", - "pallet-order/try-runtime", "pallet-liquidation/try-runtime", "pallet-assets/try-runtime", "pallet-assets-bridge/try-runtime", diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index ce93b1b..ecf8d83 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -86,7 +86,8 @@ use weights::{BlockExecutionWeight, ExtrinsicBaseWeight}; // XCM Imports use cumulus_primitives_core::{AggregateMessageOrigin, ParaId, PersistedValidationData}; -pub use pallet_order::{self, OrderGasCost}; +pub use pallet_bulk; +// pub use pallet_order::{self, OrderGasCost}; use xcm::latest::prelude::{ Asset as MultiAsset, BodyId, InteriorLocation as InteriorMultiLocation, Junction::PalletInstance, Location as MultiLocation, @@ -333,7 +334,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { /// up by `pallet_aura` to implement `fn slot_duration()`. /// /// Change this to adjust the block time. -pub const MILLISECS_PER_BLOCK: u64 = 12000; +pub const MILLISECS_PER_BLOCK: u64 = 6000; pub const WEIGHT_MILLISECS_PER_BLOCK: u64 = 2000; // NOTE: Currently it is not possible to change the slot duration after the chain has started. @@ -689,52 +690,60 @@ impl pallet_collator_selection::Config for Runtime { type WeightInfo = (); } -pub struct OrderGasCostHandler(); - -impl OrderGasCost for OrderGasCostHandler -where - T: pallet_order::Config, - T::AccountId: From<[u8; 32]>, -{ - fn gas_cost( - block_number: BlockNumberFor, - ) -> Result, sp_runtime::DispatchError> { - let sequece_number = >::block_2_sequence(block_number); - if sequece_number.is_none() { - return Ok(None); - } - let order = >::order_map( - sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, - ) - .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; - let mut r = [0u8; 32]; - r.copy_from_slice(order.orderer.encode().as_slice()); - let account = T::AccountId::try_from(r) - .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; - Ok(Some((account, order.price))) - } -} - -parameter_types! { - pub const SlotWidth: u32 = 2; - pub const OrderMaxAmount:Balance = 200000000; - pub const TxPoolThreshold:Balance = 3000000000; -} +// pub struct OrderGasCostHandler(); + +// impl OrderGasCost for OrderGasCostHandler +// where +// T: pallet_order::Config, +// T::AccountId: From<[u8; 32]>, +// { +// fn gas_cost( +// block_number: BlockNumberFor, +// ) -> Result, sp_runtime::DispatchError> { +// let sequece_number = >::block_2_sequence(block_number); +// if sequece_number.is_none() { +// return Ok(None); +// } +// let order = >::order_map( +// sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, +// ) +// .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; +// let mut r = [0u8; 32]; +// r.copy_from_slice(order.orderer.encode().as_slice()); +// let account = T::AccountId::try_from(r) +// .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; +// Ok(Some((account, order.price))) +// } +// } + +// parameter_types! { +// pub const SlotWidth: u32 = 2; +// pub const OrderMaxAmount:Balance = 200000000; +// pub const TxPoolThreshold:Balance = 3000000000; +// } type EnsureRootOrHalf = EitherOfDiverse< EnsureRoot, pallet_collective::EnsureProportionMoreThan, >; -impl pallet_order::Config for Runtime { +// impl pallet_order::Config for Runtime { +// type RuntimeEvent = RuntimeEvent; +// type AuthorityId = AuraId; +// type Currency = Balances; +// type UpdateOrigin = EnsureRootOrHalf; +// type OrderMaxAmount = OrderMaxAmount; +// type SlotWidth = SlotWidth; +// type TxPoolThreshold = TxPoolThreshold; +// type WeightInfo = pallet_order::weights::SubstrateWeight; +// } + +impl pallet_bulk::Config for Runtime { type RuntimeEvent = RuntimeEvent; type AuthorityId = AuraId; type Currency = Balances; type UpdateOrigin = EnsureRootOrHalf; - type OrderMaxAmount = OrderMaxAmount; - type SlotWidth = SlotWidth; - type TxPoolThreshold = TxPoolThreshold; - type WeightInfo = pallet_order::weights::SubstrateWeight; + type WeightInfo = (); } parameter_types! { @@ -970,7 +979,7 @@ impl pallet_liquidation::Config for Runtime { type Currency = Balances; type XcmSender = xcm_config::XcmRouter; type WeightToFee = WeightToFee; - type OrderGasCost = OrderGasCostHandler; + type OrderGasCost = (); type SystemRatio = SystemRatio; type TreasuryRatio = TreasuryRatio; type OperationRatio = OperationRatio; @@ -1167,7 +1176,7 @@ construct_runtime!( HotfixSufficients: pallet_hotfix_sufficients = 45, //Magnet - OrderPallet: pallet_order = 51, + // OrderPallet: pallet_order = 51, EVMUtils: pallet_evm_utils = 60, Pot: pallet_pot = 61, Assurance: pallet_assurance = 62, @@ -1176,6 +1185,7 @@ construct_runtime!( //Contracts RandomnessCollectiveFlip: pallet_insecure_randomness_collective_flip = 70, Contracts: pallet_contracts = 71, + BulkPallet: pallet_bulk = 72, } ); @@ -1189,7 +1199,7 @@ mod benches { [pallet_sudo, Sudo] [pallet_collator_selection, CollatorSelection] [cumulus_pallet_xcmp_queue, XcmpQueue] - [pallet_order, OrderPallet] + // [pallet_order, OrderPallet] ); } @@ -1537,39 +1547,39 @@ impl_runtime_apis! { ParachainSystem::collect_collation_info(header) } } - impl magnet_primitives_order::OrderRuntimeApi for Runtime { - - fn slot_width()-> u32{ - OrderPallet::slot_width() - } - fn order_max_amount() -> Balance { - OrderPallet::order_max_amount() - } - fn sequence_number()-> u64 { - OrderPallet::sequence_number() - } - - fn current_relay_height()-> u32 { - OrderPallet::current_relay_height() - } - - fn order_placed( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - para_id:ParaId, - )-> Option { - OrderPallet::order_placed(relay_storage_proof, validation_data, para_id) - } - - fn reach_txpool_threshold(gas_balance:Balance) -> bool { - OrderPallet::reach_txpool_threshold(gas_balance) - } - - - fn order_executed(sequence_number:u64) -> bool { - OrderPallet::order_executed(sequence_number) - } - } + // impl magnet_primitives_order::OrderRuntimeApi for Runtime { + + // fn slot_width()-> u32{ + // OrderPallet::slot_width() + // } + // fn order_max_amount() -> Balance { + // OrderPallet::order_max_amount() + // } + // fn sequence_number()-> u64 { + // OrderPallet::sequence_number() + // } + + // fn current_relay_height()-> u32 { + // OrderPallet::current_relay_height() + // } + + // fn order_placed( + // relay_storage_proof: sp_trie::StorageProof, + // validation_data: PersistedValidationData, + // para_id:ParaId, + // )-> Option { + // OrderPallet::order_placed(relay_storage_proof, validation_data, para_id) + // } + + // fn reach_txpool_threshold(gas_balance:Balance) -> bool { + // OrderPallet::reach_txpool_threshold(gas_balance) + // } + + + // fn order_executed(sequence_number:u64) -> bool { + // OrderPallet::order_executed(sequence_number) + // } + // } impl mp_system::OnRelayChainApi for Runtime { fn on_relaychain(block_number: u32) -> i32 { From c7b73ea4b723ea1a2de818e338505f72e443dd83 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Tue, 25 Jun 2024 21:32:20 +0800 Subject: [PATCH 07/44] feat:Randomly select a collator to listen to events --- client/coretime/bulk/src/lib.rs | 78 +++++++++++++++++++++++------ client/coretime/common/src/lib.rs | 24 +++++++++ node/src/service.rs | 6 ++- primitives/coretime/bulk/src/lib.rs | 2 + 4 files changed, 92 insertions(+), 18 deletions(-) diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index fd5deb8..2f04325 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -13,7 +13,6 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -use cumulus_primitives_core::BlockT; use cumulus_primitives_core::ParaId; use cumulus_relay_chain_interface::RelayChainInterface; use polkadot_primitives::AccountId; @@ -26,6 +25,7 @@ use std::error::Error; use std::sync::Arc; mod metadata; use codec::{Codec, Decode}; +use cumulus_primitives_core::relay_chain::BlockNumber as RelayBlockNumber; use dp_chain_state_snapshot::GenericStateProof; use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; use mc_coretime_common::is_parathread; @@ -36,10 +36,12 @@ use mp_coretime_bulk::{self, well_known_keys::broker_regions}; use pallet_broker::RegionRecord; use pallet_broker::{CoreMask, RegionId}; use sp_application_crypto::AppPublic; +use sp_consensus_aura::AuraApi; use sp_core::{crypto::Pair, H256}; +use sp_keystore::KeystorePtr; use sp_runtime::{ codec::Encode, - traits::{AtLeast32BitUnsigned, Header as HeaderT, MaybeDisplay, Member}, + traits::{AtLeast32BitUnsigned, Block as BlockT, Header as HeaderT, MaybeDisplay, Member}, }; use sp_state_machine::StorageProof; use sp_storage::StorageKey; @@ -61,30 +63,57 @@ fn u8_array_to_u128(array: [u8; 10]) -> u128 { result } -pub async fn coretime_bulk_task( +pub async fn coretime_bulk_task( + parachain: &P, relay_chain: R, + height: RelayBlockNumber, p_hash: H256, para_id: ParaId, bulk_record: Arc>, + keystore: KeystorePtr, ) -> Result<(), Box> where + Block: BlockT, + P: ProvideRuntimeApi + UsageProvider, R: RelayChainInterface + Clone, + P::Api: AuraApi, + PB: Pair + 'static, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, { // Determine whether it is a parathread let parathread = is_parathread(relay_chain, p_hash, para_id).await?; if !parathread { return Ok(()); } - // Query CoreAssigned Event + + // Randomly select a collator to perform the following operations. + let hash = parachain.usage_info().chain.finalized_hash; + let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; + let auth_len = authorities.len() as u32; + let idx = height % auth_len; + let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; + + if collator_public.is_none() { + return Ok(()); + } + // Query Broker Assigned Event let api = OnlineClient::::from_url("ws://127.0.0.1:8855").await?; let block = api.blocks().at_latest().await?; + { + let mut bulk_record_local = bulk_record.lock().await; + let pre_block_height = bulk_record_local.coretime_para_height; + let block_number = block.number(); + if pre_block_height != block_number { + bulk_record_local.coretime_para_height = block_number; + } else { + return Ok(()); + } + } + let events = block.events().await?; for event in events.iter() { let event = event?; - let pallet = event.pallet_name(); - let variant = event.variant_name(); - let field_values = event.field_values()?; - log::info!("{:?},{:?},{:?}", pallet, variant, field_values); let event_detail = event.as_event::(); if let Ok(assigned_event) = event_detail { if let Some(ev) = assigned_event { @@ -134,12 +163,20 @@ where Ok(()) } -pub async fn run_coretime_bulk_task( +pub async fn run_coretime_bulk_task( + parachain: Arc

, relay_chain: R, para_id: ParaId, bulk_record: Arc>, + keystore: KeystorePtr, ) where + Block: BlockT, + P: ProvideRuntimeApi + UsageProvider, R: RelayChainInterface + Clone, + P::Api: AuraApi, + PB: Pair + 'static, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, { let relay_chain_notification = async move { let new_best_heads = relay_chain @@ -153,8 +190,7 @@ pub async fn run_coretime_bulk_task( h = new_best_heads.next() => { match h { Some((height, hash)) => { - log::info!("{:?},{:?}",height, hash); - coretime_bulk_task(relay_chain.clone(), hash, para_id, bulk_record.clone()).await?; + coretime_bulk_task::<_,_,_, PB>(&*parachain, relay_chain.clone(), height, hash, para_id, bulk_record.clone(), keystore.clone()).await?; }, None => { return Ok::<(), Box>(()); @@ -169,20 +205,30 @@ pub async fn run_coretime_bulk_task( } } -pub fn spawn_bulk_task( - parachain: Arc, +pub fn spawn_bulk_task( + parachain: Arc

, para_id: ParaId, relay_chain: R, task_manager: &TaskManager, bulk_record: Arc>, + keystore: KeystorePtr, ) -> sc_service::error::Result<()> where Block: BlockT, R: RelayChainInterface + Clone + 'static, - T: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, + P: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, + P::Api: AuraApi, + PB: Pair + 'static, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, { - let coretime_bulk_task = - run_coretime_bulk_task(relay_chain.clone(), para_id, bulk_record.clone()); + let coretime_bulk_task = run_coretime_bulk_task::<_, _, _, PB>( + parachain.clone(), + relay_chain.clone(), + para_id, + bulk_record.clone(), + keystore, + ); task_manager .spawn_essential_handle() .spawn("bulk task", "magport", coretime_bulk_task); diff --git a/client/coretime/common/src/lib.rs b/client/coretime/common/src/lib.rs index 462d57c..6c9ff84 100644 --- a/client/coretime/common/src/lib.rs +++ b/client/coretime/common/src/lib.rs @@ -26,7 +26,9 @@ use runtime_parachains::{configuration::HostConfiguration, paras::ParaLifecycle} use sc_client_api::UsageProvider; use sc_service::TaskManager; use sp_api::ProvideRuntimeApi; +use sp_core::crypto::{ByteArray, Pair}; use sp_core::H256; +use sp_keystore::KeystorePtr; use sp_state_machine::StorageProof; use sp_storage::StorageKey; use std::error::Error; @@ -39,6 +41,7 @@ use subxt::{ utils::MultiSignature, Config, OnlineClient, PolkadotConfig, }; +type AuthorityId

=

::Public; pub async fn is_parathread( relay_chain: impl RelayChainInterface + Clone, @@ -62,3 +65,24 @@ pub async fn is_parathread( }; Ok(is_parathread) } + +pub async fn order_slot( + idx: u32, + authorities: &[AuthorityId

], + keystore: &KeystorePtr, +) -> Option { + if authorities.is_empty() { + return None; + } + + let expected_author = authorities.get(idx as usize).expect( + "authorities not empty; index constrained to list length;this is a valid index; qed", + ); + + if keystore.has_keys(&[(expected_author.to_raw_vec(), sp_application_crypto::key_types::AURA)]) + { + Some(expected_author.clone()) + } else { + None + } +} diff --git a/node/src/service.rs b/node/src/service.rs index f3244b4..f435913 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -486,14 +486,16 @@ async fn start_node_impl( let bulk_mem_record = Arc::new(Mutex::new(BulkMemRecord { storage_proof: StorageProof::empty(), storage_root: Default::default(), + coretime_para_height: 0, region_id: 0u128.into(), })); - spawn_bulk_task( + spawn_bulk_task::<_, _, _, sp_consensus_aura::sr25519::AuthorityPair>( client.clone(), para_id, relay_chain_interface.clone(), &task_manager, bulk_mem_record.clone(), + params.keystore_container.keystore().clone(), )?; start_consensus( client.clone(), @@ -642,7 +644,7 @@ fn start_consensus( .await; let bulk_inherent = bulk_inherent.ok_or_else(|| { Box::::from( - "Failed to create order inherent", + "Failed to create bulk inherent", ) })?; Ok(bulk_inherent) diff --git a/primitives/coretime/bulk/src/lib.rs b/primitives/coretime/bulk/src/lib.rs index 4e82b34..c3fc180 100644 --- a/primitives/coretime/bulk/src/lib.rs +++ b/primitives/coretime/bulk/src/lib.rs @@ -47,6 +47,8 @@ pub struct BulkInherentData { pub struct BulkMemRecord { /// Proof of coretime parachain storage. pub storage_proof: sp_trie::StorageProof, + /// Block height of coretime parachain. + pub coretime_para_height: u32, /// Root of coretime parachain storage. pub storage_root: PHash, pub region_id: RegionId, From 4d557e9cba1d300c96440f615903daa6ba14cb74 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Wed, 26 Jun 2024 21:27:49 +0800 Subject: [PATCH 08/44] 1.add genis config 2.add trait for get gas cost --- Cargo.lock | 1 + client/coretime/bulk/src/lib.rs | 165 ++++++++++++------ node/src/service.rs | 48 ++--- pallets/bulk/src/lib.rs | 107 ++++++++++-- .../coretime/bulk/src/inherent_client.rs | 38 +--- primitives/coretime/bulk/src/lib.rs | 46 +++-- primitives/coretime/common/src/lib.rs | 7 - .../coretime/common/src/well_known_keys.rs | 8 +- runtime/Cargo.toml | 3 + runtime/src/lib.rs | 26 ++- 10 files changed, 291 insertions(+), 158 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 9e123f2..f1b0f16 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -8642,6 +8642,7 @@ dependencies = [ "frame-try-runtime", "hex-literal", "log", + "mp-coretime-bulk", "mp-system", "pallet-assets", "pallet-assets-bridge", diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 2f04325..61759b5 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -15,6 +15,7 @@ // along with Magnet. If not, see . use cumulus_primitives_core::ParaId; use cumulus_relay_chain_interface::RelayChainInterface; +use mp_coretime_bulk::BulkStatus; use polkadot_primitives::AccountId; use polkadot_primitives::Balance; use sc_client_api::UsageProvider; @@ -29,10 +30,12 @@ use cumulus_primitives_core::relay_chain::BlockNumber as RelayBlockNumber; use dp_chain_state_snapshot::GenericStateProof; use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; use mc_coretime_common::is_parathread; +use metadata::api::runtime_types::pallet_broker::coretime_interface; use metadata::api::{runtime_types, runtime_types::coretime_rococo_runtime as polakdot_runtime}; use mp_coretime_bulk::well_known_keys::REGIONS; use mp_coretime_bulk::BulkMemRecord; use mp_coretime_bulk::{self, well_known_keys::broker_regions}; +use pallet_broker::CoreAssignment; use pallet_broker::RegionRecord; use pallet_broker::{CoreMask, RegionId}; use sp_application_crypto::AppPublic; @@ -54,6 +57,10 @@ use subxt::{ utils::MultiSignature, Config, OnlineClient, PolkadotConfig, }; +// use subxt::ext::scale_encode; +// use subxt::ext::scale_decode; +// use subxt::ext::scale_decode::DecodeAsType; +// use subxt::ext::scale_encode::EncodeAsType; fn u8_array_to_u128(array: [u8; 10]) -> u128 { let mut result: u128 = 0; @@ -63,6 +70,32 @@ fn u8_array_to_u128(array: [u8; 10]) -> u128 { result } +// #[derive(Encode, Decode)] +// enum CoretimeParaRuntimePallets { +// #[codec(index = 50)] +// Broker(BrokerProviderEvents), +// } + +// #[derive(Encode, Decode, EncodeAsType, DecodeAsType)] +// struct CoreAssigned { +// /// The index of the Core which has been assigned. +// core: u16, +// /// The Relay-chain block at which this assignment should take effect. +// when: u32, +// /// The workload to be done on the Core. +// assignment: Vec<(CoreAssignment, u16)>, +// } +// impl subxt::events::StaticEvent for CoreAssigned { +// const PALLET: &'static str = "Broker"; +// const EVENT: &'static str = "CoreAssigned"; +// } + +// #[derive(Encode, Decode)] +// enum BrokerProviderEvents { +// #[codec(index = 26)] +// CoreAssigned(CoreAssigned), +// } + pub async fn coretime_bulk_task( parachain: &P, relay_chain: R, @@ -94,67 +127,93 @@ where let idx = height % auth_len; let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; - if collator_public.is_none() { - return Ok(()); - } + // if collator_public.is_none() { + // return Ok(()); + // } + let mut bulk_record_local = bulk_record.lock().await; + let bulk_status = bulk_record_local.status.clone(); // Query Broker Assigned Event let api = OnlineClient::::from_url("ws://127.0.0.1:8855").await?; let block = api.blocks().at_latest().await?; - { - let mut bulk_record_local = bulk_record.lock().await; - let pre_block_height = bulk_record_local.coretime_para_height; - let block_number = block.number(); - if pre_block_height != block_number { - bulk_record_local.coretime_para_height = block_number; - } else { - return Ok(()); - } + let pre_block_height = bulk_record_local.coretime_para_height; + let block_number = block.number(); + if pre_block_height != block_number { + bulk_record_local.coretime_para_height = block_number; + } else { + return Ok(()); } let events = block.events().await?; for event in events.iter() { let event = event?; - let event_detail = event.as_event::(); - if let Ok(assigned_event) = event_detail { - if let Some(ev) = assigned_event { - log::info!("{:?},{:?},{:?}", ev.region_id, ev.task, ev.duration); - let pid: u32 = para_id.into(); - if ev.task == pid { - // - let rpc_client = RpcClient::from_url("ws://127.0.0.1:8855").await?; - let rpc = LegacyRpcMethods::::new(rpc_client.clone()); - let mask = u8_array_to_u128(ev.region_id.mask.0); - let core_mask = CoreMask::from(mask); - let region_id = RegionId { - begin: ev.region_id.begin, - core: ev.region_id.core, - mask: core_mask, - }; - println!("region_id:{:?}", region_id); - let key = broker_regions(region_id); - println!("key:{:?}", key); - let mut relevant_keys = Vec::new(); - relevant_keys.push(key.as_slice()); - let proof = rpc - .state_get_read_proof(relevant_keys, Some(events.block_hash())) - .await - .unwrap(); - let storage_proof = - StorageProof::new(proof.proof.into_iter().map(|bytes| bytes.to_vec())); - println!("{:?}", storage_proof); - let storage_root = block.header().state_root; - let relay_storage_rooted_proof: GenericStateProof< - cumulus_primitives_core::relay_chain::Block, - > = GenericStateProof::new(storage_root, storage_proof.clone()).unwrap(); - let head_data = relay_storage_rooted_proof - .read_entry::>(key.as_slice(), None) - .ok(); - println!("head_data:{:?}", head_data); - if let Some(region_record) = head_data { - let mut bulk_record_local = bulk_record.lock().await; - bulk_record_local.storage_proof = storage_proof; - bulk_record_local.storage_root = storage_root; - bulk_record_local.region_id = region_id; + if bulk_status == BulkStatus::Purchased { + let ev_assigned = event.as_event::(); + if let Ok(assigned_event) = ev_assigned { + if let Some(ev) = assigned_event { + log::info!("{:?},{:?},{:?}", ev.region_id, ev.task, ev.duration); + let pid: u32 = para_id.into(); + if ev.task == pid { + // + let rpc_client = RpcClient::from_url("ws://127.0.0.1:8855").await?; + let rpc = LegacyRpcMethods::::new(rpc_client.clone()); + let mask = u8_array_to_u128(ev.region_id.mask.0); + let core_mask = CoreMask::from(mask); + let region_id = RegionId { + begin: ev.region_id.begin, + core: ev.region_id.core, + mask: core_mask, + }; + println!("region_id:{:?}", region_id); + let key = broker_regions(region_id); + println!("key:{:?}", key); + let mut relevant_keys = Vec::new(); + relevant_keys.push(key.as_slice()); + let proof = rpc + .state_get_read_proof(relevant_keys, Some(events.block_hash())) + .await + .unwrap(); + let storage_proof = + StorageProof::new(proof.proof.into_iter().map(|bytes| bytes.to_vec())); + println!("{:?}", storage_proof); + let storage_root = block.header().state_root; + let relay_storage_rooted_proof: GenericStateProof< + cumulus_primitives_core::relay_chain::Block, + > = GenericStateProof::new(storage_root, storage_proof.clone()).unwrap(); + let head_data = relay_storage_rooted_proof + .read_entry::>(key.as_slice(), None) + .ok(); + println!("head_data:{:?}", head_data); + if let Some(region_record) = head_data { + bulk_record_local.storage_proof = storage_proof; + bulk_record_local.storage_root = storage_root; + bulk_record_local.region_id = region_id; + bulk_record_local.status = BulkStatus::Assigned; + bulk_record_local.duration = ev.duration; + } + } + } + continue; + } + } + if bulk_status == BulkStatus::Assigned { + let ev_core_assigned = event.as_event::(); + if let Ok(core_assigned_event) = ev_core_assigned { + if let Some(ev) = core_assigned_event { + log::info!("{:?},{:?},{:?}", ev.core, ev.when, ev.assignment); + for (core_assign, _) in ev.assignment { + if let coretime_interface::CoreAssignment::Task(id) = core_assign { + let pid: u32 = para_id.into(); + if id == pid { + bulk_record_local.start_relaychain_height = ev.when; + let constant_query = + metadata::api::ConstantsApi.broker().timeslice_period(); + let time_slice = api.constants().at(&constant_query)?; + bulk_record_local.end_relaychain_height = + ev.when + bulk_record_local.duration * time_slice; + // find it. + bulk_record_local.status = BulkStatus::CoreAssigned; + } + } } } } diff --git a/node/src/service.rs b/node/src/service.rs index f435913..ac01f7c 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -51,6 +51,7 @@ use futures::lock::Mutex; // use magnet_primitives_order::{OrderRecord, OrderStatus}; use mc_coretime_bulk::spawn_bulk_task; use mp_coretime_bulk::BulkMemRecord; +use mp_coretime_bulk::BulkStatus; use sp_core::ByteArray; use sp_runtime::AccountId32; use sp_trie::StorageProof; @@ -488,6 +489,10 @@ async fn start_node_impl( storage_root: Default::default(), coretime_para_height: 0, region_id: 0u128.into(), + start_relaychain_height: 0, + end_relaychain_height: 0, + status: BulkStatus::Purchased, + duration: 0, })); spawn_bulk_task::<_, _, _, sp_consensus_aura::sr25519::AuthorityPair>( client.clone(), @@ -603,45 +608,24 @@ fn start_consensus( let params = BasicAuraParams { // create_inherent_data_providers: move |_, ()| async move { Ok(()) }, create_inherent_data_providers: move |_, ()| { - // let relay_chain_interface = relay_chain_interface.clone(); let bulk_mem_record_clone = bulk_mem_record.clone(); async move { - // let parent_hash = relay_chain_interface.best_block_hash().await?; - // let (relay_parent, validation_data, sequence_number, author_pub) = { - // let order_record_local = order_record_clone.lock().await; - // if order_record_local.validation_data.is_none() { - // (parent_hash, None, order_record_local.sequence_number, None) - // } else { - // ( - // order_record_local.relay_parent.expect("can not get relay_parent hash"), - // order_record_local.validation_data.clone(), - // order_record_local.sequence_number, - // order_record_local.author_pub.clone(), - // ) - // } - // }; - // let order_inherent = magnet_primitives_order::OrderInherentData::create_at( - // relay_parent, - // &relay_chain_interface, - // &validation_data, - // para_id, - // sequence_number, - // &author_pub, - // ) - // .await; - // let order_inherent = order_inherent.ok_or_else(|| { - // Box::::from( - // "Failed to create order inherent", - // ) - // })?; - // Ok(order_inherent) - let bulk_mem_record_clone_local = bulk_mem_record_clone.lock().await; + let mut bulk_mem_record_clone_local = bulk_mem_record_clone.lock().await; + let storage_proof = + if bulk_mem_record_clone_local.status == BulkStatus::CoreAssigned { + Some(&bulk_mem_record_clone_local.storage_proof) + } else { + None + }; let bulk_inherent = mp_coretime_bulk::BulkInherentData::create_at( - &bulk_mem_record_clone_local.storage_proof, + storage_proof, bulk_mem_record_clone_local.storage_root, bulk_mem_record_clone_local.region_id, + bulk_mem_record_clone_local.start_relaychain_height, + bulk_mem_record_clone_local.end_relaychain_height, ) .await; + bulk_mem_record_clone_local.status = BulkStatus::Purchased; let bulk_inherent = bulk_inherent.ok_or_else(|| { Box::::from( "Failed to create bulk inherent", diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index 6b44f41..318cb82 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -69,6 +69,10 @@ pub struct BulkRecord { pub price: Balance, /// Purchase duration. pub duration: u32, + /// Relaychain block number of start schedule coretime core. + pub start_relaychain_height: u32, + /// Relaychain block number of end schedule coretime core. + pub end_relaychain_height: u32, } #[frame_support::pallet] pub mod pallet { @@ -82,6 +86,8 @@ pub mod pallet { type Currency: Currency; + type RelayChainStateProvider: cumulus_pallet_parachain_system::RelaychainStateProvider; + type AuthorityId: Member + Parameter + RuntimeAppPublic @@ -92,11 +98,20 @@ pub mod pallet { type UpdateOrigin: EnsureOrigin; type WeightInfo: WeightInfo; + + /// Max length of url, coretime parachain rpc url. + #[pallet::constant] + type MaxUrlLength: Get; } #[pallet::pallet] pub struct Pallet(PhantomData); + /// Url storage. + #[pallet::storage] + #[pallet::getter(fn coretime_rpc_url)] + pub type RpcUrl = StorageValue<_, BoundedVec, OptionQuery>; + #[pallet::type_value] pub fn RecordIndexOnEmpty() -> u32 { 0 @@ -112,6 +127,25 @@ pub mod pallet { pub type BulkRecords = StorageMap<_, Twox64Concat, u32, BulkRecord, T::AuthorityId>, OptionQuery>; + #[pallet::genesis_config] + pub struct GenesisConfig { + pub rpc_url: BoundedVec, + pub _marker: PhantomData, + } + + impl Default for GenesisConfig { + fn default() -> Self { + Self { rpc_url: BoundedVec::new(), _marker: Default::default() } + } + } + + #[pallet::genesis_build] + impl BuildGenesisConfig for GenesisConfig { + fn build(&self) { + RpcUrl::::put(&self.rpc_url); + } + } + #[pallet::event] #[pallet::generate_deposit(pub(super) fn deposit_event)] pub enum Event { @@ -138,9 +172,16 @@ pub mod pallet { const INHERENT_IDENTIFIER: InherentIdentifier = mp_coretime_bulk::INHERENT_IDENTIFIER; fn create_inherent(data: &InherentData) -> Option { - let data = data.get_data(&mp_coretime_bulk::INHERENT_IDENTIFIER).ok().flatten(); + let data: Option = + data.get_data(&mp_coretime_bulk::INHERENT_IDENTIFIER).ok().flatten(); match data { - Some(data) => Some(Call::create_record { data }), + Some(data) => { + if data.storage_proof.is_none() { + None + } else { + Some(Call::create_record { data }) + } + }, None => None, } } @@ -165,11 +206,16 @@ pub mod pallet { ) -> DispatchResultWithPostInfo { ensure_none(origin)?; - let mp_coretime_bulk::BulkInherentData { storage_proof, storage_root, region_id } = - data; + let mp_coretime_bulk::BulkInherentData { + storage_proof, + storage_root, + region_id, + start_relaychain_height, + end_relaychain_height, + } = data; let relay_storage_rooted_proof: GenericStateProof< cumulus_primitives_core::relay_chain::Block, - > = GenericStateProof::new(storage_root, storage_proof).unwrap(); + > = GenericStateProof::new(storage_root, storage_proof.unwrap()).unwrap(); let key = broker_regions(region_id); let region_record_data = relay_storage_rooted_proof .read_entry::>>(key.as_slice(), None) @@ -182,24 +228,53 @@ pub mod pallet { purchaser: region_record.owner, price: region_record.paid.unwrap(), duration: region_record.end, + start_relaychain_height, + end_relaychain_height, }, ); + RecordIndex::::set(old_record_index + 1); } let total_weight = T::DbWeight::get().reads_writes(2, 1); Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) } + + /// Set coretime parachain rpc url. + /// + /// Parameters: + /// - `url`: Url. + #[pallet::call_index(1)] + #[pallet::weight(0)] + pub fn set_rpc_url( + origin: OriginFor, + url: BoundedVec, + ) -> DispatchResult { + T::UpdateOrigin::ensure_origin(origin)?; + + RpcUrl::::put(url.clone()); + + Ok(()) + } + } +} + +impl Pallet { + pub fn rpc_url() -> Vec { + let rpc_url = RpcUrl::::get(); + if let Some(url) = rpc_url { + url.into() + } else { + Vec::new() + } } } -impl Pallet {} - -// pub trait OrderGasCost { -// /// Gas consumed by placing an order in a certain block. -// /// -// /// Parameters: -// /// - `block_number`: The block number of para chain. -// fn gas_cost( -// block_number: BlockNumberFor, -// ) -> Result, DispatchError>; -// } +pub trait BulkGasCost { + /// In Bulk mode, the average gas consumed by a block. + /// + /// Parameters: + /// - `block_number`: The block number of para chain. + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, DispatchError>; +} diff --git a/primitives/coretime/bulk/src/inherent_client.rs b/primitives/coretime/bulk/src/inherent_client.rs index 72fb223..3ad57b3 100644 --- a/primitives/coretime/bulk/src/inherent_client.rs +++ b/primitives/coretime/bulk/src/inherent_client.rs @@ -24,47 +24,25 @@ use { cumulus_relay_chain_interface::{PHash, RelayChainInterface}, }; -/// Collect the relevant coretime para chain state in form of a proof -/// for putting it into the bulk inherent. -// async fn collect_coretime_parachain_storage_proof( -// region_id: RegionId, -// ) -> Option { -// let mut relevant_keys = Vec::new(); -// //Broker Regions -// relevant_keys.push(broker_regions(region_id)); - -// // let relay_storage_proof = relay_chain_interface.prove_read(relay_parent, &relevant_keys).await; -// // match relay_storage_proof { -// // Ok(proof) => Some(proof), -// // Err(err) => { -// // log::info!("RelayChainError:{:?}", err); -// // None -// // }, -// // } -// None -// } - impl BulkInherentData { /// Create the [`BulkInherentData`] at the given `relay_parent`. /// /// Returns `None` if the creation failed. pub async fn create_at( - // relay_parent: PHash, - // author_pub: &AuthorityId, - // region_id: RegionId, - storage_proof: &sp_trie::StorageProof, + storage_proof: Option<&sp_trie::StorageProof>, storage_root: PHash, region_id: RegionId, + start: u32, + end: u32, ) -> Option { - // let storage_proof = collect_coretime_parachain_storage_proof(region_id).await?; - + let storage_proof = + if let Some(proof) = storage_proof { Some(proof.clone()) } else { None }; Some(BulkInherentData { - storage_proof: storage_proof.clone(), + storage_proof, storage_root, region_id, - // purchaser: author_pub.clone(), - // price: 0, - // duration: 0, + start_relaychain_height: start, + end_relaychain_height: end, }) } } diff --git a/primitives/coretime/bulk/src/lib.rs b/primitives/coretime/bulk/src/lib.rs index c3fc180..311c20a 100644 --- a/primitives/coretime/bulk/src/lib.rs +++ b/primitives/coretime/bulk/src/lib.rs @@ -37,31 +37,53 @@ use {scale_info::TypeInfo, sp_inherents::InherentIdentifier}; #[derive(Encode, Decode, sp_core::RuntimeDebug, Clone, PartialEq, TypeInfo)] pub struct BulkInherentData { /// Proof of coretime parachain storage. - pub storage_proof: sp_trie::StorageProof, + pub storage_proof: Option, /// Root of coretime parachain storage. pub storage_root: PHash, + /// The identity of the Region. pub region_id: RegionId, + /// Relaychain block number of start schedule coretime core. + pub start_relaychain_height: u32, + /// Relaychain block number of end schedule coretime core. + pub end_relaychain_height: u32, +} + +/// Status of bulk purchased then assigned. +#[derive(Clone, PartialEq, Eq)] +pub enum BulkStatus { + /// User call broker purchase. + Purchased, + /// User call broker assign. + Assigned, + /// broker do_tick(). + CoreAssigned, } #[derive(Clone)] pub struct BulkMemRecord { - /// Proof of coretime parachain storage. - pub storage_proof: sp_trie::StorageProof, /// Block height of coretime parachain. pub coretime_para_height: u32, + /// Proof of coretime parachain storage. + pub storage_proof: sp_trie::StorageProof, /// Root of coretime parachain storage. pub storage_root: PHash, + /// The identity of the Region. pub region_id: RegionId, + /// Relaychain block number of start schedule coretime core. + pub start_relaychain_height: u32, + /// Relaychain block number of end schedule coretime core. + pub end_relaychain_height: u32, + pub duration: u32, + pub status: BulkStatus, } + // Identifier of the order inherent pub const INHERENT_IDENTIFIER: InherentIdentifier = *b"bulkihrt"; -// sp_api::decl_runtime_apis! { -// #[api_version(2)] -// pub trait BulkRuntimeApi where -// Balance: Codec + MaybeDisplay, -// AuthorityId:Codec -// { - -// } -// } +sp_api::decl_runtime_apis! { + #[api_version(2)] + pub trait BulkRuntimeApi + { + fn rpc_url() -> Vec; + } +} diff --git a/primitives/coretime/common/src/lib.rs b/primitives/coretime/common/src/lib.rs index eea99a8..236265b 100644 --- a/primitives/coretime/common/src/lib.rs +++ b/primitives/coretime/common/src/lib.rs @@ -20,11 +20,4 @@ //! the order pallet inherent //! #![cfg_attr(not(feature = "std"), no_std)] -use cumulus_primitives_core::{ - relay_chain::BlockNumber as RelayBlockNumber, relay_chain::Hash as PHash, ParaId, - PersistedValidationData, -}; -use sp_core::H256; -use sp_runtime::sp_std::vec::Vec; -use sp_runtime::traits::MaybeDisplay; pub mod well_known_keys; diff --git a/primitives/coretime/common/src/well_known_keys.rs b/primitives/coretime/common/src/well_known_keys.rs index 269454c..a8bb99e 100644 --- a/primitives/coretime/common/src/well_known_keys.rs +++ b/primitives/coretime/common/src/well_known_keys.rs @@ -17,13 +17,7 @@ //! Keys of well known. #![cfg_attr(not(feature = "std"), no_std)] -use cumulus_primitives_core::relay_chain::CoreIndex; -use { - cumulus_primitives_core::ParaId, - sp_core::Encode, - sp_io::hashing::{blake2_128, twox_256, twox_64}, - sp_std::vec::Vec, -}; +use {cumulus_primitives_core::ParaId, sp_core::Encode, sp_io::hashing::twox_64, sp_std::vec::Vec}; pub const PARAS_PARA_LIFECYCLES: &[u8] = &hex_literal::hex!["cd710b30bd2eab0352ddcc26417aa194281e0bfde17b36573208a06cb5cfba6b"]; diff --git a/runtime/Cargo.toml b/runtime/Cargo.toml index e4abff8..4b8471f 100644 --- a/runtime/Cargo.toml +++ b/runtime/Cargo.toml @@ -32,6 +32,8 @@ pallet-pot-runtime-api = { path = "../pallets/pot/runtime-api", default-features pallet-assurance = { path = "../pallets/assurance", default-features = false } pallet-liquidation = {path = "../pallets/liquidation", default-features = false} pallet-bulk = { path = "../pallets/bulk", default-features = false } +mp-coretime-bulk = { path = "../primitives/coretime/bulk", default-features = false } + # Substrate frame-benchmarking = { workspace = true, default-features = false, optional = true} @@ -205,6 +207,7 @@ std = [ "pallet-insecure-randomness-collective-flip/std", "pallet-contracts/std", "pallet-bulk/std", + "mp-coretime-bulk/std", ] runtime-benchmarks = [ diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index ecf8d83..a413ae9 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -86,7 +86,7 @@ use weights::{BlockExecutionWeight, ExtrinsicBaseWeight}; // XCM Imports use cumulus_primitives_core::{AggregateMessageOrigin, ParaId, PersistedValidationData}; -pub use pallet_bulk; +pub use pallet_bulk::{self, BulkGasCost}; // pub use pallet_order::{self, OrderGasCost}; use xcm::latest::prelude::{ Asset as MultiAsset, BodyId, InteriorLocation as InteriorMultiLocation, @@ -737,12 +737,30 @@ type EnsureRootOrHalf = EitherOfDiverse< // type TxPoolThreshold = TxPoolThreshold; // type WeightInfo = pallet_order::weights::SubstrateWeight; // } +pub struct OrderGasCostHandler(); + +impl BulkGasCost for OrderGasCostHandler +where + T: pallet_bulk::Config, + T::AccountId: From<[u8; 32]>, +{ + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError> { + Ok(None) + } +} +parameter_types! { + pub const MaxUrlLength: u32 = 300; +} impl pallet_bulk::Config for Runtime { type RuntimeEvent = RuntimeEvent; type AuthorityId = AuraId; type Currency = Balances; + type RelayChainStateProvider = cumulus_pallet_parachain_system::RelaychainDataProvider; type UpdateOrigin = EnsureRootOrHalf; + type MaxUrlLength = MaxUrlLength; type WeightInfo = (); } @@ -1580,6 +1598,12 @@ impl_runtime_apis! { // OrderPallet::order_executed(sequence_number) // } // } + impl mp_coretime_bulk::BulkRuntimeApi for Runtime { + + fn rpc_url()-> Vec{ + BulkPallet::rpc_url() + } + } impl mp_system::OnRelayChainApi for Runtime { fn on_relaychain(block_number: u32) -> i32 { From f892b1a0b4e53ba76fc1f6ecd4b046264929439b Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Thu, 27 Jun 2024 16:18:59 +0800 Subject: [PATCH 09/44] complete bulk mode gas cost function.make workflow cargo test normal --- client/coretime/bulk/src/lib.rs | 13 ++++++---- node/src/chain_spec.rs | 3 +++ pallets/bulk/src/lib.rs | 8 ++++++ pallets/liquidation/src/mock.rs | 38 ++++++++++++++--------------- primitives/coretime/bulk/src/lib.rs | 1 + runtime/src/lib.rs | 34 +++++++++++++++++++++++--- 6 files changed, 70 insertions(+), 27 deletions(-) diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 61759b5..5e90150 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -34,6 +34,7 @@ use metadata::api::runtime_types::pallet_broker::coretime_interface; use metadata::api::{runtime_types, runtime_types::coretime_rococo_runtime as polakdot_runtime}; use mp_coretime_bulk::well_known_keys::REGIONS; use mp_coretime_bulk::BulkMemRecord; +use mp_coretime_bulk::BulkRuntimeApi; use mp_coretime_bulk::{self, well_known_keys::broker_regions}; use pallet_broker::CoreAssignment; use pallet_broker::RegionRecord; @@ -109,7 +110,7 @@ where Block: BlockT, P: ProvideRuntimeApi + UsageProvider, R: RelayChainInterface + Clone, - P::Api: AuraApi, + P::Api: AuraApi + BulkRuntimeApi, PB: Pair + 'static, PB::Public: AppPublic + Member + Codec, PB::Signature: TryFrom> + Member + Codec, @@ -133,7 +134,9 @@ where let mut bulk_record_local = bulk_record.lock().await; let bulk_status = bulk_record_local.status.clone(); // Query Broker Assigned Event - let api = OnlineClient::::from_url("ws://127.0.0.1:8855").await?; + let url = parachain.runtime_api().rpc_url(hash)?; + let rpc_url = std::str::from_utf8(&url)?; + let api = OnlineClient::::from_url(rpc_url).await?; let block = api.blocks().at_latest().await?; let pre_block_height = bulk_record_local.coretime_para_height; let block_number = block.number(); @@ -154,7 +157,7 @@ where let pid: u32 = para_id.into(); if ev.task == pid { // - let rpc_client = RpcClient::from_url("ws://127.0.0.1:8855").await?; + let rpc_client = RpcClient::from_url(rpc_url).await?; let rpc = LegacyRpcMethods::::new(rpc_client.clone()); let mask = u8_array_to_u128(ev.region_id.mask.0); let core_mask = CoreMask::from(mask); @@ -232,7 +235,7 @@ pub async fn run_coretime_bulk_task( Block: BlockT, P: ProvideRuntimeApi + UsageProvider, R: RelayChainInterface + Clone, - P::Api: AuraApi, + P::Api: AuraApi + BulkRuntimeApi, PB: Pair + 'static, PB::Public: AppPublic + Member + Codec, PB::Signature: TryFrom> + Member + Codec, @@ -276,7 +279,7 @@ where Block: BlockT, R: RelayChainInterface + Clone + 'static, P: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, - P::Api: AuraApi, + P::Api: AuraApi + BulkRuntimeApi, PB: Pair + 'static, PB::Public: AppPublic + Member + Codec, PB::Signature: TryFrom> + Member + Codec, diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index 238d32d..1749e9a 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -282,5 +282,8 @@ fn testnet_genesis( }, "evm": { "accounts": evm_accounts }, + "bulkPallet":{ + "rpcUrl": b"ws://127.0.0.1:8855".to_vec() + }, }) } diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index 318cb82..bdda5bd 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -43,6 +43,7 @@ use primitives::{Id as ParaId, PersistedValidationData}; use sp_runtime::sp_std::{prelude::*, vec}; use sp_runtime::{traits::Member, RuntimeAppPublic}; pub mod weights; +use cumulus_pallet_parachain_system::RelaychainStateProvider; use dp_chain_state_snapshot::GenericStateProof; use pallet_broker::RegionRecord; use sp_core::crypto::ByteArray; @@ -259,6 +260,7 @@ pub mod pallet { } impl Pallet { + /// Get coretime parachain rpc url. pub fn rpc_url() -> Vec { let rpc_url = RpcUrl::::get(); if let Some(url) = rpc_url { @@ -267,6 +269,12 @@ impl Pallet { Vec::new() } } + + /// Get relaychain blocknumber. + pub fn relaychain_block_number() -> u32 { + let relay_chain_state = T::RelayChainStateProvider::current_relay_chain_state(); + relay_chain_state.number + } } pub trait BulkGasCost { diff --git a/pallets/liquidation/src/mock.rs b/pallets/liquidation/src/mock.rs index 1308232..b9a8a09 100644 --- a/pallets/liquidation/src/mock.rs +++ b/pallets/liquidation/src/mock.rs @@ -19,8 +19,8 @@ use sp_runtime::{ AccountId32, BuildStorage, Perbill, }; +use crate::OrderGasCost; use frame_system::pallet_prelude::BlockNumberFor; -use pallet_order::OrderGasCost; use sp_consensus_aura::sr25519::AuthorityId as AuraId; use sp_std::{cell::RefCell, collections::btree_map::BTreeMap}; use xcm::latest::{Assets, Location, SendError, SendResult, SendXcm, Xcm, XcmHash}; @@ -44,7 +44,7 @@ frame_support::construct_runtime!( { System: frame_system::{Pallet, Call, Config, Storage, Event}, Balances: pallet_balances::{Pallet, Call, Storage, Config, Event}, - OrderPallet: pallet_order::{Pallet, Storage, Event}, + // OrderPallet: pallet_order::{Pallet, Storage, Event}, Pot: pallet_pot::{Pallet, Call, Storage, Event}, Utility: pallet_utility::{Pallet, Call, Storage, Event}, Liquidation: pallet_liquidation::{Pallet, Storage, Event}, @@ -134,22 +134,22 @@ impl pallet_utility::Config for Test { type WeightInfo = (); } -parameter_types! { - pub const SlotWidth: u32 = 2; - pub const OrderMaxAmount:Balance = 200000000; - pub const TxPoolThreshold:Balance = 3000000000; -} - -impl pallet_order::Config for Test { - type RuntimeEvent = RuntimeEvent; - type AuthorityId = AuraId; - type Currency = Balances; - type UpdateOrigin = frame_system::EnsureRoot; - type OrderMaxAmount = OrderMaxAmount; - type SlotWidth = SlotWidth; - type TxPoolThreshold = TxPoolThreshold; - type WeightInfo = (); -} +// parameter_types! { +// pub const SlotWidth: u32 = 2; +// pub const OrderMaxAmount:Balance = 200000000; +// pub const TxPoolThreshold:Balance = 3000000000; +// } + +// impl pallet_order::Config for Test { +// type RuntimeEvent = RuntimeEvent; +// type AuthorityId = AuraId; +// type Currency = Balances; +// type UpdateOrigin = frame_system::EnsureRoot; +// type OrderMaxAmount = OrderMaxAmount; +// type SlotWidth = SlotWidth; +// type TxPoolThreshold = TxPoolThreshold; +// type WeightInfo = (); +// } use pallet_pot::PotNameBtreemap; use pallet_xcm::TestWeightInfo; @@ -310,7 +310,7 @@ impl WeightToFeePolynomial for WeightToFee { pub struct MockOrderGasCostHandler; impl OrderGasCost for MockOrderGasCostHandler where - T: pallet_order::Config, + T: crate::Config, T::AccountId: From<[u8; 32]>, { fn gas_cost( diff --git a/primitives/coretime/bulk/src/lib.rs b/primitives/coretime/bulk/src/lib.rs index 311c20a..06a9428 100644 --- a/primitives/coretime/bulk/src/lib.rs +++ b/primitives/coretime/bulk/src/lib.rs @@ -85,5 +85,6 @@ sp_api::decl_runtime_apis! { pub trait BulkRuntimeApi { fn rpc_url() -> Vec; + fn relaychain_block_number()->u32; } } diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index a413ae9..bd31392 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -11,6 +11,8 @@ mod weights; pub mod xcm_config; pub mod xcms; +use core::ops::Div; + use codec::{Decode, Encode}; use cumulus_pallet_parachain_system::RelayNumberStrictlyIncreases; @@ -24,7 +26,7 @@ use sp_runtime::{ create_runtime_str, generic, impl_opaque_keys, traits::{ AccountIdLookup, BlakeTwo256, Block as BlockT, DispatchInfoOf, Dispatchable, Get, - IdentifyAccount, PostDispatchInfoOf, UniqueSaturatedInto, Verify, + IdentifyAccount, PostDispatchInfoOf, Saturating, UniqueSaturatedInto, Verify, }, transaction_validity::{TransactionSource, TransactionValidity, TransactionValidityError}, ApplyExtrinsicResult, ConsensusEngineId, MultiSignature, Percent, @@ -82,8 +84,8 @@ pub use parachains_common::message_queue::{NarrowOriginToSibling, ParaIdToSiblin use polkadot_runtime_common::xcm_sender::NoPriceForMessageDelivery; use polkadot_runtime_common::{BlockHashCount, SlowAdjustingFeeUpdate}; +use sp_runtime::SaturatedConversion; use weights::{BlockExecutionWeight, ExtrinsicBaseWeight}; - // XCM Imports use cumulus_primitives_core::{AggregateMessageOrigin, ParaId, PersistedValidationData}; pub use pallet_bulk::{self, BulkGasCost}; @@ -747,7 +749,29 @@ where fn gas_cost( block_number: BlockNumberFor, ) -> Result, sp_runtime::DispatchError> { - Ok(None) + let record_index = >::record_index(); + let mut result = None; + for i in 0..record_index { + let bulk_record = >::bulk_records(i); + if let Some(record) = bulk_record { + if block_number.into() >= record.start_relaychain_height.into() + && block_number.into() <= record.end_relaychain_height.into() + { + let price: u128 = record.price.saturated_into(); + let duration = + (record.end_relaychain_height - record.start_relaychain_height) as u128; + let balance = price + .checked_div(duration) + .ok_or(sp_runtime::DispatchError::Other("duration error"))?; + let mut r = [0u8; 32]; + r.copy_from_slice(record.purchaser.encode().as_slice()); + let account = T::AccountId::try_from(r) + .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; + result = Some((account, balance)); + } + } + } + Ok(result) } } parameter_types! { @@ -1603,6 +1627,10 @@ impl_runtime_apis! { fn rpc_url()-> Vec{ BulkPallet::rpc_url() } + + fn relaychain_block_number()->u32 { + BulkPallet::relaychain_block_number() + } } impl mp_system::OnRelayChainApi for Runtime { From a335113f85dc31658eab34ed0315134f1d735676 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Thu, 27 Jun 2024 21:49:43 +0800 Subject: [PATCH 10/44] add bulk test code,cargo test success --- client/coretime/bulk/src/lib.rs | 2 + node/src/service.rs | 4 +- pallets/bulk/Cargo.toml | 1 + pallets/bulk/src/lib.rs | 11 +- pallets/bulk/src/mock.rs | 375 ++++++++++++++-------------- pallets/bulk/src/proof_data.rs | 49 ++-- pallets/bulk/src/tests.rs | 135 +++++----- primitives/coretime/bulk/src/lib.rs | 4 +- 8 files changed, 288 insertions(+), 293 deletions(-) diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 5e90150..29b0603 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -200,6 +200,7 @@ where } if bulk_status == BulkStatus::Assigned { let ev_core_assigned = event.as_event::(); + log::info!("ev_core_assigned:{:?}", ev_core_assigned); if let Ok(core_assigned_event) = ev_core_assigned { if let Some(ev) = core_assigned_event { log::info!("{:?},{:?},{:?}", ev.core, ev.when, ev.assignment); @@ -222,6 +223,7 @@ where } } } + log::info!("bulk_record:{:?}", bulk_record_local); Ok(()) } diff --git a/node/src/service.rs b/node/src/service.rs index ac01f7c..412e52b 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -625,7 +625,9 @@ fn start_consensus( bulk_mem_record_clone_local.end_relaychain_height, ) .await; - bulk_mem_record_clone_local.status = BulkStatus::Purchased; + if storage_proof.is_some() { + bulk_mem_record_clone_local.status = BulkStatus::Purchased; + } let bulk_inherent = bulk_inherent.ok_or_else(|| { Box::::from( "Failed to create bulk inherent", diff --git a/pallets/bulk/Cargo.toml b/pallets/bulk/Cargo.toml index f139818..db6da54 100644 --- a/pallets/bulk/Cargo.toml +++ b/pallets/bulk/Cargo.toml @@ -56,6 +56,7 @@ pallet-xcm = { workspace = true, default-features = false} pallet-society ={ workspace = true, default-features = false} xcm-builder = { workspace = true, default-features = false } parachains-common = { workspace = true, default-features = false } +cumulus-pallet-parachain-system = { workspace = true, default-features = false, features = ["parameterized-consensus-hook",] } [features] default = [ "std" ] diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index bdda5bd..946564e 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -48,15 +48,15 @@ use dp_chain_state_snapshot::GenericStateProof; use pallet_broker::RegionRecord; use sp_core::crypto::ByteArray; use weights::WeightInfo; -// #[cfg(test)] -// mod mock; +#[cfg(test)] +mod mock; -// #[cfg(test)] -// mod tests; +#[cfg(test)] +mod tests; // #[cfg(any(test, feature = "runtime-benchmarks"))] // mod benchmarking; -// mod proof_data; +mod proof_data; type BalanceOf = <::Currency as Currency<::AccountId>>::Balance; @@ -214,6 +214,7 @@ pub mod pallet { start_relaychain_height, end_relaychain_height, } = data; + let relay_storage_rooted_proof: GenericStateProof< cumulus_primitives_core::relay_chain::Block, > = GenericStateProof::new(storage_root, storage_proof.unwrap()).unwrap(); diff --git a/pallets/bulk/src/mock.rs b/pallets/bulk/src/mock.rs index 71fa00d..ecec2e9 100644 --- a/pallets/bulk/src/mock.rs +++ b/pallets/bulk/src/mock.rs @@ -1,183 +1,192 @@ -// // Copyright (C) Magnet. -// // This file is part of Magnet. - -// // Magnet is free software: you can redistribute it and/or modify -// // it under the terms of the GNU General Public License as published by -// // the Free Software Foundation, either version 3 of the License, or -// // (at your option) any later version. - -// // Magnet is distributed in the hope that it will be useful, -// // but WITHOUT ANY WARRANTY; without even the implied warranty of -// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// // GNU General Public License for more details. - -// // You should have received a copy of the GNU General Public License -// // along with Magnet. If not, see . - -// use crate::{self as order_pallet, OrderGasCost}; -// use codec::Encode; -// pub use frame_support::{ -// construct_runtime, derive_impl, parameter_types, -// traits::{Everything, Hooks}, -// }; -// use frame_system as system; -// use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; -// pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; -// use sp_core::{crypto::AccountId32, H256}; -// use sp_runtime::{ -// traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, -// BuildStorage, MultiSignature, -// }; - -// type Block = frame_system::mocking::MockBlock; -// type Signature = MultiSignature; -// type AccountId = <::Signer as IdentifyAccount>::AccountId; -// type Balance = u128; -// // Configure a mock runtime to test the pallet. -// construct_runtime!( -// pub enum Test -// { -// System: frame_system::{Pallet, Call, Config, Storage, Event}, -// Balances: pallet_balances::{Pallet, Call, Event}, -// OrderPallet: order_pallet::{Pallet, Call, Storage, Event}, -// MockPallet: mock_pallet, -// } -// ); - -// parameter_types! { -// pub const BlockHashCount: u64 = 250; -// pub const SS58Prefix: u8 = 42; -// } - -// #[derive_impl(frame_system::config_preludes::ParaChainDefaultConfig as frame_system::DefaultConfig)] -// impl system::Config for Test { -// type BaseCallFilter = Everything; -// type BlockWeights = (); -// type BlockLength = (); -// type DbWeight = (); -// type RuntimeOrigin = RuntimeOrigin; -// type RuntimeCall = RuntimeCall; -// type Nonce = u64; -// type Hash = H256; -// type Hashing = BlakeTwo256; -// type AccountId = AccountId32; -// type Lookup = IdentityLookup; -// type Block = Block; -// type RuntimeEvent = RuntimeEvent; -// type BlockHashCount = BlockHashCount; -// type Version = (); -// type PalletInfo = PalletInfo; -// type AccountData = pallet_balances::AccountData; -// type OnNewAccount = (); -// type OnKilledAccount = (); -// type SystemWeightInfo = (); -// type SS58Prefix = SS58Prefix; -// type OnSetCode = (); -// type MaxConsumers = frame_support::traits::ConstU32<16>; -// } -// parameter_types! { -// pub const ExistentialDeposit: u64 = 5; -// } -// impl pallet_balances::Config for Test { -// type MaxLocks = (); -// type MaxReserves = (); -// type ReserveIdentifier = [u8; 8]; -// type Balance = u128; -// type RuntimeEvent = RuntimeEvent; -// type DustRemoval = (); -// type ExistentialDeposit = ExistentialDeposit; -// type AccountStore = System; -// type WeightInfo = (); -// type FreezeIdentifier = (); -// type MaxFreezes = (); -// type RuntimeHoldReason = (); -// type RuntimeFreezeReason = (); -// } -// parameter_types! { -// pub const SlotWidth: u32 = 2; -// pub const OrderMaxAmount:Balance = 200000000; -// pub const TxPoolThreshold:Balance = 3000000000; -// } -// impl crate::Config for Test { -// type RuntimeEvent = RuntimeEvent; -// type AuthorityId = AuraId; -// type UpdateOrigin = EnsureRoot; -// type Currency = Balances; -// type OrderMaxAmount = OrderMaxAmount; -// type SlotWidth = SlotWidth; -// type TxPoolThreshold = TxPoolThreshold; -// type WeightInfo = (); -// } -// pub struct OrderGasCostHandler(); - -// impl OrderGasCost for OrderGasCostHandler -// where -// T: crate::Config, -// T::AccountId: From<[u8; 32]>, -// { -// fn gas_cost( -// block_number: BlockNumberFor, -// ) -> Result, sp_runtime::DispatchError> { -// let sequece_number = >::block_2_sequence(block_number); -// if sequece_number.is_none() { -// return Ok(None); -// } -// let order = >::order_map( -// sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, -// ) -// .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; -// let mut r = [0u8; 32]; -// r.copy_from_slice(order.orderer.encode().as_slice()); -// let account = T::AccountId::try_from(r) -// .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; -// Ok(Some((account, order.price))) -// } -// } - -// #[frame_support::pallet] -// pub mod mock_pallet { -// use super::*; -// #[pallet::config] -// pub trait Config: frame_system::Config { -// type OrderGasCost: OrderGasCost; -// } - -// #[pallet::call] -// impl Pallet {} - -// #[pallet::pallet] -// #[pallet::without_storage_info] -// pub struct Pallet(_); - -// impl Pallet { -// pub fn get_gas_cost(block_number: BlockNumberFor) -> Option<(T::AccountId, Balance)> { -// T::OrderGasCost::gas_cost(block_number).unwrap() -// } -// } -// } - -// impl mock_pallet::Config for Test { -// type OrderGasCost = OrderGasCostHandler; -// } -// pub struct ExtBuilder { -// balances: Vec<(AccountId32, u128)>, -// } - -// impl Default for ExtBuilder { -// fn default() -> Self { -// Self { balances: Default::default() } -// } -// } - -// impl ExtBuilder { -// pub fn build(self) -> sp_io::TestExternalities { -// // Build genesis storage according to the mock runtime. -// let mut t = frame_system::GenesisConfig::::default().build_storage().unwrap(); -// pallet_balances::GenesisConfig:: { balances: self.balances } -// .assimilate_storage(&mut t) -// .unwrap(); -// let mut ext = sp_io::TestExternalities::new(t); -// ext.execute_with(|| System::set_block_number(1)); -// ext -// } -// } +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +use crate::{self as bulk_pallet, BulkGasCost}; +use codec::Encode; +use cumulus_pallet_parachain_system::{RelayChainState, RelaychainStateProvider}; +pub use frame_support::{ + construct_runtime, derive_impl, parameter_types, + traits::{Everything, Hooks}, +}; +use frame_system as system; +use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; +pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; +use sp_core::{crypto::AccountId32, H256}; +use sp_runtime::{ + traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, + BuildStorage, MultiSignature, +}; + +type Block = frame_system::mocking::MockBlock; +type Signature = MultiSignature; +type AccountId = <::Signer as IdentifyAccount>::AccountId; +type Balance = u128; +// Configure a mock runtime to test the pallet. +construct_runtime!( + pub enum Test + { + System: frame_system::{Pallet, Call, Config, Storage, Event}, + Balances: pallet_balances::{Pallet, Call, Event}, + BulkPallet: bulk_pallet::{Pallet, Call, Storage, Event}, + MockPallet: mock_pallet, + } +); + +parameter_types! { + pub const BlockHashCount: u64 = 250; + pub const SS58Prefix: u8 = 42; +} + +#[derive_impl(frame_system::config_preludes::ParaChainDefaultConfig as frame_system::DefaultConfig)] +impl system::Config for Test { + type BaseCallFilter = Everything; + type BlockWeights = (); + type BlockLength = (); + type DbWeight = (); + type RuntimeOrigin = RuntimeOrigin; + type RuntimeCall = RuntimeCall; + type Nonce = u64; + type Hash = H256; + type Hashing = BlakeTwo256; + type AccountId = AccountId32; + type Lookup = IdentityLookup; + type Block = Block; + type RuntimeEvent = RuntimeEvent; + type BlockHashCount = BlockHashCount; + type Version = (); + type PalletInfo = PalletInfo; + type AccountData = pallet_balances::AccountData; + type OnNewAccount = (); + type OnKilledAccount = (); + type SystemWeightInfo = (); + type SS58Prefix = SS58Prefix; + type OnSetCode = (); + type MaxConsumers = frame_support::traits::ConstU32<16>; +} +parameter_types! { + pub const ExistentialDeposit: u64 = 5; +} +impl pallet_balances::Config for Test { + type MaxLocks = (); + type MaxReserves = (); + type ReserveIdentifier = [u8; 8]; + type Balance = u128; + type RuntimeEvent = RuntimeEvent; + type DustRemoval = (); + type ExistentialDeposit = ExistentialDeposit; + type AccountStore = System; + type WeightInfo = (); + type FreezeIdentifier = (); + type MaxFreezes = (); + type RuntimeHoldReason = (); + type RuntimeFreezeReason = (); +} + +pub(crate) const MOCK_RELAY_ROOT_KEY: &[u8] = b"MOCK_RELAY_ROOT_KEY"; + +pub struct MockRelayStateProvider; + +impl RelaychainStateProvider for MockRelayStateProvider { + fn current_relay_chain_state() -> RelayChainState { + let root = frame_support::storage::unhashed::get(MOCK_RELAY_ROOT_KEY) + .expect("root should be set by mock"); + + RelayChainState { + state_root: root, + number: 0, // block number is not relevant here + } + } + + #[cfg(feature = "runtime-benchmarks")] + fn set_current_relay_chain_state(state: RelayChainState) { + frame_support::storage::unhashed::put(b"MOCK_RELAY_ROOT_KEY", &state.state_root); + } +} + +parameter_types! { + pub const MaxUrlLength: u32 = 300; +} + +impl crate::Config for Test { + type RuntimeEvent = RuntimeEvent; + type AuthorityId = AuraId; + type UpdateOrigin = EnsureRoot; + type Currency = Balances; + type RelayChainStateProvider = MockRelayStateProvider; + type MaxUrlLength = MaxUrlLength; + type WeightInfo = (); +} +pub struct BulkGasCostHandler(); + +impl BulkGasCost for BulkGasCostHandler +where + T: crate::Config, + T::AccountId: From<[u8; 32]>, +{ + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError> { + Ok(None) + } +} + +#[frame_support::pallet] +pub mod mock_pallet { + use super::*; + #[pallet::config] + pub trait Config: frame_system::Config { + type BulkGasCost: BulkGasCost; + } + + #[pallet::call] + impl Pallet {} + + #[pallet::pallet] + #[pallet::without_storage_info] + pub struct Pallet(_); + + impl Pallet { + pub fn get_gas_cost(block_number: BlockNumberFor) -> Option<(T::AccountId, Balance)> { + T::BulkGasCost::gas_cost(block_number).unwrap() + } + } +} + +impl mock_pallet::Config for Test { + type BulkGasCost = BulkGasCostHandler; +} +pub struct ExtBuilder { + balances: Vec<(AccountId32, u128)>, +} + +impl Default for ExtBuilder { + fn default() -> Self { + Self { balances: Default::default() } + } +} + +impl ExtBuilder { + pub fn build(self) -> sp_io::TestExternalities { + // Build genesis storage according to the mock runtime. + let mut t = frame_system::GenesisConfig::::default().build_storage().unwrap(); + pallet_balances::GenesisConfig:: { balances: self.balances } + .assimilate_storage(&mut t) + .unwrap(); + let mut ext = sp_io::TestExternalities::new(t); + ext.execute_with(|| System::set_block_number(1)); + ext + } +} diff --git a/pallets/bulk/src/proof_data.rs b/pallets/bulk/src/proof_data.rs index 5239a0f..93d41cd 100644 --- a/pallets/bulk/src/proof_data.rs +++ b/pallets/bulk/src/proof_data.rs @@ -1,29 +1,28 @@ -// // Copyright (C) Magnet. -// // This file is part of Magnet. +// Copyright (C) Magnet. +// This file is part of Magnet. -// // Magnet is free software: you can redistribute it and/or modify -// // it under the terms of the GNU General Public License as published by -// // the Free Software Foundation, either version 3 of the License, or -// // (at your option) any later version. +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. -// // Magnet is distributed in the hope that it will be useful, -// // but WITHOUT ANY WARRANTY; without even the implied warranty of -// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// // GNU General Public License for more details. +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. -// // You should have received a copy of the GNU General Public License -// // along with Magnet. If not, see . +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . -// #[allow(dead_code)] -// pub const ENCODED_PROOFS: &[(&str, &[&str])] = &[ -// ("6b7db61c1bee66952742baa01b5a16efe3b6dbc015db0bbbc0d50349eb86279e",&[ -// "2000000000000000a2e9b53d55170200000001000000000007c09b001b01390202000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d809698000000000000000000000000000000020000004200e8030000809698000000000000000000000000000000020000000407fe65717dad0447d715f660a0a58411de509b42e6efb8375f562f58a554d5860ee96725030000000000000000000000000000020000002100d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000000000000000000000000000000000000200000000001a037449c93a000000", -// "3ed41e5e16056765bc8461851072c9d74259dee8a67b8efa0538928edcd6d3dc677e250771c8f75fa2e6cc8942f06f84", -// "800104801a93e89e41a278828d5caad67eb07073bca1b6cccc49807dbb0476cb27dced8b80c11c1757f8dc26ef0d97db7c703034b9a9001ad382ed9e1ff900f6ac927cea97", -// "80c19c8040ccdfa3ac9b91388fa827571930b3c1e805eb35304412ff42cc6df33ca548ee806bd20dcb3f9e7c87137961ace69ccd74eb92eb3ca730ea10fc736b7f261cbd7380257442a3193ebf64fb8a0019b2d9fc1d97734011eb5a8d2ea414f5ff9a27952b804a061d1ed9340acbb3bfeeb8dd6662b24e093240981c068dafa7044ed379307f80c692d333d8a2af1468e95d1583f2ff2dcde7a5607f9490af0e17dff8a1330cc48005beaee4aeb1f362f62d090d987e09cee98c4bbafd8042732406115019b3b6b2809c048073a3a4c42b9174519d6fdac372683ca85cc3b0cac1a1a9ddaf243b59b1", -// "80ffff805f00b947f4aaec99e6613e9511e9cda57d739ea73a0f2db02c08509a021ac7c180c63e2c041524586654422f91098a9b35e5d0ea88d44c334c4ffa6112e7aa696f80f40031d9a794a6cd84c0d942827d55968e796a5350b0df1d18c410b8903ce59980b8acbbf86a4082fb580470e18b67d0099be087b38e04c862e8d2ad2b4b984f68801c8066816a9737e80e67d14190ebabfe1f77c68975a57867a3e721759387b16f800cb049cc6bc5b79fb79d7da92aadb3c7d5df71e403364142445ab1e212424b7c80c0c6776ecc8630ecc28971e2155751cdeead63676a6d5313771f902a26a528a0805b682132c52908705526057f73ab7fccab4af6d72a9805634dd8d3cc53f130d18012b1a0dc047d3b9d5e8792fb372059a04d44300f0f667a2a14a8777ccfe7fdff80de00eff4d3f779a7434826e0d0f3a1ec71dd4028c42e90718c657e3f1c2ed23680af18bd988a60b703c96993f291b836fe5f6df4ea5a7d36c9d1e65cd44bc1c5a98037af338c5d64d1babf36777405396255681f8bef661a6cd600052dceffba87ab80f4429c1b9ec6915b41ad4f0b3aa4f0fcf7ef80690cab6590739ce7e415f4e966800117ab1066009e6ab3db03ed63038d60ed339fccef41d35668e22d99ba0a7142806bfdbbf0e0bedcb993b65c9cea1e929a56d78a3b7bc53d1b7ca6fc488e2295ee8011cf4cd49d702989ad1e066e4983740ef04216f8945156021e524d97b57e240a", -// "9eaa394eea5630e07c48ae0c9558cef7398f80a506ec64a470c01c9ac42ea190d29a5f5d900256035bd485a0563a428f7d0369809aea767c8a069c1f1759636c9f4672b4483e36cc35d06881c141bd5e4c40d75e505f0e7b9012096b41c4eb3aaf947f6ea4290800004c5f0684a022a34dd8bfa2baaf44f172b71004018004952dfbd3c381037ea2a1ddd3c7252f15de49dd55db9697c7513fd0750e1ca980a22e4b0da2642d6cda7bd1dc00e5fd760e4d6e18684676b9612f3045023088cf80809890dfdabf4da4f92e0ffab00c1cedd68369e0cc3ce4432de6f8abe9220b5380690a57078e6f7e247b25365dad04c1fef7b0d5401cad9087216ca0f33d7788a06c5f09cce9c888469bb1a0dceaa129672ef824599318726f636f636f" -// ]) -// ]; -// #[allow(dead_code)] -// pub const HEAD_DATA:&[&str] = &["00000000000000000000000000000000000000000000000000000000000000000070049f18759406809dc703bba5534cd06df7453974b4599e08d6709db651e0a203170a2e7597b7b7e3d84c05391d139a62b157e78786d8c082f29dcf4c11131400"]; +#[allow(dead_code)] +pub const STORAGE_PROOF: &[&str] = &[ +"16000000d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d01000e2707000000000000000000000000", +"3f2007d04ec0ed1186e131723f64ef181e1c0c0000000100ffffffffffffffffffff358b741885135ef388abcf1fffd8290678a3a09a9b044f19e46f900f5ffc052f", +"80202080c526dfbf4a65e5d298e8b6c1cdac88ca71fd54975b7c6421b42973529c8e122980b57459b0fad405fcc8486156b1470fbf5da3e704b1905743fa11c028b774b890", +"80bff88002196afa3517dd88d98df436d300706cba9f2508c809bdd2cb2b556869b52d6780c4f7d82fa54c259feb751f64d63cc93749ee0d1f597b163c528d28d137907e3580c0cdd088d3767a4996a380bac2a88c7741b45b4b928c47f8d6ea84536f37e8bf80d53186d94b57d88622a71b3f7734455caedbdd97140df7b5056af030a28c8b6580d6b012f7b6fe3aa5e92edd95403a941a475f81d169e337e28e3f858e31cda40e808bbfc9f2049917e614e48154e3514abd53eabf6abf9a03fbfa079216c2ad0c478009a2de8fe94fc80a905b30932d17cf3490b0e1c46450870631882c287a13dea680adaad05a15ff0002ee84c917bcdbb7d7e97da1921f09c236e613c8f67bf907f380d62b78e6c0701b9acd2abb83656deedca91088aebcd26bb1a763ef7dab77d47880e8cafbef50a072daa5de180d2be3869dcb1187f5fb62e391aa55d235ef772c38808a3d2f156da5d357a1a063bb1d300aaa8cde71a200bcbf86f7512e9640d42f3380ad26a440ead6e38e025ea27e4c61d8f74734893728e00f9d57eb4521e576ec97", +"9ecb50595177a3177648411a42aca0f53b2880ccfcb9650f1764ce72092cd8c2a9b2a237dee22b6a4b42facfbddc0d2dded2bc8038eaec222e3ad57272dadec1b6f8b33b1f2c831f3e1280662847bb6080e8d5ec80ab19bc967e9c7be013655549197002712b4e3cba3803c35236badc872fdf3f2f505f0e7b9012096b41c4eb3aaf947f6ea429080000805c4823a2c831fae207465959acd4250e8edb3b4c5f6ab6e4344aca3baa9eaf2280acc3fdd3a823110b0a67f332f6a4c2588c2e3a7bbba188464f4a28cfbd13b41f80deaed939d20f6089a99e8cf9a2d6fb1117bc1bfbe3592553bf1288fe2d59c6de", +"9f0dc63b0b76ffd6f80704a090da6f8719180080dc89902e909ee4918e5b69cf45cdf2dbc64681fc967849e20d901aa3baf97880806844f5ceff6f4e914d758565e90802e3739ed53e7b7c91727fcd10ce1bbb6d10", +]; +#[allow(dead_code)] +pub const STORAGE_ROOT: &[&str] = + &["3fa15d051c9e13076dbfc98f5aaac3b60dc07f208c1dd652a1abb3a2badabcf1"]; diff --git a/pallets/bulk/src/tests.rs b/pallets/bulk/src/tests.rs index f12f8c5..0f5c3d2 100644 --- a/pallets/bulk/src/tests.rs +++ b/pallets/bulk/src/tests.rs @@ -1,82 +1,63 @@ -// // Copyright (C) Magnet. -// // This file is part of Magnet. +// Copyright (C) Magnet. +// This file is part of Magnet. -// // Magnet is free software: you can redistribute it and/or modify -// // it under the terms of the GNU General Public License as published by -// // the Free Software Foundation, either version 3 of the License, or -// // (at your option) any later version. +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. -// // Magnet is distributed in the hope that it will be useful, -// // but WITHOUT ANY WARRANTY; without even the implied warranty of -// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// // GNU General Public License for more details. +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. -// // You should have received a copy of the GNU General Public License -// // along with Magnet. If not, see . +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . -// use crate::mock::*; -// use codec::Decode; -// use cumulus_primitives_core::{ParaId, PersistedValidationData}; -// use frame_support::{ -// inherent::{InherentData, ProvideInherent}, -// traits::UnfilteredDispatchable, -// }; -// use frame_system::RawOrigin; -// use parachains_common::AccountId; -// use primitives::HeadData; -// use sp_trie::StorageProof; +use crate::mock::*; +use crate::proof_data::{STORAGE_PROOF, STORAGE_ROOT}; +use codec::Decode; +use cumulus_primitives_core::{ParaId, PersistedValidationData}; +use frame_support::{ + inherent::{InherentData, ProvideInherent}, + traits::UnfilteredDispatchable, +}; +use frame_system::RawOrigin; +use pallet_broker::{CoreMask, RegionId}; +use parachains_common::AccountId; +use primitives::HeadData; +use sp_trie::StorageProof; -// use crate::proof_data::{ENCODED_PROOFS, HEAD_DATA}; -// #[test] -// fn order_default_value() { -// ExtBuilder::default().build().execute_with(|| { -// assert_eq!(OrderPallet::slot_width(), 2); -// }); -// } - -// #[test] -// fn order_normal_test() { -// ExtBuilder::default().build().execute_with(|| { -// System::set_block_number(1); - -// let encoded = ENCODED_PROOFS[0]; -// let root = hex::decode(encoded.0).unwrap(); -// let relay_chain_state_proof = -// StorageProof::new(encoded.1.iter().map(|s| hex::decode(s).unwrap())); -// let relay_root: cumulus_primitives_core::relay_chain::Hash = -// <[u8; 32]>::try_from(root).unwrap().into(); -// let mut inherent_data = InherentData::default(); -// let head_data = hex::decode(HEAD_DATA[0]).unwrap(); -// let perist_data = PersistedValidationData { -// parent_head: HeadData::decode(&mut head_data.as_slice()).unwrap(), -// relay_parent_number: 29, -// relay_parent_storage_root: relay_root, -// max_pov_size: 5242880 as u32, -// }; -// let order_inherent_data = magnet_primitives_order::OrderInherentData { -// relay_storage_proof: relay_chain_state_proof, -// validation_data: Some(perist_data), -// para_id: ParaId::from(1000), -// sequence_number: 0, -// author_pub: Some(AccountId::from(hex_literal::hex!( -// "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" -// ))), -// }; -// inherent_data -// .put_data(magnet_primitives_order::INHERENT_IDENTIFIER, &order_inherent_data) -// .expect("failed to put VFP inherent"); -// OrderPallet::create_inherent(&inherent_data) -// .expect("got an inherent") -// .dispatch_bypass_filter(RawOrigin::None.into()) -// .expect("dispatch succeeded"); -// OrderPallet::on_finalize(1); -// assert_eq!(OrderPallet::sequence_number(), 1); -// let gas_cost = MockPallet::get_gas_cost(1).unwrap(); -// assert_eq!( -// gas_cost.0, -// AccountId::from(hex_literal::hex!( -// "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" -// )) -// ); -// }); -// } +#[test] +fn bulk_inherent_test() { + ExtBuilder::default().build().execute_with(|| { + System::set_block_number(1); + let root = hex::decode(STORAGE_ROOT[0]).unwrap(); + let coretime_chain_state_proof = + StorageProof::new(STORAGE_PROOF.iter().map(|s| hex::decode(s).unwrap())); + let storage_root: cumulus_primitives_core::relay_chain::Hash = + <[u8; 32]>::try_from(root).unwrap().into(); + let core_mask = CoreMask::from(0xFFFFFFFFFFFFFFFFFFFF); + let region_id = RegionId { begin: 12, core: 1, mask: core_mask }; + let mut inherent_data = InherentData::default(); + let bulk_inherent_data = mp_coretime_bulk::BulkInherentData { + storage_proof: Some(coretime_chain_state_proof), + storage_root, + region_id, + start_relaychain_height: 120, + end_relaychain_height: 220, + }; + inherent_data + .put_data(mp_coretime_bulk::INHERENT_IDENTIFIER, &bulk_inherent_data) + .expect("failed to put VFP inherent"); + BulkPallet::create_inherent(&inherent_data) + .expect("got an inherent") + .dispatch_bypass_filter(RawOrigin::None.into()) + .expect("dispatch succeeded"); + BulkPallet::on_finalize(1); + assert_eq!(BulkPallet::record_index(), 1); + let record = BulkPallet::bulk_records(0).unwrap(); + assert_eq!(record.start_relaychain_height, 120); + assert_eq!(record.end_relaychain_height, 220); + }); +} diff --git a/primitives/coretime/bulk/src/lib.rs b/primitives/coretime/bulk/src/lib.rs index 06a9428..de7880d 100644 --- a/primitives/coretime/bulk/src/lib.rs +++ b/primitives/coretime/bulk/src/lib.rs @@ -49,7 +49,7 @@ pub struct BulkInherentData { } /// Status of bulk purchased then assigned. -#[derive(Clone, PartialEq, Eq)] +#[derive(Clone, PartialEq, Eq, Debug)] pub enum BulkStatus { /// User call broker purchase. Purchased, @@ -59,7 +59,7 @@ pub enum BulkStatus { CoreAssigned, } -#[derive(Clone)] +#[derive(Clone, Debug)] pub struct BulkMemRecord { /// Block height of coretime parachain. pub coretime_para_height: u32, From 234cce17ee4fb58d6975f74c2f3518338307ed98 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Fri, 28 Jun 2024 16:03:57 +0800 Subject: [PATCH 11/44] update weights.rs, add set_rpc_url weight --- pallets/bulk/src/benchmarking.rs | 76 +++++++++++++++----------------- pallets/bulk/src/lib.rs | 6 +-- pallets/bulk/src/weights.rs | 49 ++++++++++---------- runtime/Cargo.toml | 3 +- runtime/src/lib.rs | 3 +- 5 files changed, 66 insertions(+), 71 deletions(-) diff --git a/pallets/bulk/src/benchmarking.rs b/pallets/bulk/src/benchmarking.rs index 3abea2f..2344657 100644 --- a/pallets/bulk/src/benchmarking.rs +++ b/pallets/bulk/src/benchmarking.rs @@ -1,40 +1,36 @@ -// // Copyright (C) Magnet. -// // This file is part of Magnet. - -// // Magnet is free software: you can redistribute it and/or modify -// // it under the terms of the GNU General Public License as published by -// // the Free Software Foundation, either version 3 of the License, or -// // (at your option) any later version. - -// // Magnet is distributed in the hope that it will be useful, -// // but WITHOUT ANY WARRANTY; without even the implied warranty of -// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// // GNU General Public License for more details. - -// // You should have received a copy of the GNU General Public License -// // along with Magnet. If not, see . - -// //! Benchmarking setup for pallet-order - -// use super::*; - -// #[allow(unused)] -// use crate::Pallet as Order; -// use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller}; -// use frame_system::RawOrigin; - -// benchmarks! { -// set_parameter { -// let s in 0 .. 100; -// let caller: T::AccountId = whitelisted_caller(); -// let test_balance = BalanceOf::::from(200000000 as u32); -// let test_threshold = BalanceOf::::from(3000000000 as u32); -// }: _(RawOrigin::Root, Some(4), Some(test_balance), Some(test_threshold)) -// verify { -// assert_eq!(SlotWidth::::get(), 4); -// assert_eq!(OrderMaxAmount::::get(), test_balance); -// assert_eq!(TxPoolThreshold::::get(), test_threshold); -// } -// } - -// impl_benchmark_test_suite!(Order, crate::mock::ExtBuilder::default().build(), crate::mock::Test,); +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! Benchmarking setup for pallet-bulk + +use super::*; + +#[allow(unused)] +use crate::Pallet as Bulk; +use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller}; +use frame_system::RawOrigin; + +benchmarks! { + set_rpc_url { + let s in 0 .. 100; + let url = BoundedVec::try_from("ws://127.0.0.1:8855".as_bytes().to_vec()).unwrap(); + }: _(RawOrigin::Root, url.clone()) + verify { + assert_eq!(RpcUrl::::get(), Some(url)); + } +} + +impl_benchmark_test_suite!(Bulk, crate::mock::ExtBuilder::default().build(), crate::mock::Test,); diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index 946564e..c70c80d 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -54,8 +54,8 @@ mod mock; #[cfg(test)] mod tests; -// #[cfg(any(test, feature = "runtime-benchmarks"))] -// mod benchmarking; +#[cfg(any(test, feature = "runtime-benchmarks"))] +mod benchmarking; mod proof_data; type BalanceOf = @@ -246,7 +246,7 @@ pub mod pallet { /// Parameters: /// - `url`: Url. #[pallet::call_index(1)] - #[pallet::weight(0)] + #[pallet::weight(::WeightInfo::set_rpc_url())] pub fn set_rpc_url( origin: OriginFor, url: BoundedVec, diff --git a/pallets/bulk/src/weights.rs b/pallets/bulk/src/weights.rs index 6563e21..0c6bf90 100644 --- a/pallets/bulk/src/weights.rs +++ b/pallets/bulk/src/weights.rs @@ -1,10 +1,10 @@ -//! Autogenerated weights for `pallet_order` +//! Autogenerated weights for `pallet_bulk` //! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev -//! DATE: 2024-01-19, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-28, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` //! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `sulijia-pc`, CPU: `AMD Ryzen 7 5800U with Radeon Graphics` +//! HOSTNAME: ``, CPU: `AMD Ryzen 7 5800U with Radeon Graphics` //! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 // Executed Command: @@ -16,7 +16,7 @@ // --execution=wasm // --wasm-execution=compiled // --pallet -// pallet_order +// pallet_bulk // --extrinsic // * // --steps @@ -24,47 +24,44 @@ // --repeat // 20 // --output -// pallets/order/src/weights.rs +// weights.rs #![cfg_attr(rustfmt, rustfmt_skip)] #![allow(unused_parens)] #![allow(unused_imports)] #![allow(missing_docs)] -use frame_support::{traits::Get, weights::Weight}; +use frame_support::{traits::Get, weights::{Weight, constants::RocksDbWeight}}; use core::marker::PhantomData; -use frame_support::weights::constants::RocksDbWeight; - +/// Weight functions needed for pallet. pub trait WeightInfo { - fn set_parameter(s: Option, ) -> Weight; + fn set_rpc_url() -> Weight; } -/// Weight functions for `pallet_order`. +/// Weight functions for `pallet_bulk`. pub struct SubstrateWeight(PhantomData); impl WeightInfo for SubstrateWeight { - /// Storage: `OrderPallet::SlotWidth` (r:0 w:1) - /// Proof: `OrderPallet::SlotWidth` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `OrderPallet::TxPoolThreshold` (r:0 w:1) - /// Proof: `OrderPallet::TxPoolThreshold` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) - /// Storage: `OrderPallet::OrderMaxAmount` (r:0 w:1) - /// Proof: `OrderPallet::OrderMaxAmount` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) + /// Storage: `BulkPallet::RpcUrl` (r:0 w:1) + /// Proof: `BulkPallet::RpcUrl` (`max_values`: Some(1), `max_size`: Some(302), added: 797, mode: `MaxEncodedLen`) /// The range of component `s` is `[0, 100]`. - fn set_parameter(_s: Option, ) -> Weight { + fn set_rpc_url() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_649_000 picoseconds. - Weight::from_parts(5_090_860, 0) + // Minimum execution time: 3_486_000 picoseconds. + Weight::from_parts(4_089_957, 0) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(3)) + .saturating_add(T::DbWeight::get().writes(1)) } } impl WeightInfo for () { - fn set_parameter(_s: Option, ) -> Weight { - Weight::from_parts(5_090_860, 0) - .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 2_411 + fn set_rpc_url() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 3_486_000 picoseconds. + Weight::from_parts(4_089_957, 0) .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(RocksDbWeight::get().writes(3)) + .saturating_add(RocksDbWeight::get().writes(1)) } } \ No newline at end of file diff --git a/runtime/Cargo.toml b/runtime/Cargo.toml index 4b8471f..8b46185 100644 --- a/runtime/Cargo.toml +++ b/runtime/Cargo.toml @@ -248,7 +248,8 @@ runtime-benchmarks = [ "pallet-conviction-voting/runtime-benchmarks", "pallet-ranked-collective/runtime-benchmarks", "pallet-scheduler/runtime-benchmarks", - "pallet-contracts/runtime-benchmarks", + "pallet-contracts/runtime-benchmarks", + "pallet-bulk/runtime-benchmarks", ] try-runtime = [ diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index bd31392..f3b1932 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -785,7 +785,7 @@ impl pallet_bulk::Config for Runtime { type RelayChainStateProvider = cumulus_pallet_parachain_system::RelaychainDataProvider; type UpdateOrigin = EnsureRootOrHalf; type MaxUrlLength = MaxUrlLength; - type WeightInfo = (); + type WeightInfo = pallet_bulk::weights::SubstrateWeight; } parameter_types! { @@ -1241,6 +1241,7 @@ mod benches { [pallet_sudo, Sudo] [pallet_collator_selection, CollatorSelection] [cumulus_pallet_xcmp_queue, XcmpQueue] + [pallet_bulk, BulkPallet] // [pallet_order, OrderPallet] ); } From e0f2a76e4ff3d07b26a6737e14f8d68322795f34 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sat, 29 Jun 2024 11:32:11 +0800 Subject: [PATCH 12/44] 1.remove useless import 2.add comment of coretime client and coretime primitives 3.reconstruct state snapshot code --- Cargo.lock | 19 +- client/coretime/bulk/Cargo.toml | 4 +- client/coretime/bulk/src/lib.rs | 175 +- client/coretime/bulk/src/metadata.rs | 19414 +--------------- client/coretime/common/Cargo.toml | 2 +- client/coretime/common/src/lib.rs | 36 +- node/src/service.rs | 1 - pallets/bulk/Cargo.toml | 4 +- pallets/bulk/src/lib.rs | 12 +- primitives/chain-state-snapshot/Cargo.toml | 24 - primitives/coretime/bulk/Cargo.toml | 4 +- .../coretime/bulk/src/inherent_client.rs | 9 +- primitives/coretime/bulk/src/lib.rs | 20 +- .../coretime/bulk/src/well_known_keys.rs | 9 +- primitives/coretime/common/Cargo.toml | 6 +- .../common/src/chain_state_snapshot.rs} | 12 +- primitives/coretime/common/src/lib.rs | 5 +- 17 files changed, 239 insertions(+), 19517 deletions(-) delete mode 100644 primitives/chain-state-snapshot/Cargo.toml rename primitives/{chain-state-snapshot/src/lib.rs => coretime/common/src/chain_state_snapshot.rs} (94%) diff --git a/Cargo.lock b/Cargo.lock index f1b0f16..dd6212f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2885,17 +2885,6 @@ version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "75b325c5dbd37f80359721ad39aca5a29fb04c89279657cffdda8736d0c0b9d2" -[[package]] -name = "dp-chain-state-snapshot" -version = "0.1.0" -dependencies = [ - "cumulus-primitives-core", - "parity-scale-codec", - "sp-runtime 31.0.1", - "sp-state-machine 0.35.0", - "sp-trie 29.0.0", -] - [[package]] name = "dtoa" version = "1.0.9" @@ -6020,11 +6009,11 @@ dependencies = [ "cumulus-primitives-core", "cumulus-primitives-parachain-inherent", "cumulus-relay-chain-interface", - "dp-chain-state-snapshot", "futures", "log", "mc-coretime-common", "mp-coretime-bulk", + "mp-coretime-common", "pallet-broker", "parity-scale-codec", "polkadot-node-primitives", @@ -6307,7 +6296,7 @@ dependencies = [ [[package]] name = "mp-coretime-bulk" -version = "0.2.0" +version = "0.1.0" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -6333,7 +6322,7 @@ dependencies = [ [[package]] name = "mp-coretime-common" -version = "0.2.0" +version = "0.1.0" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -7300,7 +7289,6 @@ version = "0.2.0" dependencies = [ "cumulus-pallet-parachain-system", "cumulus-primitives-core", - "dp-chain-state-snapshot", "frame-benchmarking", "frame-support", "frame-system", @@ -7308,6 +7296,7 @@ dependencies = [ "hex-literal", "log", "mp-coretime-bulk", + "mp-coretime-common", "pallet-balances", "pallet-broker", "pallet-collective", diff --git a/client/coretime/bulk/Cargo.toml b/client/coretime/bulk/Cargo.toml index 0691b3e..520a191 100644 --- a/client/coretime/bulk/Cargo.toml +++ b/client/coretime/bulk/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "mc-coretime-bulk" -authors = ["Anonymous"] +authors = ["Magnet"] description = "client of magnet coretime bulk mode" license = "Apache License 2.0" homepage = "https://magnet.magport.io/" @@ -18,8 +18,8 @@ log = { workspace = true } subxt = { workspace = true, features = ["substrate-compat"]} # Local -dp-chain-state-snapshot = { path = "../../../primitives/chain-state-snapshot"} mp-coretime-bulk = { path = "../../../primitives/coretime/bulk"} +mp-coretime-common = { path = "../../../primitives/coretime/common"} mc-coretime-common = { path = "../common"} # Substrate diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 29b0603..c4f11b9 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -13,56 +13,45 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -use cumulus_primitives_core::ParaId; + +//! Coretime bulk mode Spawner +//! +//! The technical implementation logic here is to periodically call the background task here based on the interval between +//! parachain releases as the time period. +//! Each time it is called, it first checks the final block of the coretime parachain to see if there is an Assigned event +//! and assigns it to the current parachain. If so, it records it and then looks for subsequent block events to see if there +//! is a CoreAssigned event. If so, it means that coretime is assigned to the parachain, +//! and then the information recorded in the memory is passed to the block through inherent data. +//! +mod metadata; + +use codec::Codec; +use cumulus_primitives_core::{relay_chain::BlockNumber as RelayBlockNumber, ParaId}; use cumulus_relay_chain_interface::RelayChainInterface; -use mp_coretime_bulk::BulkStatus; -use polkadot_primitives::AccountId; -use polkadot_primitives::Balance; +use futures::{lock::Mutex, pin_mut, select, FutureExt, StreamExt}; +use mc_coretime_common::is_parathread; +use mp_coretime_bulk::{ + self, well_known_keys::broker_regions, BulkMemRecord, BulkRuntimeApi, BulkStatus, +}; +use mp_coretime_common::chain_state_snapshot::GenericStateProof; +use pallet_broker::{CoreMask, RegionId, RegionRecord}; +use polkadot_primitives::{AccountId, Balance}; use sc_client_api::UsageProvider; use sc_service::TaskManager; use sp_api::ProvideRuntimeApi; -use sp_core::ByteArray; -use std::error::Error; -use std::sync::Arc; -mod metadata; -use codec::{Codec, Decode}; -use cumulus_primitives_core::relay_chain::BlockNumber as RelayBlockNumber; -use dp_chain_state_snapshot::GenericStateProof; -use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; -use mc_coretime_common::is_parathread; -use metadata::api::runtime_types::pallet_broker::coretime_interface; -use metadata::api::{runtime_types, runtime_types::coretime_rococo_runtime as polakdot_runtime}; -use mp_coretime_bulk::well_known_keys::REGIONS; -use mp_coretime_bulk::BulkMemRecord; -use mp_coretime_bulk::BulkRuntimeApi; -use mp_coretime_bulk::{self, well_known_keys::broker_regions}; -use pallet_broker::CoreAssignment; -use pallet_broker::RegionRecord; -use pallet_broker::{CoreMask, RegionId}; use sp_application_crypto::AppPublic; use sp_consensus_aura::AuraApi; use sp_core::{crypto::Pair, H256}; use sp_keystore::KeystorePtr; -use sp_runtime::{ - codec::Encode, - traits::{AtLeast32BitUnsigned, Block as BlockT, Header as HeaderT, MaybeDisplay, Member}, -}; +use sp_runtime::traits::{Block as BlockT, Member}; use sp_state_machine::StorageProof; -use sp_storage::StorageKey; -use std::fmt::Debug; -use subxt::client::OfflineClientT; +use std::{error::Error, sync::Arc}; use subxt::{ backend::{legacy::LegacyRpcMethods, rpc::RpcClient}, - config::polkadot::PolkadotExtrinsicParamsBuilder as Params, - tx::Signer, - utils::MultiSignature, - Config, OnlineClient, PolkadotConfig, + OnlineClient, PolkadotConfig, }; -// use subxt::ext::scale_encode; -// use subxt::ext::scale_decode; -// use subxt::ext::scale_decode::DecodeAsType; -// use subxt::ext::scale_encode::EncodeAsType; +/// [u8;10] to u128 fn u8_array_to_u128(array: [u8; 10]) -> u128 { let mut result: u128 = 0; for &byte in &array { @@ -71,32 +60,7 @@ fn u8_array_to_u128(array: [u8; 10]) -> u128 { result } -// #[derive(Encode, Decode)] -// enum CoretimeParaRuntimePallets { -// #[codec(index = 50)] -// Broker(BrokerProviderEvents), -// } - -// #[derive(Encode, Decode, EncodeAsType, DecodeAsType)] -// struct CoreAssigned { -// /// The index of the Core which has been assigned. -// core: u16, -// /// The Relay-chain block at which this assignment should take effect. -// when: u32, -// /// The workload to be done on the Core. -// assignment: Vec<(CoreAssignment, u16)>, -// } -// impl subxt::events::StaticEvent for CoreAssigned { -// const PALLET: &'static str = "Broker"; -// const EVENT: &'static str = "CoreAssigned"; -// } - -// #[derive(Encode, Decode)] -// enum BrokerProviderEvents { -// #[codec(index = 26)] -// CoreAssigned(CoreAssigned), -// } - +/// The main logic of bulk task. pub async fn coretime_bulk_task( parachain: &P, relay_chain: R, @@ -104,7 +68,6 @@ pub async fn coretime_bulk_task( p_hash: H256, para_id: ParaId, bulk_record: Arc>, - keystore: KeystorePtr, ) -> Result<(), Box> where Block: BlockT, @@ -121,25 +84,25 @@ where return Ok(()); } - // Randomly select a collator to perform the following operations. let hash = parachain.usage_info().chain.finalized_hash; - let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; - let auth_len = authorities.len() as u32; - let idx = height % auth_len; - let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; - - // if collator_public.is_none() { - // return Ok(()); - // } + let mut bulk_record_local = bulk_record.lock().await; + let bulk_status = bulk_record_local.status.clone(); - // Query Broker Assigned Event + // Get the final block of the coretime parachain through subxt. let url = parachain.runtime_api().rpc_url(hash)?; + let rpc_url = std::str::from_utf8(&url)?; + let api = OnlineClient::::from_url(rpc_url).await?; + let block = api.blocks().at_latest().await?; + let pre_block_height = bulk_record_local.coretime_para_height; + let block_number = block.number(); + + // If the block number has not changed, it will be returned without any processing. if pre_block_height != block_number { bulk_record_local.coretime_para_height = block_number; } else { @@ -149,44 +112,61 @@ where let events = block.events().await?; for event in events.iter() { let event = event?; + // Init status is Purchased,assume that a user has already purchased coretime. if bulk_status == BulkStatus::Purchased { - let ev_assigned = event.as_event::(); + // Query Broker Assigned Event + let ev_assigned = event.as_event::(); + if let Ok(assigned_event) = ev_assigned { if let Some(ev) = assigned_event { - log::info!("{:?},{:?},{:?}", ev.region_id, ev.task, ev.duration); + log::info!( + "Find Assigned event:{:?},{:?},{:?}", + ev.region_id, + ev.task, + ev.duration + ); + let pid: u32 = para_id.into(); + if ev.task == pid { - // + // Call rpc state_getReadProof. let rpc_client = RpcClient::from_url(rpc_url).await?; + let rpc = LegacyRpcMethods::::new(rpc_client.clone()); + let mask = u8_array_to_u128(ev.region_id.mask.0); + let core_mask = CoreMask::from(mask); + let region_id = RegionId { begin: ev.region_id.begin, core: ev.region_id.core, mask: core_mask, }; - println!("region_id:{:?}", region_id); + let key = broker_regions(region_id); - println!("key:{:?}", key); + let mut relevant_keys = Vec::new(); relevant_keys.push(key.as_slice()); + let proof = rpc .state_get_read_proof(relevant_keys, Some(events.block_hash())) .await .unwrap(); let storage_proof = StorageProof::new(proof.proof.into_iter().map(|bytes| bytes.to_vec())); - println!("{:?}", storage_proof); + let storage_root = block.header().state_root; + // Create coretime parachain storage root proof. let relay_storage_rooted_proof: GenericStateProof< cumulus_primitives_core::relay_chain::Block, > = GenericStateProof::new(storage_root, storage_proof.clone()).unwrap(); + let head_data = relay_storage_rooted_proof .read_entry::>(key.as_slice(), None) .ok(); - println!("head_data:{:?}", head_data); - if let Some(region_record) = head_data { + // Check proof is ok. + if head_data.is_some() { bulk_record_local.storage_proof = storage_proof; bulk_record_local.storage_root = storage_root; bulk_record_local.region_id = region_id; @@ -198,20 +178,32 @@ where continue; } } + // Should first record Assigned event info. if bulk_status == BulkStatus::Assigned { - let ev_core_assigned = event.as_event::(); - log::info!("ev_core_assigned:{:?}", ev_core_assigned); + // Query CoreAssigned event. + let ev_core_assigned = event.as_event::(); + if let Ok(core_assigned_event) = ev_core_assigned { if let Some(ev) = core_assigned_event { - log::info!("{:?},{:?},{:?}", ev.core, ev.when, ev.assignment); + log::info!( + "Find CoreAssigned event: {:?},{:?},{:?}", + ev.core, + ev.when, + ev.assignment + ); + for (core_assign, _) in ev.assignment { - if let coretime_interface::CoreAssignment::Task(id) = core_assign { + if let metadata::CoreAssignment::Task(id) = core_assign { let pid: u32 = para_id.into(); if id == pid { bulk_record_local.start_relaychain_height = ev.when; + let constant_query = - metadata::api::ConstantsApi.broker().timeslice_period(); - let time_slice = api.constants().at(&constant_query)?; + subxt::dynamic::constant("Broker", "TimeslicePeriod"); + + let time_slice = + api.constants().at(&constant_query)?.to_value()?.context; + bulk_record_local.end_relaychain_height = ev.when + bulk_record_local.duration * time_slice; // find it. @@ -223,7 +215,6 @@ where } } } - log::info!("bulk_record:{:?}", bulk_record_local); Ok(()) } @@ -232,7 +223,6 @@ pub async fn run_coretime_bulk_task( relay_chain: R, para_id: ParaId, bulk_record: Arc>, - keystore: KeystorePtr, ) where Block: BlockT, P: ProvideRuntimeApi + UsageProvider, @@ -254,7 +244,7 @@ pub async fn run_coretime_bulk_task( h = new_best_heads.next() => { match h { Some((height, hash)) => { - coretime_bulk_task::<_,_,_, PB>(&*parachain, relay_chain.clone(), height, hash, para_id, bulk_record.clone(), keystore.clone()).await?; + coretime_bulk_task::<_,_,_, PB>(&*parachain, relay_chain.clone(), height, hash, para_id, bulk_record.clone()).await?; }, None => { return Ok::<(), Box>(()); @@ -269,13 +259,13 @@ pub async fn run_coretime_bulk_task( } } +/// Spawn task for bulk mode pub fn spawn_bulk_task( parachain: Arc

, para_id: ParaId, relay_chain: R, task_manager: &TaskManager, bulk_record: Arc>, - keystore: KeystorePtr, ) -> sc_service::error::Result<()> where Block: BlockT, @@ -291,7 +281,6 @@ where relay_chain.clone(), para_id, bulk_record.clone(), - keystore, ); task_manager .spawn_essential_handle() diff --git a/client/coretime/bulk/src/metadata.rs b/client/coretime/bulk/src/metadata.rs index 5805941..9aa3fd0 100644 --- a/client/coretime/bulk/src/metadata.rs +++ b/client/coretime/bulk/src/metadata.rs @@ -1,19308 +1,108 @@ -#[allow(dead_code, unused_imports, non_camel_case_types)] -#[allow(clippy::all)] -#[allow(rustdoc::broken_intra_doc_links)] -pub mod api { - #[allow(unused_imports)] - mod root_mod { - pub use super::*; - } - pub static PALLETS: [&str; 19usize] = [ - "System", - "ParachainSystem", - "Timestamp", - "ParachainInfo", - "Balances", - "TransactionPayment", - "Authorship", - "CollatorSelection", - "Session", - "Aura", - "AuraExt", - "XcmpQueue", - "PolkadotXcm", - "CumulusXcm", - "MessageQueue", - "Utility", - "Multisig", - "Broker", - "Sudo", - ]; - pub static RUNTIME_APIS: [&str; 12usize] = [ - "AuraApi", - "Core", - "Metadata", - "BlockBuilder", - "TaggedTransactionQueue", - "OffchainWorkerApi", - "SessionKeys", - "AccountNonceApi", - "TransactionPaymentApi", - "TransactionPaymentCallApi", - "CollectCollationInfo", - "GenesisBuilder", - ]; - #[doc = r" The error type returned when there is a runtime issue."] - pub type DispatchError = runtime_types::sp_runtime::DispatchError; - #[doc = r" The outer event enum."] - pub type Event = runtime_types::coretime_rococo_runtime::RuntimeEvent; - #[doc = r" The outer extrinsic enum."] - pub type Call = runtime_types::coretime_rococo_runtime::RuntimeCall; - #[doc = r" The outer error enum representing the DispatchError's Module variant."] - pub type Error = runtime_types::coretime_rococo_runtime::RuntimeError; - pub fn constants() -> ConstantsApi { - ConstantsApi - } - pub fn storage() -> StorageApi { - StorageApi - } - pub fn tx() -> TransactionApi { - TransactionApi - } - pub fn apis() -> runtime_apis::RuntimeApi { - runtime_apis::RuntimeApi - } - pub mod runtime_apis { - use super::root_mod; - use super::runtime_types; - use subxt::ext::codec::Encode; - pub struct RuntimeApi; - impl RuntimeApi { - pub fn aura_api(&self) -> aura_api::AuraApi { - aura_api::AuraApi - } - pub fn core(&self) -> core::Core { - core::Core - } - pub fn metadata(&self) -> metadata::Metadata { - metadata::Metadata - } - pub fn block_builder(&self) -> block_builder::BlockBuilder { - block_builder::BlockBuilder - } - pub fn tagged_transaction_queue( - &self, - ) -> tagged_transaction_queue::TaggedTransactionQueue { - tagged_transaction_queue::TaggedTransactionQueue - } - pub fn offchain_worker_api(&self) -> offchain_worker_api::OffchainWorkerApi { - offchain_worker_api::OffchainWorkerApi - } - pub fn session_keys(&self) -> session_keys::SessionKeys { - session_keys::SessionKeys - } - pub fn account_nonce_api(&self) -> account_nonce_api::AccountNonceApi { - account_nonce_api::AccountNonceApi - } - pub fn transaction_payment_api( - &self, - ) -> transaction_payment_api::TransactionPaymentApi { - transaction_payment_api::TransactionPaymentApi - } - pub fn transaction_payment_call_api( - &self, - ) -> transaction_payment_call_api::TransactionPaymentCallApi { - transaction_payment_call_api::TransactionPaymentCallApi - } - pub fn collect_collation_info(&self) -> collect_collation_info::CollectCollationInfo { - collect_collation_info::CollectCollationInfo - } - pub fn genesis_builder(&self) -> genesis_builder::GenesisBuilder { - genesis_builder::GenesisBuilder - } - } - pub mod aura_api { - use super::root_mod; - use super::runtime_types; - #[doc = " API necessary for block authorship with aura."] - pub struct AuraApi; - impl AuraApi { - #[doc = " Returns the slot duration for Aura."] - #[doc = ""] - #[doc = " Currently, only the value provided by this type at genesis will be used."] - pub fn slot_duration( - &self, - ) -> ::subxt::runtime_api::Payload< - types::SlotDuration, - runtime_types::sp_consensus_slots::SlotDuration, - > { - ::subxt::runtime_api::Payload::new_static( - "AuraApi", - "slot_duration", - types::SlotDuration {}, - [ - 233u8, 210u8, 132u8, 172u8, 100u8, 125u8, 239u8, 92u8, 114u8, 82u8, - 7u8, 110u8, 179u8, 196u8, 10u8, 19u8, 211u8, 15u8, 174u8, 2u8, 91u8, - 73u8, 133u8, 100u8, 205u8, 201u8, 191u8, 60u8, 163u8, 122u8, 215u8, - 10u8, - ], - ) - } - #[doc = " Return the current set of authorities."] - pub fn authorities( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Authorities, - ::std::vec::Vec, - > { - ::subxt::runtime_api::Payload::new_static( - "AuraApi", - "authorities", - types::Authorities {}, - [ - 96u8, 136u8, 226u8, 244u8, 105u8, 189u8, 8u8, 250u8, 71u8, 230u8, 37u8, - 123u8, 218u8, 47u8, 179u8, 16u8, 170u8, 181u8, 165u8, 77u8, 102u8, - 51u8, 43u8, 51u8, 186u8, 84u8, 49u8, 15u8, 208u8, 226u8, 129u8, 230u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SlotDuration {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Authorities {} - } - } - pub mod core { - use super::root_mod; - use super::runtime_types; - #[doc = " The `Core` runtime api that every Substrate runtime needs to implement."] - pub struct Core; - impl Core { - #[doc = " Returns the version of the runtime."] - pub fn version( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Version, - runtime_types::sp_version::RuntimeVersion, - > { - ::subxt::runtime_api::Payload::new_static( - "Core", - "version", - types::Version {}, - [ - 76u8, 202u8, 17u8, 117u8, 189u8, 237u8, 239u8, 237u8, 151u8, 17u8, - 125u8, 159u8, 218u8, 92u8, 57u8, 238u8, 64u8, 147u8, 40u8, 72u8, 157u8, - 116u8, 37u8, 195u8, 156u8, 27u8, 123u8, 173u8, 178u8, 102u8, 136u8, - 6u8, - ], - ) - } - #[doc = " Execute the given block."] - pub fn execute_block( - &self, - block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > >, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "Core", - "execute_block", - types::ExecuteBlock { block }, - [ - 133u8, 135u8, 228u8, 65u8, 106u8, 27u8, 85u8, 158u8, 112u8, 254u8, - 93u8, 26u8, 102u8, 201u8, 118u8, 216u8, 249u8, 247u8, 91u8, 74u8, 56u8, - 208u8, 231u8, 115u8, 131u8, 29u8, 209u8, 6u8, 65u8, 57u8, 214u8, 125u8, - ], - ) - } - #[doc = " Initialize a block with the given header."] - pub fn initialize_block( - &self, - header: runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "Core", - "initialize_block", - types::InitializeBlock { header }, - [ - 146u8, 138u8, 72u8, 240u8, 63u8, 96u8, 110u8, 189u8, 77u8, 92u8, 96u8, - 232u8, 41u8, 217u8, 105u8, 148u8, 83u8, 190u8, 152u8, 219u8, 19u8, - 87u8, 163u8, 1u8, 232u8, 25u8, 221u8, 74u8, 224u8, 67u8, 223u8, 34u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Version {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExecuteBlock { pub block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InitializeBlock { - pub header: - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - } - } - } - pub mod metadata { - use super::root_mod; - use super::runtime_types; - #[doc = " The `Metadata` api trait that returns metadata for the runtime."] - pub struct Metadata; - impl Metadata { - #[doc = " Returns the metadata of a runtime."] - pub fn metadata( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Metadata, - runtime_types::sp_core::OpaqueMetadata, - > { - ::subxt::runtime_api::Payload::new_static( - "Metadata", - "metadata", - types::Metadata {}, - [ - 231u8, 24u8, 67u8, 152u8, 23u8, 26u8, 188u8, 82u8, 229u8, 6u8, 185u8, - 27u8, 175u8, 68u8, 83u8, 122u8, 69u8, 89u8, 185u8, 74u8, 248u8, 87u8, - 217u8, 124u8, 193u8, 252u8, 199u8, 186u8, 196u8, 179u8, 179u8, 96u8, - ], - ) - } - #[doc = " Returns the metadata at a given version."] - #[doc = ""] - #[doc = " If the given `version` isn't supported, this will return `None`."] - #[doc = " Use [`Self::metadata_versions`] to find out about supported metadata version of the runtime."] - pub fn metadata_at_version( - &self, - version: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::MetadataAtVersion, - ::core::option::Option, - > { - ::subxt::runtime_api::Payload::new_static( - "Metadata", - "metadata_at_version", - types::MetadataAtVersion { version }, - [ - 131u8, 53u8, 212u8, 234u8, 16u8, 25u8, 120u8, 252u8, 153u8, 153u8, - 216u8, 28u8, 54u8, 113u8, 52u8, 236u8, 146u8, 68u8, 142u8, 8u8, 10u8, - 169u8, 131u8, 142u8, 204u8, 38u8, 48u8, 108u8, 134u8, 86u8, 226u8, - 61u8, - ], - ) - } - #[doc = " Returns the supported metadata versions."] - #[doc = ""] - #[doc = " This can be used to call `metadata_at_version`."] - pub fn metadata_versions( - &self, - ) -> ::subxt::runtime_api::Payload< - types::MetadataVersions, - ::std::vec::Vec<::core::primitive::u32>, - > { - ::subxt::runtime_api::Payload::new_static( - "Metadata", - "metadata_versions", - types::MetadataVersions {}, - [ - 23u8, 144u8, 137u8, 91u8, 188u8, 39u8, 231u8, 208u8, 252u8, 218u8, - 224u8, 176u8, 77u8, 32u8, 130u8, 212u8, 223u8, 76u8, 100u8, 190u8, - 82u8, 94u8, 190u8, 8u8, 82u8, 244u8, 225u8, 179u8, 85u8, 176u8, 56u8, - 16u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Metadata {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MetadataAtVersion { - pub version: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MetadataVersions {} - } - } - pub mod block_builder { - use super::root_mod; - use super::runtime_types; - #[doc = " The `BlockBuilder` api trait that provides the required functionality for building a block."] - pub struct BlockBuilder; - impl BlockBuilder { - #[doc = " Apply the given extrinsic."] - #[doc = ""] - #[doc = " Returns an inclusion outcome which specifies if this extrinsic is included in"] - #[doc = " this block or not."] - pub fn apply_extrinsic( - &self, - extrinsic : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, - ) -> ::subxt::runtime_api::Payload< - types::ApplyExtrinsic, - ::core::result::Result< - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - runtime_types::sp_runtime::transaction_validity::TransactionValidityError, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "BlockBuilder", - "apply_extrinsic", - types::ApplyExtrinsic { extrinsic }, - [ - 72u8, 54u8, 139u8, 3u8, 118u8, 136u8, 65u8, 47u8, 6u8, 105u8, 125u8, - 223u8, 160u8, 29u8, 103u8, 74u8, 79u8, 149u8, 48u8, 90u8, 237u8, 2u8, - 97u8, 201u8, 123u8, 34u8, 167u8, 37u8, 187u8, 35u8, 176u8, 97u8, - ], - ) - } - #[doc = " Finish the current block."] - pub fn finalize_block( - &self, - ) -> ::subxt::runtime_api::Payload< - types::FinalizeBlock, - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - > { - ::subxt::runtime_api::Payload::new_static( - "BlockBuilder", - "finalize_block", - types::FinalizeBlock {}, - [ - 244u8, 207u8, 24u8, 33u8, 13u8, 69u8, 9u8, 249u8, 145u8, 143u8, 122u8, - 96u8, 197u8, 55u8, 64u8, 111u8, 238u8, 224u8, 34u8, 201u8, 27u8, 146u8, - 232u8, 99u8, 191u8, 30u8, 114u8, 16u8, 32u8, 220u8, 58u8, 62u8, - ], - ) - } - #[doc = " Generate inherent extrinsics. The inherent data will vary from chain to chain."] pub fn inherent_extrinsics (& self , inherent : runtime_types :: sp_inherents :: InherentData ,) -> :: subxt :: runtime_api :: Payload < types :: InherentExtrinsics , :: std :: vec :: Vec < :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > >{ - ::subxt::runtime_api::Payload::new_static( - "BlockBuilder", - "inherent_extrinsics", - types::InherentExtrinsics { inherent }, - [ - 254u8, 110u8, 245u8, 201u8, 250u8, 192u8, 27u8, 228u8, 151u8, 213u8, - 166u8, 89u8, 94u8, 81u8, 189u8, 234u8, 64u8, 18u8, 245u8, 80u8, 29u8, - 18u8, 140u8, 129u8, 113u8, 236u8, 135u8, 55u8, 79u8, 159u8, 175u8, - 183u8, - ], - ) - } - #[doc = " Check that the inherents are valid. The inherent data will vary from chain to chain."] - pub fn check_inherents( - &self, - block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > >, - data: runtime_types::sp_inherents::InherentData, - ) -> ::subxt::runtime_api::Payload< - types::CheckInherents, - runtime_types::sp_inherents::CheckInherentsResult, - > { - ::subxt::runtime_api::Payload::new_static( - "BlockBuilder", - "check_inherents", - types::CheckInherents { block, data }, - [ - 153u8, 134u8, 1u8, 215u8, 139u8, 11u8, 53u8, 51u8, 210u8, 175u8, 197u8, - 28u8, 38u8, 209u8, 175u8, 247u8, 142u8, 157u8, 50u8, 151u8, 164u8, - 191u8, 181u8, 118u8, 80u8, 97u8, 160u8, 248u8, 110u8, 217u8, 181u8, - 234u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApplyExtrinsic { pub extrinsic : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FinalizeBlock {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InherentExtrinsics { - pub inherent: runtime_types::sp_inherents::InherentData, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckInherents { pub block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > , pub data : runtime_types :: sp_inherents :: InherentData , } - } - } - pub mod tagged_transaction_queue { - use super::root_mod; - use super::runtime_types; - #[doc = " The `TaggedTransactionQueue` api trait for interfering with the transaction queue."] - pub struct TaggedTransactionQueue; - impl TaggedTransactionQueue { - #[doc = " Validate the transaction."] - #[doc = ""] - #[doc = " This method is invoked by the transaction pool to learn details about given transaction."] - #[doc = " The implementation should make sure to verify the correctness of the transaction"] - #[doc = " against current state. The given `block_hash` corresponds to the hash of the block"] - #[doc = " that is used as current state."] - #[doc = ""] - #[doc = " Note that this call may be performed by the pool multiple times and transactions"] - #[doc = " might be verified in any possible order."] - pub fn validate_transaction( - &self, - source: runtime_types::sp_runtime::transaction_validity::TransactionSource, - tx : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, - block_hash: ::subxt::utils::H256, - ) -> ::subxt::runtime_api::Payload< - types::ValidateTransaction, - ::core::result::Result< - runtime_types::sp_runtime::transaction_validity::ValidTransaction, - runtime_types::sp_runtime::transaction_validity::TransactionValidityError, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "TaggedTransactionQueue", - "validate_transaction", - types::ValidateTransaction { source, tx, block_hash }, - [ - 196u8, 50u8, 90u8, 49u8, 109u8, 251u8, 200u8, 35u8, 23u8, 150u8, 140u8, - 143u8, 232u8, 164u8, 133u8, 89u8, 32u8, 240u8, 115u8, 39u8, 95u8, 70u8, - 162u8, 76u8, 122u8, 73u8, 151u8, 144u8, 234u8, 120u8, 100u8, 29u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidateTransaction { pub source : runtime_types :: sp_runtime :: transaction_validity :: TransactionSource , pub tx : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub block_hash : :: subxt :: utils :: H256 , } - } - } - pub mod offchain_worker_api { - use super::root_mod; - use super::runtime_types; - #[doc = " The offchain worker api."] - pub struct OffchainWorkerApi; - impl OffchainWorkerApi { - #[doc = " Starts the off-chain task for given block header."] - pub fn offchain_worker( - &self, - header: runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "OffchainWorkerApi", - "offchain_worker", - types::OffchainWorker { header }, - [ - 10u8, 135u8, 19u8, 153u8, 33u8, 216u8, 18u8, 242u8, 33u8, 140u8, 4u8, - 223u8, 200u8, 130u8, 103u8, 118u8, 137u8, 24u8, 19u8, 127u8, 161u8, - 29u8, 184u8, 111u8, 222u8, 111u8, 253u8, 73u8, 45u8, 31u8, 79u8, 60u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OffchainWorker { - pub header: - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - } - } - } - pub mod session_keys { - use super::root_mod; - use super::runtime_types; - #[doc = " Session keys runtime api."] - pub struct SessionKeys; - impl SessionKeys { - #[doc = " Generate a set of session keys with optionally using the given seed."] - #[doc = " The keys should be stored within the keystore exposed via runtime"] - #[doc = " externalities."] - #[doc = ""] - #[doc = " The seed needs to be a valid `utf8` string."] - #[doc = ""] - #[doc = " Returns the concatenated SCALE encoded public keys."] - pub fn generate_session_keys( - &self, - seed: ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, - ) -> ::subxt::runtime_api::Payload< - types::GenerateSessionKeys, - ::std::vec::Vec<::core::primitive::u8>, - > { - ::subxt::runtime_api::Payload::new_static( - "SessionKeys", - "generate_session_keys", - types::GenerateSessionKeys { seed }, - [ - 96u8, 171u8, 164u8, 166u8, 175u8, 102u8, 101u8, 47u8, 133u8, 95u8, - 102u8, 202u8, 83u8, 26u8, 238u8, 47u8, 126u8, 132u8, 22u8, 11u8, 33u8, - 190u8, 175u8, 94u8, 58u8, 245u8, 46u8, 80u8, 195u8, 184u8, 107u8, 65u8, - ], - ) - } - #[doc = " Decode the given public session keys."] - #[doc = ""] - #[doc = " Returns the list of public raw public keys + key type."] - pub fn decode_session_keys( - &self, - encoded: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::runtime_api::Payload< - types::DecodeSessionKeys, - ::core::option::Option< - ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - runtime_types::sp_core::crypto::KeyTypeId, - )>, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "SessionKeys", - "decode_session_keys", - types::DecodeSessionKeys { encoded }, - [ - 57u8, 242u8, 18u8, 51u8, 132u8, 110u8, 238u8, 255u8, 39u8, 194u8, 8u8, - 54u8, 198u8, 178u8, 75u8, 151u8, 148u8, 176u8, 144u8, 197u8, 87u8, - 29u8, 179u8, 235u8, 176u8, 78u8, 252u8, 103u8, 72u8, 203u8, 151u8, - 248u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GenerateSessionKeys { - pub seed: ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DecodeSessionKeys { - pub encoded: ::std::vec::Vec<::core::primitive::u8>, - } - } - } - pub mod account_nonce_api { - use super::root_mod; - use super::runtime_types; - #[doc = " The API to query account nonce."] - pub struct AccountNonceApi; - impl AccountNonceApi { - #[doc = " Get current account nonce of given `AccountId`."] - pub fn account_nonce( - &self, - account: ::subxt::utils::AccountId32, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "AccountNonceApi", - "account_nonce", - types::AccountNonce { account }, - [ - 231u8, 82u8, 7u8, 227u8, 131u8, 2u8, 215u8, 252u8, 173u8, 82u8, 11u8, - 103u8, 200u8, 25u8, 114u8, 116u8, 79u8, 229u8, 152u8, 150u8, 236u8, - 37u8, 101u8, 26u8, 220u8, 146u8, 182u8, 101u8, 73u8, 55u8, 191u8, - 171u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AccountNonce { - pub account: ::subxt::utils::AccountId32, - } - } - } - pub mod transaction_payment_api { - use super::root_mod; - use super::runtime_types; - pub struct TransactionPaymentApi; - impl TransactionPaymentApi { - pub fn query_info( - &self, - uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, - len: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::QueryInfo, - runtime_types::pallet_transaction_payment::types::RuntimeDispatchInfo< - ::core::primitive::u128, - runtime_types::sp_weights::weight_v2::Weight, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentApi", - "query_info", - types::QueryInfo { uxt, len }, - [ - 56u8, 30u8, 174u8, 34u8, 202u8, 24u8, 177u8, 189u8, 145u8, 36u8, 1u8, - 156u8, 98u8, 209u8, 178u8, 49u8, 198u8, 23u8, 150u8, 173u8, 35u8, - 205u8, 147u8, 129u8, 42u8, 22u8, 69u8, 3u8, 129u8, 8u8, 196u8, 139u8, - ], - ) - } - pub fn query_fee_details( - &self, - uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, - len: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::QueryFeeDetails, - runtime_types::pallet_transaction_payment::types::FeeDetails< - ::core::primitive::u128, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentApi", - "query_fee_details", - types::QueryFeeDetails { uxt, len }, - [ - 117u8, 60u8, 137u8, 159u8, 237u8, 252u8, 216u8, 238u8, 232u8, 1u8, - 100u8, 152u8, 26u8, 185u8, 145u8, 125u8, 68u8, 189u8, 4u8, 30u8, 125u8, - 7u8, 196u8, 153u8, 235u8, 51u8, 219u8, 108u8, 185u8, 254u8, 100u8, - 201u8, - ], - ) - } - pub fn query_weight_to_fee( - &self, - weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::runtime_api::Payload - { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentApi", - "query_weight_to_fee", - types::QueryWeightToFee { weight }, - [ - 206u8, 243u8, 189u8, 83u8, 231u8, 244u8, 247u8, 52u8, 126u8, 208u8, - 224u8, 5u8, 163u8, 108u8, 254u8, 114u8, 214u8, 156u8, 227u8, 217u8, - 211u8, 198u8, 121u8, 164u8, 110u8, 54u8, 181u8, 146u8, 50u8, 146u8, - 146u8, 23u8, - ], - ) - } - pub fn query_length_to_fee( - &self, - length: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload - { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentApi", - "query_length_to_fee", - types::QueryLengthToFee { length }, - [ - 92u8, 132u8, 29u8, 119u8, 66u8, 11u8, 196u8, 224u8, 129u8, 23u8, 249u8, - 12u8, 32u8, 28u8, 92u8, 50u8, 188u8, 101u8, 203u8, 229u8, 248u8, 216u8, - 130u8, 150u8, 212u8, 161u8, 81u8, 254u8, 116u8, 89u8, 162u8, 48u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryInfo { pub uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub len : :: core :: primitive :: u32 , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryFeeDetails { pub uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: coretime_rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub len : :: core :: primitive :: u32 , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryWeightToFee { - pub weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryLengthToFee { - pub length: ::core::primitive::u32, - } - } - } - pub mod transaction_payment_call_api { - use super::root_mod; - use super::runtime_types; - pub struct TransactionPaymentCallApi; - impl TransactionPaymentCallApi { - #[doc = " Query information of a dispatch class, weight, and fee of a given encoded `Call`."] - pub fn query_call_info( - &self, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - len: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::QueryCallInfo, - runtime_types::pallet_transaction_payment::types::RuntimeDispatchInfo< - ::core::primitive::u128, - runtime_types::sp_weights::weight_v2::Weight, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentCallApi", - "query_call_info", - types::QueryCallInfo { call, len }, - [ - 144u8, 172u8, 193u8, 149u8, 28u8, 82u8, 208u8, 226u8, 171u8, 59u8, - 10u8, 77u8, 230u8, 162u8, 177u8, 49u8, 193u8, 102u8, 128u8, 112u8, - 235u8, 183u8, 35u8, 97u8, 139u8, 157u8, 177u8, 173u8, 205u8, 6u8, - 255u8, 26u8, - ], - ) - } - #[doc = " Query fee details of a given encoded `Call`."] - pub fn query_call_fee_details( - &self, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - len: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::QueryCallFeeDetails, - runtime_types::pallet_transaction_payment::types::FeeDetails< - ::core::primitive::u128, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentCallApi", - "query_call_fee_details", - types::QueryCallFeeDetails { call, len }, - [ - 53u8, 126u8, 3u8, 45u8, 40u8, 132u8, 229u8, 63u8, 8u8, 241u8, 124u8, - 160u8, 30u8, 139u8, 140u8, 97u8, 78u8, 59u8, 151u8, 84u8, 29u8, 36u8, - 232u8, 93u8, 116u8, 66u8, 35u8, 191u8, 43u8, 172u8, 29u8, 8u8, - ], - ) - } - #[doc = " Query the output of the current `WeightToFee` given some input."] - pub fn query_weight_to_fee( - &self, - weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::runtime_api::Payload - { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentCallApi", - "query_weight_to_fee", - types::QueryWeightToFee { weight }, - [ - 117u8, 91u8, 94u8, 22u8, 248u8, 212u8, 15u8, 23u8, 97u8, 116u8, 64u8, - 228u8, 83u8, 123u8, 87u8, 77u8, 97u8, 7u8, 98u8, 181u8, 6u8, 165u8, - 114u8, 141u8, 164u8, 113u8, 126u8, 88u8, 174u8, 171u8, 224u8, 35u8, - ], - ) - } - #[doc = " Query the output of the current `LengthToFee` given some input."] - pub fn query_length_to_fee( - &self, - length: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload - { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentCallApi", - "query_length_to_fee", - types::QueryLengthToFee { length }, - [ - 246u8, 40u8, 4u8, 160u8, 152u8, 94u8, 170u8, 53u8, 205u8, 122u8, 5u8, - 69u8, 70u8, 25u8, 128u8, 156u8, 119u8, 134u8, 116u8, 147u8, 14u8, - 164u8, 65u8, 140u8, 86u8, 13u8, 250u8, 218u8, 89u8, 95u8, 234u8, 228u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryCallInfo { - pub call: runtime_types::coretime_rococo_runtime::RuntimeCall, - pub len: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryCallFeeDetails { - pub call: runtime_types::coretime_rococo_runtime::RuntimeCall, - pub len: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryWeightToFee { - pub weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryLengthToFee { - pub length: ::core::primitive::u32, - } - } - } - pub mod collect_collation_info { - use super::root_mod; - use super::runtime_types; - #[doc = " Runtime api to collect information about a collation."] - pub struct CollectCollationInfo; - impl CollectCollationInfo { - #[doc = " Collect information about a collation."] - #[doc = ""] - #[doc = " The given `header` is the header of the built block for that"] - #[doc = " we are collecting the collation info for."] - pub fn collect_collation_info( - &self, - header: runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - ) -> ::subxt::runtime_api::Payload< - types::CollectCollationInfo, - runtime_types::cumulus_primitives_core::CollationInfo, - > { - ::subxt::runtime_api::Payload::new_static( - "CollectCollationInfo", - "collect_collation_info", - types::CollectCollationInfo { header }, - [ - 56u8, 138u8, 105u8, 91u8, 216u8, 40u8, 255u8, 98u8, 86u8, 138u8, 185u8, - 155u8, 80u8, 141u8, 85u8, 48u8, 252u8, 235u8, 178u8, 231u8, 111u8, - 216u8, 71u8, 20u8, 33u8, 202u8, 24u8, 215u8, 214u8, 132u8, 51u8, 166u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CollectCollationInfo { - pub header: - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - } - } - } - pub mod genesis_builder { - use super::root_mod; - use super::runtime_types; - #[doc = " API to interact with GenesisConfig for the runtime"] - pub struct GenesisBuilder; - impl GenesisBuilder { - #[doc = " Creates the default `GenesisConfig` and returns it as a JSON blob."] - #[doc = ""] - #[doc = " This function instantiates the default `GenesisConfig` struct for the runtime and serializes it into a JSON"] - #[doc = " blob. It returns a `Vec` containing the JSON representation of the default `GenesisConfig`."] - pub fn create_default_config( - &self, - ) -> ::subxt::runtime_api::Payload< - types::CreateDefaultConfig, - ::std::vec::Vec<::core::primitive::u8>, - > { - ::subxt::runtime_api::Payload::new_static( - "GenesisBuilder", - "create_default_config", - types::CreateDefaultConfig {}, - [ - 238u8, 5u8, 139u8, 81u8, 184u8, 155u8, 221u8, 118u8, 190u8, 76u8, - 229u8, 67u8, 132u8, 89u8, 83u8, 80u8, 56u8, 171u8, 169u8, 64u8, 123u8, - 20u8, 129u8, 159u8, 28u8, 135u8, 84u8, 52u8, 192u8, 98u8, 104u8, 214u8, - ], - ) - } - #[doc = " Build `GenesisConfig` from a JSON blob not using any defaults and store it in the storage."] - #[doc = ""] - #[doc = " This function deserializes the full `GenesisConfig` from the given JSON blob and puts it into the storage."] - #[doc = " If the provided JSON blob is incorrect or incomplete or the deserialization fails, an error is returned."] - #[doc = " It is recommended to log any errors encountered during the process."] - #[doc = ""] - #[doc = " Please note that provided json blob must contain all `GenesisConfig` fields, no defaults will be used."] - pub fn build_config( - &self, - json: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::runtime_api::Payload< - types::BuildConfig, - ::core::result::Result<(), ::std::string::String>, - > { - ::subxt::runtime_api::Payload::new_static( - "GenesisBuilder", - "build_config", - types::BuildConfig { json }, - [ - 6u8, 98u8, 68u8, 125u8, 157u8, 26u8, 107u8, 86u8, 213u8, 227u8, 26u8, - 229u8, 122u8, 161u8, 229u8, 114u8, 123u8, 192u8, 66u8, 231u8, 148u8, - 175u8, 5u8, 185u8, 248u8, 88u8, 40u8, 122u8, 230u8, 209u8, 170u8, - 254u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreateDefaultConfig {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BuildConfig { - pub json: ::std::vec::Vec<::core::primitive::u8>, - } - } - } - } - pub fn custom() -> CustomValuesApi { - CustomValuesApi - } - pub struct CustomValuesApi; - impl CustomValuesApi {} - pub struct ConstantsApi; - impl ConstantsApi { - pub fn system(&self) -> system::constants::ConstantsApi { - system::constants::ConstantsApi - } - pub fn timestamp(&self) -> timestamp::constants::ConstantsApi { - timestamp::constants::ConstantsApi - } - pub fn balances(&self) -> balances::constants::ConstantsApi { - balances::constants::ConstantsApi - } - pub fn transaction_payment(&self) -> transaction_payment::constants::ConstantsApi { - transaction_payment::constants::ConstantsApi - } - pub fn xcmp_queue(&self) -> xcmp_queue::constants::ConstantsApi { - xcmp_queue::constants::ConstantsApi - } - pub fn message_queue(&self) -> message_queue::constants::ConstantsApi { - message_queue::constants::ConstantsApi - } - pub fn utility(&self) -> utility::constants::ConstantsApi { - utility::constants::ConstantsApi - } - pub fn multisig(&self) -> multisig::constants::ConstantsApi { - multisig::constants::ConstantsApi - } - pub fn broker(&self) -> broker::constants::ConstantsApi { - broker::constants::ConstantsApi - } - } - pub struct StorageApi; - impl StorageApi { - pub fn system(&self) -> system::storage::StorageApi { - system::storage::StorageApi - } - pub fn parachain_system(&self) -> parachain_system::storage::StorageApi { - parachain_system::storage::StorageApi - } - pub fn timestamp(&self) -> timestamp::storage::StorageApi { - timestamp::storage::StorageApi - } - pub fn parachain_info(&self) -> parachain_info::storage::StorageApi { - parachain_info::storage::StorageApi - } - pub fn balances(&self) -> balances::storage::StorageApi { - balances::storage::StorageApi - } - pub fn transaction_payment(&self) -> transaction_payment::storage::StorageApi { - transaction_payment::storage::StorageApi - } - pub fn authorship(&self) -> authorship::storage::StorageApi { - authorship::storage::StorageApi - } - pub fn collator_selection(&self) -> collator_selection::storage::StorageApi { - collator_selection::storage::StorageApi - } - pub fn session(&self) -> session::storage::StorageApi { - session::storage::StorageApi - } - pub fn aura(&self) -> aura::storage::StorageApi { - aura::storage::StorageApi - } - pub fn aura_ext(&self) -> aura_ext::storage::StorageApi { - aura_ext::storage::StorageApi - } - pub fn xcmp_queue(&self) -> xcmp_queue::storage::StorageApi { - xcmp_queue::storage::StorageApi - } - pub fn polkadot_xcm(&self) -> polkadot_xcm::storage::StorageApi { - polkadot_xcm::storage::StorageApi - } - pub fn message_queue(&self) -> message_queue::storage::StorageApi { - message_queue::storage::StorageApi - } - pub fn multisig(&self) -> multisig::storage::StorageApi { - multisig::storage::StorageApi - } - pub fn broker(&self) -> broker::storage::StorageApi { - broker::storage::StorageApi - } - pub fn sudo(&self) -> sudo::storage::StorageApi { - sudo::storage::StorageApi - } - } - pub struct TransactionApi; - impl TransactionApi { - pub fn system(&self) -> system::calls::TransactionApi { - system::calls::TransactionApi - } - pub fn parachain_system(&self) -> parachain_system::calls::TransactionApi { - parachain_system::calls::TransactionApi - } - pub fn timestamp(&self) -> timestamp::calls::TransactionApi { - timestamp::calls::TransactionApi - } - pub fn parachain_info(&self) -> parachain_info::calls::TransactionApi { - parachain_info::calls::TransactionApi - } - pub fn balances(&self) -> balances::calls::TransactionApi { - balances::calls::TransactionApi - } - pub fn collator_selection(&self) -> collator_selection::calls::TransactionApi { - collator_selection::calls::TransactionApi - } - pub fn session(&self) -> session::calls::TransactionApi { - session::calls::TransactionApi - } - pub fn xcmp_queue(&self) -> xcmp_queue::calls::TransactionApi { - xcmp_queue::calls::TransactionApi - } - pub fn polkadot_xcm(&self) -> polkadot_xcm::calls::TransactionApi { - polkadot_xcm::calls::TransactionApi - } - pub fn cumulus_xcm(&self) -> cumulus_xcm::calls::TransactionApi { - cumulus_xcm::calls::TransactionApi - } - pub fn message_queue(&self) -> message_queue::calls::TransactionApi { - message_queue::calls::TransactionApi - } - pub fn utility(&self) -> utility::calls::TransactionApi { - utility::calls::TransactionApi - } - pub fn multisig(&self) -> multisig::calls::TransactionApi { - multisig::calls::TransactionApi - } - pub fn broker(&self) -> broker::calls::TransactionApi { - broker::calls::TransactionApi - } - pub fn sudo(&self) -> sudo::calls::TransactionApi { - sudo::calls::TransactionApi - } - } - #[doc = r" check whether the metadata provided is aligned with this statically generated code."] - pub fn is_codegen_valid_for(metadata: &::subxt::Metadata) -> bool { - let runtime_metadata_hash = metadata - .hasher() - .only_these_pallets(&PALLETS) - .only_these_runtime_apis(&RUNTIME_APIS) - .hash(); - runtime_metadata_hash - == [ - 242u8, 249u8, 231u8, 131u8, 221u8, 227u8, 243u8, 80u8, 94u8, 43u8, 167u8, 107u8, - 160u8, 189u8, 68u8, 67u8, 246u8, 202u8, 187u8, 14u8, 58u8, 172u8, 27u8, 33u8, - 232u8, 78u8, 146u8, 148u8, 181u8, 89u8, 134u8, 221u8, - ] - } - pub mod system { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the System pallet"] - pub type Error = runtime_types::frame_system::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::frame_system::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Remark { - pub remark: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for Remark { - const PALLET: &'static str = "System"; - const CALL: &'static str = "remark"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHeapPages { - pub pages: ::core::primitive::u64, - } - impl ::subxt::blocks::StaticExtrinsic for SetHeapPages { - const PALLET: &'static str = "System"; - const CALL: &'static str = "set_heap_pages"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCode { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for SetCode { - const PALLET: &'static str = "System"; - const CALL: &'static str = "set_code"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCodeWithoutChecks { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for SetCodeWithoutChecks { - const PALLET: &'static str = "System"; - const CALL: &'static str = "set_code_without_checks"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetStorage { - pub items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - } - impl ::subxt::blocks::StaticExtrinsic for SetStorage { - const PALLET: &'static str = "System"; - const CALL: &'static str = "set_storage"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillStorage { - pub keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - } - impl ::subxt::blocks::StaticExtrinsic for KillStorage { - const PALLET: &'static str = "System"; - const CALL: &'static str = "kill_storage"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillPrefix { - pub prefix: ::std::vec::Vec<::core::primitive::u8>, - pub subkeys: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for KillPrefix { - const PALLET: &'static str = "System"; - const CALL: &'static str = "kill_prefix"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemarkWithEvent { - pub remark: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for RemarkWithEvent { - const PALLET: &'static str = "System"; - const CALL: &'static str = "remark_with_event"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AuthorizeUpgrade { - pub code_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for AuthorizeUpgrade { - const PALLET: &'static str = "System"; - const CALL: &'static str = "authorize_upgrade"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AuthorizeUpgradeWithoutChecks { - pub code_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for AuthorizeUpgradeWithoutChecks { - const PALLET: &'static str = "System"; - const CALL: &'static str = "authorize_upgrade_without_checks"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApplyAuthorizedUpgrade { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for ApplyAuthorizedUpgrade { - const PALLET: &'static str = "System"; - const CALL: &'static str = "apply_authorized_upgrade"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::remark`]."] - pub fn remark( - &self, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "remark", - types::Remark { remark }, - [ - 43u8, 126u8, 180u8, 174u8, 141u8, 48u8, 52u8, 125u8, 166u8, 212u8, - 216u8, 98u8, 100u8, 24u8, 132u8, 71u8, 101u8, 64u8, 246u8, 169u8, 33u8, - 250u8, 147u8, 208u8, 2u8, 40u8, 129u8, 209u8, 232u8, 207u8, 207u8, - 13u8, - ], - ) - } - #[doc = "See [`Pallet::set_heap_pages`]."] - pub fn set_heap_pages( - &self, - pages: ::core::primitive::u64, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_heap_pages", - types::SetHeapPages { pages }, - [ - 188u8, 191u8, 99u8, 216u8, 219u8, 109u8, 141u8, 50u8, 78u8, 235u8, - 215u8, 242u8, 195u8, 24u8, 111u8, 76u8, 229u8, 64u8, 99u8, 225u8, - 134u8, 121u8, 81u8, 209u8, 127u8, 223u8, 98u8, 215u8, 150u8, 70u8, - 57u8, 147u8, - ], - ) - } - #[doc = "See [`Pallet::set_code`]."] - pub fn set_code( - &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_code", - types::SetCode { code }, - [ - 233u8, 248u8, 88u8, 245u8, 28u8, 65u8, 25u8, 169u8, 35u8, 237u8, 19u8, - 203u8, 136u8, 160u8, 18u8, 3u8, 20u8, 197u8, 81u8, 169u8, 244u8, 188u8, - 27u8, 147u8, 147u8, 236u8, 65u8, 25u8, 3u8, 143u8, 182u8, 22u8, - ], - ) - } - #[doc = "See [`Pallet::set_code_without_checks`]."] - pub fn set_code_without_checks( - &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_code_without_checks", - types::SetCodeWithoutChecks { code }, - [ - 82u8, 212u8, 157u8, 44u8, 70u8, 0u8, 143u8, 15u8, 109u8, 109u8, 107u8, - 157u8, 141u8, 42u8, 169u8, 11u8, 15u8, 186u8, 252u8, 138u8, 10u8, - 147u8, 15u8, 178u8, 247u8, 229u8, 213u8, 98u8, 207u8, 231u8, 119u8, - 115u8, - ], - ) - } - #[doc = "See [`Pallet::set_storage`]."] - pub fn set_storage( - &self, - items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_storage", - types::SetStorage { items }, - [ - 141u8, 216u8, 52u8, 222u8, 223u8, 136u8, 123u8, 181u8, 19u8, 75u8, - 163u8, 102u8, 229u8, 189u8, 158u8, 142u8, 95u8, 235u8, 240u8, 49u8, - 150u8, 76u8, 78u8, 137u8, 126u8, 88u8, 183u8, 88u8, 231u8, 146u8, - 234u8, 43u8, - ], - ) - } - #[doc = "See [`Pallet::kill_storage`]."] - pub fn kill_storage( - &self, - keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "kill_storage", - types::KillStorage { keys }, - [ - 73u8, 63u8, 196u8, 36u8, 144u8, 114u8, 34u8, 213u8, 108u8, 93u8, 209u8, - 234u8, 153u8, 185u8, 33u8, 91u8, 187u8, 195u8, 223u8, 130u8, 58u8, - 156u8, 63u8, 47u8, 228u8, 249u8, 216u8, 139u8, 143u8, 177u8, 41u8, - 35u8, - ], - ) - } - #[doc = "See [`Pallet::kill_prefix`]."] - pub fn kill_prefix( - &self, - prefix: ::std::vec::Vec<::core::primitive::u8>, - subkeys: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "kill_prefix", - types::KillPrefix { prefix, subkeys }, - [ - 184u8, 57u8, 139u8, 24u8, 208u8, 87u8, 108u8, 215u8, 198u8, 189u8, - 175u8, 242u8, 167u8, 215u8, 97u8, 63u8, 110u8, 166u8, 238u8, 98u8, - 67u8, 236u8, 111u8, 110u8, 234u8, 81u8, 102u8, 5u8, 182u8, 5u8, 214u8, - 85u8, - ], - ) - } - #[doc = "See [`Pallet::remark_with_event`]."] - pub fn remark_with_event( - &self, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "remark_with_event", - types::RemarkWithEvent { remark }, - [ - 120u8, 120u8, 153u8, 92u8, 184u8, 85u8, 34u8, 2u8, 174u8, 206u8, 105u8, - 228u8, 233u8, 130u8, 80u8, 246u8, 228u8, 59u8, 234u8, 240u8, 4u8, 49u8, - 147u8, 170u8, 115u8, 91u8, 149u8, 200u8, 228u8, 181u8, 8u8, 154u8, - ], - ) - } - #[doc = "See [`Pallet::authorize_upgrade`]."] - pub fn authorize_upgrade( - &self, - code_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "authorize_upgrade", - types::AuthorizeUpgrade { code_hash }, - [ - 4u8, 14u8, 76u8, 107u8, 209u8, 129u8, 9u8, 39u8, 193u8, 17u8, 84u8, - 254u8, 170u8, 214u8, 24u8, 155u8, 29u8, 184u8, 249u8, 241u8, 109u8, - 58u8, 145u8, 131u8, 109u8, 63u8, 38u8, 165u8, 107u8, 215u8, 217u8, - 172u8, - ], - ) - } - #[doc = "See [`Pallet::authorize_upgrade_without_checks`]."] - pub fn authorize_upgrade_without_checks( - &self, - code_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "authorize_upgrade_without_checks", - types::AuthorizeUpgradeWithoutChecks { code_hash }, - [ - 126u8, 126u8, 55u8, 26u8, 47u8, 55u8, 66u8, 8u8, 167u8, 18u8, 29u8, - 136u8, 146u8, 14u8, 189u8, 117u8, 16u8, 227u8, 162u8, 61u8, 149u8, - 197u8, 104u8, 184u8, 185u8, 161u8, 99u8, 154u8, 80u8, 125u8, 181u8, - 233u8, - ], - ) - } - #[doc = "See [`Pallet::apply_authorized_upgrade`]."] - pub fn apply_authorized_upgrade( - &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "apply_authorized_upgrade", - types::ApplyAuthorizedUpgrade { code }, - [ - 232u8, 107u8, 127u8, 38u8, 230u8, 29u8, 97u8, 4u8, 160u8, 191u8, 222u8, - 156u8, 245u8, 102u8, 196u8, 141u8, 44u8, 163u8, 98u8, 68u8, 125u8, - 32u8, 124u8, 101u8, 108u8, 93u8, 211u8, 52u8, 0u8, 231u8, 33u8, 227u8, - ], - ) - } - } - } - #[doc = "Event for the System pallet."] - pub type Event = runtime_types::frame_system::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An extrinsic completed successfully."] - pub struct ExtrinsicSuccess { - pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - } - impl ::subxt::events::StaticEvent for ExtrinsicSuccess { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "ExtrinsicSuccess"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An extrinsic failed."] - pub struct ExtrinsicFailed { - pub dispatch_error: runtime_types::sp_runtime::DispatchError, - pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - } - impl ::subxt::events::StaticEvent for ExtrinsicFailed { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "ExtrinsicFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "`:code` was updated."] - pub struct CodeUpdated; - impl ::subxt::events::StaticEvent for CodeUpdated { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "CodeUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new account was created."] - pub struct NewAccount { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for NewAccount { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "NewAccount"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was reaped."] - pub struct KilledAccount { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for KilledAccount { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "KilledAccount"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "On on-chain remark happened."] - pub struct Remarked { - pub sender: ::subxt::utils::AccountId32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Remarked { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "Remarked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An upgrade was authorized."] - pub struct UpgradeAuthorized { - pub code_hash: ::subxt::utils::H256, - pub check_version: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for UpgradeAuthorized { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "UpgradeAuthorized"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The full account information for a particular account ID."] - pub fn account_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::AccountInfo< - ::core::primitive::u32, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "Account", - vec![], - [ - 14u8, 233u8, 115u8, 214u8, 0u8, 109u8, 222u8, 121u8, 162u8, 65u8, 60u8, - 175u8, 209u8, 79u8, 222u8, 124u8, 22u8, 235u8, 138u8, 176u8, 133u8, - 124u8, 90u8, 158u8, 85u8, 45u8, 37u8, 174u8, 47u8, 79u8, 47u8, 166u8, - ], - ) - } - #[doc = " The full account information for a particular account ID."] - pub fn account( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::AccountInfo< - ::core::primitive::u32, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Account", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 14u8, 233u8, 115u8, 214u8, 0u8, 109u8, 222u8, 121u8, 162u8, 65u8, 60u8, - 175u8, 209u8, 79u8, 222u8, 124u8, 22u8, 235u8, 138u8, 176u8, 133u8, - 124u8, 90u8, 158u8, 85u8, 45u8, 37u8, 174u8, 47u8, 79u8, 47u8, 166u8, - ], - ) - } - #[doc = " Total extrinsics count for the current block."] - pub fn extrinsic_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicCount", - vec![], - [ - 102u8, 76u8, 236u8, 42u8, 40u8, 231u8, 33u8, 222u8, 123u8, 147u8, - 153u8, 148u8, 234u8, 203u8, 181u8, 119u8, 6u8, 187u8, 177u8, 199u8, - 120u8, 47u8, 137u8, 254u8, 96u8, 100u8, 165u8, 182u8, 249u8, 230u8, - 159u8, 79u8, - ], - ) - } - #[doc = " The current weight for the block."] - pub fn block_weight( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_support::dispatch::PerDispatchClass< - runtime_types::sp_weights::weight_v2::Weight, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockWeight", - vec![], - [ - 158u8, 46u8, 228u8, 89u8, 210u8, 214u8, 84u8, 154u8, 50u8, 68u8, 63u8, - 62u8, 43u8, 42u8, 99u8, 27u8, 54u8, 42u8, 146u8, 44u8, 241u8, 216u8, - 229u8, 30u8, 216u8, 255u8, 165u8, 238u8, 181u8, 130u8, 36u8, 102u8, - ], - ) - } - #[doc = " Total length (in bytes) for all extrinsics put together, for the current block."] - pub fn all_extrinsics_len( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "AllExtrinsicsLen", - vec![], - [ - 117u8, 86u8, 61u8, 243u8, 41u8, 51u8, 102u8, 214u8, 137u8, 100u8, - 243u8, 185u8, 122u8, 174u8, 187u8, 117u8, 86u8, 189u8, 63u8, 135u8, - 101u8, 218u8, 203u8, 201u8, 237u8, 254u8, 128u8, 183u8, 169u8, 221u8, - 242u8, 65u8, - ], - ) - } - #[doc = " Map of block numbers to block hashes."] - pub fn block_hash_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockHash", - vec![], - [ - 217u8, 32u8, 215u8, 253u8, 24u8, 182u8, 207u8, 178u8, 157u8, 24u8, - 103u8, 100u8, 195u8, 165u8, 69u8, 152u8, 112u8, 181u8, 56u8, 192u8, - 164u8, 16u8, 20u8, 222u8, 28u8, 214u8, 144u8, 142u8, 146u8, 69u8, - 202u8, 118u8, - ], - ) - } - #[doc = " Map of block numbers to block hashes."] - pub fn block_hash( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockHash", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 217u8, 32u8, 215u8, 253u8, 24u8, 182u8, 207u8, 178u8, 157u8, 24u8, - 103u8, 100u8, 195u8, 165u8, 69u8, 152u8, 112u8, 181u8, 56u8, 192u8, - 164u8, 16u8, 20u8, 222u8, 28u8, 214u8, 144u8, 142u8, 146u8, 69u8, - 202u8, 118u8, - ], - ) - } - #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] - pub fn extrinsic_data_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicData", - vec![], - [ - 160u8, 180u8, 122u8, 18u8, 196u8, 26u8, 2u8, 37u8, 115u8, 232u8, 133u8, - 220u8, 106u8, 245u8, 4u8, 129u8, 42u8, 84u8, 241u8, 45u8, 199u8, 179u8, - 128u8, 61u8, 170u8, 137u8, 231u8, 156u8, 247u8, 57u8, 47u8, 38u8, - ], - ) - } - #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] - pub fn extrinsic_data( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicData", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 160u8, 180u8, 122u8, 18u8, 196u8, 26u8, 2u8, 37u8, 115u8, 232u8, 133u8, - 220u8, 106u8, 245u8, 4u8, 129u8, 42u8, 84u8, 241u8, 45u8, 199u8, 179u8, - 128u8, 61u8, 170u8, 137u8, 231u8, 156u8, 247u8, 57u8, 47u8, 38u8, - ], - ) - } - #[doc = " The current block number being processed. Set by `execute_block`."] - pub fn number( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Number", - vec![], - [ - 30u8, 194u8, 177u8, 90u8, 194u8, 232u8, 46u8, 180u8, 85u8, 129u8, 14u8, - 9u8, 8u8, 8u8, 23u8, 95u8, 230u8, 5u8, 13u8, 105u8, 125u8, 2u8, 22u8, - 200u8, 78u8, 93u8, 115u8, 28u8, 150u8, 113u8, 48u8, 53u8, - ], - ) - } - #[doc = " Hash of the previous block."] - pub fn parent_hash( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "ParentHash", - vec![], - [ - 26u8, 130u8, 11u8, 216u8, 155u8, 71u8, 128u8, 170u8, 30u8, 153u8, 21u8, - 192u8, 62u8, 93u8, 137u8, 80u8, 120u8, 81u8, 202u8, 94u8, 248u8, 125u8, - 71u8, 82u8, 141u8, 229u8, 32u8, 56u8, 73u8, 50u8, 101u8, 78u8, - ], - ) - } - #[doc = " Digest of the current block, also part of the block header."] - pub fn digest( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_runtime::generic::digest::Digest, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Digest", - vec![], - [ - 61u8, 64u8, 237u8, 91u8, 145u8, 232u8, 17u8, 254u8, 181u8, 16u8, 234u8, - 91u8, 51u8, 140u8, 254u8, 131u8, 98u8, 135u8, 21u8, 37u8, 251u8, 20u8, - 58u8, 92u8, 123u8, 141u8, 14u8, 227u8, 146u8, 46u8, 222u8, 117u8, - ], - ) - } - #[doc = " Events deposited for the current block."] - #[doc = ""] - #[doc = " NOTE: The item is unbound and should therefore never be read on chain."] - #[doc = " It could otherwise inflate the PoV size of a block."] - #[doc = ""] - #[doc = " Events have a large in-memory size. Box the events to not go out-of-memory"] - #[doc = " just in case someone still reads them from within the runtime."] - pub fn events( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::frame_system::EventRecord< - runtime_types::coretime_rococo_runtime::RuntimeEvent, - ::subxt::utils::H256, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Events", - vec![], - [ - 116u8, 34u8, 143u8, 0u8, 100u8, 96u8, 191u8, 144u8, 117u8, 233u8, - 245u8, 65u8, 232u8, 97u8, 101u8, 184u8, 150u8, 152u8, 218u8, 179u8, - 195u8, 142u8, 170u8, 211u8, 191u8, 58u8, 100u8, 54u8, 248u8, 57u8, - 227u8, 165u8, - ], - ) - } - #[doc = " The number of events in the `Events` list."] - pub fn event_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "EventCount", - vec![], - [ - 175u8, 24u8, 252u8, 184u8, 210u8, 167u8, 146u8, 143u8, 164u8, 80u8, - 151u8, 205u8, 189u8, 189u8, 55u8, 220u8, 47u8, 101u8, 181u8, 33u8, - 254u8, 131u8, 13u8, 143u8, 3u8, 244u8, 245u8, 45u8, 2u8, 210u8, 79u8, - 133u8, - ], - ) - } - #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] - #[doc = " of events in the `>` list."] - #[doc = ""] - #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] - #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] - #[doc = " in case of changes fetch the list of events of interest."] - #[doc = ""] - #[doc = " The value has the type `(BlockNumberFor, EventIndex)` because if we used only just"] - #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] - #[doc = " no notification will be triggered thus the event might be lost."] - pub fn event_topics_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "EventTopics", - vec![], - [ - 40u8, 225u8, 14u8, 75u8, 44u8, 176u8, 76u8, 34u8, 143u8, 107u8, 69u8, - 133u8, 114u8, 13u8, 172u8, 250u8, 141u8, 73u8, 12u8, 65u8, 217u8, 63u8, - 120u8, 241u8, 48u8, 106u8, 143u8, 161u8, 128u8, 100u8, 166u8, 59u8, - ], - ) - } - #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] - #[doc = " of events in the `>` list."] - #[doc = ""] - #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] - #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] - #[doc = " in case of changes fetch the list of events of interest."] - #[doc = ""] - #[doc = " The value has the type `(BlockNumberFor, EventIndex)` because if we used only just"] - #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] - #[doc = " no notification will be triggered thus the event might be lost."] - pub fn event_topics( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "EventTopics", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 40u8, 225u8, 14u8, 75u8, 44u8, 176u8, 76u8, 34u8, 143u8, 107u8, 69u8, - 133u8, 114u8, 13u8, 172u8, 250u8, 141u8, 73u8, 12u8, 65u8, 217u8, 63u8, - 120u8, 241u8, 48u8, 106u8, 143u8, 161u8, 128u8, 100u8, 166u8, 59u8, - ], - ) - } - #[doc = " Stores the `spec_version` and `spec_name` of when the last runtime upgrade happened."] - pub fn last_runtime_upgrade( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::LastRuntimeUpgradeInfo, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "LastRuntimeUpgrade", - vec![], - [ - 137u8, 29u8, 175u8, 75u8, 197u8, 208u8, 91u8, 207u8, 156u8, 87u8, - 148u8, 68u8, 91u8, 140u8, 22u8, 233u8, 1u8, 229u8, 56u8, 34u8, 40u8, - 194u8, 253u8, 30u8, 163u8, 39u8, 54u8, 209u8, 13u8, 27u8, 139u8, 184u8, - ], - ) - } - #[doc = " True if we have upgraded so that `type RefCount` is `u32`. False (default) if not."] - pub fn upgraded_to_u32_ref_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "UpgradedToU32RefCount", - vec![], - [ - 229u8, 73u8, 9u8, 132u8, 186u8, 116u8, 151u8, 171u8, 145u8, 29u8, 34u8, - 130u8, 52u8, 146u8, 124u8, 175u8, 79u8, 189u8, 147u8, 230u8, 234u8, - 107u8, 124u8, 31u8, 2u8, 22u8, 86u8, 190u8, 4u8, 147u8, 50u8, 245u8, - ], - ) - } - #[doc = " True if we have upgraded so that AccountInfo contains three types of `RefCount`. False"] - #[doc = " (default) if not."] - pub fn upgraded_to_triple_ref_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "UpgradedToTripleRefCount", - vec![], - [ - 97u8, 66u8, 124u8, 243u8, 27u8, 167u8, 147u8, 81u8, 254u8, 201u8, - 101u8, 24u8, 40u8, 231u8, 14u8, 179u8, 154u8, 163u8, 71u8, 81u8, 185u8, - 167u8, 82u8, 254u8, 189u8, 3u8, 101u8, 207u8, 206u8, 194u8, 155u8, - 151u8, - ], - ) - } - #[doc = " The execution phase of the block."] - pub fn execution_phase( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::Phase, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "ExecutionPhase", - vec![], - [ - 191u8, 129u8, 100u8, 134u8, 126u8, 116u8, 154u8, 203u8, 220u8, 200u8, - 0u8, 26u8, 161u8, 250u8, 133u8, 205u8, 146u8, 24u8, 5u8, 156u8, 158u8, - 35u8, 36u8, 253u8, 52u8, 235u8, 86u8, 167u8, 35u8, 100u8, 119u8, 27u8, - ], - ) - } - #[doc = " `Some` if a code upgrade has been authorized."] - pub fn authorized_upgrade( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::CodeUpgradeAuthorization, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "AuthorizedUpgrade", - vec![], - [ - 165u8, 97u8, 27u8, 138u8, 2u8, 28u8, 55u8, 92u8, 96u8, 96u8, 168u8, - 169u8, 55u8, 178u8, 44u8, 127u8, 58u8, 140u8, 206u8, 178u8, 1u8, 37u8, - 214u8, 213u8, 251u8, 123u8, 5u8, 111u8, 90u8, 148u8, 217u8, 135u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Block & extrinsics weights: base values and limits."] - pub fn block_weights( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "System", - "BlockWeights", - [ - 176u8, 124u8, 225u8, 136u8, 25u8, 73u8, 247u8, 33u8, 82u8, 206u8, 85u8, - 190u8, 127u8, 102u8, 71u8, 11u8, 185u8, 8u8, 58u8, 0u8, 94u8, 55u8, - 163u8, 177u8, 104u8, 59u8, 60u8, 136u8, 246u8, 116u8, 0u8, 239u8, - ], - ) - } - #[doc = " The maximum length of a block (in bytes)."] - pub fn block_length( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "System", - "BlockLength", - [ - 23u8, 242u8, 225u8, 39u8, 225u8, 67u8, 152u8, 41u8, 155u8, 104u8, 68u8, - 229u8, 185u8, 133u8, 10u8, 143u8, 184u8, 152u8, 234u8, 44u8, 140u8, - 96u8, 166u8, 235u8, 162u8, 160u8, 72u8, 7u8, 35u8, 194u8, 3u8, 37u8, - ], - ) - } - #[doc = " Maximum number of block number to block hash mappings to keep (oldest pruned first)."] - pub fn block_hash_count( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "System", - "BlockHashCount", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The weight of runtime database operations the runtime can invoke."] - pub fn db_weight( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "System", - "DbWeight", - [ - 42u8, 43u8, 178u8, 142u8, 243u8, 203u8, 60u8, 173u8, 118u8, 111u8, - 200u8, 170u8, 102u8, 70u8, 237u8, 187u8, 198u8, 120u8, 153u8, 232u8, - 183u8, 76u8, 74u8, 10u8, 70u8, 243u8, 14u8, 218u8, 213u8, 126u8, 29u8, - 177u8, - ], - ) - } - #[doc = " Get the chain's current version."] - pub fn version( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "System", - "Version", - [ - 219u8, 45u8, 162u8, 245u8, 177u8, 246u8, 48u8, 126u8, 191u8, 157u8, - 228u8, 83u8, 111u8, 133u8, 183u8, 13u8, 148u8, 108u8, 92u8, 102u8, - 72u8, 205u8, 74u8, 242u8, 233u8, 79u8, 20u8, 170u8, 72u8, 202u8, 158u8, - 165u8, - ], - ) - } - #[doc = " The designated SS58 prefix of this chain."] - #[doc = ""] - #[doc = " This replaces the \"ss58Format\" property declared in the chain spec. Reason is"] - #[doc = " that the runtime should know about the prefix in order to make use of it as"] - #[doc = " an identifier of the chain."] - pub fn ss58_prefix(&self) -> ::subxt::constants::Address<::core::primitive::u16> { - ::subxt::constants::Address::new_static( - "System", - "SS58Prefix", - [ - 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, - 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, - 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, - ], - ) - } - } - } - } - pub mod parachain_system { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::cumulus_pallet_parachain_system::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::cumulus_pallet_parachain_system::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidationData { - pub data: - runtime_types::cumulus_primitives_parachain_inherent::ParachainInherentData, - } - impl ::subxt::blocks::StaticExtrinsic for SetValidationData { - const PALLET: &'static str = "ParachainSystem"; - const CALL: &'static str = "set_validation_data"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoSendUpwardMessage { - pub message: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for SudoSendUpwardMessage { - const PALLET: &'static str = "ParachainSystem"; - const CALL: &'static str = "sudo_send_upward_message"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AuthorizeUpgrade { - pub code_hash: ::subxt::utils::H256, - pub check_version: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for AuthorizeUpgrade { - const PALLET: &'static str = "ParachainSystem"; - const CALL: &'static str = "authorize_upgrade"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EnactAuthorizedUpgrade { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for EnactAuthorizedUpgrade { - const PALLET: &'static str = "ParachainSystem"; - const CALL: &'static str = "enact_authorized_upgrade"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::set_validation_data`]."] - pub fn set_validation_data( - &self, - data : runtime_types :: cumulus_primitives_parachain_inherent :: ParachainInherentData, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParachainSystem", - "set_validation_data", - types::SetValidationData { data }, - [ - 167u8, 126u8, 75u8, 137u8, 220u8, 60u8, 106u8, 214u8, 92u8, 170u8, - 136u8, 176u8, 98u8, 0u8, 234u8, 217u8, 146u8, 113u8, 149u8, 88u8, - 114u8, 141u8, 228u8, 105u8, 136u8, 71u8, 233u8, 18u8, 70u8, 36u8, 24u8, - 249u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_send_upward_message`]."] - pub fn sudo_send_upward_message( - &self, - message: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParachainSystem", - "sudo_send_upward_message", - types::SudoSendUpwardMessage { message }, - [ - 1u8, 231u8, 11u8, 78u8, 127u8, 117u8, 248u8, 67u8, 230u8, 199u8, 126u8, - 47u8, 20u8, 62u8, 252u8, 138u8, 199u8, 48u8, 41u8, 21u8, 28u8, 157u8, - 218u8, 143u8, 4u8, 253u8, 62u8, 192u8, 94u8, 252u8, 92u8, 180u8, - ], - ) - } - #[doc = "See [`Pallet::authorize_upgrade`]."] - pub fn authorize_upgrade( - &self, - code_hash: ::subxt::utils::H256, - check_version: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParachainSystem", - "authorize_upgrade", - types::AuthorizeUpgrade { code_hash, check_version }, - [ - 213u8, 114u8, 107u8, 169u8, 223u8, 147u8, 205u8, 204u8, 3u8, 81u8, - 228u8, 0u8, 82u8, 57u8, 43u8, 95u8, 12u8, 59u8, 241u8, 176u8, 143u8, - 131u8, 253u8, 166u8, 98u8, 187u8, 94u8, 235u8, 177u8, 110u8, 162u8, - 218u8, - ], - ) - } - #[doc = "See [`Pallet::enact_authorized_upgrade`]."] - pub fn enact_authorized_upgrade( - &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParachainSystem", - "enact_authorized_upgrade", - types::EnactAuthorizedUpgrade { code }, - [ - 232u8, 135u8, 114u8, 87u8, 196u8, 146u8, 244u8, 19u8, 106u8, 73u8, - 88u8, 193u8, 48u8, 14u8, 72u8, 133u8, 247u8, 147u8, 50u8, 95u8, 252u8, - 213u8, 192u8, 47u8, 244u8, 102u8, 195u8, 120u8, 179u8, 87u8, 94u8, 8u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::cumulus_pallet_parachain_system::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The validation function has been scheduled to apply."] - pub struct ValidationFunctionStored; - impl ::subxt::events::StaticEvent for ValidationFunctionStored { - const PALLET: &'static str = "ParachainSystem"; - const EVENT: &'static str = "ValidationFunctionStored"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The validation function was applied as of the contained relay chain block number."] - pub struct ValidationFunctionApplied { - pub relay_chain_block_num: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ValidationFunctionApplied { - const PALLET: &'static str = "ParachainSystem"; - const EVENT: &'static str = "ValidationFunctionApplied"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The relay-chain aborted the upgrade process."] - pub struct ValidationFunctionDiscarded; - impl ::subxt::events::StaticEvent for ValidationFunctionDiscarded { - const PALLET: &'static str = "ParachainSystem"; - const EVENT: &'static str = "ValidationFunctionDiscarded"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some downward messages have been received and will be processed."] - pub struct DownwardMessagesReceived { - pub count: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for DownwardMessagesReceived { - const PALLET: &'static str = "ParachainSystem"; - const EVENT: &'static str = "DownwardMessagesReceived"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Downward messages were processed using the given weight."] - pub struct DownwardMessagesProcessed { - pub weight_used: runtime_types::sp_weights::weight_v2::Weight, - pub dmq_head: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for DownwardMessagesProcessed { - const PALLET: &'static str = "ParachainSystem"; - const EVENT: &'static str = "DownwardMessagesProcessed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An upward message was sent to the relay chain."] - pub struct UpwardMessageSent { - pub message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, - } - impl ::subxt::events::StaticEvent for UpwardMessageSent { - const PALLET: &'static str = "ParachainSystem"; - const EVENT: &'static str = "UpwardMessageSent"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Latest included block descendants the runtime accepted. In other words, these are"] - #[doc = " ancestors of the currently executing block which have not been included in the observed"] - #[doc = " relay-chain state."] - #[doc = ""] - #[doc = " The segment length is limited by the capacity returned from the [`ConsensusHook`] configured"] - #[doc = " in the pallet."] pub fn unincluded_segment (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: Ancestor < :: subxt :: utils :: H256 > > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "UnincludedSegment", - vec![], - [ - 73u8, 83u8, 226u8, 16u8, 203u8, 233u8, 221u8, 109u8, 23u8, 114u8, 56u8, - 154u8, 100u8, 116u8, 253u8, 10u8, 164u8, 22u8, 110u8, 73u8, 245u8, - 226u8, 54u8, 146u8, 67u8, 109u8, 149u8, 142u8, 154u8, 218u8, 55u8, - 178u8, - ], - ) - } - #[doc = " Storage field that keeps track of bandwidth used by the unincluded segment along with the"] - #[doc = " latest HRMP watermark. Used for limiting the acceptance of new blocks with"] - #[doc = " respect to relay chain constraints."] pub fn aggregated_unincluded_segment (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: SegmentTracker < :: subxt :: utils :: H256 > , :: subxt :: storage :: address :: Yes , () , () >{ - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "AggregatedUnincludedSegment", - vec![], - [ - 165u8, 51u8, 182u8, 156u8, 65u8, 114u8, 167u8, 133u8, 245u8, 52u8, - 32u8, 119u8, 159u8, 65u8, 201u8, 108u8, 99u8, 43u8, 84u8, 63u8, 95u8, - 182u8, 134u8, 163u8, 51u8, 202u8, 243u8, 82u8, 225u8, 192u8, 186u8, - 2u8, - ], - ) - } - #[doc = " In case of a scheduled upgrade, this storage field contains the validation code to be"] - #[doc = " applied."] - #[doc = ""] - #[doc = " As soon as the relay chain gives us the go-ahead signal, we will overwrite the"] - #[doc = " [`:code`][sp_core::storage::well_known_keys::CODE] which will result the next block process"] - #[doc = " with the new validation code. This concludes the upgrade process."] - pub fn pending_validation_code( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "PendingValidationCode", - vec![], - [ - 78u8, 159u8, 219u8, 211u8, 177u8, 80u8, 102u8, 93u8, 83u8, 146u8, 90u8, - 233u8, 232u8, 11u8, 104u8, 172u8, 93u8, 68u8, 44u8, 228u8, 99u8, 197u8, - 254u8, 28u8, 181u8, 215u8, 247u8, 238u8, 49u8, 49u8, 195u8, 249u8, - ], - ) - } - #[doc = " Validation code that is set by the parachain and is to be communicated to collator and"] - #[doc = " consequently the relay-chain."] - #[doc = ""] - #[doc = " This will be cleared in `on_initialize` of each new block if no other pallet already set"] - #[doc = " the value."] - pub fn new_validation_code( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "NewValidationCode", - vec![], - [ - 185u8, 123u8, 152u8, 122u8, 230u8, 136u8, 79u8, 73u8, 206u8, 19u8, - 59u8, 57u8, 75u8, 250u8, 83u8, 185u8, 29u8, 76u8, 89u8, 137u8, 77u8, - 163u8, 25u8, 125u8, 182u8, 67u8, 2u8, 180u8, 48u8, 237u8, 49u8, 171u8, - ], - ) - } - #[doc = " The [`PersistedValidationData`] set for this block."] - #[doc = " This value is expected to be set only once per block and it's never stored"] - #[doc = " in the trie."] - pub fn validation_data( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::PersistedValidationData< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "ValidationData", - vec![], - [ - 193u8, 240u8, 25u8, 56u8, 103u8, 173u8, 56u8, 56u8, 229u8, 243u8, 91u8, - 25u8, 249u8, 95u8, 122u8, 93u8, 37u8, 181u8, 54u8, 244u8, 217u8, 200u8, - 62u8, 136u8, 80u8, 148u8, 16u8, 177u8, 124u8, 211u8, 95u8, 24u8, - ], - ) - } - #[doc = " Were the validation data set to notify the relay chain?"] - pub fn did_set_validation_code( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "DidSetValidationCode", - vec![], - [ - 233u8, 228u8, 48u8, 111u8, 200u8, 35u8, 30u8, 139u8, 251u8, 77u8, - 196u8, 252u8, 35u8, 222u8, 129u8, 235u8, 7u8, 19u8, 156u8, 82u8, 126u8, - 173u8, 29u8, 62u8, 20u8, 67u8, 166u8, 116u8, 108u8, 182u8, 57u8, 246u8, - ], - ) - } - #[doc = " The relay chain block number associated with the last parachain block."] - #[doc = ""] - #[doc = " This is updated in `on_finalize`."] - pub fn last_relay_chain_block_number( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "LastRelayChainBlockNumber", - vec![], - [ - 17u8, 65u8, 131u8, 169u8, 195u8, 243u8, 195u8, 93u8, 220u8, 174u8, - 75u8, 216u8, 214u8, 227u8, 96u8, 40u8, 8u8, 153u8, 116u8, 160u8, 79u8, - 255u8, 35u8, 232u8, 242u8, 42u8, 100u8, 150u8, 208u8, 210u8, 142u8, - 186u8, - ], - ) - } - #[doc = " An option which indicates if the relay-chain restricts signalling a validation code upgrade."] - #[doc = " In other words, if this is `Some` and [`NewValidationCode`] is `Some` then the produced"] - #[doc = " candidate will be invalid."] - #[doc = ""] - #[doc = " This storage item is a mirror of the corresponding value for the current parachain from the"] - #[doc = " relay-chain. This value is ephemeral which means it doesn't hit the storage. This value is"] - #[doc = " set after the inherent."] - pub fn upgrade_restriction_signal( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option< - runtime_types::polkadot_primitives::v6::UpgradeRestriction, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "UpgradeRestrictionSignal", - vec![], - [ - 235u8, 240u8, 37u8, 44u8, 181u8, 52u8, 7u8, 216u8, 20u8, 139u8, 69u8, - 124u8, 21u8, 173u8, 237u8, 64u8, 105u8, 88u8, 49u8, 69u8, 123u8, 55u8, - 181u8, 167u8, 112u8, 183u8, 190u8, 231u8, 231u8, 127u8, 77u8, 148u8, - ], - ) - } - #[doc = " Optional upgrade go-ahead signal from the relay-chain."] - #[doc = ""] - #[doc = " This storage item is a mirror of the corresponding value for the current parachain from the"] - #[doc = " relay-chain. This value is ephemeral which means it doesn't hit the storage. This value is"] - #[doc = " set after the inherent."] - pub fn upgrade_go_ahead( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "UpgradeGoAhead", - vec![], - [ - 149u8, 144u8, 186u8, 88u8, 180u8, 34u8, 82u8, 226u8, 100u8, 148u8, - 246u8, 55u8, 233u8, 97u8, 43u8, 0u8, 48u8, 31u8, 69u8, 154u8, 29u8, - 147u8, 241u8, 91u8, 81u8, 126u8, 206u8, 117u8, 14u8, 149u8, 87u8, 88u8, - ], - ) - } - #[doc = " The state proof for the last relay parent block."] - #[doc = ""] - #[doc = " This field is meant to be updated each block with the validation data inherent. Therefore,"] - #[doc = " before processing of the inherent, e.g. in `on_initialize` this data may be stale."] - #[doc = ""] - #[doc = " This data is also absent from the genesis."] - pub fn relay_state_proof( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_trie::storage_proof::StorageProof, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "RelayStateProof", - vec![], - [ - 46u8, 115u8, 163u8, 190u8, 246u8, 47u8, 200u8, 159u8, 206u8, 204u8, - 94u8, 250u8, 127u8, 112u8, 109u8, 111u8, 210u8, 195u8, 244u8, 41u8, - 36u8, 187u8, 71u8, 150u8, 149u8, 253u8, 143u8, 33u8, 83u8, 189u8, - 182u8, 238u8, - ], - ) - } - #[doc = " The snapshot of some state related to messaging relevant to the current parachain as per"] - #[doc = " the relay parent."] - #[doc = ""] - #[doc = " This field is meant to be updated each block with the validation data inherent. Therefore,"] - #[doc = " before processing of the inherent, e.g. in `on_initialize` this data may be stale."] - #[doc = ""] - #[doc = " This data is also absent from the genesis."] pub fn relevant_messaging_state (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: cumulus_pallet_parachain_system :: relay_state_snapshot :: MessagingStateSnapshot , :: subxt :: storage :: address :: Yes , () , () >{ - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "RelevantMessagingState", - vec![], - [ - 117u8, 166u8, 186u8, 126u8, 21u8, 174u8, 86u8, 253u8, 163u8, 90u8, - 54u8, 226u8, 186u8, 253u8, 126u8, 168u8, 145u8, 45u8, 155u8, 32u8, - 97u8, 110u8, 208u8, 125u8, 47u8, 113u8, 165u8, 199u8, 210u8, 118u8, - 217u8, 73u8, - ], - ) - } - #[doc = " The parachain host configuration that was obtained from the relay parent."] - #[doc = ""] - #[doc = " This field is meant to be updated each block with the validation data inherent. Therefore,"] - #[doc = " before processing of the inherent, e.g. in `on_initialize` this data may be stale."] - #[doc = ""] - #[doc = " This data is also absent from the genesis."] - pub fn host_configuration( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::AbridgedHostConfiguration, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "HostConfiguration", - vec![], - [ - 252u8, 23u8, 111u8, 189u8, 120u8, 204u8, 129u8, 223u8, 248u8, 179u8, - 239u8, 173u8, 133u8, 61u8, 140u8, 2u8, 75u8, 32u8, 204u8, 178u8, 69u8, - 21u8, 44u8, 227u8, 178u8, 179u8, 33u8, 26u8, 131u8, 156u8, 78u8, 85u8, - ], - ) - } - #[doc = " The last downward message queue chain head we have observed."] - #[doc = ""] - #[doc = " This value is loaded before and saved after processing inbound downward messages carried"] - #[doc = " by the system inherent."] - pub fn last_dmq_mqc_head( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::cumulus_primitives_parachain_inherent::MessageQueueChain, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "LastDmqMqcHead", - vec![], - [ - 1u8, 70u8, 140u8, 40u8, 51u8, 127u8, 75u8, 80u8, 5u8, 49u8, 196u8, - 31u8, 30u8, 61u8, 54u8, 252u8, 0u8, 0u8, 100u8, 115u8, 177u8, 250u8, - 138u8, 48u8, 107u8, 41u8, 93u8, 87u8, 195u8, 107u8, 206u8, 227u8, - ], - ) - } - #[doc = " The message queue chain heads we have observed per each channel incoming channel."] - #[doc = ""] - #[doc = " This value is loaded before and saved after processing inbound downward messages carried"] - #[doc = " by the system inherent."] - pub fn last_hrmp_mqc_heads( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::KeyedVec< - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::cumulus_primitives_parachain_inherent::MessageQueueChain, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "LastHrmpMqcHeads", - vec![], - [ - 131u8, 170u8, 142u8, 30u8, 101u8, 113u8, 131u8, 81u8, 38u8, 168u8, - 98u8, 3u8, 9u8, 109u8, 96u8, 179u8, 115u8, 177u8, 128u8, 11u8, 238u8, - 54u8, 81u8, 60u8, 97u8, 112u8, 224u8, 175u8, 86u8, 133u8, 182u8, 76u8, - ], - ) - } - #[doc = " Number of downward messages processed in a block."] - #[doc = ""] - #[doc = " This will be cleared in `on_initialize` of each new block."] - pub fn processed_downward_messages( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "ProcessedDownwardMessages", - vec![], - [ - 151u8, 234u8, 196u8, 87u8, 130u8, 79u8, 4u8, 102u8, 47u8, 10u8, 33u8, - 132u8, 149u8, 118u8, 61u8, 141u8, 5u8, 1u8, 30u8, 120u8, 220u8, 156u8, - 16u8, 11u8, 14u8, 52u8, 126u8, 151u8, 244u8, 149u8, 197u8, 51u8, - ], - ) - } - #[doc = " HRMP watermark that was set in a block."] - #[doc = ""] - #[doc = " This will be cleared in `on_initialize` of each new block."] - pub fn hrmp_watermark( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "HrmpWatermark", - vec![], - [ - 77u8, 62u8, 59u8, 220u8, 7u8, 125u8, 98u8, 249u8, 108u8, 212u8, 223u8, - 99u8, 152u8, 13u8, 29u8, 80u8, 166u8, 65u8, 232u8, 113u8, 145u8, 128u8, - 123u8, 35u8, 238u8, 31u8, 113u8, 156u8, 220u8, 104u8, 217u8, 165u8, - ], - ) - } - #[doc = " HRMP messages that were sent in a block."] - #[doc = ""] - #[doc = " This will be cleared in `on_initialize` of each new block."] - pub fn hrmp_outbound_messages( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::OutboundHrmpMessage< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "HrmpOutboundMessages", - vec![], - [ - 42u8, 9u8, 96u8, 217u8, 25u8, 101u8, 129u8, 147u8, 150u8, 20u8, 164u8, - 186u8, 217u8, 178u8, 15u8, 201u8, 233u8, 104u8, 92u8, 120u8, 29u8, - 245u8, 196u8, 13u8, 141u8, 210u8, 102u8, 62u8, 216u8, 80u8, 246u8, - 145u8, - ], - ) - } - #[doc = " Upward messages that were sent in a block."] - #[doc = ""] - #[doc = " This will be cleared in `on_initialize` of each new block."] - pub fn upward_messages( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "UpwardMessages", - vec![], - [ - 179u8, 127u8, 8u8, 94u8, 194u8, 246u8, 53u8, 79u8, 80u8, 22u8, 18u8, - 75u8, 116u8, 163u8, 90u8, 161u8, 30u8, 140u8, 57u8, 126u8, 60u8, 91u8, - 23u8, 30u8, 120u8, 245u8, 125u8, 96u8, 152u8, 25u8, 248u8, 85u8, - ], - ) - } - #[doc = " Upward messages that are still pending and not yet send to the relay chain."] - pub fn pending_upward_messages( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "PendingUpwardMessages", - vec![], - [ - 239u8, 45u8, 18u8, 173u8, 148u8, 150u8, 55u8, 176u8, 173u8, 156u8, - 246u8, 226u8, 198u8, 214u8, 104u8, 187u8, 186u8, 13u8, 83u8, 194u8, - 153u8, 29u8, 228u8, 109u8, 26u8, 18u8, 212u8, 151u8, 246u8, 24u8, - 133u8, 216u8, - ], - ) - } - #[doc = " The factor to multiply the base delivery fee by for UMP."] - pub fn upward_delivery_fee_factor( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "UpwardDeliveryFeeFactor", - vec![], - [ - 40u8, 217u8, 164u8, 111u8, 151u8, 132u8, 69u8, 226u8, 163u8, 175u8, - 43u8, 239u8, 179u8, 217u8, 136u8, 161u8, 13u8, 251u8, 163u8, 102u8, - 24u8, 27u8, 168u8, 89u8, 221u8, 83u8, 93u8, 64u8, 96u8, 117u8, 146u8, - 71u8, - ], - ) - } - #[doc = " The number of HRMP messages we observed in `on_initialize` and thus used that number for"] - #[doc = " announcing the weight of `on_initialize` and `on_finalize`."] - pub fn announced_hrmp_messages_per_candidate( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "AnnouncedHrmpMessagesPerCandidate", - vec![], - [ - 93u8, 11u8, 229u8, 172u8, 73u8, 87u8, 13u8, 149u8, 15u8, 94u8, 163u8, - 107u8, 156u8, 22u8, 131u8, 177u8, 96u8, 247u8, 213u8, 224u8, 41u8, - 126u8, 157u8, 33u8, 154u8, 194u8, 95u8, 234u8, 65u8, 19u8, 58u8, 161u8, - ], - ) - } - #[doc = " The weight we reserve at the beginning of the block for processing XCMP messages. This"] - #[doc = " overrides the amount set in the Config trait."] - pub fn reserved_xcmp_weight_override( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_weights::weight_v2::Weight, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "ReservedXcmpWeightOverride", - vec![], - [ - 176u8, 93u8, 203u8, 74u8, 18u8, 170u8, 246u8, 203u8, 109u8, 89u8, 86u8, - 77u8, 96u8, 66u8, 189u8, 79u8, 184u8, 253u8, 11u8, 230u8, 87u8, 120u8, - 1u8, 254u8, 215u8, 41u8, 210u8, 86u8, 239u8, 206u8, 60u8, 2u8, - ], - ) - } - #[doc = " The weight we reserve at the beginning of the block for processing DMP messages. This"] - #[doc = " overrides the amount set in the Config trait."] - pub fn reserved_dmp_weight_override( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_weights::weight_v2::Weight, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "ReservedDmpWeightOverride", - vec![], - [ - 205u8, 124u8, 9u8, 156u8, 255u8, 207u8, 208u8, 23u8, 179u8, 132u8, - 254u8, 157u8, 237u8, 240u8, 167u8, 203u8, 253u8, 111u8, 136u8, 32u8, - 100u8, 152u8, 16u8, 19u8, 175u8, 14u8, 108u8, 61u8, 59u8, 231u8, 70u8, - 112u8, - ], - ) - } - #[doc = " A custom head data that should be returned as result of `validate_block`."] - #[doc = ""] - #[doc = " See `Pallet::set_custom_validation_head_data` for more information."] - pub fn custom_validation_head_data( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainSystem", - "CustomValidationHeadData", - vec![], - [ - 52u8, 186u8, 187u8, 57u8, 245u8, 171u8, 202u8, 23u8, 92u8, 80u8, 118u8, - 66u8, 251u8, 156u8, 175u8, 254u8, 141u8, 185u8, 115u8, 209u8, 170u8, - 165u8, 1u8, 242u8, 120u8, 234u8, 162u8, 24u8, 135u8, 105u8, 8u8, 177u8, - ], - ) - } - } - } - } - pub mod timestamp { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_timestamp::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Set { - #[codec(compact)] - pub now: ::core::primitive::u64, - } - impl ::subxt::blocks::StaticExtrinsic for Set { - const PALLET: &'static str = "Timestamp"; - const CALL: &'static str = "set"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::set`]."] - pub fn set(&self, now: ::core::primitive::u64) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Timestamp", - "set", - types::Set { now }, - [ - 37u8, 95u8, 49u8, 218u8, 24u8, 22u8, 0u8, 95u8, 72u8, 35u8, 155u8, - 199u8, 213u8, 54u8, 207u8, 22u8, 185u8, 193u8, 221u8, 70u8, 18u8, - 200u8, 4u8, 231u8, 195u8, 173u8, 6u8, 122u8, 11u8, 203u8, 231u8, 227u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current time for the current block."] - pub fn now( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Timestamp", - "Now", - vec![], - [ - 44u8, 50u8, 80u8, 30u8, 195u8, 146u8, 123u8, 238u8, 8u8, 163u8, 187u8, - 92u8, 61u8, 39u8, 51u8, 29u8, 173u8, 169u8, 217u8, 158u8, 85u8, 187u8, - 141u8, 26u8, 12u8, 115u8, 51u8, 11u8, 200u8, 244u8, 138u8, 152u8, - ], - ) - } - #[doc = " Whether the timestamp has been updated in this block."] - #[doc = ""] - #[doc = " This value is updated to `true` upon successful submission of a timestamp by a node."] - #[doc = " It is then checked at the end of each block execution in the `on_finalize` hook."] - pub fn did_update( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Timestamp", - "DidUpdate", - vec![], - [ - 229u8, 175u8, 246u8, 102u8, 237u8, 158u8, 212u8, 229u8, 238u8, 214u8, - 205u8, 160u8, 164u8, 252u8, 195u8, 75u8, 139u8, 110u8, 22u8, 34u8, - 248u8, 204u8, 107u8, 46u8, 20u8, 200u8, 238u8, 167u8, 71u8, 41u8, - 214u8, 140u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum period between blocks."] - #[doc = ""] - #[doc = " Be aware that this is different to the *expected* period that the block production"] - #[doc = " apparatus provides. Your chosen consensus system will generally work with this to"] - #[doc = " determine a sensible block time. For example, in the Aura pallet it will be double this"] - #[doc = " period on default settings."] - pub fn minimum_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Timestamp", - "MinimumPeriod", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - } - } - } - pub mod parachain_info { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::staging_parachain_info::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - } - pub struct TransactionApi; - impl TransactionApi {} - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - pub fn parachain_id( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParachainInfo", - "ParachainId", - vec![], - [ - 160u8, 130u8, 74u8, 181u8, 231u8, 180u8, 246u8, 152u8, 204u8, 44u8, - 245u8, 91u8, 113u8, 246u8, 218u8, 50u8, 254u8, 248u8, 35u8, 219u8, - 83u8, 144u8, 228u8, 245u8, 122u8, 53u8, 194u8, 172u8, 222u8, 118u8, - 202u8, 91u8, - ], - ) - } - } - } - } - pub mod balances { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_balances::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_balances::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAllowDeath { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for TransferAllowDeath { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "transfer_allow_death"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceTransfer { - pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceTransfer { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "force_transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferKeepAlive { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for TransferKeepAlive { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "transfer_keep_alive"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAll { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub keep_alive: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for TransferAll { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "transfer_all"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnreserve { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub amount: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceUnreserve { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "force_unreserve"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpgradeAccounts { - pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - impl ::subxt::blocks::StaticExtrinsic for UpgradeAccounts { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "upgrade_accounts"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetBalance { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub new_free: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSetBalance { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "force_set_balance"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceAdjustTotalIssuance { - pub direction: runtime_types::pallet_balances::types::AdjustmentDirection, - #[codec(compact)] - pub delta: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceAdjustTotalIssuance { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "force_adjust_total_issuance"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::transfer_allow_death`]."] - pub fn transfer_allow_death( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_allow_death", - types::TransferAllowDeath { dest, value }, - [ - 51u8, 166u8, 195u8, 10u8, 139u8, 218u8, 55u8, 130u8, 6u8, 194u8, 35u8, - 140u8, 27u8, 205u8, 214u8, 222u8, 102u8, 43u8, 143u8, 145u8, 86u8, - 219u8, 210u8, 147u8, 13u8, 39u8, 51u8, 21u8, 237u8, 179u8, 132u8, - 130u8, - ], - ) - } - #[doc = "See [`Pallet::force_transfer`]."] - pub fn force_transfer( - &self, - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_transfer", - types::ForceTransfer { source, dest, value }, - [ - 154u8, 93u8, 222u8, 27u8, 12u8, 248u8, 63u8, 213u8, 224u8, 86u8, 250u8, - 153u8, 249u8, 102u8, 83u8, 160u8, 79u8, 125u8, 105u8, 222u8, 77u8, - 180u8, 90u8, 105u8, 81u8, 217u8, 60u8, 25u8, 213u8, 51u8, 185u8, 96u8, - ], - ) - } - #[doc = "See [`Pallet::transfer_keep_alive`]."] - pub fn transfer_keep_alive( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_keep_alive", - types::TransferKeepAlive { dest, value }, - [ - 245u8, 14u8, 190u8, 193u8, 32u8, 210u8, 74u8, 92u8, 25u8, 182u8, 76u8, - 55u8, 247u8, 83u8, 114u8, 75u8, 143u8, 236u8, 117u8, 25u8, 54u8, 157u8, - 208u8, 207u8, 233u8, 89u8, 70u8, 161u8, 235u8, 242u8, 222u8, 59u8, - ], - ) - } - #[doc = "See [`Pallet::transfer_all`]."] - pub fn transfer_all( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_all", - types::TransferAll { dest, keep_alive }, - [ - 105u8, 132u8, 49u8, 144u8, 195u8, 250u8, 34u8, 46u8, 213u8, 248u8, - 112u8, 188u8, 81u8, 228u8, 136u8, 18u8, 67u8, 172u8, 37u8, 38u8, 238u8, - 9u8, 34u8, 15u8, 67u8, 34u8, 148u8, 195u8, 223u8, 29u8, 154u8, 6u8, - ], - ) - } - #[doc = "See [`Pallet::force_unreserve`]."] - pub fn force_unreserve( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_unreserve", - types::ForceUnreserve { who, amount }, - [ - 142u8, 151u8, 64u8, 205u8, 46u8, 64u8, 62u8, 122u8, 108u8, 49u8, 223u8, - 140u8, 120u8, 153u8, 35u8, 165u8, 187u8, 38u8, 157u8, 200u8, 123u8, - 199u8, 198u8, 168u8, 208u8, 159u8, 39u8, 134u8, 92u8, 103u8, 84u8, - 171u8, - ], - ) - } - #[doc = "See [`Pallet::upgrade_accounts`]."] - pub fn upgrade_accounts( - &self, - who: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "upgrade_accounts", - types::UpgradeAccounts { who }, - [ - 66u8, 200u8, 179u8, 104u8, 65u8, 2u8, 101u8, 56u8, 130u8, 161u8, 224u8, - 233u8, 255u8, 124u8, 70u8, 122u8, 8u8, 49u8, 103u8, 178u8, 68u8, 47u8, - 214u8, 166u8, 217u8, 116u8, 178u8, 50u8, 212u8, 164u8, 98u8, 226u8, - ], - ) - } - #[doc = "See [`Pallet::force_set_balance`]."] - pub fn force_set_balance( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - new_free: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_set_balance", - types::ForceSetBalance { who, new_free }, - [ - 114u8, 229u8, 59u8, 204u8, 180u8, 83u8, 17u8, 4u8, 59u8, 4u8, 55u8, - 39u8, 151u8, 196u8, 124u8, 60u8, 209u8, 65u8, 193u8, 11u8, 44u8, 164u8, - 116u8, 93u8, 169u8, 30u8, 199u8, 165u8, 55u8, 231u8, 223u8, 43u8, - ], - ) - } - #[doc = "See [`Pallet::force_adjust_total_issuance`]."] - pub fn force_adjust_total_issuance( - &self, - direction: runtime_types::pallet_balances::types::AdjustmentDirection, - delta: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_adjust_total_issuance", - types::ForceAdjustTotalIssuance { direction, delta }, - [ - 208u8, 134u8, 56u8, 133u8, 232u8, 164u8, 10u8, 213u8, 53u8, 193u8, - 190u8, 63u8, 236u8, 186u8, 96u8, 122u8, 104u8, 87u8, 173u8, 38u8, 58u8, - 176u8, 21u8, 78u8, 42u8, 106u8, 46u8, 248u8, 251u8, 190u8, 150u8, - 202u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_balances::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was created with some free balance."] - pub struct Endowed { - pub account: ::subxt::utils::AccountId32, - pub free_balance: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Endowed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Endowed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] - #[doc = "resulting in an outright loss."] - pub struct DustLost { - pub account: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DustLost { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "DustLost"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Transfer succeeded."] - pub struct Transfer { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Transfer { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A balance was set by root."] - pub struct BalanceSet { - pub who: ::subxt::utils::AccountId32, - pub free: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for BalanceSet { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "BalanceSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was reserved (moved from free to reserved)."] - pub struct Reserved { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Reserved { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Reserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was unreserved (moved from reserved to free)."] - pub struct Unreserved { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unreserved { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Unreserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was moved from the reserve of the first account to the second account."] - #[doc = "Final argument indicates the destination balance type."] - pub struct ReserveRepatriated { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - } - impl ::subxt::events::StaticEvent for ReserveRepatriated { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "ReserveRepatriated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was deposited (e.g. for transaction fees)."] - pub struct Deposit { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Deposit { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Deposit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] - pub struct Withdraw { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdraw { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Withdraw"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] - pub struct Slashed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Slashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was minted into an account."] - pub struct Minted { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Minted { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Minted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was burned from an account."] - pub struct Burned { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Burned { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Burned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was suspended from an account (it can be restored later)."] - pub struct Suspended { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Suspended { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Suspended"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was restored into an account."] - pub struct Restored { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Restored { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Restored"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was upgraded."] - pub struct Upgraded { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Upgraded { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Upgraded"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] - pub struct Issued { - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Issued { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Issued"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] - pub struct Rescinded { - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Rescinded { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Rescinded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was locked."] - pub struct Locked { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Locked { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Locked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was unlocked."] - pub struct Unlocked { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unlocked { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Unlocked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was frozen."] - pub struct Frozen { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Frozen { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Frozen"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was thawed."] - pub struct Thawed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Thawed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Thawed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `TotalIssuance` was forcefully changed."] - pub struct TotalIssuanceForced { - pub old: ::core::primitive::u128, - pub new: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for TotalIssuanceForced { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "TotalIssuanceForced"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The total units issued in the system."] - pub fn total_issuance( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "TotalIssuance", - vec![], - [ - 116u8, 70u8, 119u8, 194u8, 69u8, 37u8, 116u8, 206u8, 171u8, 70u8, - 171u8, 210u8, 226u8, 111u8, 184u8, 204u8, 206u8, 11u8, 68u8, 72u8, - 255u8, 19u8, 194u8, 11u8, 27u8, 194u8, 81u8, 204u8, 59u8, 224u8, 202u8, - 185u8, - ], - ) - } - #[doc = " The total units of outstanding deactivated balance in the system."] - pub fn inactive_issuance( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "InactiveIssuance", - vec![], - [ - 212u8, 185u8, 19u8, 50u8, 250u8, 72u8, 173u8, 50u8, 4u8, 104u8, 161u8, - 249u8, 77u8, 247u8, 204u8, 248u8, 11u8, 18u8, 57u8, 4u8, 82u8, 110u8, - 30u8, 216u8, 16u8, 37u8, 87u8, 67u8, 189u8, 235u8, 214u8, 155u8, - ], - ) - } - #[doc = " The Balances pallet example of storing the balance of an account."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " You can also store the balance of an account in the `System` pallet."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = System"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] - #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] - #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] - #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] - pub fn account_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Account", - vec![], - [ - 213u8, 38u8, 200u8, 69u8, 218u8, 0u8, 112u8, 181u8, 160u8, 23u8, 96u8, - 90u8, 3u8, 88u8, 126u8, 22u8, 103u8, 74u8, 64u8, 69u8, 29u8, 247u8, - 18u8, 17u8, 234u8, 143u8, 189u8, 22u8, 247u8, 194u8, 154u8, 249u8, - ], - ) - } - #[doc = " The Balances pallet example of storing the balance of an account."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " You can also store the balance of an account in the `System` pallet."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = System"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] - #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] - #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] - #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] - pub fn account( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Account", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 213u8, 38u8, 200u8, 69u8, 218u8, 0u8, 112u8, 181u8, 160u8, 23u8, 96u8, - 90u8, 3u8, 88u8, 126u8, 22u8, 103u8, 74u8, 64u8, 69u8, 29u8, 247u8, - 18u8, 17u8, 234u8, 143u8, 189u8, 22u8, 247u8, 194u8, 154u8, 249u8, - ], - ) - } - #[doc = " Any liquidity locks on some account balances."] - #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] - pub fn locks_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Locks", - vec![], - [ - 10u8, 223u8, 55u8, 0u8, 249u8, 69u8, 168u8, 41u8, 75u8, 35u8, 120u8, - 167u8, 18u8, 132u8, 9u8, 20u8, 91u8, 51u8, 27u8, 69u8, 136u8, 187u8, - 13u8, 220u8, 163u8, 122u8, 26u8, 141u8, 174u8, 249u8, 85u8, 37u8, - ], - ) - } - #[doc = " Any liquidity locks on some account balances."] - #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] - pub fn locks( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Locks", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 10u8, 223u8, 55u8, 0u8, 249u8, 69u8, 168u8, 41u8, 75u8, 35u8, 120u8, - 167u8, 18u8, 132u8, 9u8, 20u8, 91u8, 51u8, 27u8, 69u8, 136u8, 187u8, - 13u8, 220u8, 163u8, 122u8, 26u8, 141u8, 174u8, 249u8, 85u8, 37u8, - ], - ) - } - #[doc = " Named reserves on some account balances."] - pub fn reserves_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::ReserveData< - [::core::primitive::u8; 8usize], - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Reserves", - vec![], - [ - 112u8, 10u8, 241u8, 77u8, 64u8, 187u8, 106u8, 159u8, 13u8, 153u8, - 140u8, 178u8, 182u8, 50u8, 1u8, 55u8, 149u8, 92u8, 196u8, 229u8, 170u8, - 106u8, 193u8, 88u8, 255u8, 244u8, 2u8, 193u8, 62u8, 235u8, 204u8, 91u8, - ], - ) - } - #[doc = " Named reserves on some account balances."] - pub fn reserves( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::ReserveData< - [::core::primitive::u8; 8usize], - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Reserves", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 112u8, 10u8, 241u8, 77u8, 64u8, 187u8, 106u8, 159u8, 13u8, 153u8, - 140u8, 178u8, 182u8, 50u8, 1u8, 55u8, 149u8, 92u8, 196u8, 229u8, 170u8, - 106u8, 193u8, 88u8, 255u8, 244u8, 2u8, 193u8, 62u8, 235u8, 204u8, 91u8, - ], - ) - } - #[doc = " Holds on account balances."] - pub fn holds_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - runtime_types::coretime_rococo_runtime::RuntimeHoldReason, - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Holds", - vec![], - [ - 37u8, 176u8, 2u8, 18u8, 109u8, 26u8, 66u8, 81u8, 28u8, 104u8, 149u8, - 117u8, 119u8, 114u8, 196u8, 35u8, 172u8, 155u8, 66u8, 195u8, 98u8, - 37u8, 134u8, 22u8, 106u8, 221u8, 215u8, 97u8, 25u8, 28u8, 21u8, 206u8, - ], - ) - } - #[doc = " Holds on account balances."] - pub fn holds( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - runtime_types::coretime_rococo_runtime::RuntimeHoldReason, - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Holds", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 37u8, 176u8, 2u8, 18u8, 109u8, 26u8, 66u8, 81u8, 28u8, 104u8, 149u8, - 117u8, 119u8, 114u8, 196u8, 35u8, 172u8, 155u8, 66u8, 195u8, 98u8, - 37u8, 134u8, 22u8, 106u8, 221u8, 215u8, 97u8, 25u8, 28u8, 21u8, 206u8, - ], - ) - } - #[doc = " Freeze locks on account balances."] - pub fn freezes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Freezes", - vec![], - [ - 69u8, 49u8, 165u8, 76u8, 135u8, 142u8, 179u8, 118u8, 50u8, 109u8, 53u8, - 112u8, 110u8, 94u8, 30u8, 93u8, 173u8, 38u8, 27u8, 142u8, 19u8, 5u8, - 163u8, 4u8, 68u8, 218u8, 179u8, 224u8, 118u8, 218u8, 115u8, 64u8, - ], - ) - } - #[doc = " Freeze locks on account balances."] - pub fn freezes( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Freezes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 69u8, 49u8, 165u8, 76u8, 135u8, 142u8, 179u8, 118u8, 50u8, 109u8, 53u8, - 112u8, 110u8, 94u8, 30u8, 93u8, 173u8, 38u8, 27u8, 142u8, 19u8, 5u8, - 163u8, 4u8, 68u8, 218u8, 179u8, 224u8, 118u8, 218u8, 115u8, 64u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount required to keep an account open. MUST BE GREATER THAN ZERO!"] - #[doc = ""] - #[doc = " If you *really* need it to be zero, you can enable the feature `insecure_zero_ed` for"] - #[doc = " this pallet. However, you do so at your own risk: this will open up a major DoS vector."] - #[doc = " In case you have multiple sources of provider references, you may also get unexpected"] - #[doc = " behaviour if you set this to zero."] - #[doc = ""] - #[doc = " Bottom line: Do yourself a favour and make it at least one!"] - pub fn existential_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Balances", - "ExistentialDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum number of locks that should exist on an account."] - #[doc = " Not strictly enforced, but used for weight estimation."] - pub fn max_locks(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxLocks", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of named reserves that can exist on an account."] - pub fn max_reserves(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxReserves", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of individual freeze locks that can exist on an account at any time."] - pub fn max_freezes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxFreezes", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod transaction_payment { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_transaction_payment::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] - #[doc = "has been paid by `who`."] - pub struct TransactionFeePaid { - pub who: ::subxt::utils::AccountId32, - pub actual_fee: ::core::primitive::u128, - pub tip: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for TransactionFeePaid { - const PALLET: &'static str = "TransactionPayment"; - const EVENT: &'static str = "TransactionFeePaid"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - pub fn next_fee_multiplier( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "TransactionPayment", - "NextFeeMultiplier", - vec![], - [ - 247u8, 39u8, 81u8, 170u8, 225u8, 226u8, 82u8, 147u8, 34u8, 113u8, - 147u8, 213u8, 59u8, 80u8, 139u8, 35u8, 36u8, 196u8, 152u8, 19u8, 9u8, - 159u8, 176u8, 79u8, 249u8, 201u8, 170u8, 1u8, 129u8, 79u8, 146u8, - 197u8, - ], - ) - } - pub fn storage_version( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_transaction_payment::Releases, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "TransactionPayment", - "StorageVersion", - vec![], - [ - 105u8, 243u8, 158u8, 241u8, 159u8, 231u8, 253u8, 6u8, 4u8, 32u8, 85u8, - 178u8, 126u8, 31u8, 203u8, 134u8, 154u8, 38u8, 122u8, 155u8, 150u8, - 251u8, 174u8, 15u8, 74u8, 134u8, 216u8, 244u8, 168u8, 175u8, 158u8, - 144u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " A fee multiplier for `Operational` extrinsics to compute \"virtual tip\" to boost their"] - #[doc = " `priority`"] - #[doc = ""] - #[doc = " This value is multiplied by the `final_fee` to obtain a \"virtual tip\" that is later"] - #[doc = " added to a tip component in regular `priority` calculations."] - #[doc = " It means that a `Normal` transaction can front-run a similarly-sized `Operational`"] - #[doc = " extrinsic (with no tip), by including a tip value greater than the virtual tip."] - #[doc = ""] - #[doc = " ```rust,ignore"] - #[doc = " // For `Normal`"] - #[doc = " let priority = priority_calc(tip);"] - #[doc = ""] - #[doc = " // For `Operational`"] - #[doc = " let virtual_tip = (inclusion_fee + tip) * OperationalFeeMultiplier;"] - #[doc = " let priority = priority_calc(tip + virtual_tip);"] - #[doc = " ```"] - #[doc = ""] - #[doc = " Note that since we use `final_fee` the multiplier applies also to the regular `tip`"] - #[doc = " sent with the transaction. So, not only does the transaction get a priority bump based"] - #[doc = " on the `inclusion_fee`, but we also amplify the impact of tips applied to `Operational`"] - #[doc = " transactions."] - pub fn operational_fee_multiplier( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u8> { - ::subxt::constants::Address::new_static( - "TransactionPayment", - "OperationalFeeMultiplier", - [ - 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, - 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, - 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, - 165u8, - ], - ) - } - } - } - } - pub mod authorship { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Author of current block."] - pub fn author( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Authorship", - "Author", - vec![], - [ - 247u8, 192u8, 118u8, 227u8, 47u8, 20u8, 203u8, 199u8, 216u8, 87u8, - 220u8, 50u8, 166u8, 61u8, 168u8, 213u8, 253u8, 62u8, 202u8, 199u8, - 61u8, 192u8, 237u8, 53u8, 22u8, 148u8, 164u8, 245u8, 99u8, 24u8, 146u8, - 18u8, - ], - ) - } - } - } - } - pub mod collator_selection { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_collator_selection::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_collator_selection::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetInvulnerables { - pub new: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - impl ::subxt::blocks::StaticExtrinsic for SetInvulnerables { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "set_invulnerables"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDesiredCandidates { - pub max: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetDesiredCandidates { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "set_desired_candidates"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCandidacyBond { - pub bond: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for SetCandidacyBond { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "set_candidacy_bond"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RegisterAsCandidate; - impl ::subxt::blocks::StaticExtrinsic for RegisterAsCandidate { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "register_as_candidate"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LeaveIntent; - impl ::subxt::blocks::StaticExtrinsic for LeaveIntent { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "leave_intent"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddInvulnerable { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for AddInvulnerable { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "add_invulnerable"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveInvulnerable { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveInvulnerable { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "remove_invulnerable"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpdateBond { - pub new_deposit: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for UpdateBond { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "update_bond"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TakeCandidateSlot { - pub deposit: ::core::primitive::u128, - pub target: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for TakeCandidateSlot { - const PALLET: &'static str = "CollatorSelection"; - const CALL: &'static str = "take_candidate_slot"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::set_invulnerables`]."] - pub fn set_invulnerables( - &self, - new: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "set_invulnerables", - types::SetInvulnerables { new }, - [ - 113u8, 217u8, 14u8, 48u8, 6u8, 198u8, 8u8, 170u8, 8u8, 237u8, 230u8, - 184u8, 17u8, 181u8, 15u8, 126u8, 117u8, 3u8, 208u8, 215u8, 40u8, 16u8, - 150u8, 162u8, 37u8, 196u8, 235u8, 36u8, 247u8, 24u8, 187u8, 17u8, - ], - ) - } - #[doc = "See [`Pallet::set_desired_candidates`]."] - pub fn set_desired_candidates( - &self, - max: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "set_desired_candidates", - types::SetDesiredCandidates { max }, - [ - 174u8, 44u8, 232u8, 155u8, 228u8, 219u8, 239u8, 75u8, 86u8, 150u8, - 135u8, 214u8, 58u8, 9u8, 25u8, 133u8, 245u8, 101u8, 85u8, 246u8, 15u8, - 248u8, 165u8, 87u8, 88u8, 28u8, 10u8, 196u8, 86u8, 89u8, 28u8, 165u8, - ], - ) - } - #[doc = "See [`Pallet::set_candidacy_bond`]."] - pub fn set_candidacy_bond( - &self, - bond: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "set_candidacy_bond", - types::SetCandidacyBond { bond }, - [ - 250u8, 4u8, 185u8, 228u8, 101u8, 223u8, 49u8, 44u8, 172u8, 148u8, - 216u8, 242u8, 192u8, 88u8, 228u8, 59u8, 225u8, 222u8, 171u8, 40u8, - 23u8, 1u8, 46u8, 183u8, 189u8, 191u8, 156u8, 12u8, 218u8, 116u8, 76u8, - 59u8, - ], - ) - } - #[doc = "See [`Pallet::register_as_candidate`]."] - pub fn register_as_candidate( - &self, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "register_as_candidate", - types::RegisterAsCandidate {}, - [ - 69u8, 222u8, 214u8, 106u8, 105u8, 168u8, 82u8, 239u8, 158u8, 117u8, - 224u8, 89u8, 228u8, 51u8, 221u8, 244u8, 88u8, 63u8, 72u8, 119u8, 224u8, - 111u8, 93u8, 39u8, 18u8, 66u8, 72u8, 105u8, 70u8, 66u8, 178u8, 173u8, - ], - ) - } - #[doc = "See [`Pallet::leave_intent`]."] - pub fn leave_intent(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "leave_intent", - types::LeaveIntent {}, - [ - 126u8, 57u8, 10u8, 67u8, 120u8, 229u8, 70u8, 23u8, 154u8, 215u8, 226u8, - 178u8, 203u8, 152u8, 195u8, 177u8, 157u8, 158u8, 40u8, 17u8, 93u8, - 225u8, 253u8, 217u8, 48u8, 165u8, 55u8, 79u8, 43u8, 123u8, 193u8, - 147u8, - ], - ) - } - #[doc = "See [`Pallet::add_invulnerable`]."] - pub fn add_invulnerable( - &self, - who: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "add_invulnerable", - types::AddInvulnerable { who }, - [ - 115u8, 109u8, 38u8, 19u8, 81u8, 194u8, 124u8, 140u8, 239u8, 23u8, 85u8, - 62u8, 241u8, 83u8, 11u8, 241u8, 14u8, 34u8, 206u8, 63u8, 104u8, 78u8, - 96u8, 182u8, 173u8, 198u8, 230u8, 107u8, 102u8, 6u8, 164u8, 75u8, - ], - ) - } - #[doc = "See [`Pallet::remove_invulnerable`]."] - pub fn remove_invulnerable( - &self, - who: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "remove_invulnerable", - types::RemoveInvulnerable { who }, - [ - 103u8, 146u8, 23u8, 136u8, 61u8, 65u8, 172u8, 157u8, 216u8, 200u8, - 119u8, 28u8, 189u8, 215u8, 13u8, 100u8, 102u8, 13u8, 94u8, 12u8, 78u8, - 156u8, 149u8, 74u8, 126u8, 118u8, 127u8, 49u8, 129u8, 2u8, 12u8, 118u8, - ], - ) - } - #[doc = "See [`Pallet::update_bond`]."] - pub fn update_bond( - &self, - new_deposit: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "update_bond", - types::UpdateBond { new_deposit }, - [ - 47u8, 184u8, 193u8, 220u8, 160u8, 1u8, 253u8, 203u8, 8u8, 142u8, 43u8, - 151u8, 190u8, 138u8, 201u8, 174u8, 233u8, 112u8, 200u8, 247u8, 251u8, - 94u8, 23u8, 224u8, 150u8, 179u8, 190u8, 140u8, 199u8, 50u8, 2u8, 249u8, - ], - ) - } - #[doc = "See [`Pallet::take_candidate_slot`]."] - pub fn take_candidate_slot( - &self, - deposit: ::core::primitive::u128, - target: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "CollatorSelection", - "take_candidate_slot", - types::TakeCandidateSlot { deposit, target }, - [ - 48u8, 150u8, 189u8, 206u8, 199u8, 196u8, 173u8, 3u8, 206u8, 10u8, 50u8, - 160u8, 15u8, 53u8, 189u8, 126u8, 154u8, 36u8, 90u8, 66u8, 235u8, 12u8, - 107u8, 44u8, 117u8, 33u8, 207u8, 194u8, 251u8, 194u8, 224u8, 80u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_collator_selection::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New Invulnerables were set."] - pub struct NewInvulnerables { - pub invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - impl ::subxt::events::StaticEvent for NewInvulnerables { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "NewInvulnerables"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new Invulnerable was added."] - pub struct InvulnerableAdded { - pub account_id: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for InvulnerableAdded { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "InvulnerableAdded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An Invulnerable was removed."] - pub struct InvulnerableRemoved { - pub account_id: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for InvulnerableRemoved { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "InvulnerableRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The number of desired candidates was set."] - pub struct NewDesiredCandidates { - pub desired_candidates: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for NewDesiredCandidates { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "NewDesiredCandidates"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The candidacy bond was set."] - pub struct NewCandidacyBond { - pub bond_amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for NewCandidacyBond { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "NewCandidacyBond"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new candidate joined."] - pub struct CandidateAdded { - pub account_id: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for CandidateAdded { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "CandidateAdded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Bond of a candidate updated."] - pub struct CandidateBondUpdated { - pub account_id: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for CandidateBondUpdated { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "CandidateBondUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was removed."] - pub struct CandidateRemoved { - pub account_id: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for CandidateRemoved { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "CandidateRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was replaced in the candidate list by another one."] - pub struct CandidateReplaced { - pub old: ::subxt::utils::AccountId32, - pub new: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for CandidateReplaced { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "CandidateReplaced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was unable to be added to the Invulnerables because they did not have keys"] - #[doc = "registered. Other Invulnerables may have been set."] - pub struct InvalidInvulnerableSkipped { - pub account_id: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for InvalidInvulnerableSkipped { - const PALLET: &'static str = "CollatorSelection"; - const EVENT: &'static str = "InvalidInvulnerableSkipped"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The invulnerable, permissioned collators. This list must be sorted."] - pub fn invulnerables( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "CollatorSelection", - "Invulnerables", - vec![], - [ - 109u8, 180u8, 25u8, 41u8, 152u8, 158u8, 186u8, 214u8, 89u8, 222u8, - 103u8, 14u8, 91u8, 3u8, 65u8, 6u8, 255u8, 62u8, 47u8, 255u8, 132u8, - 164u8, 217u8, 200u8, 130u8, 29u8, 168u8, 23u8, 81u8, 217u8, 35u8, - 123u8, - ], - ) - } - #[doc = " The (community, limited) collation candidates. `Candidates` and `Invulnerables` should be"] - #[doc = " mutually exclusive."] - #[doc = ""] - #[doc = " This list is sorted in ascending order by deposit and when the deposits are equal, the least"] - #[doc = " recently updated is considered greater."] - pub fn candidate_list( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_collator_selection::pallet::CandidateInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "CollatorSelection", - "CandidateList", - vec![], - [ - 77u8, 195u8, 89u8, 139u8, 79u8, 111u8, 151u8, 215u8, 19u8, 152u8, 67u8, - 49u8, 74u8, 76u8, 3u8, 60u8, 51u8, 140u8, 6u8, 134u8, 159u8, 55u8, - 196u8, 57u8, 189u8, 31u8, 219u8, 218u8, 164u8, 189u8, 196u8, 60u8, - ], - ) - } - #[doc = " Last block authored by collator."] - pub fn last_authored_block_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "CollatorSelection", - "LastAuthoredBlock", - vec![], - [ - 176u8, 170u8, 165u8, 244u8, 101u8, 126u8, 24u8, 132u8, 228u8, 138u8, - 72u8, 241u8, 144u8, 100u8, 79u8, 112u8, 9u8, 46u8, 210u8, 80u8, 12u8, - 126u8, 32u8, 214u8, 26u8, 171u8, 155u8, 3u8, 233u8, 22u8, 164u8, 25u8, - ], - ) - } - #[doc = " Last block authored by collator."] - pub fn last_authored_block( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "CollatorSelection", - "LastAuthoredBlock", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 176u8, 170u8, 165u8, 244u8, 101u8, 126u8, 24u8, 132u8, 228u8, 138u8, - 72u8, 241u8, 144u8, 100u8, 79u8, 112u8, 9u8, 46u8, 210u8, 80u8, 12u8, - 126u8, 32u8, 214u8, 26u8, 171u8, 155u8, 3u8, 233u8, 22u8, 164u8, 25u8, - ], - ) - } - #[doc = " Desired number of candidates."] - #[doc = ""] - #[doc = " This should ideally always be less than [`Config::MaxCandidates`] for weights to be correct."] - pub fn desired_candidates( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "CollatorSelection", - "DesiredCandidates", - vec![], - [ - 69u8, 199u8, 130u8, 132u8, 10u8, 127u8, 204u8, 220u8, 59u8, 107u8, - 96u8, 180u8, 42u8, 235u8, 14u8, 126u8, 231u8, 242u8, 162u8, 126u8, - 63u8, 223u8, 15u8, 250u8, 22u8, 210u8, 54u8, 34u8, 235u8, 191u8, 250u8, - 21u8, - ], - ) - } - #[doc = " Fixed amount to deposit to become a collator."] - #[doc = ""] - #[doc = " When a collator calls `leave_intent` they immediately receive the deposit back."] - pub fn candidacy_bond( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "CollatorSelection", - "CandidacyBond", - vec![], - [ - 71u8, 134u8, 156u8, 102u8, 201u8, 83u8, 240u8, 251u8, 189u8, 213u8, - 211u8, 182u8, 126u8, 122u8, 41u8, 174u8, 105u8, 29u8, 216u8, 23u8, - 255u8, 55u8, 245u8, 187u8, 234u8, 234u8, 178u8, 155u8, 145u8, 49u8, - 196u8, 214u8, - ], - ) - } - } - } - } - pub mod session { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the session pallet."] - pub type Error = runtime_types::pallet_session::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_session::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetKeys { - pub keys: runtime_types::coretime_rococo_runtime::SessionKeys, - pub proof: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for SetKeys { - const PALLET: &'static str = "Session"; - const CALL: &'static str = "set_keys"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PurgeKeys; - impl ::subxt::blocks::StaticExtrinsic for PurgeKeys { - const PALLET: &'static str = "Session"; - const CALL: &'static str = "purge_keys"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::set_keys`]."] - pub fn set_keys( - &self, - keys: runtime_types::coretime_rococo_runtime::SessionKeys, - proof: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Session", - "set_keys", - types::SetKeys { keys, proof }, - [ - 10u8, 183u8, 202u8, 82u8, 236u8, 202u8, 212u8, 220u8, 51u8, 217u8, - 229u8, 169u8, 238u8, 141u8, 129u8, 231u8, 203u8, 176u8, 97u8, 148u8, - 240u8, 87u8, 177u8, 245u8, 33u8, 109u8, 243u8, 52u8, 46u8, 118u8, - 164u8, 35u8, - ], - ) - } - #[doc = "See [`Pallet::purge_keys`]."] - pub fn purge_keys(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Session", - "purge_keys", - types::PurgeKeys {}, - [ - 215u8, 204u8, 146u8, 236u8, 32u8, 78u8, 198u8, 79u8, 85u8, 214u8, 15u8, - 151u8, 158u8, 31u8, 146u8, 119u8, 119u8, 204u8, 151u8, 169u8, 226u8, - 67u8, 217u8, 39u8, 241u8, 245u8, 203u8, 240u8, 203u8, 172u8, 16u8, - 209u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_session::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New session has happened. Note that the argument is the session index, not the"] - #[doc = "block number as the type might suggest."] - pub struct NewSession { - pub session_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for NewSession { - const PALLET: &'static str = "Session"; - const EVENT: &'static str = "NewSession"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current set of validators."] - pub fn validators( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "Validators", - vec![], - [ - 50u8, 86u8, 154u8, 222u8, 249u8, 209u8, 156u8, 22u8, 155u8, 25u8, - 133u8, 194u8, 210u8, 50u8, 38u8, 28u8, 139u8, 201u8, 90u8, 139u8, - 115u8, 12u8, 12u8, 141u8, 4u8, 178u8, 201u8, 241u8, 223u8, 234u8, 6u8, - 86u8, - ], - ) - } - #[doc = " Current index of the session."] - pub fn current_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "CurrentIndex", - vec![], - [ - 167u8, 151u8, 125u8, 150u8, 159u8, 21u8, 78u8, 217u8, 237u8, 183u8, - 135u8, 65u8, 187u8, 114u8, 188u8, 206u8, 16u8, 32u8, 69u8, 208u8, - 134u8, 159u8, 232u8, 224u8, 243u8, 27u8, 31u8, 166u8, 145u8, 44u8, - 221u8, 230u8, - ], - ) - } - #[doc = " True if the underlying economic identities or weighting behind the validators"] - #[doc = " has changed in the queued validator set."] - pub fn queued_changed( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "QueuedChanged", - vec![], - [ - 184u8, 137u8, 224u8, 137u8, 31u8, 236u8, 95u8, 164u8, 102u8, 225u8, - 198u8, 227u8, 140u8, 37u8, 113u8, 57u8, 59u8, 4u8, 202u8, 102u8, 117u8, - 36u8, 226u8, 64u8, 113u8, 141u8, 199u8, 111u8, 99u8, 144u8, 198u8, - 153u8, - ], - ) - } - #[doc = " The queued keys for the next session. When the next session begins, these keys"] - #[doc = " will be used to determine the validator's session keys."] - pub fn queued_keys( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::coretime_rococo_runtime::SessionKeys, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "QueuedKeys", - vec![], - [ - 3u8, 214u8, 191u8, 168u8, 90u8, 94u8, 107u8, 111u8, 170u8, 31u8, 78u8, - 61u8, 240u8, 184u8, 170u8, 104u8, 178u8, 229u8, 159u8, 89u8, 207u8, - 37u8, 49u8, 209u8, 131u8, 165u8, 14u8, 169u8, 13u8, 68u8, 151u8, 144u8, - ], - ) - } - #[doc = " Indices of disabled validators."] - #[doc = ""] - #[doc = " The vec is always kept sorted so that we can find whether a given validator is"] - #[doc = " disabled using binary search. It gets cleared when `on_session_ending` returns"] - #[doc = " a new set of identities."] - pub fn disabled_validators( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "DisabledValidators", - vec![], - [ - 213u8, 19u8, 168u8, 234u8, 187u8, 200u8, 180u8, 97u8, 234u8, 189u8, - 36u8, 233u8, 158u8, 184u8, 45u8, 35u8, 129u8, 213u8, 133u8, 8u8, 104u8, - 183u8, 46u8, 68u8, 154u8, 240u8, 132u8, 22u8, 247u8, 11u8, 54u8, 221u8, - ], - ) - } - #[doc = " The next session keys for a validator."] - pub fn next_keys_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::coretime_rococo_runtime::SessionKeys, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "NextKeys", - vec![], - [ - 193u8, 216u8, 53u8, 103u8, 143u8, 241u8, 201u8, 54u8, 108u8, 149u8, - 241u8, 42u8, 3u8, 151u8, 223u8, 246u8, 30u8, 6u8, 239u8, 206u8, 27u8, - 172u8, 43u8, 226u8, 177u8, 111u8, 203u8, 78u8, 49u8, 34u8, 200u8, 6u8, - ], - ) - } - #[doc = " The next session keys for a validator."] - pub fn next_keys( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::coretime_rococo_runtime::SessionKeys, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "NextKeys", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 193u8, 216u8, 53u8, 103u8, 143u8, 241u8, 201u8, 54u8, 108u8, 149u8, - 241u8, 42u8, 3u8, 151u8, 223u8, 246u8, 30u8, 6u8, 239u8, 206u8, 27u8, - 172u8, 43u8, 226u8, 177u8, 111u8, 203u8, 78u8, 49u8, 34u8, 200u8, 6u8, - ], - ) - } - #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] - pub fn key_owner_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "KeyOwner", - vec![], - [ - 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, - 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, - 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, - 206u8, - ], - ) - } - #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] - pub fn key_owner_iter1( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "KeyOwner", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, - 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, - 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, - 206u8, - ], - ) - } - #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] - pub fn key_owner( - &self, - _0: impl ::std::borrow::Borrow, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "KeyOwner", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, - 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, - 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, - 206u8, - ], - ) - } - } - } - } - pub mod aura { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current authority set."] - pub fn authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::sp_consensus_aura::sr25519::app_sr25519::Public, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Aura", - "Authorities", - vec![], - [ - 232u8, 129u8, 167u8, 104u8, 47u8, 188u8, 238u8, 164u8, 6u8, 29u8, - 129u8, 45u8, 64u8, 182u8, 194u8, 47u8, 0u8, 73u8, 63u8, 102u8, 204u8, - 94u8, 111u8, 96u8, 137u8, 7u8, 141u8, 110u8, 180u8, 80u8, 228u8, 16u8, - ], - ) - } - #[doc = " The current slot of this block."] - #[doc = ""] - #[doc = " This will be set in `on_initialize`."] - pub fn current_slot( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_slots::Slot, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Aura", - "CurrentSlot", - vec![], - [ - 112u8, 199u8, 115u8, 248u8, 217u8, 242u8, 45u8, 231u8, 178u8, 53u8, - 236u8, 167u8, 219u8, 238u8, 81u8, 243u8, 39u8, 140u8, 68u8, 19u8, - 201u8, 169u8, 211u8, 133u8, 135u8, 213u8, 150u8, 105u8, 60u8, 252u8, - 43u8, 57u8, - ], - ) - } - } - } - } - pub mod aura_ext { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Serves as cache for the authorities."] - #[doc = ""] - #[doc = " The authorities in AuRa are overwritten in `on_initialize` when we switch to a new session,"] - #[doc = " but we require the old authorities to verify the seal when validating a PoV. This will"] - #[doc = " always be updated to the latest AuRa authorities in `on_finalize`."] - pub fn authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::sp_consensus_aura::sr25519::app_sr25519::Public, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "AuraExt", - "Authorities", - vec![], - [ - 232u8, 129u8, 167u8, 104u8, 47u8, 188u8, 238u8, 164u8, 6u8, 29u8, - 129u8, 45u8, 64u8, 182u8, 194u8, 47u8, 0u8, 73u8, 63u8, 102u8, 204u8, - 94u8, 111u8, 96u8, 137u8, 7u8, 141u8, 110u8, 180u8, 80u8, 228u8, 16u8, - ], - ) - } - #[doc = " Current slot paired with a number of authored blocks."] - #[doc = ""] - #[doc = " Updated on each block initialization."] - pub fn slot_info( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (runtime_types::sp_consensus_slots::Slot, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "AuraExt", - "SlotInfo", - vec![], - [ - 135u8, 135u8, 71u8, 123u8, 102u8, 223u8, 215u8, 76u8, 183u8, 169u8, - 108u8, 60u8, 122u8, 5u8, 24u8, 201u8, 96u8, 59u8, 132u8, 95u8, 253u8, - 100u8, 148u8, 184u8, 133u8, 146u8, 101u8, 201u8, 91u8, 30u8, 76u8, - 169u8, - ], - ) - } - } - } - } - pub mod xcmp_queue { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::cumulus_pallet_xcmp_queue::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::cumulus_pallet_xcmp_queue::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SuspendXcmExecution; - impl ::subxt::blocks::StaticExtrinsic for SuspendXcmExecution { - const PALLET: &'static str = "XcmpQueue"; - const CALL: &'static str = "suspend_xcm_execution"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ResumeXcmExecution; - impl ::subxt::blocks::StaticExtrinsic for ResumeXcmExecution { - const PALLET: &'static str = "XcmpQueue"; - const CALL: &'static str = "resume_xcm_execution"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpdateSuspendThreshold { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for UpdateSuspendThreshold { - const PALLET: &'static str = "XcmpQueue"; - const CALL: &'static str = "update_suspend_threshold"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpdateDropThreshold { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for UpdateDropThreshold { - const PALLET: &'static str = "XcmpQueue"; - const CALL: &'static str = "update_drop_threshold"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpdateResumeThreshold { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for UpdateResumeThreshold { - const PALLET: &'static str = "XcmpQueue"; - const CALL: &'static str = "update_resume_threshold"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::suspend_xcm_execution`]."] - pub fn suspend_xcm_execution( - &self, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmpQueue", - "suspend_xcm_execution", - types::SuspendXcmExecution {}, - [ - 54u8, 120u8, 33u8, 251u8, 74u8, 56u8, 29u8, 76u8, 104u8, 218u8, 115u8, - 198u8, 148u8, 237u8, 9u8, 191u8, 241u8, 48u8, 33u8, 24u8, 60u8, 144u8, - 22u8, 78u8, 58u8, 50u8, 26u8, 188u8, 231u8, 42u8, 201u8, 76u8, - ], - ) - } - #[doc = "See [`Pallet::resume_xcm_execution`]."] - pub fn resume_xcm_execution( - &self, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmpQueue", - "resume_xcm_execution", - types::ResumeXcmExecution {}, - [ - 173u8, 231u8, 78u8, 253u8, 108u8, 234u8, 199u8, 124u8, 184u8, 154u8, - 95u8, 194u8, 13u8, 77u8, 175u8, 7u8, 7u8, 112u8, 161u8, 72u8, 133u8, - 71u8, 63u8, 218u8, 97u8, 226u8, 133u8, 6u8, 93u8, 177u8, 247u8, 109u8, - ], - ) - } - #[doc = "See [`Pallet::update_suspend_threshold`]."] - pub fn update_suspend_threshold( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmpQueue", - "update_suspend_threshold", - types::UpdateSuspendThreshold { new }, - [ - 64u8, 91u8, 172u8, 51u8, 220u8, 174u8, 54u8, 47u8, 57u8, 89u8, 75u8, - 39u8, 126u8, 198u8, 143u8, 35u8, 70u8, 125u8, 167u8, 14u8, 17u8, 18u8, - 146u8, 222u8, 100u8, 92u8, 81u8, 239u8, 173u8, 43u8, 42u8, 174u8, - ], - ) - } - #[doc = "See [`Pallet::update_drop_threshold`]."] - pub fn update_drop_threshold( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmpQueue", - "update_drop_threshold", - types::UpdateDropThreshold { new }, - [ - 123u8, 54u8, 12u8, 180u8, 165u8, 198u8, 141u8, 200u8, 149u8, 168u8, - 186u8, 237u8, 162u8, 91u8, 89u8, 242u8, 229u8, 16u8, 32u8, 254u8, 59u8, - 168u8, 31u8, 134u8, 217u8, 251u8, 0u8, 102u8, 113u8, 194u8, 175u8, 9u8, - ], - ) - } - #[doc = "See [`Pallet::update_resume_threshold`]."] - pub fn update_resume_threshold( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmpQueue", - "update_resume_threshold", - types::UpdateResumeThreshold { new }, - [ - 172u8, 136u8, 11u8, 106u8, 42u8, 157u8, 167u8, 183u8, 87u8, 62u8, - 182u8, 17u8, 184u8, 59u8, 215u8, 230u8, 18u8, 243u8, 212u8, 34u8, 54u8, - 188u8, 95u8, 119u8, 173u8, 20u8, 91u8, 206u8, 212u8, 57u8, 136u8, 77u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::cumulus_pallet_xcmp_queue::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An HRMP message was sent to a sibling parachain."] - pub struct XcmpMessageSent { - pub message_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for XcmpMessageSent { - const PALLET: &'static str = "XcmpQueue"; - const EVENT: &'static str = "XcmpMessageSent"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The suspended inbound XCMP channels. All others are not suspended."] - #[doc = ""] - #[doc = " This is a `StorageValue` instead of a `StorageMap` since we expect multiple reads per block"] - #[doc = " to different keys with a one byte payload. The access to `BoundedBTreeSet` will be cached"] - #[doc = " within the block and therefore only included once in the proof size."] - #[doc = ""] - #[doc = " NOTE: The PoV benchmarking cannot know this and will over-estimate, but the actual proof"] - #[doc = " will be smaller."] - pub fn inbound_xcmp_suspended( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_btree_set::BoundedBTreeSet< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "InboundXcmpSuspended", - vec![], - [ - 110u8, 23u8, 239u8, 104u8, 136u8, 224u8, 179u8, 180u8, 40u8, 159u8, - 54u8, 15u8, 55u8, 111u8, 75u8, 147u8, 131u8, 127u8, 9u8, 57u8, 133u8, - 70u8, 175u8, 181u8, 232u8, 49u8, 13u8, 19u8, 59u8, 151u8, 179u8, 215u8, - ], - ) - } - #[doc = " The non-empty XCMP channels in order of becoming non-empty, and the index of the first"] - #[doc = " and last outbound message. If the two indices are equal, then it indicates an empty"] - #[doc = " queue and there must be a non-`Ok` `OutboundStatus`. We assume queues grow no greater"] - #[doc = " than 65535 items. Queue indices for normal messages begin at one; zero is reserved in"] - #[doc = " case of the need to send a high-priority signal message this block."] - #[doc = " The bool is true if there is a signal message waiting to be sent."] - pub fn outbound_xcmp_status( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::cumulus_pallet_xcmp_queue::OutboundChannelDetails, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "OutboundXcmpStatus", - vec![], - [ - 181u8, 5u8, 216u8, 176u8, 154u8, 233u8, 116u8, 14u8, 151u8, 1u8, 114u8, - 16u8, 42u8, 20u8, 63u8, 233u8, 79u8, 122u8, 87u8, 255u8, 75u8, 149u8, - 176u8, 106u8, 23u8, 101u8, 228u8, 120u8, 217u8, 167u8, 127u8, 117u8, - ], - ) - } - #[doc = " The messages outbound in a given XCMP channel."] - pub fn outbound_xcmp_messages_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "OutboundXcmpMessages", - vec![], - [ - 156u8, 3u8, 202u8, 175u8, 175u8, 129u8, 38u8, 144u8, 35u8, 59u8, 228u8, - 159u8, 142u8, 25u8, 19u8, 73u8, 73u8, 6u8, 115u8, 19u8, 236u8, 235u8, - 144u8, 172u8, 31u8, 168u8, 24u8, 65u8, 115u8, 95u8, 77u8, 63u8, - ], - ) - } - #[doc = " The messages outbound in a given XCMP channel."] - pub fn outbound_xcmp_messages_iter1( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "OutboundXcmpMessages", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 156u8, 3u8, 202u8, 175u8, 175u8, 129u8, 38u8, 144u8, 35u8, 59u8, 228u8, - 159u8, 142u8, 25u8, 19u8, 73u8, 73u8, 6u8, 115u8, 19u8, 236u8, 235u8, - 144u8, 172u8, 31u8, 168u8, 24u8, 65u8, 115u8, 95u8, 77u8, 63u8, - ], - ) - } - #[doc = " The messages outbound in a given XCMP channel."] - pub fn outbound_xcmp_messages( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - _1: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "OutboundXcmpMessages", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 156u8, 3u8, 202u8, 175u8, 175u8, 129u8, 38u8, 144u8, 35u8, 59u8, 228u8, - 159u8, 142u8, 25u8, 19u8, 73u8, 73u8, 6u8, 115u8, 19u8, 236u8, 235u8, - 144u8, 172u8, 31u8, 168u8, 24u8, 65u8, 115u8, 95u8, 77u8, 63u8, - ], - ) - } - #[doc = " Any signal messages waiting to be sent."] - pub fn signal_messages_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "SignalMessages", - vec![], - [ - 182u8, 143u8, 233u8, 233u8, 111u8, 137u8, 174u8, 165u8, 166u8, 7u8, - 229u8, 183u8, 99u8, 108u8, 30u8, 162u8, 71u8, 55u8, 122u8, 124u8, - 249u8, 203u8, 142u8, 124u8, 158u8, 213u8, 182u8, 159u8, 206u8, 249u8, - 180u8, 24u8, - ], - ) - } - #[doc = " Any signal messages waiting to be sent."] - pub fn signal_messages( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "SignalMessages", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 182u8, 143u8, 233u8, 233u8, 111u8, 137u8, 174u8, 165u8, 166u8, 7u8, - 229u8, 183u8, 99u8, 108u8, 30u8, 162u8, 71u8, 55u8, 122u8, 124u8, - 249u8, 203u8, 142u8, 124u8, 158u8, 213u8, 182u8, 159u8, 206u8, 249u8, - 180u8, 24u8, - ], - ) - } - #[doc = " The configuration which controls the dynamics of the outbound queue."] - pub fn queue_config( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::cumulus_pallet_xcmp_queue::QueueConfigData, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "QueueConfig", - vec![], - [ - 185u8, 67u8, 247u8, 243u8, 211u8, 232u8, 57u8, 240u8, 237u8, 181u8, - 23u8, 114u8, 215u8, 128u8, 193u8, 1u8, 176u8, 53u8, 110u8, 195u8, - 148u8, 80u8, 187u8, 143u8, 62u8, 30u8, 143u8, 34u8, 248u8, 109u8, 3u8, - 141u8, - ], - ) - } - #[doc = " Whether or not the XCMP queue is suspended from executing incoming XCMs or not."] - pub fn queue_suspended( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "QueueSuspended", - vec![], - [ - 165u8, 66u8, 105u8, 244u8, 113u8, 43u8, 177u8, 252u8, 212u8, 243u8, - 143u8, 184u8, 87u8, 51u8, 163u8, 104u8, 29u8, 84u8, 119u8, 74u8, 233u8, - 129u8, 203u8, 105u8, 2u8, 101u8, 19u8, 170u8, 69u8, 253u8, 80u8, 132u8, - ], - ) - } - #[doc = " The factor to multiply the base delivery fee by."] - pub fn delivery_fee_factor_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "DeliveryFeeFactor", - vec![], - [ - 43u8, 5u8, 63u8, 235u8, 115u8, 155u8, 130u8, 27u8, 75u8, 216u8, 177u8, - 135u8, 203u8, 147u8, 167u8, 95u8, 208u8, 188u8, 25u8, 14u8, 84u8, 63u8, - 116u8, 41u8, 148u8, 110u8, 115u8, 215u8, 196u8, 36u8, 75u8, 102u8, - ], - ) - } - #[doc = " The factor to multiply the base delivery fee by."] - pub fn delivery_fee_factor( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmpQueue", - "DeliveryFeeFactor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 43u8, 5u8, 63u8, 235u8, 115u8, 155u8, 130u8, 27u8, 75u8, 216u8, 177u8, - 135u8, 203u8, 147u8, 167u8, 95u8, 208u8, 188u8, 25u8, 14u8, 84u8, 63u8, - 116u8, 41u8, 148u8, 110u8, 115u8, 215u8, 196u8, 36u8, 75u8, 102u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The maximum number of inbound XCMP channels that can be suspended simultaneously."] - #[doc = ""] - #[doc = " Any further channel suspensions will fail and messages may get dropped without further"] - #[doc = " notice. Choosing a high value (1000) is okay; the trade-off that is described in"] - #[doc = " [`InboundXcmpSuspended`] still applies at that scale."] - pub fn max_inbound_suspended( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "XcmpQueue", - "MaxInboundSuspended", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod polkadot_xcm { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_xcm::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_xcm::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Send { - pub dest: ::std::boxed::Box, - pub message: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for Send { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "send"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TeleportAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for TeleportAssets { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "teleport_assets"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReserveTransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ReserveTransferAssets { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "reserve_transfer_assets"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Execute { - pub message: ::std::boxed::Box, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for Execute { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "execute"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceXcmVersion { - pub location: - ::std::boxed::Box, - pub version: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceXcmVersion { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "force_xcm_version"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceDefaultXcmVersion { - pub maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - } - impl ::subxt::blocks::StaticExtrinsic for ForceDefaultXcmVersion { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "force_default_xcm_version"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSubscribeVersionNotify { - pub location: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSubscribeVersionNotify { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "force_subscribe_version_notify"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnsubscribeVersionNotify { - pub location: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for ForceUnsubscribeVersionNotify { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "force_unsubscribe_version_notify"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LimitedReserveTransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v3::WeightLimit, - } - impl ::subxt::blocks::StaticExtrinsic for LimitedReserveTransferAssets { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "limited_reserve_transfer_assets"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LimitedTeleportAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v3::WeightLimit, - } - impl ::subxt::blocks::StaticExtrinsic for LimitedTeleportAssets { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "limited_teleport_assets"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSuspension { - pub suspended: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSuspension { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "force_suspension"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v3::WeightLimit, - } - impl ::subxt::blocks::StaticExtrinsic for TransferAssets { - const PALLET: &'static str = "PolkadotXcm"; - const CALL: &'static str = "transfer_assets"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::send`]."] - pub fn send( - &self, - dest: runtime_types::xcm::VersionedLocation, - message: runtime_types::xcm::VersionedXcm, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "send", - types::Send { - dest: ::std::boxed::Box::new(dest), - message: ::std::boxed::Box::new(message), - }, - [ - 47u8, 63u8, 128u8, 176u8, 10u8, 137u8, 124u8, 238u8, 155u8, 37u8, - 193u8, 160u8, 83u8, 240u8, 21u8, 179u8, 169u8, 131u8, 27u8, 104u8, - 195u8, 208u8, 123u8, 14u8, 221u8, 12u8, 45u8, 81u8, 148u8, 76u8, 17u8, - 100u8, - ], - ) - } - #[doc = "See [`Pallet::teleport_assets`]."] - pub fn teleport_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "teleport_assets", - types::TeleportAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - }, - [ - 124u8, 191u8, 118u8, 61u8, 45u8, 225u8, 97u8, 83u8, 198u8, 20u8, 139u8, - 117u8, 241u8, 1u8, 19u8, 54u8, 79u8, 181u8, 131u8, 112u8, 11u8, 118u8, - 147u8, 12u8, 89u8, 156u8, 123u8, 123u8, 195u8, 45u8, 50u8, 107u8, - ], - ) - } - #[doc = "See [`Pallet::reserve_transfer_assets`]."] - pub fn reserve_transfer_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "reserve_transfer_assets", - types::ReserveTransferAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - }, - [ - 97u8, 102u8, 230u8, 44u8, 135u8, 197u8, 43u8, 53u8, 182u8, 125u8, - 140u8, 141u8, 229u8, 73u8, 29u8, 55u8, 159u8, 104u8, 197u8, 20u8, - 124u8, 234u8, 250u8, 94u8, 133u8, 253u8, 189u8, 6u8, 216u8, 162u8, - 218u8, 89u8, - ], - ) - } - #[doc = "See [`Pallet::execute`]."] - pub fn execute( - &self, - message: runtime_types::xcm::VersionedXcm2, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "execute", - types::Execute { message: ::std::boxed::Box::new(message), max_weight }, - [ - 71u8, 109u8, 92u8, 110u8, 198u8, 150u8, 140u8, 125u8, 248u8, 236u8, - 177u8, 156u8, 198u8, 223u8, 51u8, 15u8, 52u8, 240u8, 20u8, 200u8, 68u8, - 145u8, 36u8, 156u8, 159u8, 153u8, 125u8, 48u8, 181u8, 61u8, 53u8, - 208u8, - ], - ) - } - #[doc = "See [`Pallet::force_xcm_version`]."] - pub fn force_xcm_version( - &self, - location: runtime_types::staging_xcm::v4::location::Location, - version: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "force_xcm_version", - types::ForceXcmVersion { - location: ::std::boxed::Box::new(location), - version, - }, - [ - 69u8, 151u8, 198u8, 154u8, 69u8, 181u8, 41u8, 111u8, 145u8, 230u8, - 103u8, 42u8, 237u8, 91u8, 235u8, 6u8, 156u8, 65u8, 187u8, 48u8, 171u8, - 200u8, 49u8, 4u8, 9u8, 210u8, 229u8, 152u8, 187u8, 88u8, 80u8, 246u8, - ], - ) - } - #[doc = "See [`Pallet::force_default_xcm_version`]."] - pub fn force_default_xcm_version( - &self, - maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "force_default_xcm_version", - types::ForceDefaultXcmVersion { maybe_xcm_version }, - [ - 43u8, 114u8, 102u8, 104u8, 209u8, 234u8, 108u8, 173u8, 109u8, 188u8, - 94u8, 214u8, 136u8, 43u8, 153u8, 75u8, 161u8, 192u8, 76u8, 12u8, 221u8, - 237u8, 158u8, 247u8, 41u8, 193u8, 35u8, 174u8, 183u8, 207u8, 79u8, - 213u8, - ], - ) - } - #[doc = "See [`Pallet::force_subscribe_version_notify`]."] - pub fn force_subscribe_version_notify( - &self, - location: runtime_types::xcm::VersionedLocation, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "force_subscribe_version_notify", - types::ForceSubscribeVersionNotify { - location: ::std::boxed::Box::new(location), - }, - [ - 203u8, 171u8, 70u8, 130u8, 46u8, 63u8, 76u8, 50u8, 105u8, 23u8, 249u8, - 190u8, 115u8, 74u8, 70u8, 125u8, 132u8, 112u8, 138u8, 60u8, 33u8, 35u8, - 45u8, 29u8, 95u8, 103u8, 187u8, 182u8, 188u8, 196u8, 248u8, 152u8, - ], - ) - } - #[doc = "See [`Pallet::force_unsubscribe_version_notify`]."] - pub fn force_unsubscribe_version_notify( - &self, - location: runtime_types::xcm::VersionedLocation, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "force_unsubscribe_version_notify", - types::ForceUnsubscribeVersionNotify { - location: ::std::boxed::Box::new(location), - }, - [ - 6u8, 113u8, 168u8, 215u8, 233u8, 202u8, 249u8, 134u8, 131u8, 8u8, - 142u8, 203u8, 142u8, 95u8, 216u8, 70u8, 38u8, 99u8, 166u8, 97u8, 218u8, - 132u8, 247u8, 14u8, 42u8, 99u8, 4u8, 115u8, 200u8, 180u8, 213u8, 50u8, - ], - ) - } - #[doc = "See [`Pallet::limited_reserve_transfer_assets`]."] - pub fn limited_reserve_transfer_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "limited_reserve_transfer_assets", - types::LimitedReserveTransferAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - weight_limit, - }, - [ - 198u8, 66u8, 204u8, 162u8, 222u8, 246u8, 141u8, 165u8, 241u8, 62u8, - 43u8, 236u8, 56u8, 200u8, 54u8, 47u8, 174u8, 83u8, 167u8, 220u8, 174u8, - 111u8, 123u8, 202u8, 248u8, 232u8, 166u8, 80u8, 152u8, 223u8, 86u8, - 141u8, - ], - ) - } - #[doc = "See [`Pallet::limited_teleport_assets`]."] - pub fn limited_teleport_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "limited_teleport_assets", - types::LimitedTeleportAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - weight_limit, - }, - [ - 70u8, 61u8, 32u8, 43u8, 101u8, 104u8, 251u8, 60u8, 212u8, 124u8, 113u8, - 243u8, 241u8, 183u8, 5u8, 231u8, 209u8, 231u8, 136u8, 3u8, 145u8, - 242u8, 179u8, 171u8, 185u8, 185u8, 7u8, 34u8, 5u8, 203u8, 21u8, 210u8, - ], - ) - } - #[doc = "See [`Pallet::force_suspension`]."] - pub fn force_suspension( - &self, - suspended: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "force_suspension", - types::ForceSuspension { suspended }, - [ - 78u8, 125u8, 93u8, 55u8, 129u8, 44u8, 36u8, 227u8, 75u8, 46u8, 68u8, - 202u8, 81u8, 127u8, 111u8, 92u8, 149u8, 38u8, 225u8, 185u8, 183u8, - 154u8, 89u8, 159u8, 79u8, 10u8, 229u8, 1u8, 226u8, 243u8, 65u8, 238u8, - ], - ) - } - #[doc = "See [`Pallet::transfer_assets`]."] - pub fn transfer_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "PolkadotXcm", - "transfer_assets", - types::TransferAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - weight_limit, - }, - [ - 44u8, 155u8, 182u8, 37u8, 123u8, 148u8, 150u8, 191u8, 117u8, 32u8, - 16u8, 238u8, 121u8, 188u8, 217u8, 110u8, 10u8, 236u8, 174u8, 91u8, - 100u8, 201u8, 109u8, 109u8, 60u8, 177u8, 233u8, 66u8, 181u8, 191u8, - 105u8, 37u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_xcm::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Execution of an XCM message was attempted."] - pub struct Attempted { - pub outcome: runtime_types::staging_xcm::v4::traits::Outcome, - } - impl ::subxt::events::StaticEvent for Attempted { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "Attempted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A XCM message was sent."] - pub struct Sent { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub message: runtime_types::staging_xcm::v4::Xcm, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for Sent { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "Sent"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response received which does not match a registered query. This may be because a"] - #[doc = "matching query was never registered, it may be because it is a duplicate response, or"] - #[doc = "because the query timed out."] - pub struct UnexpectedResponse { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for UnexpectedResponse { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "UnexpectedResponse"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] - #[doc = "no registered notification call."] - pub struct ResponseReady { - pub query_id: ::core::primitive::u64, - pub response: runtime_types::staging_xcm::v4::Response, - } - impl ::subxt::events::StaticEvent for ResponseReady { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "ResponseReady"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The registered notification has"] - #[doc = "been dispatched and executed successfully."] - pub struct Notified { - pub query_id: ::core::primitive::u64, - pub pallet_index: ::core::primitive::u8, - pub call_index: ::core::primitive::u8, - } - impl ::subxt::events::StaticEvent for Notified { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "Notified"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The registered notification"] - #[doc = "could not be dispatched because the dispatch weight is greater than the maximum weight"] - #[doc = "originally budgeted by this runtime for the query result."] - pub struct NotifyOverweight { - pub query_id: ::core::primitive::u64, - pub pallet_index: ::core::primitive::u8, - pub call_index: ::core::primitive::u8, - pub actual_weight: runtime_types::sp_weights::weight_v2::Weight, - pub max_budgeted_weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::events::StaticEvent for NotifyOverweight { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "NotifyOverweight"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. There was a general error with"] - #[doc = "dispatching the notification call."] - pub struct NotifyDispatchError { - pub query_id: ::core::primitive::u64, - pub pallet_index: ::core::primitive::u8, - pub call_index: ::core::primitive::u8, - } - impl ::subxt::events::StaticEvent for NotifyDispatchError { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "NotifyDispatchError"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] - #[doc = "decoded into a `Call`; this might be due to dispatch function having a signature which"] - #[doc = "is not `(origin, QueryId, Response)`."] - pub struct NotifyDecodeFailed { - pub query_id: ::core::primitive::u64, - pub pallet_index: ::core::primitive::u8, - pub call_index: ::core::primitive::u8, - } - impl ::subxt::events::StaticEvent for NotifyDecodeFailed { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "NotifyDecodeFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the origin location of the response does"] - #[doc = "not match that expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - pub struct InvalidResponder { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - pub expected_location: - ::core::option::Option, - } - impl ::subxt::events::StaticEvent for InvalidResponder { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "InvalidResponder"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the expected origin location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - pub struct InvalidResponderVersion { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for InvalidResponderVersion { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "InvalidResponderVersion"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Received query response has been read and removed."] - pub struct ResponseTaken { - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for ResponseTaken { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "ResponseTaken"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some assets have been placed in an asset trap."] - pub struct AssetsTrapped { - pub hash: ::subxt::utils::H256, - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub assets: runtime_types::xcm::VersionedAssets, - } - impl ::subxt::events::StaticEvent for AssetsTrapped { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "AssetsTrapped"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An XCM version change notification message has been attempted to be sent."] - #[doc = ""] - #[doc = "The cost of sending it (borne by the chain) is included."] - pub struct VersionChangeNotified { - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub result: ::core::primitive::u32, - pub cost: runtime_types::staging_xcm::v4::asset::Assets, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for VersionChangeNotified { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "VersionChangeNotified"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The supported version of a location has been changed. This might be through an"] - #[doc = "automatic notification or a manual intervention."] - pub struct SupportedVersionChanged { - pub location: runtime_types::staging_xcm::v4::location::Location, - pub version: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for SupportedVersionChanged { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "SupportedVersionChanged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "sending the notification to it."] - pub struct NotifyTargetSendFail { - pub location: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - pub error: runtime_types::xcm::v3::traits::Error, - } - impl ::subxt::events::StaticEvent for NotifyTargetSendFail { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "NotifyTargetSendFail"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "migrating the location to our new XCM format."] - pub struct NotifyTargetMigrationFail { - pub location: runtime_types::xcm::VersionedLocation, - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for NotifyTargetMigrationFail { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "NotifyTargetMigrationFail"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the expected querier location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - pub struct InvalidQuerierVersion { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for InvalidQuerierVersion { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "InvalidQuerierVersion"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the querier location of the response does"] - #[doc = "not match the expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - pub struct InvalidQuerier { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - pub expected_querier: runtime_types::staging_xcm::v4::location::Location, - pub maybe_actual_querier: - ::core::option::Option, - } - impl ::subxt::events::StaticEvent for InvalidQuerier { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "InvalidQuerier"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A remote has requested XCM version change notification from us and we have honored it."] - #[doc = "A version information message is sent to them and its cost is included."] - pub struct VersionNotifyStarted { - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub cost: runtime_types::staging_xcm::v4::asset::Assets, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for VersionNotifyStarted { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "VersionNotifyStarted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "We have requested that a remote chain send us XCM version change notifications."] - pub struct VersionNotifyRequested { - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub cost: runtime_types::staging_xcm::v4::asset::Assets, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for VersionNotifyRequested { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "VersionNotifyRequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "We have requested that a remote chain stops sending us XCM version change"] - #[doc = "notifications."] - pub struct VersionNotifyUnrequested { - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub cost: runtime_types::staging_xcm::v4::asset::Assets, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for VersionNotifyUnrequested { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "VersionNotifyUnrequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Fees were paid from a location for an operation (often for using `SendXcm`)."] - pub struct FeesPaid { - pub paying: runtime_types::staging_xcm::v4::location::Location, - pub fees: runtime_types::staging_xcm::v4::asset::Assets, - } - impl ::subxt::events::StaticEvent for FeesPaid { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "FeesPaid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some assets have been claimed from an asset trap"] - pub struct AssetsClaimed { - pub hash: ::subxt::utils::H256, - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub assets: runtime_types::xcm::VersionedAssets, - } - impl ::subxt::events::StaticEvent for AssetsClaimed { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "AssetsClaimed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A XCM version migration finished."] - pub struct VersionMigrationFinished { - pub version: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for VersionMigrationFinished { - const PALLET: &'static str = "PolkadotXcm"; - const EVENT: &'static str = "VersionMigrationFinished"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The latest available query index."] - pub fn query_counter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "QueryCounter", - vec![], - [ - 216u8, 73u8, 160u8, 232u8, 60u8, 245u8, 218u8, 219u8, 152u8, 68u8, - 146u8, 219u8, 255u8, 7u8, 86u8, 112u8, 83u8, 49u8, 94u8, 173u8, 64u8, - 203u8, 147u8, 226u8, 236u8, 39u8, 129u8, 106u8, 209u8, 113u8, 150u8, - 50u8, - ], - ) - } - #[doc = " The ongoing queries."] - pub fn queries_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "Queries", - vec![], - [ - 246u8, 75u8, 240u8, 129u8, 106u8, 114u8, 99u8, 154u8, 176u8, 188u8, - 146u8, 125u8, 244u8, 103u8, 187u8, 171u8, 60u8, 119u8, 4u8, 90u8, 58u8, - 180u8, 48u8, 165u8, 145u8, 125u8, 227u8, 233u8, 11u8, 142u8, 122u8, - 3u8, - ], - ) - } - #[doc = " The ongoing queries."] - pub fn queries( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "Queries", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 246u8, 75u8, 240u8, 129u8, 106u8, 114u8, 99u8, 154u8, 176u8, 188u8, - 146u8, 125u8, 244u8, 103u8, 187u8, 171u8, 60u8, 119u8, 4u8, 90u8, 58u8, - 180u8, 48u8, 165u8, 145u8, 125u8, 227u8, 233u8, 11u8, 142u8, 122u8, - 3u8, - ], - ) - } - #[doc = " The existing asset traps."] - #[doc = ""] - #[doc = " Key is the blake2 256 hash of (origin, versioned `Assets`) pair. Value is the number of"] - #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] - pub fn asset_traps_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "AssetTraps", - vec![], - [ - 148u8, 41u8, 254u8, 134u8, 61u8, 172u8, 126u8, 146u8, 78u8, 178u8, - 50u8, 77u8, 226u8, 8u8, 200u8, 78u8, 77u8, 91u8, 26u8, 133u8, 104u8, - 126u8, 28u8, 28u8, 202u8, 62u8, 87u8, 183u8, 231u8, 191u8, 5u8, 181u8, - ], - ) - } - #[doc = " The existing asset traps."] - #[doc = ""] - #[doc = " Key is the blake2 256 hash of (origin, versioned `Assets`) pair. Value is the number of"] - #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] - pub fn asset_traps( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "AssetTraps", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 148u8, 41u8, 254u8, 134u8, 61u8, 172u8, 126u8, 146u8, 78u8, 178u8, - 50u8, 77u8, 226u8, 8u8, 200u8, 78u8, 77u8, 91u8, 26u8, 133u8, 104u8, - 126u8, 28u8, 28u8, 202u8, 62u8, 87u8, 183u8, 231u8, 191u8, 5u8, 181u8, - ], - ) - } - #[doc = " Default version to encode XCM when latest version of destination is unknown. If `None`,"] - #[doc = " then the destinations whose XCM version is unknown are considered unreachable."] - pub fn safe_xcm_version( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "SafeXcmVersion", - vec![], - [ - 187u8, 8u8, 74u8, 126u8, 80u8, 215u8, 177u8, 60u8, 223u8, 123u8, 196u8, - 155u8, 166u8, 66u8, 25u8, 164u8, 191u8, 66u8, 116u8, 131u8, 116u8, - 188u8, 224u8, 122u8, 75u8, 195u8, 246u8, 188u8, 83u8, 134u8, 49u8, - 143u8, - ], - ) - } - #[doc = " The Latest versions that we know various locations support."] - pub fn supported_version_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "SupportedVersion", - vec![], - [ - 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, - 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, - 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, - 202u8, 24u8, - ], - ) - } - #[doc = " The Latest versions that we know various locations support."] - pub fn supported_version_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "SupportedVersion", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, - 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, - 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, - 202u8, 24u8, - ], - ) - } - #[doc = " The Latest versions that we know various locations support."] - pub fn supported_version( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "SupportedVersion", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, - 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, - 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, - 202u8, 24u8, - ], - ) - } - #[doc = " All locations that we have requested version notifications from."] - pub fn version_notifiers_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "VersionNotifiers", - vec![], - [ - 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, - 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, - 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, - 201u8, 49u8, - ], - ) - } - #[doc = " All locations that we have requested version notifications from."] - pub fn version_notifiers_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "VersionNotifiers", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, - 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, - 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, - 201u8, 49u8, - ], - ) - } - #[doc = " All locations that we have requested version notifications from."] - pub fn version_notifiers( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "VersionNotifiers", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, - 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, - 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, - 201u8, 49u8, - ], - ) - } - #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] - #[doc = " of our versions we informed them of."] - pub fn version_notify_targets_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u64, - runtime_types::sp_weights::weight_v2::Weight, - ::core::primitive::u32, - ), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "VersionNotifyTargets", - vec![], - [ - 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, - 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, - 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, - ], - ) - } - #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] - #[doc = " of our versions we informed them of."] - pub fn version_notify_targets_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u64, - runtime_types::sp_weights::weight_v2::Weight, - ::core::primitive::u32, - ), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "VersionNotifyTargets", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, - 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, - 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, - ], - ) - } - #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] - #[doc = " of our versions we informed them of."] - pub fn version_notify_targets( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u64, - runtime_types::sp_weights::weight_v2::Weight, - ::core::primitive::u32, - ), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "VersionNotifyTargets", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, - 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, - 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, - ], - ) - } - #[doc = " Destinations whose latest XCM version we would like to know. Duplicates not allowed, and"] - #[doc = " the `u32` counter is the number of times that a send to the destination has been attempted,"] - #[doc = " which is used as a prioritization."] - pub fn version_discovery_queue( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - runtime_types::xcm::VersionedLocation, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "VersionDiscoveryQueue", - vec![], - [ - 95u8, 74u8, 97u8, 94u8, 40u8, 140u8, 175u8, 176u8, 224u8, 222u8, 83u8, - 199u8, 170u8, 102u8, 3u8, 77u8, 127u8, 208u8, 155u8, 122u8, 176u8, - 51u8, 15u8, 253u8, 231u8, 245u8, 91u8, 192u8, 60u8, 144u8, 101u8, - 168u8, - ], - ) - } - #[doc = " The current migration's stage, if any."] - pub fn current_migration( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::VersionMigrationStage, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "CurrentMigration", - vec![], - [ - 74u8, 138u8, 181u8, 162u8, 59u8, 251u8, 37u8, 28u8, 232u8, 51u8, 30u8, - 152u8, 252u8, 133u8, 95u8, 195u8, 47u8, 127u8, 21u8, 44u8, 62u8, 143u8, - 170u8, 234u8, 160u8, 37u8, 131u8, 179u8, 57u8, 241u8, 140u8, 124u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on a remote chain."] - pub fn remote_locked_fungibles_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "RemoteLockedFungibles", - vec![], - [ - 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, - 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, - 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, - 201u8, 150u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on a remote chain."] - pub fn remote_locked_fungibles_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "RemoteLockedFungibles", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, - 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, - 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, - 201u8, 150u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on a remote chain."] - pub fn remote_locked_fungibles_iter2( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "RemoteLockedFungibles", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, - 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, - 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, - 201u8, 150u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on a remote chain."] - pub fn remote_locked_fungibles( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _2: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "RemoteLockedFungibles", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_2.borrow()), - ], - [ - 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, - 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, - 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, - 201u8, 150u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on this chain."] - pub fn locked_fungibles_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u128, - runtime_types::xcm::VersionedLocation, - )>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "LockedFungibles", - vec![], - [ - 254u8, 234u8, 1u8, 27u8, 27u8, 32u8, 217u8, 24u8, 47u8, 30u8, 62u8, - 80u8, 86u8, 125u8, 120u8, 24u8, 143u8, 229u8, 161u8, 153u8, 240u8, - 246u8, 80u8, 15u8, 49u8, 189u8, 20u8, 204u8, 239u8, 198u8, 97u8, 174u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on this chain."] - pub fn locked_fungibles( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u128, - runtime_types::xcm::VersionedLocation, - )>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "LockedFungibles", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 254u8, 234u8, 1u8, 27u8, 27u8, 32u8, 217u8, 24u8, 47u8, 30u8, 62u8, - 80u8, 86u8, 125u8, 120u8, 24u8, 143u8, 229u8, 161u8, 153u8, 240u8, - 246u8, 80u8, 15u8, 49u8, 189u8, 20u8, 204u8, 239u8, 198u8, 97u8, 174u8, - ], - ) - } - #[doc = " Global suspension state of the XCM executor."] - pub fn xcm_execution_suspended( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "PolkadotXcm", - "XcmExecutionSuspended", - vec![], - [ - 182u8, 54u8, 69u8, 68u8, 78u8, 76u8, 103u8, 79u8, 47u8, 136u8, 99u8, - 104u8, 128u8, 129u8, 249u8, 54u8, 214u8, 136u8, 97u8, 48u8, 178u8, - 42u8, 26u8, 27u8, 82u8, 24u8, 33u8, 77u8, 33u8, 27u8, 20u8, 127u8, - ], - ) - } - } - } - } - pub mod cumulus_xcm { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::cumulus_pallet_xcm::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - } - pub struct TransactionApi; - impl TransactionApi {} - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::cumulus_pallet_xcm::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Downward message is invalid XCM."] - #[doc = "\\[ id \\]"] - pub struct InvalidFormat(pub [::core::primitive::u8; 32usize]); - impl ::subxt::events::StaticEvent for InvalidFormat { - const PALLET: &'static str = "CumulusXcm"; - const EVENT: &'static str = "InvalidFormat"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Downward message is unsupported version of XCM."] - #[doc = "\\[ id \\]"] - pub struct UnsupportedVersion(pub [::core::primitive::u8; 32usize]); - impl ::subxt::events::StaticEvent for UnsupportedVersion { - const PALLET: &'static str = "CumulusXcm"; - const EVENT: &'static str = "UnsupportedVersion"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Downward message executed with the given outcome."] - #[doc = "\\[ id, outcome \\]"] - pub struct ExecutedDownward( - pub [::core::primitive::u8; 32usize], - pub runtime_types::staging_xcm::v4::traits::Outcome, - ); - impl ::subxt::events::StaticEvent for ExecutedDownward { - const PALLET: &'static str = "CumulusXcm"; - const EVENT: &'static str = "ExecutedDownward"; - } - } - } - pub mod message_queue { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_message_queue::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_message_queue::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReapPage { - pub message_origin: - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - pub page_index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ReapPage { - const PALLET: &'static str = "MessageQueue"; - const CALL: &'static str = "reap_page"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExecuteOverweight { - pub message_origin: - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - pub page: ::core::primitive::u32, - pub index: ::core::primitive::u32, - pub weight_limit: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for ExecuteOverweight { - const PALLET: &'static str = "MessageQueue"; - const CALL: &'static str = "execute_overweight"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::reap_page`]."] - pub fn reap_page( - &self, - message_origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - page_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "MessageQueue", - "reap_page", - types::ReapPage { message_origin, page_index }, - [ - 116u8, 17u8, 120u8, 238u8, 117u8, 222u8, 10u8, 166u8, 132u8, 181u8, - 114u8, 150u8, 242u8, 202u8, 31u8, 143u8, 212u8, 65u8, 145u8, 249u8, - 27u8, 204u8, 137u8, 133u8, 220u8, 187u8, 137u8, 90u8, 112u8, 55u8, - 104u8, 163u8, - ], - ) - } - #[doc = "See [`Pallet::execute_overweight`]."] - pub fn execute_overweight( - &self, - message_origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - page: ::core::primitive::u32, - index: ::core::primitive::u32, - weight_limit: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "MessageQueue", - "execute_overweight", - types::ExecuteOverweight { message_origin, page, index, weight_limit }, - [ - 177u8, 54u8, 82u8, 58u8, 94u8, 125u8, 241u8, 172u8, 52u8, 7u8, 236u8, - 80u8, 66u8, 99u8, 42u8, 199u8, 38u8, 195u8, 65u8, 118u8, 166u8, 246u8, - 239u8, 195u8, 144u8, 153u8, 155u8, 8u8, 224u8, 56u8, 106u8, 135u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_message_queue::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Message discarded due to an error in the `MessageProcessor` (usually a format error)."] - pub struct ProcessingFailed { - pub id: ::subxt::utils::H256, - pub origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - pub error: runtime_types::frame_support::traits::messages::ProcessMessageError, - } - impl ::subxt::events::StaticEvent for ProcessingFailed { - const PALLET: &'static str = "MessageQueue"; - const EVENT: &'static str = "ProcessingFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Message is processed."] - pub struct Processed { - pub id: ::subxt::utils::H256, - pub origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - pub weight_used: runtime_types::sp_weights::weight_v2::Weight, - pub success: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for Processed { - const PALLET: &'static str = "MessageQueue"; - const EVENT: &'static str = "Processed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Message placed in overweight queue."] - pub struct OverweightEnqueued { - pub id: [::core::primitive::u8; 32usize], - pub origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - pub page_index: ::core::primitive::u32, - pub message_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for OverweightEnqueued { - const PALLET: &'static str = "MessageQueue"; - const EVENT: &'static str = "OverweightEnqueued"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "This page was reaped."] - pub struct PageReaped { - pub origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for PageReaped { - const PALLET: &'static str = "MessageQueue"; - const EVENT: &'static str = "PageReaped"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The index of the first and last (non-empty) pages."] - pub fn book_state_for_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_message_queue::BookState< - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "BookStateFor", - vec![], - [ - 33u8, 240u8, 235u8, 59u8, 150u8, 42u8, 91u8, 248u8, 235u8, 52u8, 170u8, - 52u8, 195u8, 129u8, 6u8, 174u8, 57u8, 242u8, 30u8, 220u8, 232u8, 4u8, - 246u8, 218u8, 162u8, 174u8, 102u8, 95u8, 210u8, 92u8, 133u8, 143u8, - ], - ) - } - #[doc = " The index of the first and last (non-empty) pages."] - pub fn book_state_for( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_message_queue::BookState< - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "BookStateFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 33u8, 240u8, 235u8, 59u8, 150u8, 42u8, 91u8, 248u8, 235u8, 52u8, 170u8, - 52u8, 195u8, 129u8, 6u8, 174u8, 57u8, 242u8, 30u8, 220u8, 232u8, 4u8, - 246u8, 218u8, 162u8, 174u8, 102u8, 95u8, 210u8, 92u8, 133u8, 143u8, - ], - ) - } - #[doc = " The origin at which we should begin servicing."] - pub fn service_head( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "ServiceHead", - vec![], - [ - 104u8, 146u8, 240u8, 41u8, 171u8, 68u8, 20u8, 147u8, 212u8, 155u8, - 59u8, 39u8, 174u8, 186u8, 97u8, 250u8, 41u8, 247u8, 67u8, 190u8, 252u8, - 167u8, 234u8, 36u8, 124u8, 239u8, 163u8, 72u8, 223u8, 82u8, 82u8, - 171u8, - ], - ) - } - #[doc = " The map of page indices to pages."] - pub fn pages_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_message_queue::Page<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "Pages", - vec![], - [ - 45u8, 202u8, 18u8, 128u8, 31u8, 194u8, 175u8, 173u8, 99u8, 81u8, 161u8, - 44u8, 32u8, 183u8, 238u8, 181u8, 110u8, 240u8, 203u8, 12u8, 152u8, - 58u8, 239u8, 190u8, 144u8, 168u8, 210u8, 33u8, 121u8, 250u8, 137u8, - 142u8, - ], - ) - } - #[doc = " The map of page indices to pages."] - pub fn pages_iter1( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_message_queue::Page<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "Pages", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 45u8, 202u8, 18u8, 128u8, 31u8, 194u8, 175u8, 173u8, 99u8, 81u8, 161u8, - 44u8, 32u8, 183u8, 238u8, 181u8, 110u8, 240u8, 203u8, 12u8, 152u8, - 58u8, 239u8, 190u8, 144u8, 168u8, 210u8, 33u8, 121u8, 250u8, 137u8, - 142u8, - ], - ) - } - #[doc = " The map of page indices to pages."] - pub fn pages( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - >, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_message_queue::Page<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "Pages", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 45u8, 202u8, 18u8, 128u8, 31u8, 194u8, 175u8, 173u8, 99u8, 81u8, 161u8, - 44u8, 32u8, 183u8, 238u8, 181u8, 110u8, 240u8, 203u8, 12u8, 152u8, - 58u8, 239u8, 190u8, 144u8, 168u8, 210u8, 33u8, 121u8, 250u8, 137u8, - 142u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The size of the page; this implies the maximum message size which can be sent."] - #[doc = ""] - #[doc = " A good value depends on the expected message sizes, their weights, the weight that is"] - #[doc = " available for processing them and the maximal needed message size. The maximal message"] - #[doc = " size is slightly lower than this as defined by [`MaxMessageLenOf`]."] - pub fn heap_size(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "MessageQueue", - "HeapSize", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of stale pages (i.e. of overweight messages) allowed before culling"] - #[doc = " can happen. Once there are more stale pages than this, then historical pages may be"] - #[doc = " dropped, even if they contain unprocessed overweight messages."] - pub fn max_stale(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "MessageQueue", - "MaxStale", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The amount of weight (if any) which should be provided to the message queue for"] - #[doc = " servicing enqueued items."] - #[doc = ""] - #[doc = " This may be legitimately `None` in the case that you will call"] - #[doc = " `ServiceQueues::service_queues` manually."] - pub fn service_weight( - &self, - ) -> ::subxt::constants::Address< - ::core::option::Option, - > { - ::subxt::constants::Address::new_static( - "MessageQueue", - "ServiceWeight", - [ - 204u8, 140u8, 63u8, 167u8, 49u8, 8u8, 148u8, 163u8, 190u8, 224u8, 15u8, - 103u8, 86u8, 153u8, 248u8, 117u8, 223u8, 117u8, 210u8, 80u8, 205u8, - 155u8, 40u8, 11u8, 59u8, 63u8, 129u8, 156u8, 17u8, 83u8, 177u8, 250u8, - ], - ) - } - } - } - } - pub mod utility { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_utility::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_utility::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Batch { - pub calls: ::std::vec::Vec, - } - impl ::subxt::blocks::StaticExtrinsic for Batch { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "batch"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsDerivative { - pub index: ::core::primitive::u16, - pub call: - ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for AsDerivative { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "as_derivative"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BatchAll { - pub calls: ::std::vec::Vec, - } - impl ::subxt::blocks::StaticExtrinsic for BatchAll { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "batch_all"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchAs { - pub as_origin: - ::std::boxed::Box, - pub call: - ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for DispatchAs { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "dispatch_as"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceBatch { - pub calls: ::std::vec::Vec, - } - impl ::subxt::blocks::StaticExtrinsic for ForceBatch { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "force_batch"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WithWeight { - pub call: - ::std::boxed::Box, - pub weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for WithWeight { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "with_weight"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::batch`]."] - pub fn batch( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "batch", - types::Batch { calls }, - [ - 196u8, 209u8, 52u8, 231u8, 46u8, 197u8, 7u8, 8u8, 85u8, 223u8, 142u8, - 251u8, 7u8, 60u8, 113u8, 87u8, 8u8, 125u8, 194u8, 180u8, 144u8, 212u8, - 243u8, 127u8, 87u8, 76u8, 7u8, 54u8, 64u8, 141u8, 206u8, 51u8, - ], - ) - } - #[doc = "See [`Pallet::as_derivative`]."] - pub fn as_derivative( - &self, - index: ::core::primitive::u16, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "as_derivative", - types::AsDerivative { index, call: ::std::boxed::Box::new(call) }, - [ - 126u8, 211u8, 152u8, 5u8, 89u8, 68u8, 210u8, 83u8, 191u8, 217u8, 168u8, - 29u8, 141u8, 230u8, 4u8, 219u8, 91u8, 223u8, 27u8, 85u8, 63u8, 251u8, - 141u8, 0u8, 99u8, 230u8, 91u8, 145u8, 177u8, 106u8, 14u8, 189u8, - ], - ) - } - #[doc = "See [`Pallet::batch_all`]."] - pub fn batch_all( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "batch_all", - types::BatchAll { calls }, - [ - 131u8, 0u8, 44u8, 110u8, 130u8, 180u8, 218u8, 239u8, 123u8, 185u8, - 204u8, 239u8, 83u8, 11u8, 0u8, 138u8, 164u8, 212u8, 139u8, 147u8, 20u8, - 105u8, 176u8, 167u8, 207u8, 66u8, 244u8, 13u8, 56u8, 50u8, 183u8, 26u8, - ], - ) - } - #[doc = "See [`Pallet::dispatch_as`]."] - pub fn dispatch_as( - &self, - as_origin: runtime_types::coretime_rococo_runtime::OriginCaller, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "dispatch_as", - types::DispatchAs { - as_origin: ::std::boxed::Box::new(as_origin), - call: ::std::boxed::Box::new(call), - }, - [ - 103u8, 50u8, 121u8, 101u8, 30u8, 227u8, 123u8, 125u8, 94u8, 185u8, - 74u8, 165u8, 178u8, 61u8, 204u8, 15u8, 220u8, 149u8, 88u8, 142u8, - 213u8, 16u8, 27u8, 11u8, 233u8, 82u8, 225u8, 11u8, 118u8, 201u8, 160u8, - 99u8, - ], - ) - } - #[doc = "See [`Pallet::force_batch`]."] - pub fn force_batch( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "force_batch", - types::ForceBatch { calls }, - [ - 137u8, 141u8, 119u8, 237u8, 225u8, 180u8, 133u8, 11u8, 223u8, 67u8, - 96u8, 59u8, 207u8, 168u8, 81u8, 69u8, 109u8, 14u8, 202u8, 96u8, 10u8, - 66u8, 102u8, 222u8, 29u8, 9u8, 69u8, 28u8, 2u8, 99u8, 127u8, 173u8, - ], - ) - } - #[doc = "See [`Pallet::with_weight`]."] - pub fn with_weight( - &self, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "with_weight", - types::WithWeight { call: ::std::boxed::Box::new(call), weight }, - [ - 169u8, 60u8, 21u8, 80u8, 219u8, 219u8, 154u8, 125u8, 254u8, 169u8, - 22u8, 243u8, 7u8, 4u8, 225u8, 11u8, 134u8, 236u8, 83u8, 184u8, 188u8, - 10u8, 248u8, 127u8, 240u8, 220u8, 74u8, 212u8, 104u8, 60u8, 31u8, - 164u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_utility::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] - #[doc = "well as the error."] - pub struct BatchInterrupted { - pub index: ::core::primitive::u32, - pub error: runtime_types::sp_runtime::DispatchError, - } - impl ::subxt::events::StaticEvent for BatchInterrupted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchInterrupted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches completed fully with no error."] - pub struct BatchCompleted; - impl ::subxt::events::StaticEvent for BatchCompleted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchCompleted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches completed but has errors."] - pub struct BatchCompletedWithErrors; - impl ::subxt::events::StaticEvent for BatchCompletedWithErrors { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchCompletedWithErrors"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single item within a Batch of dispatches has completed with no error."] - pub struct ItemCompleted; - impl ::subxt::events::StaticEvent for ItemCompleted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "ItemCompleted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single item within a Batch of dispatches has completed with error."] - pub struct ItemFailed { - pub error: runtime_types::sp_runtime::DispatchError, - } - impl ::subxt::events::StaticEvent for ItemFailed { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "ItemFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A call was dispatched."] - pub struct DispatchedAs { - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for DispatchedAs { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "DispatchedAs"; - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The limit on the number of batched calls."] - pub fn batched_calls_limit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Utility", - "batched_calls_limit", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod multisig { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_multisig::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_multisig::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMultiThreshold1 { - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub call: - ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for AsMultiThreshold1 { - const PALLET: &'static str = "Multisig"; - const CALL: &'static str = "as_multi_threshold_1"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - pub call: - ::std::boxed::Box, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for AsMulti { - const PALLET: &'static str = "Multisig"; - const CALL: &'static str = "as_multi"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - pub call_hash: [::core::primitive::u8; 32usize], - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for ApproveAsMulti { - const PALLET: &'static str = "Multisig"; - const CALL: &'static str = "approve_as_multi"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::blocks::StaticExtrinsic for CancelAsMulti { - const PALLET: &'static str = "Multisig"; - const CALL: &'static str = "cancel_as_multi"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::as_multi_threshold_1`]."] - pub fn as_multi_threshold_1( - &self, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Multisig", - "as_multi_threshold_1", - types::AsMultiThreshold1 { - other_signatories, - call: ::std::boxed::Box::new(call), - }, - [ - 254u8, 54u8, 88u8, 235u8, 170u8, 12u8, 95u8, 53u8, 93u8, 170u8, 39u8, - 224u8, 0u8, 128u8, 16u8, 91u8, 152u8, 70u8, 66u8, 52u8, 134u8, 110u8, - 178u8, 37u8, 53u8, 125u8, 162u8, 72u8, 102u8, 78u8, 73u8, 96u8, - ], - ) - } - #[doc = "See [`Pallet::as_multi`]."] - pub fn as_multi( - &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Multisig", - "as_multi", - types::AsMulti { - threshold, - other_signatories, - maybe_timepoint, - call: ::std::boxed::Box::new(call), - max_weight, - }, - [ - 125u8, 11u8, 76u8, 234u8, 44u8, 41u8, 237u8, 218u8, 233u8, 225u8, - 254u8, 203u8, 234u8, 214u8, 181u8, 116u8, 14u8, 100u8, 187u8, 243u8, - 166u8, 26u8, 216u8, 0u8, 196u8, 134u8, 66u8, 121u8, 92u8, 100u8, 165u8, - 180u8, - ], - ) - } - #[doc = "See [`Pallet::approve_as_multi`]."] - pub fn approve_as_multi( - &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call_hash: [::core::primitive::u8; 32usize], - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Multisig", - "approve_as_multi", - types::ApproveAsMulti { - threshold, - other_signatories, - maybe_timepoint, - call_hash, - max_weight, - }, - [ - 248u8, 46u8, 131u8, 35u8, 204u8, 12u8, 218u8, 150u8, 88u8, 131u8, 89u8, - 13u8, 95u8, 122u8, 87u8, 107u8, 136u8, 154u8, 92u8, 199u8, 108u8, 92u8, - 207u8, 171u8, 113u8, 8u8, 47u8, 248u8, 65u8, 26u8, 203u8, 135u8, - ], - ) - } - #[doc = "See [`Pallet::cancel_as_multi`]."] - pub fn cancel_as_multi( - &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - call_hash: [::core::primitive::u8; 32usize], - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Multisig", - "cancel_as_multi", - types::CancelAsMulti { threshold, other_signatories, timepoint, call_hash }, - [ - 212u8, 179u8, 123u8, 40u8, 209u8, 228u8, 181u8, 0u8, 109u8, 28u8, 27u8, - 48u8, 15u8, 47u8, 203u8, 54u8, 106u8, 114u8, 28u8, 118u8, 101u8, 201u8, - 95u8, 187u8, 46u8, 182u8, 4u8, 30u8, 227u8, 105u8, 14u8, 81u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_multisig::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new multisig operation has begun."] - pub struct NewMultisig { - pub approving: ::subxt::utils::AccountId32, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for NewMultisig { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "NewMultisig"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been approved by someone."] - pub struct MultisigApproval { - pub approving: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for MultisigApproval { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigApproval"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been executed."] - pub struct MultisigExecuted { - pub approving: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for MultisigExecuted { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigExecuted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been cancelled."] - pub struct MultisigCancelled { - pub cancelling: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for MultisigCancelled { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigCancelled"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The set of open multisig operations."] - pub fn multisigs_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - vec![], - [ - 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, - 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, - 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, - ], - ) - } - #[doc = " The set of open multisig operations."] - pub fn multisigs_iter1( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, - 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, - 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, - ], - ) - } - #[doc = " The set of open multisig operations."] - pub fn multisigs( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, - 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, - 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The base amount of currency needed to reserve for creating a multisig execution or to"] - #[doc = " store a dispatch call for later."] - #[doc = ""] - #[doc = " This is held for an additional storage item whose value size is"] - #[doc = " `4 + sizeof((BlockNumber, Balance, AccountId))` bytes and whose key size is"] - #[doc = " `32 + sizeof(AccountId)` bytes."] - pub fn deposit_base(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Multisig", - "DepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per unit threshold when creating a multisig execution."] - #[doc = ""] - #[doc = " This is held for adding 32 bytes more into a pre-existing storage value."] - pub fn deposit_factor( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Multisig", - "DepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum amount of signatories allowed in the multisig."] - pub fn max_signatories( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Multisig", - "MaxSignatories", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod broker { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_broker::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_broker::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Configure { - pub config: runtime_types::pallet_broker::types::ConfigRecord< - ::core::primitive::u32, - ::core::primitive::u32, - >, - } - impl ::subxt::blocks::StaticExtrinsic for Configure { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "configure"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Reserve { - pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - } - impl ::subxt::blocks::StaticExtrinsic for Reserve { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "reserve"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unreserve { - pub item_index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Unreserve { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "unreserve"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetLease { - pub task: ::core::primitive::u32, - pub until: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetLease { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "set_lease"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct StartSales { - pub initial_price: ::core::primitive::u128, - pub core_count: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for StartSales { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "start_sales"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Purchase { - pub price_limit: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for Purchase { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "purchase"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Renew { - pub core: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for Renew { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "renew"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Transfer { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub new_owner: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for Transfer { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Partition { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub pivot: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Partition { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "partition"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Interlace { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub pivot: runtime_types::pallet_broker::core_mask::CoreMask, - } - impl ::subxt::blocks::StaticExtrinsic for Interlace { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "interlace"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Assign { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub task: ::core::primitive::u32, - pub finality: runtime_types::pallet_broker::types::Finality, - } - impl ::subxt::blocks::StaticExtrinsic for Assign { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "assign"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Pool { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub payee: ::subxt::utils::AccountId32, - pub finality: runtime_types::pallet_broker::types::Finality, - } - impl ::subxt::blocks::StaticExtrinsic for Pool { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "pool"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimRevenue { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub max_timeslices: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ClaimRevenue { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "claim_revenue"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PurchaseCredit { - pub amount: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for PurchaseCredit { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "purchase_credit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DropRegion { - pub region_id: runtime_types::pallet_broker::types::RegionId, - } - impl ::subxt::blocks::StaticExtrinsic for DropRegion { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "drop_region"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DropContribution { - pub region_id: runtime_types::pallet_broker::types::RegionId, - } - impl ::subxt::blocks::StaticExtrinsic for DropContribution { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "drop_contribution"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DropHistory { - pub when: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for DropHistory { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "drop_history"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DropRenewal { - pub core: ::core::primitive::u16, - pub when: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for DropRenewal { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "drop_renewal"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestCoreCount { - pub core_count: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for RequestCoreCount { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "request_core_count"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NotifyCoreCount { - pub core_count: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for NotifyCoreCount { - const PALLET: &'static str = "Broker"; - const CALL: &'static str = "notify_core_count"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::configure`]."] - pub fn configure( - &self, - config: runtime_types::pallet_broker::types::ConfigRecord< - ::core::primitive::u32, - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "configure", - types::Configure { config }, - [ - 47u8, 41u8, 114u8, 129u8, 138u8, 255u8, 77u8, 164u8, 39u8, 215u8, - 231u8, 16u8, 128u8, 220u8, 80u8, 21u8, 199u8, 112u8, 5u8, 209u8, 6u8, - 196u8, 157u8, 38u8, 124u8, 127u8, 134u8, 246u8, 255u8, 191u8, 29u8, - 235u8, - ], - ) - } - #[doc = "See [`Pallet::reserve`]."] - pub fn reserve( - &self, - workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "reserve", - types::Reserve { workload }, - [ - 179u8, 93u8, 196u8, 189u8, 19u8, 203u8, 18u8, 244u8, 161u8, 158u8, - 222u8, 96u8, 140u8, 137u8, 255u8, 4u8, 126u8, 244u8, 236u8, 163u8, - 99u8, 232u8, 70u8, 173u8, 205u8, 167u8, 26u8, 55u8, 133u8, 249u8, 20u8, - 154u8, - ], - ) - } - #[doc = "See [`Pallet::unreserve`]."] - pub fn unreserve( - &self, - item_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "unreserve", - types::Unreserve { item_index }, - [ - 159u8, 127u8, 127u8, 134u8, 252u8, 69u8, 255u8, 67u8, 14u8, 221u8, - 14u8, 56u8, 194u8, 46u8, 33u8, 150u8, 67u8, 124u8, 122u8, 138u8, 74u8, - 186u8, 185u8, 182u8, 42u8, 20u8, 42u8, 178u8, 245u8, 72u8, 116u8, 18u8, - ], - ) - } - #[doc = "See [`Pallet::set_lease`]."] - pub fn set_lease( - &self, - task: ::core::primitive::u32, - until: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "set_lease", - types::SetLease { task, until }, - [ - 183u8, 72u8, 230u8, 156u8, 226u8, 167u8, 172u8, 191u8, 10u8, 221u8, - 224u8, 153u8, 217u8, 195u8, 165u8, 138u8, 154u8, 158u8, 140u8, 121u8, - 77u8, 139u8, 152u8, 7u8, 250u8, 8u8, 33u8, 183u8, 250u8, 150u8, 105u8, - 199u8, - ], - ) - } - #[doc = "See [`Pallet::start_sales`]."] - pub fn start_sales( - &self, - initial_price: ::core::primitive::u128, - core_count: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "start_sales", - types::StartSales { initial_price, core_count }, - [ - 78u8, 51u8, 30u8, 152u8, 207u8, 24u8, 207u8, 149u8, 236u8, 132u8, 62u8, - 228u8, 250u8, 140u8, 44u8, 240u8, 59u8, 114u8, 148u8, 198u8, 151u8, - 127u8, 221u8, 188u8, 250u8, 161u8, 104u8, 7u8, 225u8, 80u8, 170u8, - 207u8, - ], - ) - } - #[doc = "See [`Pallet::purchase`]."] - pub fn purchase( - &self, - price_limit: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "purchase", - types::Purchase { price_limit }, - [ - 180u8, 34u8, 117u8, 232u8, 116u8, 211u8, 229u8, 201u8, 144u8, 72u8, - 36u8, 255u8, 68u8, 70u8, 150u8, 113u8, 230u8, 12u8, 152u8, 88u8, 137u8, - 220u8, 36u8, 6u8, 96u8, 236u8, 108u8, 186u8, 103u8, 92u8, 207u8, 176u8, - ], - ) - } - #[doc = "See [`Pallet::renew`]."] - pub fn renew( - &self, - core: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "renew", - types::Renew { core }, - [ - 89u8, 65u8, 189u8, 173u8, 166u8, 60u8, 207u8, 186u8, 18u8, 239u8, - 130u8, 6u8, 200u8, 56u8, 74u8, 221u8, 220u8, 88u8, 213u8, 202u8, 125u8, - 44u8, 75u8, 102u8, 192u8, 238u8, 170u8, 18u8, 186u8, 101u8, 181u8, - 105u8, - ], - ) - } - #[doc = "See [`Pallet::transfer`]."] - pub fn transfer( - &self, - region_id: runtime_types::pallet_broker::types::RegionId, - new_owner: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "transfer", - types::Transfer { region_id, new_owner }, - [ - 80u8, 18u8, 186u8, 227u8, 213u8, 255u8, 214u8, 84u8, 250u8, 102u8, - 108u8, 104u8, 158u8, 4u8, 14u8, 94u8, 122u8, 6u8, 74u8, 182u8, 193u8, - 11u8, 191u8, 226u8, 2u8, 184u8, 104u8, 126u8, 66u8, 22u8, 125u8, 249u8, - ], - ) - } - #[doc = "See [`Pallet::partition`]."] - pub fn partition( - &self, - region_id: runtime_types::pallet_broker::types::RegionId, - pivot: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "partition", - types::Partition { region_id, pivot }, - [ - 8u8, 89u8, 3u8, 231u8, 184u8, 148u8, 1u8, 32u8, 90u8, 170u8, 209u8, - 110u8, 243u8, 170u8, 140u8, 168u8, 241u8, 4u8, 223u8, 68u8, 70u8, 52u8, - 109u8, 128u8, 61u8, 167u8, 51u8, 133u8, 74u8, 141u8, 0u8, 36u8, - ], - ) - } - #[doc = "See [`Pallet::interlace`]."] - pub fn interlace( - &self, - region_id: runtime_types::pallet_broker::types::RegionId, - pivot: runtime_types::pallet_broker::core_mask::CoreMask, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "interlace", - types::Interlace { region_id, pivot }, - [ - 7u8, 93u8, 42u8, 166u8, 194u8, 35u8, 255u8, 78u8, 40u8, 127u8, 224u8, - 63u8, 218u8, 150u8, 143u8, 233u8, 48u8, 33u8, 140u8, 72u8, 247u8, - 251u8, 179u8, 25u8, 68u8, 157u8, 27u8, 108u8, 183u8, 159u8, 33u8, - 123u8, - ], - ) - } - #[doc = "See [`Pallet::assign`]."] - pub fn assign( - &self, - region_id: runtime_types::pallet_broker::types::RegionId, - task: ::core::primitive::u32, - finality: runtime_types::pallet_broker::types::Finality, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "assign", - types::Assign { region_id, task, finality }, - [ - 91u8, 132u8, 233u8, 43u8, 154u8, 152u8, 15u8, 44u8, 202u8, 230u8, - 122u8, 5u8, 3u8, 5u8, 116u8, 221u8, 207u8, 161u8, 160u8, 100u8, 151u8, - 98u8, 161u8, 218u8, 124u8, 92u8, 45u8, 0u8, 103u8, 188u8, 223u8, 53u8, - ], - ) - } - #[doc = "See [`Pallet::pool`]."] - pub fn pool( - &self, - region_id: runtime_types::pallet_broker::types::RegionId, - payee: ::subxt::utils::AccountId32, - finality: runtime_types::pallet_broker::types::Finality, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "pool", - types::Pool { region_id, payee, finality }, - [ - 14u8, 189u8, 13u8, 148u8, 5u8, 149u8, 194u8, 194u8, 84u8, 123u8, 52u8, - 69u8, 38u8, 226u8, 26u8, 222u8, 247u8, 149u8, 148u8, 248u8, 145u8, - 205u8, 36u8, 139u8, 40u8, 126u8, 14u8, 54u8, 83u8, 248u8, 240u8, 139u8, - ], - ) - } - #[doc = "See [`Pallet::claim_revenue`]."] - pub fn claim_revenue( - &self, - region_id: runtime_types::pallet_broker::types::RegionId, - max_timeslices: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "claim_revenue", - types::ClaimRevenue { region_id, max_timeslices }, - [ - 124u8, 55u8, 35u8, 170u8, 105u8, 123u8, 63u8, 62u8, 63u8, 149u8, 17u8, - 149u8, 185u8, 220u8, 151u8, 206u8, 14u8, 217u8, 84u8, 97u8, 81u8, - 250u8, 122u8, 124u8, 189u8, 144u8, 211u8, 126u8, 158u8, 80u8, 249u8, - 237u8, - ], - ) - } - #[doc = "See [`Pallet::purchase_credit`]."] - pub fn purchase_credit( - &self, - amount: ::core::primitive::u128, - beneficiary: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "purchase_credit", - types::PurchaseCredit { amount, beneficiary }, - [ - 112u8, 183u8, 193u8, 102u8, 30u8, 216u8, 254u8, 165u8, 45u8, 117u8, - 26u8, 95u8, 232u8, 47u8, 237u8, 81u8, 13u8, 191u8, 179u8, 107u8, 183u8, - 182u8, 168u8, 106u8, 164u8, 89u8, 193u8, 116u8, 36u8, 181u8, 146u8, - 160u8, - ], - ) - } - #[doc = "See [`Pallet::drop_region`]."] - pub fn drop_region( - &self, - region_id: runtime_types::pallet_broker::types::RegionId, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "drop_region", - types::DropRegion { region_id }, - [ - 192u8, 116u8, 124u8, 133u8, 187u8, 176u8, 149u8, 187u8, 230u8, 107u8, - 149u8, 185u8, 139u8, 18u8, 154u8, 186u8, 153u8, 56u8, 199u8, 218u8, - 117u8, 84u8, 113u8, 15u8, 233u8, 177u8, 33u8, 224u8, 182u8, 191u8, - 202u8, 234u8, - ], - ) - } - #[doc = "See [`Pallet::drop_contribution`]."] - pub fn drop_contribution( - &self, - region_id: runtime_types::pallet_broker::types::RegionId, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "drop_contribution", - types::DropContribution { region_id }, - [ - 174u8, 22u8, 254u8, 7u8, 41u8, 231u8, 26u8, 174u8, 125u8, 110u8, 9u8, - 27u8, 116u8, 152u8, 51u8, 247u8, 167u8, 126u8, 92u8, 232u8, 122u8, - 189u8, 37u8, 166u8, 181u8, 75u8, 33u8, 188u8, 147u8, 110u8, 111u8, - 10u8, - ], - ) - } - #[doc = "See [`Pallet::drop_history`]."] - pub fn drop_history( - &self, - when: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "drop_history", - types::DropHistory { when }, - [ - 57u8, 162u8, 131u8, 40u8, 152u8, 60u8, 57u8, 118u8, 165u8, 10u8, 170u8, - 202u8, 43u8, 5u8, 118u8, 213u8, 151u8, 89u8, 119u8, 247u8, 133u8, 78u8, - 13u8, 229u8, 159u8, 106u8, 47u8, 244u8, 140u8, 20u8, 80u8, 106u8, - ], - ) - } - #[doc = "See [`Pallet::drop_renewal`]."] - pub fn drop_renewal( - &self, - core: ::core::primitive::u16, - when: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "drop_renewal", - types::DropRenewal { core, when }, - [ - 209u8, 97u8, 211u8, 220u8, 204u8, 144u8, 175u8, 124u8, 55u8, 157u8, - 186u8, 45u8, 197u8, 25u8, 107u8, 108u8, 45u8, 163u8, 95u8, 200u8, - 130u8, 163u8, 22u8, 229u8, 15u8, 249u8, 135u8, 102u8, 12u8, 179u8, - 77u8, 162u8, - ], - ) - } - #[doc = "See [`Pallet::request_core_count`]."] - pub fn request_core_count( - &self, - core_count: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "request_core_count", - types::RequestCoreCount { core_count }, - [ - 32u8, 197u8, 224u8, 109u8, 148u8, 220u8, 31u8, 58u8, 219u8, 175u8, - 220u8, 169u8, 217u8, 190u8, 128u8, 122u8, 142u8, 12u8, 52u8, 105u8, - 40u8, 236u8, 54u8, 27u8, 246u8, 8u8, 152u8, 213u8, 127u8, 25u8, 118u8, - 20u8, - ], - ) - } - #[doc = "See [`Pallet::notify_core_count`]."] - pub fn notify_core_count( - &self, - core_count: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Broker", - "notify_core_count", - types::NotifyCoreCount { core_count }, - [ - 53u8, 44u8, 53u8, 90u8, 247u8, 189u8, 94u8, 149u8, 143u8, 96u8, 51u8, - 87u8, 68u8, 179u8, 121u8, 183u8, 82u8, 109u8, 247u8, 21u8, 164u8, - 180u8, 133u8, 228u8, 247u8, 220u8, 15u8, 48u8, 113u8, 246u8, 112u8, - 49u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_broker::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A Region of Bulk Coretime has been purchased."] - pub struct Purchased { - pub who: ::subxt::utils::AccountId32, - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub price: ::core::primitive::u128, - pub duration: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Purchased { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Purchased"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The workload of a core has become renewable."] - pub struct Renewable { - pub core: ::core::primitive::u16, - pub price: ::core::primitive::u128, - pub begin: ::core::primitive::u32, - pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - } - impl ::subxt::events::StaticEvent for Renewable { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Renewable"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A workload has been renewed."] - pub struct Renewed { - pub who: ::subxt::utils::AccountId32, - pub price: ::core::primitive::u128, - pub old_core: ::core::primitive::u16, - pub core: ::core::primitive::u16, - pub begin: ::core::primitive::u32, - pub duration: ::core::primitive::u32, - pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - } - impl ::subxt::events::StaticEvent for Renewed { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Renewed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Ownership of a Region has been transferred."] - pub struct Transferred { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub duration: ::core::primitive::u32, - pub old_owner: ::subxt::utils::AccountId32, - pub owner: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Transferred { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Transferred"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A Region has been split into two non-overlapping Regions."] - pub struct Partitioned { - pub old_region_id: runtime_types::pallet_broker::types::RegionId, - pub new_region_ids: ( - runtime_types::pallet_broker::types::RegionId, - runtime_types::pallet_broker::types::RegionId, - ), - } - impl ::subxt::events::StaticEvent for Partitioned { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Partitioned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A Region has been converted into two overlapping Regions each of lesser regularity."] - pub struct Interlaced { - pub old_region_id: runtime_types::pallet_broker::types::RegionId, - pub new_region_ids: ( - runtime_types::pallet_broker::types::RegionId, - runtime_types::pallet_broker::types::RegionId, - ), - } - impl ::subxt::events::StaticEvent for Interlaced { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Interlaced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A Region has been assigned to a particular task."] - pub struct Assigned { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub duration: ::core::primitive::u32, - pub task: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Assigned { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Assigned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A Region has been added to the Instantaneous Coretime Pool."] - pub struct Pooled { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub duration: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Pooled { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Pooled"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new number of cores has been requested."] - pub struct CoreCountRequested { - pub core_count: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for CoreCountRequested { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "CoreCountRequested"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The number of cores available for scheduling has changed."] - pub struct CoreCountChanged { - pub core_count: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for CoreCountChanged { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "CoreCountChanged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "There is a new reservation for a workload."] - pub struct ReservationMade { - pub index: ::core::primitive::u32, - pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - } - impl ::subxt::events::StaticEvent for ReservationMade { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "ReservationMade"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A reservation for a workload has been cancelled."] - pub struct ReservationCancelled { - pub index: ::core::primitive::u32, - pub workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - } - impl ::subxt::events::StaticEvent for ReservationCancelled { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "ReservationCancelled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new sale has been initialized."] - pub struct SaleInitialized { - pub sale_start: ::core::primitive::u32, - pub leadin_length: ::core::primitive::u32, - pub start_price: ::core::primitive::u128, - pub regular_price: ::core::primitive::u128, - pub region_begin: ::core::primitive::u32, - pub region_end: ::core::primitive::u32, - pub ideal_cores_sold: ::core::primitive::u16, - pub cores_offered: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for SaleInitialized { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "SaleInitialized"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new lease has been created."] - pub struct Leased { - pub task: ::core::primitive::u32, - pub until: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Leased { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "Leased"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A lease is about to end."] - pub struct LeaseEnding { - pub task: ::core::primitive::u32, - pub when: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for LeaseEnding { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "LeaseEnding"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The sale rotation has been started and a new sale is imminent."] - pub struct SalesStarted { - pub price: ::core::primitive::u128, - pub core_count: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for SalesStarted { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "SalesStarted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The act of claiming revenue has begun."] - pub struct RevenueClaimBegun { - pub region: runtime_types::pallet_broker::types::RegionId, - pub max_timeslices: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for RevenueClaimBegun { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "RevenueClaimBegun"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A particular timeslice has a non-zero claim."] - pub struct RevenueClaimItem { - pub when: ::core::primitive::u32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for RevenueClaimItem { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "RevenueClaimItem"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A revenue claim has (possibly only in part) been paid."] - pub struct RevenueClaimPaid { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub next: ::core::option::Option, - } - impl ::subxt::events::StaticEvent for RevenueClaimPaid { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "RevenueClaimPaid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some Instantaneous Coretime Pool credit has been purchased."] - pub struct CreditPurchased { - pub who: ::subxt::utils::AccountId32, - pub beneficiary: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for CreditPurchased { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "CreditPurchased"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A Region has been dropped due to being out of date."] - pub struct RegionDropped { - pub region_id: runtime_types::pallet_broker::types::RegionId, - pub duration: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for RegionDropped { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "RegionDropped"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some historical Instantaneous Core Pool contribution record has been dropped."] - pub struct ContributionDropped { - pub region_id: runtime_types::pallet_broker::types::RegionId, - } - impl ::subxt::events::StaticEvent for ContributionDropped { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "ContributionDropped"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some historical Instantaneous Core Pool payment record has been initialized."] - pub struct HistoryInitialized { - pub when: ::core::primitive::u32, - pub private_pool_size: ::core::primitive::u32, - pub system_pool_size: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for HistoryInitialized { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "HistoryInitialized"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some historical Instantaneous Core Pool payment record has been dropped."] - pub struct HistoryDropped { - pub when: ::core::primitive::u32, - pub revenue: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for HistoryDropped { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "HistoryDropped"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some historical Instantaneous Core Pool payment record has been ignored because the"] - #[doc = "timeslice was already known. Governance may need to intervene."] - pub struct HistoryIgnored { - pub when: ::core::primitive::u32, - pub revenue: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for HistoryIgnored { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "HistoryIgnored"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some historical Instantaneous Core Pool Revenue is ready for payout claims."] - pub struct ClaimsReady { - pub when: ::core::primitive::u32, - pub system_payout: ::core::primitive::u128, - pub private_payout: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for ClaimsReady { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "ClaimsReady"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A Core has been assigned to one or more tasks and/or the Pool on the Relay-chain."] - pub struct CoreAssigned { - pub core: ::core::primitive::u16, - pub when: ::core::primitive::u32, - pub assignment: ::std::vec::Vec<( - runtime_types::pallet_broker::coretime_interface::CoreAssignment, - ::core::primitive::u16, - )>, - } - impl ::subxt::events::StaticEvent for CoreAssigned { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "CoreAssigned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some historical Instantaneous Core Pool payment record has been dropped."] - pub struct AllowedRenewalDropped { - pub when: ::core::primitive::u32, - pub core: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for AllowedRenewalDropped { - const PALLET: &'static str = "Broker"; - const EVENT: &'static str = "AllowedRenewalDropped"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current configuration of this pallet."] - pub fn configuration( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::ConfigRecord< - ::core::primitive::u32, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Configuration", - vec![], - [ - 235u8, 144u8, 177u8, 6u8, 2u8, 211u8, 0u8, 98u8, 225u8, 133u8, 98u8, - 140u8, 13u8, 117u8, 87u8, 151u8, 42u8, 52u8, 237u8, 170u8, 59u8, 108u8, - 169u8, 254u8, 87u8, 225u8, 64u8, 42u8, 226u8, 214u8, 219u8, 255u8, - ], - ) - } - #[doc = " The Polkadot Core reservations (generally tasked with the maintenance of System Chains)."] - pub fn reservations( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Reservations", - vec![], - [ - 181u8, 60u8, 95u8, 87u8, 83u8, 84u8, 101u8, 181u8, 171u8, 223u8, 229u8, - 6u8, 197u8, 87u8, 137u8, 19u8, 132u8, 252u8, 158u8, 51u8, 193u8, 13u8, - 205u8, 24u8, 133u8, 27u8, 53u8, 23u8, 97u8, 160u8, 39u8, 38u8, - ], - ) - } - #[doc = " The Polkadot Core legacy leases."] - pub fn leases( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::LeaseRecordItem, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Leases", - vec![], - [ - 120u8, 85u8, 234u8, 191u8, 14u8, 161u8, 200u8, 43u8, 248u8, 220u8, - 220u8, 183u8, 62u8, 101u8, 32u8, 34u8, 2u8, 157u8, 140u8, 107u8, 114u8, - 168u8, 121u8, 161u8, 113u8, 223u8, 86u8, 183u8, 226u8, 233u8, 2u8, - 250u8, - ], - ) - } - #[doc = " The current status of miscellaneous subsystems of this pallet."] - pub fn status( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::StatusRecord, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Status", - vec![], - [ - 226u8, 93u8, 147u8, 26u8, 160u8, 235u8, 247u8, 150u8, 187u8, 108u8, - 138u8, 71u8, 227u8, 121u8, 51u8, 106u8, 10u8, 18u8, 58u8, 56u8, 128u8, - 186u8, 93u8, 230u8, 176u8, 248u8, 111u8, 140u8, 148u8, 39u8, 84u8, - 144u8, - ], - ) - } - #[doc = " The details of the current sale, including its properties and status."] - pub fn sale_info( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::SaleInfoRecord< - ::core::primitive::u128, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "SaleInfo", - vec![], - [ - 127u8, 255u8, 82u8, 247u8, 241u8, 27u8, 105u8, 176u8, 147u8, 196u8, - 190u8, 63u8, 235u8, 1u8, 165u8, 106u8, 91u8, 165u8, 58u8, 132u8, 100u8, - 94u8, 106u8, 224u8, 16u8, 33u8, 50u8, 120u8, 90u8, 163u8, 108u8, 165u8, - ], - ) - } - #[doc = " Records of allowed renewals."] - pub fn allowed_renewals_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::AllowedRenewalRecord< - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "AllowedRenewals", - vec![], - [ - 198u8, 33u8, 189u8, 111u8, 176u8, 156u8, 94u8, 163u8, 130u8, 227u8, - 84u8, 165u8, 51u8, 92u8, 103u8, 62u8, 254u8, 102u8, 161u8, 31u8, 228u8, - 88u8, 91u8, 62u8, 155u8, 23u8, 183u8, 246u8, 73u8, 90u8, 151u8, 209u8, - ], - ) - } - #[doc = " Records of allowed renewals."] - pub fn allowed_renewals( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::pallet_broker::types::AllowedRenewalId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::AllowedRenewalRecord< - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "AllowedRenewals", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 198u8, 33u8, 189u8, 111u8, 176u8, 156u8, 94u8, 163u8, 130u8, 227u8, - 84u8, 165u8, 51u8, 92u8, 103u8, 62u8, 254u8, 102u8, 161u8, 31u8, 228u8, - 88u8, 91u8, 62u8, 155u8, 23u8, 183u8, 246u8, 73u8, 90u8, 151u8, 209u8, - ], - ) - } - #[doc = " The current (unassigned) Regions."] - pub fn regions_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::RegionRecord< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Regions", - vec![], - [ - 13u8, 138u8, 239u8, 59u8, 188u8, 5u8, 37u8, 111u8, 236u8, 244u8, 11u8, - 46u8, 70u8, 54u8, 140u8, 148u8, 153u8, 181u8, 57u8, 114u8, 27u8, 156u8, - 177u8, 222u8, 211u8, 79u8, 213u8, 252u8, 68u8, 12u8, 150u8, 70u8, - ], - ) - } - #[doc = " The current (unassigned) Regions."] - pub fn regions( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::RegionRecord< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Regions", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 13u8, 138u8, 239u8, 59u8, 188u8, 5u8, 37u8, 111u8, 236u8, 244u8, 11u8, - 46u8, 70u8, 54u8, 140u8, 148u8, 153u8, 181u8, 57u8, 114u8, 27u8, 156u8, - 177u8, 222u8, 211u8, 79u8, 213u8, 252u8, 68u8, 12u8, 150u8, 70u8, - ], - ) - } - #[doc = " The work we plan on having each core do at a particular time in the future."] - pub fn workplan_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Workplan", - vec![], - [ - 208u8, 23u8, 159u8, 5u8, 97u8, 15u8, 8u8, 3u8, 120u8, 151u8, 25u8, - 172u8, 99u8, 84u8, 164u8, 151u8, 35u8, 231u8, 194u8, 176u8, 74u8, - 132u8, 110u8, 238u8, 159u8, 197u8, 36u8, 64u8, 54u8, 69u8, 72u8, 163u8, - ], - ) - } - #[doc = " The work we plan on having each core do at a particular time in the future."] - pub fn workplan_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Workplan", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 208u8, 23u8, 159u8, 5u8, 97u8, 15u8, 8u8, 3u8, 120u8, 151u8, 25u8, - 172u8, 99u8, 84u8, 164u8, 151u8, 35u8, 231u8, 194u8, 176u8, 74u8, - 132u8, 110u8, 238u8, 159u8, 197u8, 36u8, 64u8, 54u8, 69u8, 72u8, 163u8, - ], - ) - } - #[doc = " The work we plan on having each core do at a particular time in the future."] - pub fn workplan( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Workplan", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 208u8, 23u8, 159u8, 5u8, 97u8, 15u8, 8u8, 3u8, 120u8, 151u8, 25u8, - 172u8, 99u8, 84u8, 164u8, 151u8, 35u8, 231u8, 194u8, 176u8, 74u8, - 132u8, 110u8, 238u8, 159u8, 197u8, 36u8, 64u8, 54u8, 69u8, 72u8, 163u8, - ], - ) - } - #[doc = " The current workload of each core. This gets updated with workplan as timeslices pass."] - pub fn workload_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Workload", - vec![], - [ - 45u8, 113u8, 84u8, 213u8, 62u8, 242u8, 79u8, 85u8, 136u8, 4u8, 216u8, - 202u8, 30u8, 188u8, 60u8, 157u8, 245u8, 141u8, 248u8, 95u8, 247u8, - 119u8, 9u8, 235u8, 164u8, 169u8, 68u8, 99u8, 217u8, 131u8, 250u8, - 137u8, - ], - ) - } - #[doc = " The current workload of each core. This gets updated with workplan as timeslices pass."] - pub fn workload( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "Workload", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 45u8, 113u8, 84u8, 213u8, 62u8, 242u8, 79u8, 85u8, 136u8, 4u8, 216u8, - 202u8, 30u8, 188u8, 60u8, 157u8, 245u8, 141u8, 248u8, 95u8, 247u8, - 119u8, 9u8, 235u8, 164u8, 169u8, 68u8, 99u8, 217u8, 131u8, 250u8, - 137u8, - ], - ) - } - #[doc = " Record of a single contribution to the Instantaneous Coretime Pool."] - pub fn insta_pool_contribution_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::ContributionRecord< - ::subxt::utils::AccountId32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "InstaPoolContribution", - vec![], - [ - 225u8, 37u8, 29u8, 149u8, 219u8, 135u8, 224u8, 209u8, 135u8, 209u8, - 121u8, 140u8, 72u8, 231u8, 213u8, 173u8, 125u8, 250u8, 14u8, 41u8, - 65u8, 242u8, 58u8, 65u8, 27u8, 164u8, 32u8, 174u8, 175u8, 253u8, 205u8, - 192u8, - ], - ) - } - #[doc = " Record of a single contribution to the Instantaneous Coretime Pool."] - pub fn insta_pool_contribution( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::ContributionRecord< - ::subxt::utils::AccountId32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "InstaPoolContribution", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 225u8, 37u8, 29u8, 149u8, 219u8, 135u8, 224u8, 209u8, 135u8, 209u8, - 121u8, 140u8, 72u8, 231u8, 213u8, 173u8, 125u8, 250u8, 14u8, 41u8, - 65u8, 242u8, 58u8, 65u8, 27u8, 164u8, 32u8, 174u8, 175u8, 253u8, 205u8, - 192u8, - ], - ) - } - #[doc = " Record of Coretime entering or leaving the Instantaneous Coretime Pool."] - pub fn insta_pool_io_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::PoolIoRecord, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "InstaPoolIo", - vec![], - [ - 162u8, 151u8, 195u8, 176u8, 123u8, 253u8, 27u8, 213u8, 21u8, 145u8, - 189u8, 94u8, 166u8, 4u8, 46u8, 24u8, 68u8, 151u8, 16u8, 131u8, 45u8, - 201u8, 54u8, 188u8, 26u8, 164u8, 35u8, 251u8, 78u8, 56u8, 39u8, 141u8, - ], - ) - } - #[doc = " Record of Coretime entering or leaving the Instantaneous Coretime Pool."] - pub fn insta_pool_io( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::PoolIoRecord, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "InstaPoolIo", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 162u8, 151u8, 195u8, 176u8, 123u8, 253u8, 27u8, 213u8, 21u8, 145u8, - 189u8, 94u8, 166u8, 4u8, 46u8, 24u8, 68u8, 151u8, 16u8, 131u8, 45u8, - 201u8, 54u8, 188u8, 26u8, 164u8, 35u8, 251u8, 78u8, 56u8, 39u8, 141u8, - ], - ) - } - #[doc = " Total InstaPool rewards for each Timeslice and the number of core parts which contributed."] - pub fn insta_pool_history_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::InstaPoolHistoryRecord< - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "InstaPoolHistory", - vec![], - [ - 126u8, 207u8, 245u8, 55u8, 169u8, 211u8, 138u8, 201u8, 39u8, 31u8, - 176u8, 228u8, 252u8, 247u8, 198u8, 195u8, 134u8, 17u8, 139u8, 200u8, - 58u8, 159u8, 232u8, 213u8, 232u8, 43u8, 30u8, 15u8, 151u8, 236u8, 76u8, - 85u8, - ], - ) - } - #[doc = " Total InstaPool rewards for each Timeslice and the number of core parts which contributed."] - pub fn insta_pool_history( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_broker::types::InstaPoolHistoryRecord< - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "InstaPoolHistory", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 126u8, 207u8, 245u8, 55u8, 169u8, 211u8, 138u8, 201u8, 39u8, 31u8, - 176u8, 228u8, 252u8, 247u8, 198u8, 195u8, 134u8, 17u8, 139u8, 200u8, - 58u8, 159u8, 232u8, 213u8, 232u8, 43u8, 30u8, 15u8, 151u8, 236u8, 76u8, - 85u8, - ], - ) - } - #[doc = " Received core count change from the relay chain."] - pub fn core_count_inbox( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u16, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Broker", - "CoreCountInbox", - vec![], - [ - 78u8, 33u8, 242u8, 74u8, 188u8, 71u8, 31u8, 182u8, 130u8, 205u8, 58u8, - 165u8, 83u8, 161u8, 140u8, 26u8, 208u8, 233u8, 130u8, 27u8, 170u8, - 220u8, 249u8, 195u8, 200u8, 141u8, 28u8, 20u8, 68u8, 86u8, 23u8, 182u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Identifier from which the internal Pot is generated."] - pub fn pallet_id( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "Broker", - "PalletId", - [ - 56u8, 243u8, 53u8, 83u8, 154u8, 179u8, 170u8, 80u8, 133u8, 173u8, 61u8, - 161u8, 47u8, 225u8, 146u8, 21u8, 50u8, 229u8, 248u8, 27u8, 104u8, 58u8, - 129u8, 197u8, 102u8, 160u8, 168u8, 205u8, 154u8, 42u8, 217u8, 53u8, - ], - ) - } - #[doc = " Number of Relay-chain blocks per timeslice."] - pub fn timeslice_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Broker", - "TimeslicePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maximum number of legacy leases."] - pub fn max_leased_cores( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Broker", - "MaxLeasedCores", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maximum number of system cores."] - pub fn max_reserved_cores( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Broker", - "MaxReservedCores", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod sudo { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the Sudo pallet."] - pub type Error = runtime_types::pallet_sudo::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_sudo::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Sudo { - pub call: - ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for Sudo { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "sudo"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoUncheckedWeight { - pub call: - ::std::boxed::Box, - pub weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for SudoUncheckedWeight { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "sudo_unchecked_weight"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetKey { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for SetKey { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "set_key"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoAs { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call: - ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for SudoAs { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "sudo_as"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveKey; - impl ::subxt::blocks::StaticExtrinsic for RemoveKey { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "remove_key"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::sudo`]."] - pub fn sudo( - &self, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "sudo", - types::Sudo { call: ::std::boxed::Box::new(call) }, - [ - 41u8, 23u8, 149u8, 206u8, 108u8, 62u8, 70u8, 168u8, 244u8, 16u8, 168u8, - 159u8, 122u8, 103u8, 32u8, 146u8, 180u8, 215u8, 7u8, 163u8, 102u8, - 243u8, 125u8, 59u8, 3u8, 110u8, 165u8, 65u8, 4u8, 53u8, 119u8, 111u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_unchecked_weight`]."] - pub fn sudo_unchecked_weight( - &self, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "sudo_unchecked_weight", - types::SudoUncheckedWeight { call: ::std::boxed::Box::new(call), weight }, - [ - 141u8, 64u8, 170u8, 4u8, 89u8, 149u8, 62u8, 1u8, 203u8, 56u8, 131u8, - 201u8, 8u8, 108u8, 213u8, 253u8, 101u8, 187u8, 26u8, 39u8, 246u8, - 185u8, 39u8, 3u8, 113u8, 211u8, 223u8, 198u8, 195u8, 81u8, 35u8, 90u8, - ], - ) - } - #[doc = "See [`Pallet::set_key`]."] - pub fn set_key( - &self, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "set_key", - types::SetKey { new }, - [ - 9u8, 73u8, 39u8, 205u8, 188u8, 127u8, 143u8, 54u8, 128u8, 94u8, 8u8, - 227u8, 197u8, 44u8, 70u8, 93u8, 228u8, 196u8, 64u8, 165u8, 226u8, - 158u8, 101u8, 192u8, 22u8, 193u8, 102u8, 84u8, 21u8, 35u8, 92u8, 198u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_as`]."] - pub fn sudo_as( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call: runtime_types::coretime_rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "sudo_as", - types::SudoAs { who, call: ::std::boxed::Box::new(call) }, - [ - 202u8, 135u8, 76u8, 156u8, 213u8, 15u8, 106u8, 60u8, 139u8, 153u8, - 152u8, 67u8, 89u8, 46u8, 122u8, 149u8, 139u8, 226u8, 189u8, 19u8, - 248u8, 220u8, 26u8, 196u8, 246u8, 244u8, 124u8, 25u8, 169u8, 181u8, - 119u8, 96u8, - ], - ) - } - #[doc = "See [`Pallet::remove_key`]."] - pub fn remove_key(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "remove_key", - types::RemoveKey {}, - [ - 133u8, 253u8, 54u8, 175u8, 202u8, 239u8, 5u8, 198u8, 180u8, 138u8, - 25u8, 28u8, 109u8, 40u8, 30u8, 56u8, 126u8, 100u8, 52u8, 205u8, 250u8, - 191u8, 61u8, 195u8, 172u8, 142u8, 184u8, 239u8, 247u8, 10u8, 211u8, - 79u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_sudo::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sudo call just took place."] - pub struct Sudid { - pub sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for Sudid { - const PALLET: &'static str = "Sudo"; - const EVENT: &'static str = "Sudid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The sudo key has been updated."] - pub struct KeyChanged { - pub old: ::core::option::Option<::subxt::utils::AccountId32>, - pub new: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for KeyChanged { - const PALLET: &'static str = "Sudo"; - const EVENT: &'static str = "KeyChanged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The key was permanently removed."] - pub struct KeyRemoved; - impl ::subxt::events::StaticEvent for KeyRemoved { - const PALLET: &'static str = "Sudo"; - const EVENT: &'static str = "KeyRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A [sudo_as](Pallet::sudo_as) call just took place."] - pub struct SudoAsDone { - pub sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for SudoAsDone { - const PALLET: &'static str = "Sudo"; - const EVENT: &'static str = "SudoAsDone"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The `AccountId` of the sudo key."] - pub fn key( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Sudo", - "Key", - vec![], - [ - 72u8, 14u8, 225u8, 162u8, 205u8, 247u8, 227u8, 105u8, 116u8, 57u8, 4u8, - 31u8, 84u8, 137u8, 227u8, 228u8, 133u8, 245u8, 206u8, 227u8, 117u8, - 36u8, 252u8, 151u8, 107u8, 15u8, 180u8, 4u8, 4u8, 152u8, 195u8, 144u8, - ], - ) - } - } - } - } - pub mod runtime_types { - use super::runtime_types; - pub mod bounded_collections { - use super::runtime_types; - pub mod bounded_btree_set { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BoundedBTreeSet<_0>(pub ::std::vec::Vec<_0>); - } - pub mod bounded_vec { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BoundedVec<_0>(pub ::std::vec::Vec<_0>); - } - pub mod weak_bounded_vec { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WeakBoundedVec<_0>(pub ::std::vec::Vec<_0>); - } - } - pub mod coretime_rococo_runtime { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum OriginCaller { - #[codec(index = 0)] - system( - runtime_types::frame_support::dispatch::RawOrigin<::subxt::utils::AccountId32>, - ), - #[codec(index = 31)] - PolkadotXcm(runtime_types::pallet_xcm::pallet::Origin), - #[codec(index = 32)] - CumulusXcm(runtime_types::cumulus_pallet_xcm::pallet::Origin), - #[codec(index = 3)] - Void(runtime_types::sp_core::Void), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Runtime; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RuntimeCall { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Call), - #[codec(index = 1)] - ParachainSystem(runtime_types::cumulus_pallet_parachain_system::pallet::Call), - #[codec(index = 3)] - Timestamp(runtime_types::pallet_timestamp::pallet::Call), - #[codec(index = 4)] - ParachainInfo(runtime_types::staging_parachain_info::pallet::Call), - #[codec(index = 10)] - Balances(runtime_types::pallet_balances::pallet::Call), - #[codec(index = 21)] - CollatorSelection(runtime_types::pallet_collator_selection::pallet::Call), - #[codec(index = 22)] - Session(runtime_types::pallet_session::pallet::Call), - #[codec(index = 30)] - XcmpQueue(runtime_types::cumulus_pallet_xcmp_queue::pallet::Call), - #[codec(index = 31)] - PolkadotXcm(runtime_types::pallet_xcm::pallet::Call), - #[codec(index = 32)] - CumulusXcm(runtime_types::cumulus_pallet_xcm::pallet::Call), - #[codec(index = 34)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Call), - #[codec(index = 40)] - Utility(runtime_types::pallet_utility::pallet::Call), - #[codec(index = 41)] - Multisig(runtime_types::pallet_multisig::pallet::Call), - #[codec(index = 50)] - Broker(runtime_types::pallet_broker::pallet::Call), - #[codec(index = 100)] - Sudo(runtime_types::pallet_sudo::pallet::Call), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RuntimeError { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Error), - #[codec(index = 1)] - ParachainSystem(runtime_types::cumulus_pallet_parachain_system::pallet::Error), - #[codec(index = 10)] - Balances(runtime_types::pallet_balances::pallet::Error), - #[codec(index = 21)] - CollatorSelection(runtime_types::pallet_collator_selection::pallet::Error), - #[codec(index = 22)] - Session(runtime_types::pallet_session::pallet::Error), - #[codec(index = 30)] - XcmpQueue(runtime_types::cumulus_pallet_xcmp_queue::pallet::Error), - #[codec(index = 31)] - PolkadotXcm(runtime_types::pallet_xcm::pallet::Error), - #[codec(index = 34)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Error), - #[codec(index = 40)] - Utility(runtime_types::pallet_utility::pallet::Error), - #[codec(index = 41)] - Multisig(runtime_types::pallet_multisig::pallet::Error), - #[codec(index = 50)] - Broker(runtime_types::pallet_broker::pallet::Error), - #[codec(index = 100)] - Sudo(runtime_types::pallet_sudo::pallet::Error), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RuntimeEvent { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Event), - #[codec(index = 1)] - ParachainSystem(runtime_types::cumulus_pallet_parachain_system::pallet::Event), - #[codec(index = 10)] - Balances(runtime_types::pallet_balances::pallet::Event), - #[codec(index = 11)] - TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), - #[codec(index = 21)] - CollatorSelection(runtime_types::pallet_collator_selection::pallet::Event), - #[codec(index = 22)] - Session(runtime_types::pallet_session::pallet::Event), - #[codec(index = 30)] - XcmpQueue(runtime_types::cumulus_pallet_xcmp_queue::pallet::Event), - #[codec(index = 31)] - PolkadotXcm(runtime_types::pallet_xcm::pallet::Event), - #[codec(index = 32)] - CumulusXcm(runtime_types::cumulus_pallet_xcm::pallet::Event), - #[codec(index = 34)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Event), - #[codec(index = 40)] - Utility(runtime_types::pallet_utility::pallet::Event), - #[codec(index = 41)] - Multisig(runtime_types::pallet_multisig::pallet::Event), - #[codec(index = 50)] - Broker(runtime_types::pallet_broker::pallet::Event), - #[codec(index = 100)] - Sudo(runtime_types::pallet_sudo::pallet::Event), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RuntimeHoldReason {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SessionKeys { - pub aura: runtime_types::sp_consensus_aura::sr25519::app_sr25519::Public, - } - } - pub mod cumulus_pallet_parachain_system { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - # [codec (index = 0)] # [doc = "See [`Pallet::set_validation_data`]."] set_validation_data { data : runtime_types :: cumulus_primitives_parachain_inherent :: ParachainInherentData , } , # [codec (index = 1)] # [doc = "See [`Pallet::sudo_send_upward_message`]."] sudo_send_upward_message { message : :: std :: vec :: Vec < :: core :: primitive :: u8 > , } , # [codec (index = 2)] # [doc = "See [`Pallet::authorize_upgrade`]."] authorize_upgrade { code_hash : :: subxt :: utils :: H256 , check_version : :: core :: primitive :: bool , } , # [codec (index = 3)] # [doc = "See [`Pallet::enact_authorized_upgrade`]."] enact_authorized_upgrade { code : :: std :: vec :: Vec < :: core :: primitive :: u8 > , } , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Attempt to upgrade validation function while existing upgrade pending."] - OverlappingUpgrades, - #[codec(index = 1)] - #[doc = "Polkadot currently prohibits this parachain from upgrading its validation function."] - ProhibitedByPolkadot, - #[codec(index = 2)] - #[doc = "The supplied validation function has compiled into a blob larger than Polkadot is"] - #[doc = "willing to run."] - TooBig, - #[codec(index = 3)] - #[doc = "The inherent which supplies the validation data did not run this block."] - ValidationDataNotAvailable, - #[codec(index = 4)] - #[doc = "The inherent which supplies the host configuration did not run this block."] - HostConfigurationNotAvailable, - #[codec(index = 5)] - #[doc = "No validation function upgrade is currently scheduled."] - NotScheduled, - #[codec(index = 6)] - #[doc = "No code upgrade has been authorized."] - NothingAuthorized, - #[codec(index = 7)] - #[doc = "The given code upgrade has not been authorized."] - Unauthorized, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "The validation function has been scheduled to apply."] - ValidationFunctionStored, - #[codec(index = 1)] - #[doc = "The validation function was applied as of the contained relay chain block number."] - ValidationFunctionApplied { relay_chain_block_num: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "The relay-chain aborted the upgrade process."] - ValidationFunctionDiscarded, - #[codec(index = 3)] - #[doc = "Some downward messages have been received and will be processed."] - DownwardMessagesReceived { count: ::core::primitive::u32 }, - #[codec(index = 4)] - #[doc = "Downward messages were processed using the given weight."] - DownwardMessagesProcessed { - weight_used: runtime_types::sp_weights::weight_v2::Weight, - dmq_head: ::subxt::utils::H256, - }, - #[codec(index = 5)] - #[doc = "An upward message was sent to the relay chain."] - UpwardMessageSent { - message_hash: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - } - } - pub mod relay_state_snapshot { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MessagingStateSnapshot { pub dmq_mqc_head : :: subxt :: utils :: H256 , pub relay_dispatch_queue_remaining_capacity : runtime_types :: cumulus_pallet_parachain_system :: relay_state_snapshot :: RelayDispatchQueueRemainingCapacity , pub ingress_channels : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: v6 :: AbridgedHrmpChannel ,) > , pub egress_channels : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: v6 :: AbridgedHrmpChannel ,) > , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RelayDispatchQueueRemainingCapacity { - pub remaining_count: ::core::primitive::u32, - pub remaining_size: ::core::primitive::u32, - } - } - pub mod unincluded_segment { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Ancestor < _0 > { pub used_bandwidth : runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: UsedBandwidth , pub para_head_hash : :: core :: option :: Option < _0 > , pub consumed_go_ahead_signal : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v6 :: UpgradeGoAhead > , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpChannelUpdate { - pub msg_count: ::core::primitive::u32, - pub total_bytes: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SegmentTracker < _0 > { pub used_bandwidth : runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: UsedBandwidth , pub hrmp_watermark : :: core :: option :: Option < :: core :: primitive :: u32 > , pub consumed_go_ahead_signal : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v6 :: UpgradeGoAhead > , # [codec (skip)] pub __subxt_unused_type_params : :: core :: marker :: PhantomData < _0 > } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UsedBandwidth { pub ump_msg_count : :: core :: primitive :: u32 , pub ump_total_bytes : :: core :: primitive :: u32 , pub hrmp_outgoing : :: subxt :: utils :: KeyedVec < runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: cumulus_pallet_parachain_system :: unincluded_segment :: HrmpChannelUpdate > , } - } - } - pub mod cumulus_pallet_xcm { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Downward message is invalid XCM."] - #[doc = "\\[ id \\]"] - InvalidFormat([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - #[doc = "Downward message is unsupported version of XCM."] - #[doc = "\\[ id \\]"] - UnsupportedVersion([::core::primitive::u8; 32usize]), - #[codec(index = 2)] - #[doc = "Downward message executed with the given outcome."] - #[doc = "\\[ id, outcome \\]"] - ExecutedDownward( - [::core::primitive::u8; 32usize], - runtime_types::staging_xcm::v4::traits::Outcome, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Origin { - #[codec(index = 0)] - Relay, - #[codec(index = 1)] - SiblingParachain(runtime_types::polkadot_parachain_primitives::primitives::Id), - } - } - } - pub mod cumulus_pallet_xcmp_queue { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 1)] - #[doc = "See [`Pallet::suspend_xcm_execution`]."] - suspend_xcm_execution, - #[codec(index = 2)] - #[doc = "See [`Pallet::resume_xcm_execution`]."] - resume_xcm_execution, - #[codec(index = 3)] - #[doc = "See [`Pallet::update_suspend_threshold`]."] - update_suspend_threshold { new: ::core::primitive::u32 }, - #[codec(index = 4)] - #[doc = "See [`Pallet::update_drop_threshold`]."] - update_drop_threshold { new: ::core::primitive::u32 }, - #[codec(index = 5)] - #[doc = "See [`Pallet::update_resume_threshold`]."] - update_resume_threshold { new: ::core::primitive::u32 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Setting the queue config failed since one of its values was invalid."] - BadQueueConfig, - #[codec(index = 1)] - #[doc = "The execution is already suspended."] - AlreadySuspended, - #[codec(index = 2)] - #[doc = "The execution is already resumed."] - AlreadyResumed, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "An HRMP message was sent to a sibling parachain."] - XcmpMessageSent { message_hash: [::core::primitive::u8; 32usize] }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OutboundChannelDetails { - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub state: runtime_types::cumulus_pallet_xcmp_queue::OutboundState, - pub signals_exist: ::core::primitive::bool, - pub first_index: ::core::primitive::u16, - pub last_index: ::core::primitive::u16, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum OutboundState { - #[codec(index = 0)] - Ok, - #[codec(index = 1)] - Suspended, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueueConfigData { - pub suspend_threshold: ::core::primitive::u32, - pub drop_threshold: ::core::primitive::u32, - pub resume_threshold: ::core::primitive::u32, - } - } - pub mod cumulus_primitives_core { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AggregateMessageOrigin { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - Parent, - #[codec(index = 2)] - Sibling(runtime_types::polkadot_parachain_primitives::primitives::Id), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CollationInfo { - pub upward_messages: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub horizontal_messages: ::std::vec::Vec< - runtime_types::polkadot_core_primitives::OutboundHrmpMessage< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - >, - pub new_validation_code: ::core::option::Option< - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - >, - pub processed_downward_messages: ::core::primitive::u32, - pub hrmp_watermark: ::core::primitive::u32, - pub head_data: runtime_types::polkadot_parachain_primitives::primitives::HeadData, - } - } - pub mod cumulus_primitives_parachain_inherent { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MessageQueueChain(pub ::subxt::utils::H256); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ParachainInherentData { - pub validation_data: - runtime_types::polkadot_primitives::v6::PersistedValidationData< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - pub relay_chain_state: runtime_types::sp_trie::storage_proof::StorageProof, - pub downward_messages: ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundDownwardMessage< - ::core::primitive::u32, - >, - >, - pub horizontal_messages: ::subxt::utils::KeyedVec< - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundHrmpMessage< - ::core::primitive::u32, - >, - >, - >, - } - } - pub mod frame_support { - use super::runtime_types; - pub mod dispatch { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DispatchClass { - #[codec(index = 0)] - Normal, - #[codec(index = 1)] - Operational, - #[codec(index = 2)] - Mandatory, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchInfo { - pub weight: runtime_types::sp_weights::weight_v2::Weight, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub pays_fee: runtime_types::frame_support::dispatch::Pays, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Pays { - #[codec(index = 0)] - Yes, - #[codec(index = 1)] - No, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PerDispatchClass<_0> { - pub normal: _0, - pub operational: _0, - pub mandatory: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RawOrigin<_0> { - #[codec(index = 0)] - Root, - #[codec(index = 1)] - Signed(_0), - #[codec(index = 2)] - None, - } - } - pub mod traits { - use super::runtime_types; - pub mod messages { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ProcessMessageError { - #[codec(index = 0)] - BadFormat, - #[codec(index = 1)] - Corrupt, - #[codec(index = 2)] - Unsupported, - #[codec(index = 3)] - Overweight(runtime_types::sp_weights::weight_v2::Weight), - #[codec(index = 4)] - Yield, - } - } - pub mod tokens { - use super::runtime_types; - pub mod misc { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BalanceStatus { - #[codec(index = 0)] - Free, - #[codec(index = 1)] - Reserved, - } - } - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PalletId(pub [::core::primitive::u8; 8usize]); - } - pub mod frame_system { - use super::runtime_types; - pub mod extensions { - use super::runtime_types; - pub mod check_genesis { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckGenesis; - } - pub mod check_mortality { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckMortality(pub runtime_types::sp_runtime::generic::era::Era); - } - pub mod check_non_zero_sender { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckNonZeroSender; - } - pub mod check_nonce { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckNonce(#[codec(compact)] pub ::core::primitive::u32); - } - pub mod check_spec_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckSpecVersion; - } - pub mod check_tx_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckTxVersion; - } - pub mod check_weight { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckWeight; - } - } - pub mod limits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BlockLength { - pub max: runtime_types::frame_support::dispatch::PerDispatchClass< - ::core::primitive::u32, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BlockWeights { - pub base_block: runtime_types::sp_weights::weight_v2::Weight, - pub max_block: runtime_types::sp_weights::weight_v2::Weight, - pub per_class: runtime_types::frame_support::dispatch::PerDispatchClass< - runtime_types::frame_system::limits::WeightsPerClass, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WeightsPerClass { - pub base_extrinsic: runtime_types::sp_weights::weight_v2::Weight, - pub max_extrinsic: - ::core::option::Option, - pub max_total: - ::core::option::Option, - pub reserved: - ::core::option::Option, - } - } - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::remark`]."] - remark { remark: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 1)] - #[doc = "See [`Pallet::set_heap_pages`]."] - set_heap_pages { pages: ::core::primitive::u64 }, - #[codec(index = 2)] - #[doc = "See [`Pallet::set_code`]."] - set_code { code: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 3)] - #[doc = "See [`Pallet::set_code_without_checks`]."] - set_code_without_checks { code: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 4)] - #[doc = "See [`Pallet::set_storage`]."] - set_storage { - items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::kill_storage`]."] - kill_storage { keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>> }, - #[codec(index = 6)] - #[doc = "See [`Pallet::kill_prefix`]."] - kill_prefix { - prefix: ::std::vec::Vec<::core::primitive::u8>, - subkeys: ::core::primitive::u32, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::remark_with_event`]."] - remark_with_event { remark: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 9)] - #[doc = "See [`Pallet::authorize_upgrade`]."] - authorize_upgrade { code_hash: ::subxt::utils::H256 }, - #[codec(index = 10)] - #[doc = "See [`Pallet::authorize_upgrade_without_checks`]."] - authorize_upgrade_without_checks { code_hash: ::subxt::utils::H256 }, - #[codec(index = 11)] - #[doc = "See [`Pallet::apply_authorized_upgrade`]."] - apply_authorized_upgrade { code: ::std::vec::Vec<::core::primitive::u8> }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the System pallet"] - pub enum Error { - #[codec(index = 0)] - #[doc = "The name of specification does not match between the current runtime"] - #[doc = "and the new runtime."] - InvalidSpecName, - #[codec(index = 1)] - #[doc = "The specification version is not allowed to decrease between the current runtime"] - #[doc = "and the new runtime."] - SpecVersionNeedsToIncrease, - #[codec(index = 2)] - #[doc = "Failed to extract the runtime version from the new runtime."] - #[doc = ""] - #[doc = "Either calling `Core_version` or decoding `RuntimeVersion` failed."] - FailedToExtractRuntimeVersion, - #[codec(index = 3)] - #[doc = "Suicide called when the account has non-default composite data."] - NonDefaultComposite, - #[codec(index = 4)] - #[doc = "There is a non-zero reference count preventing the account from being purged."] - NonZeroRefCount, - #[codec(index = 5)] - #[doc = "The origin filter prevent the call to be dispatched."] - CallFiltered, - #[codec(index = 6)] - #[doc = "No upgrade authorized."] - NothingAuthorized, - #[codec(index = 7)] - #[doc = "The submitted code is not authorized."] - Unauthorized, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Event for the System pallet."] - pub enum Event { - #[codec(index = 0)] - #[doc = "An extrinsic completed successfully."] - ExtrinsicSuccess { - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 1)] - #[doc = "An extrinsic failed."] - ExtrinsicFailed { - dispatch_error: runtime_types::sp_runtime::DispatchError, - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 2)] - #[doc = "`:code` was updated."] - CodeUpdated, - #[codec(index = 3)] - #[doc = "A new account was created."] - NewAccount { account: ::subxt::utils::AccountId32 }, - #[codec(index = 4)] - #[doc = "An account was reaped."] - KilledAccount { account: ::subxt::utils::AccountId32 }, - #[codec(index = 5)] - #[doc = "On on-chain remark happened."] - Remarked { sender: ::subxt::utils::AccountId32, hash: ::subxt::utils::H256 }, - #[codec(index = 6)] - #[doc = "An upgrade was authorized."] - UpgradeAuthorized { - code_hash: ::subxt::utils::H256, - check_version: ::core::primitive::bool, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AccountInfo<_0, _1> { - pub nonce: _0, - pub consumers: ::core::primitive::u32, - pub providers: ::core::primitive::u32, - pub sufficients: ::core::primitive::u32, - pub data: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CodeUpgradeAuthorization { - pub code_hash: ::subxt::utils::H256, - pub check_version: ::core::primitive::bool, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EventRecord<_0, _1> { - pub phase: runtime_types::frame_system::Phase, - pub event: _0, - pub topics: ::std::vec::Vec<_1>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LastRuntimeUpgradeInfo { - #[codec(compact)] - pub spec_version: ::core::primitive::u32, - pub spec_name: ::std::string::String, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Phase { - #[codec(index = 0)] - ApplyExtrinsic(::core::primitive::u32), - #[codec(index = 1)] - Finalization, - #[codec(index = 2)] - Initialization, - } - } - pub mod pallet_balances { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::transfer_allow_death`]."] - transfer_allow_death { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::force_transfer`]."] - force_transfer { - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::transfer_keep_alive`]."] - transfer_keep_alive { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::transfer_all`]."] - transfer_all { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::force_unreserve`]."] - force_unreserve { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::upgrade_accounts`]."] - upgrade_accounts { who: ::std::vec::Vec<::subxt::utils::AccountId32> }, - #[codec(index = 8)] - #[doc = "See [`Pallet::force_set_balance`]."] - force_set_balance { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - new_free: ::core::primitive::u128, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::force_adjust_total_issuance`]."] - force_adjust_total_issuance { - direction: runtime_types::pallet_balances::types::AdjustmentDirection, - #[codec(compact)] - delta: ::core::primitive::u128, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Vesting balance too high to send value."] - VestingBalance, - #[codec(index = 1)] - #[doc = "Account liquidity restrictions prevent withdrawal."] - LiquidityRestrictions, - #[codec(index = 2)] - #[doc = "Balance too low to send value."] - InsufficientBalance, - #[codec(index = 3)] - #[doc = "Value too low to create account due to existential deposit."] - ExistentialDeposit, - #[codec(index = 4)] - #[doc = "Transfer/payment would kill account."] - Expendability, - #[codec(index = 5)] - #[doc = "A vesting schedule already exists for this account."] - ExistingVestingSchedule, - #[codec(index = 6)] - #[doc = "Beneficiary account must pre-exist."] - DeadAccount, - #[codec(index = 7)] - #[doc = "Number of named reserves exceed `MaxReserves`."] - TooManyReserves, - #[codec(index = 8)] - #[doc = "Number of holds exceed `VariantCountOf`."] - TooManyHolds, - #[codec(index = 9)] - #[doc = "Number of freezes exceed `MaxFreezes`."] - TooManyFreezes, - #[codec(index = 10)] - #[doc = "The issuance cannot be modified since it is already deactivated."] - IssuanceDeactivated, - #[codec(index = 11)] - #[doc = "The delta cannot be zero."] - DeltaZero, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "An account was created with some free balance."] - Endowed { - account: ::subxt::utils::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] - #[doc = "resulting in an outright loss."] - DustLost { - account: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "Transfer succeeded."] - Transfer { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "A balance was set by root."] - BalanceSet { who: ::subxt::utils::AccountId32, free: ::core::primitive::u128 }, - #[codec(index = 4)] - #[doc = "Some balance was reserved (moved from free to reserved)."] - Reserved { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 5)] - #[doc = "Some balance was unreserved (moved from reserved to free)."] - Unreserved { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 6)] - #[doc = "Some balance was moved from the reserve of the first account to the second account."] - #[doc = "Final argument indicates the destination balance type."] - ReserveRepatriated { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - #[doc = "Some amount was deposited (e.g. for transaction fees)."] - Deposit { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] - Withdraw { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 9)] - #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] - Slashed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - #[doc = "Some amount was minted into an account."] - Minted { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - #[doc = "Some amount was burned from an account."] - Burned { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - #[doc = "Some amount was suspended from an account (it can be restored later)."] - Suspended { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 13)] - #[doc = "Some amount was restored into an account."] - Restored { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 14)] - #[doc = "An account was upgraded."] - Upgraded { who: ::subxt::utils::AccountId32 }, - #[codec(index = 15)] - #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - #[doc = "Some balance was locked."] - Locked { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - #[doc = "Some balance was unlocked."] - Unlocked { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 19)] - #[doc = "Some balance was frozen."] - Frozen { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - #[doc = "Some balance was thawed."] - Thawed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 21)] - #[doc = "The `TotalIssuance` was forcefully changed."] - TotalIssuanceForced { - old: ::core::primitive::u128, - new: ::core::primitive::u128, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AccountData<_0> { - pub free: _0, - pub reserved: _0, - pub frozen: _0, - pub flags: runtime_types::pallet_balances::types::ExtraFlags, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AdjustmentDirection { - #[codec(index = 0)] - Increase, - #[codec(index = 1)] - Decrease, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BalanceLock<_0> { - pub id: [::core::primitive::u8; 8usize], - pub amount: _0, - pub reasons: runtime_types::pallet_balances::types::Reasons, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExtraFlags(pub ::core::primitive::u128); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IdAmount<_0, _1> { - pub id: _0, - pub amount: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Reasons { - #[codec(index = 0)] - Fee, - #[codec(index = 1)] - Misc, - #[codec(index = 2)] - All, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReserveData<_0, _1> { - pub id: _0, - pub amount: _1, - } - } - } - pub mod pallet_broker { - use super::runtime_types; - pub mod core_mask { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CoreMask(pub [::core::primitive::u8; 10usize]); - } - pub mod coretime_interface { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum CoreAssignment { - #[codec(index = 0)] - Idle, - #[codec(index = 1)] - Pool, - #[codec(index = 2)] - Task(::core::primitive::u32), - } - } - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::configure`]."] - configure { - config: runtime_types::pallet_broker::types::ConfigRecord< - ::core::primitive::u32, - ::core::primitive::u32, - >, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::reserve`]."] - reserve { - workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::unreserve`]."] - unreserve { item_index: ::core::primitive::u32 }, - #[codec(index = 3)] - #[doc = "See [`Pallet::set_lease`]."] - set_lease { task: ::core::primitive::u32, until: ::core::primitive::u32 }, - #[codec(index = 4)] - #[doc = "See [`Pallet::start_sales`]."] - start_sales { - initial_price: ::core::primitive::u128, - core_count: ::core::primitive::u16, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::purchase`]."] - purchase { price_limit: ::core::primitive::u128 }, - #[codec(index = 6)] - #[doc = "See [`Pallet::renew`]."] - renew { core: ::core::primitive::u16 }, - #[codec(index = 7)] - #[doc = "See [`Pallet::transfer`]."] - transfer { - region_id: runtime_types::pallet_broker::types::RegionId, - new_owner: ::subxt::utils::AccountId32, - }, - #[codec(index = 8)] - #[doc = "See [`Pallet::partition`]."] - partition { - region_id: runtime_types::pallet_broker::types::RegionId, - pivot: ::core::primitive::u32, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::interlace`]."] - interlace { - region_id: runtime_types::pallet_broker::types::RegionId, - pivot: runtime_types::pallet_broker::core_mask::CoreMask, - }, - #[codec(index = 10)] - #[doc = "See [`Pallet::assign`]."] - assign { - region_id: runtime_types::pallet_broker::types::RegionId, - task: ::core::primitive::u32, - finality: runtime_types::pallet_broker::types::Finality, - }, - #[codec(index = 11)] - #[doc = "See [`Pallet::pool`]."] - pool { - region_id: runtime_types::pallet_broker::types::RegionId, - payee: ::subxt::utils::AccountId32, - finality: runtime_types::pallet_broker::types::Finality, - }, - #[codec(index = 12)] - #[doc = "See [`Pallet::claim_revenue`]."] - claim_revenue { - region_id: runtime_types::pallet_broker::types::RegionId, - max_timeslices: ::core::primitive::u32, - }, - #[codec(index = 13)] - #[doc = "See [`Pallet::purchase_credit`]."] - purchase_credit { - amount: ::core::primitive::u128, - beneficiary: ::subxt::utils::AccountId32, - }, - #[codec(index = 14)] - #[doc = "See [`Pallet::drop_region`]."] - drop_region { region_id: runtime_types::pallet_broker::types::RegionId }, - #[codec(index = 15)] - #[doc = "See [`Pallet::drop_contribution`]."] - drop_contribution { region_id: runtime_types::pallet_broker::types::RegionId }, - #[codec(index = 16)] - #[doc = "See [`Pallet::drop_history`]."] - drop_history { when: ::core::primitive::u32 }, - #[codec(index = 17)] - #[doc = "See [`Pallet::drop_renewal`]."] - drop_renewal { core: ::core::primitive::u16, when: ::core::primitive::u32 }, - #[codec(index = 18)] - #[doc = "See [`Pallet::request_core_count`]."] - request_core_count { core_count: ::core::primitive::u16 }, - #[codec(index = 19)] - #[doc = "See [`Pallet::notify_core_count`]."] - notify_core_count { core_count: ::core::primitive::u16 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The given region identity is not known."] - UnknownRegion, - #[codec(index = 1)] - #[doc = "The owner of the region is not the origin."] - NotOwner, - #[codec(index = 2)] - #[doc = "The pivot point of the partition at or after the end of the region."] - PivotTooLate, - #[codec(index = 3)] - #[doc = "The pivot point of the partition at the beginning of the region."] - PivotTooEarly, - #[codec(index = 4)] - #[doc = "The pivot mask for the interlacing is not contained within the region's interlace mask."] - ExteriorPivot, - #[codec(index = 5)] - #[doc = "The pivot mask for the interlacing is void (and therefore unschedulable)."] - VoidPivot, - #[codec(index = 6)] - #[doc = "The pivot mask for the interlacing is complete (and therefore not a strict subset)."] - CompletePivot, - #[codec(index = 7)] - #[doc = "The workplan of the pallet's state is invalid. This indicates a state corruption."] - CorruptWorkplan, - #[codec(index = 8)] - #[doc = "There is no sale happening currently."] - NoSales, - #[codec(index = 9)] - #[doc = "The price limit is exceeded."] - Overpriced, - #[codec(index = 10)] - #[doc = "There are no cores available."] - Unavailable, - #[codec(index = 11)] - #[doc = "The sale limit has been reached."] - SoldOut, - #[codec(index = 12)] - #[doc = "The renewal operation is not valid at the current time (it may become valid in the next"] - #[doc = "sale)."] - WrongTime, - #[codec(index = 13)] - #[doc = "Invalid attempt to renew."] - NotAllowed, - #[codec(index = 14)] - #[doc = "This pallet has not yet been initialized."] - Uninitialized, - #[codec(index = 15)] - #[doc = "The purchase cannot happen yet as the sale period is yet to begin."] - TooEarly, - #[codec(index = 16)] - #[doc = "There is no work to be done."] - NothingToDo, - #[codec(index = 17)] - #[doc = "The maximum amount of reservations has already been reached."] - TooManyReservations, - #[codec(index = 18)] - #[doc = "The maximum amount of leases has already been reached."] - TooManyLeases, - #[codec(index = 19)] - #[doc = "The revenue for the Instantaneous Core Sales of this period is not (yet) known and thus"] - #[doc = "this operation cannot proceed."] - UnknownRevenue, - #[codec(index = 20)] - #[doc = "The identified contribution to the Instantaneous Core Pool is unknown."] - UnknownContribution, - #[codec(index = 21)] - #[doc = "The workload assigned for renewal is incomplete. This is unexpected and indicates a"] - #[doc = "logic error."] - IncompleteAssignment, - #[codec(index = 22)] - #[doc = "An item cannot be dropped because it is still valid."] - StillValid, - #[codec(index = 23)] - #[doc = "The history item does not exist."] - NoHistory, - #[codec(index = 24)] - #[doc = "No reservation of the given index exists."] - UnknownReservation, - #[codec(index = 25)] - #[doc = "The renewal record cannot be found."] - UnknownRenewal, - #[codec(index = 26)] - #[doc = "The lease expiry time has already passed."] - AlreadyExpired, - #[codec(index = 27)] - #[doc = "The configuration could not be applied because it is invalid."] - InvalidConfig, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A Region of Bulk Coretime has been purchased."] - Purchased { - who: ::subxt::utils::AccountId32, - region_id: runtime_types::pallet_broker::types::RegionId, - price: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 1)] - #[doc = "The workload of a core has become renewable."] - Renewable { - core: ::core::primitive::u16, - price: ::core::primitive::u128, - begin: ::core::primitive::u32, - workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - }, - #[codec(index = 2)] - #[doc = "A workload has been renewed."] - Renewed { - who: ::subxt::utils::AccountId32, - price: ::core::primitive::u128, - old_core: ::core::primitive::u16, - core: ::core::primitive::u16, - begin: ::core::primitive::u32, - duration: ::core::primitive::u32, - workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - }, - #[codec(index = 3)] - #[doc = "Ownership of a Region has been transferred."] - Transferred { - region_id: runtime_types::pallet_broker::types::RegionId, - duration: ::core::primitive::u32, - old_owner: ::subxt::utils::AccountId32, - owner: ::subxt::utils::AccountId32, - }, - #[codec(index = 4)] - #[doc = "A Region has been split into two non-overlapping Regions."] - Partitioned { - old_region_id: runtime_types::pallet_broker::types::RegionId, - new_region_ids: ( - runtime_types::pallet_broker::types::RegionId, - runtime_types::pallet_broker::types::RegionId, - ), - }, - #[codec(index = 5)] - #[doc = "A Region has been converted into two overlapping Regions each of lesser regularity."] - Interlaced { - old_region_id: runtime_types::pallet_broker::types::RegionId, - new_region_ids: ( - runtime_types::pallet_broker::types::RegionId, - runtime_types::pallet_broker::types::RegionId, - ), - }, - #[codec(index = 6)] - #[doc = "A Region has been assigned to a particular task."] - Assigned { - region_id: runtime_types::pallet_broker::types::RegionId, - duration: ::core::primitive::u32, - task: ::core::primitive::u32, - }, - #[codec(index = 7)] - #[doc = "A Region has been added to the Instantaneous Coretime Pool."] - Pooled { - region_id: runtime_types::pallet_broker::types::RegionId, - duration: ::core::primitive::u32, - }, - #[codec(index = 8)] - #[doc = "A new number of cores has been requested."] - CoreCountRequested { core_count: ::core::primitive::u16 }, - #[codec(index = 9)] - #[doc = "The number of cores available for scheduling has changed."] - CoreCountChanged { core_count: ::core::primitive::u16 }, - #[codec(index = 10)] - #[doc = "There is a new reservation for a workload."] - ReservationMade { - index: ::core::primitive::u32, - workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - }, - #[codec(index = 11)] - #[doc = "A reservation for a workload has been cancelled."] - ReservationCancelled { - index: ::core::primitive::u32, - workload: runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - }, - #[codec(index = 12)] - #[doc = "A new sale has been initialized."] - SaleInitialized { - sale_start: ::core::primitive::u32, - leadin_length: ::core::primitive::u32, - start_price: ::core::primitive::u128, - regular_price: ::core::primitive::u128, - region_begin: ::core::primitive::u32, - region_end: ::core::primitive::u32, - ideal_cores_sold: ::core::primitive::u16, - cores_offered: ::core::primitive::u16, - }, - #[codec(index = 13)] - #[doc = "A new lease has been created."] - Leased { task: ::core::primitive::u32, until: ::core::primitive::u32 }, - #[codec(index = 14)] - #[doc = "A lease is about to end."] - LeaseEnding { task: ::core::primitive::u32, when: ::core::primitive::u32 }, - #[codec(index = 15)] - #[doc = "The sale rotation has been started and a new sale is imminent."] - SalesStarted { - price: ::core::primitive::u128, - core_count: ::core::primitive::u16, - }, - #[codec(index = 16)] - #[doc = "The act of claiming revenue has begun."] - RevenueClaimBegun { - region: runtime_types::pallet_broker::types::RegionId, - max_timeslices: ::core::primitive::u32, - }, - #[codec(index = 17)] - #[doc = "A particular timeslice has a non-zero claim."] - RevenueClaimItem { - when: ::core::primitive::u32, - amount: ::core::primitive::u128, - }, - #[codec(index = 18)] - #[doc = "A revenue claim has (possibly only in part) been paid."] - RevenueClaimPaid { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - next: ::core::option::Option, - }, - #[codec(index = 19)] - #[doc = "Some Instantaneous Coretime Pool credit has been purchased."] - CreditPurchased { - who: ::subxt::utils::AccountId32, - beneficiary: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 20)] - #[doc = "A Region has been dropped due to being out of date."] - RegionDropped { - region_id: runtime_types::pallet_broker::types::RegionId, - duration: ::core::primitive::u32, - }, - #[codec(index = 21)] - #[doc = "Some historical Instantaneous Core Pool contribution record has been dropped."] - ContributionDropped { region_id: runtime_types::pallet_broker::types::RegionId }, - #[codec(index = 22)] - #[doc = "Some historical Instantaneous Core Pool payment record has been initialized."] - HistoryInitialized { - when: ::core::primitive::u32, - private_pool_size: ::core::primitive::u32, - system_pool_size: ::core::primitive::u32, - }, - #[codec(index = 23)] - #[doc = "Some historical Instantaneous Core Pool payment record has been dropped."] - HistoryDropped { - when: ::core::primitive::u32, - revenue: ::core::primitive::u128, - }, - #[codec(index = 24)] - #[doc = "Some historical Instantaneous Core Pool payment record has been ignored because the"] - #[doc = "timeslice was already known. Governance may need to intervene."] - HistoryIgnored { - when: ::core::primitive::u32, - revenue: ::core::primitive::u128, - }, - #[codec(index = 25)] - #[doc = "Some historical Instantaneous Core Pool Revenue is ready for payout claims."] - ClaimsReady { - when: ::core::primitive::u32, - system_payout: ::core::primitive::u128, - private_payout: ::core::primitive::u128, - }, - #[codec(index = 26)] - #[doc = "A Core has been assigned to one or more tasks and/or the Pool on the Relay-chain."] - CoreAssigned { - core: ::core::primitive::u16, - when: ::core::primitive::u32, - assignment: ::std::vec::Vec<( - runtime_types::pallet_broker::coretime_interface::CoreAssignment, - ::core::primitive::u16, - )>, - }, - #[codec(index = 27)] - #[doc = "Some historical Instantaneous Core Pool payment record has been dropped."] - AllowedRenewalDropped { - when: ::core::primitive::u32, - core: ::core::primitive::u16, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AllowedRenewalId { - pub core: ::core::primitive::u16, - pub when: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AllowedRenewalRecord<_0> { - pub price: _0, - pub completion: runtime_types::pallet_broker::types::CompletionStatus, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum CompletionStatus { - #[codec(index = 0)] - Partial(runtime_types::pallet_broker::core_mask::CoreMask), - #[codec(index = 1)] - Complete( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_broker::types::ScheduleItem, - >, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ConfigRecord<_0, _1> { - pub advance_notice: _1, - pub interlude_length: _0, - pub leadin_length: _0, - pub region_length: ::core::primitive::u32, - pub ideal_bulk_proportion: runtime_types::sp_arithmetic::per_things::Perbill, - pub limit_cores_offered: ::core::option::Option<::core::primitive::u16>, - pub renewal_bump: runtime_types::sp_arithmetic::per_things::Perbill, - pub contribution_timeout: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ContributionRecord<_0> { - pub length: ::core::primitive::u32, - pub payee: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Finality { - #[codec(index = 0)] - Provisional, - #[codec(index = 1)] - Final, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InstaPoolHistoryRecord<_0> { - pub private_contributions: ::core::primitive::u32, - pub system_contributions: ::core::primitive::u32, - pub maybe_payout: ::core::option::Option<_0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LeaseRecordItem { - pub until: ::core::primitive::u32, - pub task: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PoolIoRecord { - pub private: ::core::primitive::i32, - pub system: ::core::primitive::i32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RegionId { - pub begin: ::core::primitive::u32, - pub core: ::core::primitive::u16, - pub mask: runtime_types::pallet_broker::core_mask::CoreMask, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RegionRecord<_0, _1> { - pub end: ::core::primitive::u32, - pub owner: _0, - pub paid: ::core::option::Option<_1>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SaleInfoRecord<_0, _1> { - pub sale_start: _1, - pub leadin_length: _1, - pub price: _0, - pub region_begin: ::core::primitive::u32, - pub region_end: ::core::primitive::u32, - pub ideal_cores_sold: ::core::primitive::u16, - pub cores_offered: ::core::primitive::u16, - pub first_core: ::core::primitive::u16, - pub sellout_price: ::core::option::Option<_0>, - pub cores_sold: ::core::primitive::u16, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleItem { - pub mask: runtime_types::pallet_broker::core_mask::CoreMask, - pub assignment: - runtime_types::pallet_broker::coretime_interface::CoreAssignment, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct StatusRecord { - pub core_count: ::core::primitive::u16, - pub private_pool_size: ::core::primitive::u32, - pub system_pool_size: ::core::primitive::u32, - pub last_committed_timeslice: ::core::primitive::u32, - pub last_timeslice: ::core::primitive::u32, - } - } - } - pub mod pallet_collator_selection { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::set_invulnerables`]."] - set_invulnerables { new: ::std::vec::Vec<::subxt::utils::AccountId32> }, - #[codec(index = 1)] - #[doc = "See [`Pallet::set_desired_candidates`]."] - set_desired_candidates { max: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "See [`Pallet::set_candidacy_bond`]."] - set_candidacy_bond { bond: ::core::primitive::u128 }, - #[codec(index = 3)] - #[doc = "See [`Pallet::register_as_candidate`]."] - register_as_candidate, - #[codec(index = 4)] - #[doc = "See [`Pallet::leave_intent`]."] - leave_intent, - #[codec(index = 5)] - #[doc = "See [`Pallet::add_invulnerable`]."] - add_invulnerable { who: ::subxt::utils::AccountId32 }, - #[codec(index = 6)] - #[doc = "See [`Pallet::remove_invulnerable`]."] - remove_invulnerable { who: ::subxt::utils::AccountId32 }, - #[codec(index = 7)] - #[doc = "See [`Pallet::update_bond`]."] - update_bond { new_deposit: ::core::primitive::u128 }, - #[codec(index = 8)] - #[doc = "See [`Pallet::take_candidate_slot`]."] - take_candidate_slot { - deposit: ::core::primitive::u128, - target: ::subxt::utils::AccountId32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidateInfo<_0, _1> { - pub who: _0, - pub deposit: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The pallet has too many candidates."] - TooManyCandidates, - #[codec(index = 1)] - #[doc = "Leaving would result in too few candidates."] - TooFewEligibleCollators, - #[codec(index = 2)] - #[doc = "Account is already a candidate."] - AlreadyCandidate, - #[codec(index = 3)] - #[doc = "Account is not a candidate."] - NotCandidate, - #[codec(index = 4)] - #[doc = "There are too many Invulnerables."] - TooManyInvulnerables, - #[codec(index = 5)] - #[doc = "Account is already an Invulnerable."] - AlreadyInvulnerable, - #[codec(index = 6)] - #[doc = "Account is not an Invulnerable."] - NotInvulnerable, - #[codec(index = 7)] - #[doc = "Account has no associated validator ID."] - NoAssociatedValidatorId, - #[codec(index = 8)] - #[doc = "Validator ID is not yet registered."] - ValidatorNotRegistered, - #[codec(index = 9)] - #[doc = "Could not insert in the candidate list."] - InsertToCandidateListFailed, - #[codec(index = 10)] - #[doc = "Could not remove from the candidate list."] - RemoveFromCandidateListFailed, - #[codec(index = 11)] - #[doc = "New deposit amount would be below the minimum candidacy bond."] - DepositTooLow, - #[codec(index = 12)] - #[doc = "Could not update the candidate list."] - UpdateCandidateListFailed, - #[codec(index = 13)] - #[doc = "Deposit amount is too low to take the target's slot in the candidate list."] - InsufficientBond, - #[codec(index = 14)] - #[doc = "The target account to be replaced in the candidate list is not a candidate."] - TargetIsNotCandidate, - #[codec(index = 15)] - #[doc = "The updated deposit amount is equal to the amount already reserved."] - IdenticalDeposit, - #[codec(index = 16)] - #[doc = "Cannot lower candidacy bond while occupying a future collator slot in the list."] - InvalidUnreserve, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "New Invulnerables were set."] - NewInvulnerables { invulnerables: ::std::vec::Vec<::subxt::utils::AccountId32> }, - #[codec(index = 1)] - #[doc = "A new Invulnerable was added."] - InvulnerableAdded { account_id: ::subxt::utils::AccountId32 }, - #[codec(index = 2)] - #[doc = "An Invulnerable was removed."] - InvulnerableRemoved { account_id: ::subxt::utils::AccountId32 }, - #[codec(index = 3)] - #[doc = "The number of desired candidates was set."] - NewDesiredCandidates { desired_candidates: ::core::primitive::u32 }, - #[codec(index = 4)] - #[doc = "The candidacy bond was set."] - NewCandidacyBond { bond_amount: ::core::primitive::u128 }, - #[codec(index = 5)] - #[doc = "A new candidate joined."] - CandidateAdded { - account_id: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 6)] - #[doc = "Bond of a candidate updated."] - CandidateBondUpdated { - account_id: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 7)] - #[doc = "A candidate was removed."] - CandidateRemoved { account_id: ::subxt::utils::AccountId32 }, - #[codec(index = 8)] - #[doc = "An account was replaced in the candidate list by another one."] - CandidateReplaced { - old: ::subxt::utils::AccountId32, - new: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 9)] - #[doc = "An account was unable to be added to the Invulnerables because they did not have keys"] - #[doc = "registered. Other Invulnerables may have been set."] - InvalidInvulnerableSkipped { account_id: ::subxt::utils::AccountId32 }, - } - } - } - pub mod pallet_message_queue { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::reap_page`]."] - reap_page { - message_origin: - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - page_index: ::core::primitive::u32, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::execute_overweight`]."] - execute_overweight { - message_origin: - runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - page: ::core::primitive::u32, - index: ::core::primitive::u32, - weight_limit: runtime_types::sp_weights::weight_v2::Weight, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Page is not reapable because it has items remaining to be processed and is not old"] - #[doc = "enough."] - NotReapable, - #[codec(index = 1)] - #[doc = "Page to be reaped does not exist."] - NoPage, - #[codec(index = 2)] - #[doc = "The referenced message could not be found."] - NoMessage, - #[codec(index = 3)] - #[doc = "The message was already processed and cannot be processed again."] - AlreadyProcessed, - #[codec(index = 4)] - #[doc = "The message is queued for future execution."] - Queued, - #[codec(index = 5)] - #[doc = "There is temporarily not enough weight to continue servicing messages."] - InsufficientWeight, - #[codec(index = 6)] - #[doc = "This message is temporarily unprocessable."] - #[doc = ""] - #[doc = "Such errors are expected, but not guaranteed, to resolve themselves eventually through"] - #[doc = "retrying."] - TemporarilyUnprocessable, - #[codec(index = 7)] - #[doc = "The queue is paused and no message can be executed from it."] - #[doc = ""] - #[doc = "This can change at any time and may resolve in the future by re-trying."] - QueuePaused, - #[codec(index = 8)] - #[doc = "Another call is in progress and needs to finish before this call can happen."] - RecursiveDisallowed, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Message discarded due to an error in the `MessageProcessor` (usually a format error)."] - ProcessingFailed { - id: ::subxt::utils::H256, - origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - error: runtime_types::frame_support::traits::messages::ProcessMessageError, - }, - #[codec(index = 1)] - #[doc = "Message is processed."] - Processed { - id: ::subxt::utils::H256, - origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - weight_used: runtime_types::sp_weights::weight_v2::Weight, - success: ::core::primitive::bool, - }, - #[codec(index = 2)] - #[doc = "Message placed in overweight queue."] - OverweightEnqueued { - id: [::core::primitive::u8; 32usize], - origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - page_index: ::core::primitive::u32, - message_index: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "This page was reaped."] - PageReaped { - origin: runtime_types::cumulus_primitives_core::AggregateMessageOrigin, - index: ::core::primitive::u32, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BookState<_0> { - pub begin: ::core::primitive::u32, - pub end: ::core::primitive::u32, - pub count: ::core::primitive::u32, - pub ready_neighbours: - ::core::option::Option>, - pub message_count: ::core::primitive::u64, - pub size: ::core::primitive::u64, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Neighbours<_0> { - pub prev: _0, - pub next: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Page<_0> { - pub remaining: _0, - pub remaining_size: _0, - pub first_index: _0, - pub first: _0, - pub last: _0, - pub heap: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - } - pub mod pallet_multisig { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::as_multi_threshold_1`]."] - as_multi_threshold_1 { - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - call: - ::std::boxed::Box, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::as_multi`]."] - as_multi { - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call: - ::std::boxed::Box, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::approve_as_multi`]."] - approve_as_multi { - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call_hash: [::core::primitive::u8; 32usize], - max_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::cancel_as_multi`]."] - cancel_as_multi { - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - call_hash: [::core::primitive::u8; 32usize], - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Threshold must be 2 or greater."] - MinimumThreshold, - #[codec(index = 1)] - #[doc = "Call is already approved by this signatory."] - AlreadyApproved, - #[codec(index = 2)] - #[doc = "Call doesn't need any (more) approvals."] - NoApprovalsNeeded, - #[codec(index = 3)] - #[doc = "There are too few signatories in the list."] - TooFewSignatories, - #[codec(index = 4)] - #[doc = "There are too many signatories in the list."] - TooManySignatories, - #[codec(index = 5)] - #[doc = "The signatories were provided out of order; they should be ordered."] - SignatoriesOutOfOrder, - #[codec(index = 6)] - #[doc = "The sender was contained in the other signatories; it shouldn't be."] - SenderInSignatories, - #[codec(index = 7)] - #[doc = "Multisig operation not found when attempting to cancel."] - NotFound, - #[codec(index = 8)] - #[doc = "Only the account that originally created the multisig is able to cancel it."] - NotOwner, - #[codec(index = 9)] - #[doc = "No timepoint was given, yet the multisig operation is already underway."] - NoTimepoint, - #[codec(index = 10)] - #[doc = "A different timepoint was given to the multisig operation that is underway."] - WrongTimepoint, - #[codec(index = 11)] - #[doc = "A timepoint was given, yet no multisig operation is underway."] - UnexpectedTimepoint, - #[codec(index = 12)] - #[doc = "The maximum weight information provided was too low."] - MaxWeightTooLow, - #[codec(index = 13)] - #[doc = "The data to be stored is already stored."] - AlreadyStored, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A new multisig operation has begun."] - NewMultisig { - approving: ::subxt::utils::AccountId32, - multisig: ::subxt::utils::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 1)] - #[doc = "A multisig operation has been approved by someone."] - MultisigApproval { - approving: ::subxt::utils::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::subxt::utils::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - #[doc = "A multisig operation has been executed."] - MultisigExecuted { - approving: ::subxt::utils::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::subxt::utils::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - #[doc = "A multisig operation has been cancelled."] - MultisigCancelled { - cancelling: ::subxt::utils::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::subxt::utils::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Multisig<_0, _1, _2> { - pub when: runtime_types::pallet_multisig::Timepoint<_0>, - pub deposit: _1, - pub depositor: _2, - pub approvals: runtime_types::bounded_collections::bounded_vec::BoundedVec<_2>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Timepoint<_0> { - pub height: _0, - pub index: ::core::primitive::u32, - } - } - pub mod pallet_session { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::set_keys`]."] - set_keys { - keys: runtime_types::coretime_rococo_runtime::SessionKeys, - proof: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::purge_keys`]."] - purge_keys, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the session pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Invalid ownership proof."] - InvalidProof, - #[codec(index = 1)] - #[doc = "No associated validator ID for account."] - NoAssociatedValidatorId, - #[codec(index = 2)] - #[doc = "Registered duplicate key."] - DuplicatedKey, - #[codec(index = 3)] - #[doc = "No keys are associated with this account."] - NoKeys, - #[codec(index = 4)] - #[doc = "Key setting account is not live, so it's impossible to associate keys."] - NoAccount, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "New session has happened. Note that the argument is the session index, not the"] - #[doc = "block number as the type might suggest."] - NewSession { session_index: ::core::primitive::u32 }, - } - } - } - pub mod pallet_sudo { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::sudo`]."] - sudo { - call: - ::std::boxed::Box, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::sudo_unchecked_weight`]."] - sudo_unchecked_weight { - call: - ::std::boxed::Box, - weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::set_key`]."] - set_key { new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()> }, - #[codec(index = 3)] - #[doc = "See [`Pallet::sudo_as`]."] - sudo_as { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call: - ::std::boxed::Box, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::remove_key`]."] - remove_key, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the Sudo pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Sender must be the Sudo account."] - RequireSudo, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A sudo call just took place."] - Sudid { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - #[doc = "The sudo key has been updated."] - KeyChanged { - old: ::core::option::Option<::subxt::utils::AccountId32>, - new: ::subxt::utils::AccountId32, - }, - #[codec(index = 2)] - #[doc = "The key was permanently removed."] - KeyRemoved, - #[codec(index = 3)] - #[doc = "A [sudo_as](Pallet::sudo_as) call just took place."] - SudoAsDone { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod pallet_timestamp { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::set`]."] - set { - #[codec(compact)] - now: ::core::primitive::u64, - }, - } - } - } - pub mod pallet_transaction_payment { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] - #[doc = "has been paid by `who`."] - TransactionFeePaid { - who: ::subxt::utils::AccountId32, - actual_fee: ::core::primitive::u128, - tip: ::core::primitive::u128, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FeeDetails<_0> { - pub inclusion_fee: ::core::option::Option< - runtime_types::pallet_transaction_payment::types::InclusionFee<_0>, - >, - pub tip: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InclusionFee<_0> { - pub base_fee: _0, - pub len_fee: _0, - pub adjusted_weight_fee: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RuntimeDispatchInfo<_0, _1> { - pub weight: _1, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub partial_fee: _0, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ChargeTransactionPayment(#[codec(compact)] pub ::core::primitive::u128); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Releases { - #[codec(index = 0)] - V1Ancient, - #[codec(index = 1)] - V2, - } - } - pub mod pallet_utility { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::batch`]."] - batch { - calls: ::std::vec::Vec, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::as_derivative`]."] - as_derivative { - index: ::core::primitive::u16, - call: - ::std::boxed::Box, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::batch_all`]."] - batch_all { - calls: ::std::vec::Vec, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::dispatch_as`]."] - dispatch_as { - as_origin: - ::std::boxed::Box, - call: - ::std::boxed::Box, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::force_batch`]."] - force_batch { - calls: ::std::vec::Vec, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::with_weight`]."] - with_weight { - call: - ::std::boxed::Box, - weight: runtime_types::sp_weights::weight_v2::Weight, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Too many calls batched."] - TooManyCalls, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] - #[doc = "well as the error."] - BatchInterrupted { - index: ::core::primitive::u32, - error: runtime_types::sp_runtime::DispatchError, - }, - #[codec(index = 1)] - #[doc = "Batch of dispatches completed fully with no error."] - BatchCompleted, - #[codec(index = 2)] - #[doc = "Batch of dispatches completed but has errors."] - BatchCompletedWithErrors, - #[codec(index = 3)] - #[doc = "A single item within a Batch of dispatches has completed with no error."] - ItemCompleted, - #[codec(index = 4)] - #[doc = "A single item within a Batch of dispatches has completed with error."] - ItemFailed { error: runtime_types::sp_runtime::DispatchError }, - #[codec(index = 5)] - #[doc = "A call was dispatched."] - DispatchedAs { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod pallet_xcm { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::send`]."] - send { - dest: ::std::boxed::Box, - message: ::std::boxed::Box, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::teleport_assets`]."] - teleport_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::reserve_transfer_assets`]."] - reserve_transfer_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::execute`]."] - execute { - message: ::std::boxed::Box, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::force_xcm_version`]."] - force_xcm_version { - location: - ::std::boxed::Box, - version: ::core::primitive::u32, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::force_default_xcm_version`]."] - force_default_xcm_version { - maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::force_subscribe_version_notify`]."] - force_subscribe_version_notify { - location: ::std::boxed::Box, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::force_unsubscribe_version_notify`]."] - force_unsubscribe_version_notify { - location: ::std::boxed::Box, - }, - #[codec(index = 8)] - #[doc = "See [`Pallet::limited_reserve_transfer_assets`]."] - limited_reserve_transfer_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::limited_teleport_assets`]."] - limited_teleport_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 10)] - #[doc = "See [`Pallet::force_suspension`]."] - force_suspension { suspended: ::core::primitive::bool }, - #[codec(index = 11)] - #[doc = "See [`Pallet::transfer_assets`]."] - transfer_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The desired destination was unreachable, generally because there is a no way of routing"] - #[doc = "to it."] - Unreachable, - #[codec(index = 1)] - #[doc = "There was some other issue (i.e. not to do with routing) in sending the message."] - #[doc = "Perhaps a lack of space for buffering the message."] - SendFailure, - #[codec(index = 2)] - #[doc = "The message execution fails the filter."] - Filtered, - #[codec(index = 3)] - #[doc = "The message's weight could not be determined."] - UnweighableMessage, - #[codec(index = 4)] - #[doc = "The destination `Location` provided cannot be inverted."] - DestinationNotInvertible, - #[codec(index = 5)] - #[doc = "The assets to be sent are empty."] - Empty, - #[codec(index = 6)] - #[doc = "Could not re-anchor the assets to declare the fees for the destination chain."] - CannotReanchor, - #[codec(index = 7)] - #[doc = "Too many assets have been attempted for transfer."] - TooManyAssets, - #[codec(index = 8)] - #[doc = "Origin is invalid for sending."] - InvalidOrigin, - #[codec(index = 9)] - #[doc = "The version of the `Versioned` value used is not able to be interpreted."] - BadVersion, - #[codec(index = 10)] - #[doc = "The given location could not be used (e.g. because it cannot be expressed in the"] - #[doc = "desired version of XCM)."] - BadLocation, - #[codec(index = 11)] - #[doc = "The referenced subscription could not be found."] - NoSubscription, - #[codec(index = 12)] - #[doc = "The location is invalid since it already has a subscription from us."] - AlreadySubscribed, - #[codec(index = 13)] - #[doc = "Could not check-out the assets for teleportation to the destination chain."] - CannotCheckOutTeleport, - #[codec(index = 14)] - #[doc = "The owner does not own (all) of the asset that they wish to do the operation on."] - LowBalance, - #[codec(index = 15)] - #[doc = "The asset owner has too many locks on the asset."] - TooManyLocks, - #[codec(index = 16)] - #[doc = "The given account is not an identifiable sovereign account for any location."] - AccountNotSovereign, - #[codec(index = 17)] - #[doc = "The operation required fees to be paid which the initiator could not meet."] - FeesNotMet, - #[codec(index = 18)] - #[doc = "A remote lock with the corresponding data could not be found."] - LockNotFound, - #[codec(index = 19)] - #[doc = "The unlock operation cannot succeed because there are still consumers of the lock."] - InUse, - #[codec(index = 20)] - #[doc = "Invalid non-concrete asset."] - InvalidAssetNotConcrete, - #[codec(index = 21)] - #[doc = "Invalid asset, reserve chain could not be determined for it."] - InvalidAssetUnknownReserve, - #[codec(index = 22)] - #[doc = "Invalid asset, do not support remote asset reserves with different fees reserves."] - InvalidAssetUnsupportedReserve, - #[codec(index = 23)] - #[doc = "Too many assets with different reserve locations have been attempted for transfer."] - TooManyReserves, - #[codec(index = 24)] - #[doc = "Local XCM execution incomplete."] - LocalExecutionIncomplete, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Execution of an XCM message was attempted."] - Attempted { outcome: runtime_types::staging_xcm::v4::traits::Outcome }, - #[codec(index = 1)] - #[doc = "A XCM message was sent."] - Sent { - origin: runtime_types::staging_xcm::v4::location::Location, - destination: runtime_types::staging_xcm::v4::location::Location, - message: runtime_types::staging_xcm::v4::Xcm, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - #[doc = "Query response received which does not match a registered query. This may be because a"] - #[doc = "matching query was never registered, it may be because it is a duplicate response, or"] - #[doc = "because the query timed out."] - UnexpectedResponse { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - }, - #[codec(index = 3)] - #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] - #[doc = "no registered notification call."] - ResponseReady { - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v4::Response, - }, - #[codec(index = 4)] - #[doc = "Query response has been received and query is removed. The registered notification has"] - #[doc = "been dispatched and executed successfully."] - Notified { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 5)] - #[doc = "Query response has been received and query is removed. The registered notification"] - #[doc = "could not be dispatched because the dispatch weight is greater than the maximum weight"] - #[doc = "originally budgeted by this runtime for the query result."] - NotifyOverweight { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - actual_weight: runtime_types::sp_weights::weight_v2::Weight, - max_budgeted_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 6)] - #[doc = "Query response has been received and query is removed. There was a general error with"] - #[doc = "dispatching the notification call."] - NotifyDispatchError { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 7)] - #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] - #[doc = "decoded into a `Call`; this might be due to dispatch function having a signature which"] - #[doc = "is not `(origin, QueryId, Response)`."] - NotifyDecodeFailed { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 8)] - #[doc = "Expected query response has been received but the origin location of the response does"] - #[doc = "not match that expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - InvalidResponder { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - expected_location: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - #[codec(index = 9)] - #[doc = "Expected query response has been received but the expected origin location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - InvalidResponderVersion { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - }, - #[codec(index = 10)] - #[doc = "Received query response has been read and removed."] - ResponseTaken { query_id: ::core::primitive::u64 }, - #[codec(index = 11)] - #[doc = "Some assets have been placed in an asset trap."] - AssetsTrapped { - hash: ::subxt::utils::H256, - origin: runtime_types::staging_xcm::v4::location::Location, - assets: runtime_types::xcm::VersionedAssets, - }, - #[codec(index = 12)] - #[doc = "An XCM version change notification message has been attempted to be sent."] - #[doc = ""] - #[doc = "The cost of sending it (borne by the chain) is included."] - VersionChangeNotified { - destination: runtime_types::staging_xcm::v4::location::Location, - result: ::core::primitive::u32, - cost: runtime_types::staging_xcm::v4::asset::Assets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 13)] - #[doc = "The supported version of a location has been changed. This might be through an"] - #[doc = "automatic notification or a manual intervention."] - SupportedVersionChanged { - location: runtime_types::staging_xcm::v4::location::Location, - version: ::core::primitive::u32, - }, - #[codec(index = 14)] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "sending the notification to it."] - NotifyTargetSendFail { - location: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - error: runtime_types::xcm::v3::traits::Error, - }, - #[codec(index = 15)] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "migrating the location to our new XCM format."] - NotifyTargetMigrationFail { - location: runtime_types::xcm::VersionedLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 16)] - #[doc = "Expected query response has been received but the expected querier location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - InvalidQuerierVersion { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - }, - #[codec(index = 17)] - #[doc = "Expected query response has been received but the querier location of the response does"] - #[doc = "not match the expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - InvalidQuerier { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - expected_querier: runtime_types::staging_xcm::v4::location::Location, - maybe_actual_querier: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - #[codec(index = 18)] - #[doc = "A remote has requested XCM version change notification from us and we have honored it."] - #[doc = "A version information message is sent to them and its cost is included."] - VersionNotifyStarted { - destination: runtime_types::staging_xcm::v4::location::Location, - cost: runtime_types::staging_xcm::v4::asset::Assets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 19)] - #[doc = "We have requested that a remote chain send us XCM version change notifications."] - VersionNotifyRequested { - destination: runtime_types::staging_xcm::v4::location::Location, - cost: runtime_types::staging_xcm::v4::asset::Assets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 20)] - #[doc = "We have requested that a remote chain stops sending us XCM version change"] - #[doc = "notifications."] - VersionNotifyUnrequested { - destination: runtime_types::staging_xcm::v4::location::Location, - cost: runtime_types::staging_xcm::v4::asset::Assets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 21)] - #[doc = "Fees were paid from a location for an operation (often for using `SendXcm`)."] - FeesPaid { - paying: runtime_types::staging_xcm::v4::location::Location, - fees: runtime_types::staging_xcm::v4::asset::Assets, - }, - #[codec(index = 22)] - #[doc = "Some assets have been claimed from an asset trap"] - AssetsClaimed { - hash: ::subxt::utils::H256, - origin: runtime_types::staging_xcm::v4::location::Location, - assets: runtime_types::xcm::VersionedAssets, - }, - #[codec(index = 23)] - #[doc = "A XCM version migration finished."] - VersionMigrationFinished { version: ::core::primitive::u32 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Origin { - #[codec(index = 0)] - Xcm(runtime_types::staging_xcm::v4::location::Location), - #[codec(index = 1)] - Response(runtime_types::staging_xcm::v4::location::Location), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum QueryStatus<_0> { - #[codec(index = 0)] - Pending { - responder: runtime_types::xcm::VersionedLocation, - maybe_match_querier: - ::core::option::Option, - maybe_notify: - ::core::option::Option<(::core::primitive::u8, ::core::primitive::u8)>, - timeout: _0, - }, - #[codec(index = 1)] - VersionNotifier { - origin: runtime_types::xcm::VersionedLocation, - is_active: ::core::primitive::bool, - }, - #[codec(index = 2)] - Ready { response: runtime_types::xcm::VersionedResponse, at: _0 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoteLockedFungibleRecord<_0> { - pub amount: ::core::primitive::u128, - pub owner: runtime_types::xcm::VersionedLocation, - pub locker: runtime_types::xcm::VersionedLocation, - pub consumers: runtime_types::bounded_collections::bounded_vec::BoundedVec<( - _0, - ::core::primitive::u128, - )>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionMigrationStage { - #[codec(index = 0)] - MigrateSupportedVersion, - #[codec(index = 1)] - MigrateVersionNotifiers, - #[codec(index = 2)] - NotifyCurrentTargets( - ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, - ), - #[codec(index = 3)] - MigrateAndNotifyOldTargets, - } - } - } - pub mod polkadot_core_primitives { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InboundDownwardMessage<_0> { - pub sent_at: _0, - pub msg: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InboundHrmpMessage<_0> { - pub sent_at: _0, - pub data: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OutboundHrmpMessage<_0> { - pub recipient: _0, - pub data: ::std::vec::Vec<::core::primitive::u8>, - } - } - pub mod polkadot_parachain_primitives { - use super::runtime_types; - pub mod primitives { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HeadData(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Id(pub ::core::primitive::u32); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidationCode(pub ::std::vec::Vec<::core::primitive::u8>); - } - } - pub mod polkadot_primitives { - use super::runtime_types; - pub mod v6 { - use super::runtime_types; - pub mod async_backing { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsyncBackingParams { - pub max_candidate_depth: ::core::primitive::u32, - pub allowed_ancestry_len: ::core::primitive::u32, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AbridgedHostConfiguration { - pub max_code_size: ::core::primitive::u32, - pub max_head_data_size: ::core::primitive::u32, - pub max_upward_queue_count: ::core::primitive::u32, - pub max_upward_queue_size: ::core::primitive::u32, - pub max_upward_message_size: ::core::primitive::u32, - pub max_upward_message_num_per_candidate: ::core::primitive::u32, - pub hrmp_max_message_num_per_candidate: ::core::primitive::u32, - pub validation_upgrade_cooldown: ::core::primitive::u32, - pub validation_upgrade_delay: ::core::primitive::u32, - pub async_backing_params: - runtime_types::polkadot_primitives::v6::async_backing::AsyncBackingParams, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AbridgedHrmpChannel { - pub max_capacity: ::core::primitive::u32, - pub max_total_size: ::core::primitive::u32, - pub max_message_size: ::core::primitive::u32, - pub msg_count: ::core::primitive::u32, - pub total_size: ::core::primitive::u32, - pub mqc_head: ::core::option::Option<::subxt::utils::H256>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PersistedValidationData<_0, _1> { - pub parent_head: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub relay_parent_number: _1, - pub relay_parent_storage_root: _0, - pub max_pov_size: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum UpgradeGoAhead { - #[codec(index = 0)] - Abort, - #[codec(index = 1)] - GoAhead, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum UpgradeRestriction { - #[codec(index = 0)] - Present, - } - } - } - pub mod sp_arithmetic { - use super::runtime_types; - pub mod fixed_point { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FixedU128(pub ::core::primitive::u128); - } - pub mod per_things { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Perbill(pub ::core::primitive::u32); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ArithmeticError { - #[codec(index = 0)] - Underflow, - #[codec(index = 1)] - Overflow, - #[codec(index = 2)] - DivisionByZero, - } - } - pub mod sp_consensus_aura { - use super::runtime_types; - pub mod sr25519 { - use super::runtime_types; - pub mod app_sr25519 { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - } - } - } - pub mod sp_consensus_slots { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Slot(pub ::core::primitive::u64); - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SlotDuration(pub ::core::primitive::u64); - } - pub mod sp_core { - use super::runtime_types; - pub mod crypto { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); - } - pub mod ecdsa { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub [::core::primitive::u8; 65usize]); - } - pub mod ed25519 { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - pub mod sr25519 { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaqueMetadata(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Void {} - } - pub mod sp_inherents { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckInherentsResult { - pub okay: ::core::primitive::bool, - pub fatal_error: ::core::primitive::bool, - pub errors: runtime_types::sp_inherents::InherentData, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InherentData { - pub data: ::subxt::utils::KeyedVec< - [::core::primitive::u8; 8usize], - ::std::vec::Vec<::core::primitive::u8>, - >, - } - } - pub mod sp_runtime { - use super::runtime_types; - pub mod generic { - use super::runtime_types; - pub mod block { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Block<_0, _1> { - pub header: _0, - pub extrinsics: ::std::vec::Vec<_1>, - } - } - pub mod digest { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Digest { - pub logs: - ::std::vec::Vec, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DigestItem { - #[codec(index = 6)] - PreRuntime( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 4)] - Consensus( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 5)] - Seal( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 0)] - Other(::std::vec::Vec<::core::primitive::u8>), - #[codec(index = 8)] - RuntimeEnvironmentUpdated, - } - } - pub mod era { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Era { - #[codec(index = 0)] - Immortal, - #[codec(index = 1)] - Mortal1(::core::primitive::u8), - #[codec(index = 2)] - Mortal2(::core::primitive::u8), - #[codec(index = 3)] - Mortal3(::core::primitive::u8), - #[codec(index = 4)] - Mortal4(::core::primitive::u8), - #[codec(index = 5)] - Mortal5(::core::primitive::u8), - #[codec(index = 6)] - Mortal6(::core::primitive::u8), - #[codec(index = 7)] - Mortal7(::core::primitive::u8), - #[codec(index = 8)] - Mortal8(::core::primitive::u8), - #[codec(index = 9)] - Mortal9(::core::primitive::u8), - #[codec(index = 10)] - Mortal10(::core::primitive::u8), - #[codec(index = 11)] - Mortal11(::core::primitive::u8), - #[codec(index = 12)] - Mortal12(::core::primitive::u8), - #[codec(index = 13)] - Mortal13(::core::primitive::u8), - #[codec(index = 14)] - Mortal14(::core::primitive::u8), - #[codec(index = 15)] - Mortal15(::core::primitive::u8), - #[codec(index = 16)] - Mortal16(::core::primitive::u8), - #[codec(index = 17)] - Mortal17(::core::primitive::u8), - #[codec(index = 18)] - Mortal18(::core::primitive::u8), - #[codec(index = 19)] - Mortal19(::core::primitive::u8), - #[codec(index = 20)] - Mortal20(::core::primitive::u8), - #[codec(index = 21)] - Mortal21(::core::primitive::u8), - #[codec(index = 22)] - Mortal22(::core::primitive::u8), - #[codec(index = 23)] - Mortal23(::core::primitive::u8), - #[codec(index = 24)] - Mortal24(::core::primitive::u8), - #[codec(index = 25)] - Mortal25(::core::primitive::u8), - #[codec(index = 26)] - Mortal26(::core::primitive::u8), - #[codec(index = 27)] - Mortal27(::core::primitive::u8), - #[codec(index = 28)] - Mortal28(::core::primitive::u8), - #[codec(index = 29)] - Mortal29(::core::primitive::u8), - #[codec(index = 30)] - Mortal30(::core::primitive::u8), - #[codec(index = 31)] - Mortal31(::core::primitive::u8), - #[codec(index = 32)] - Mortal32(::core::primitive::u8), - #[codec(index = 33)] - Mortal33(::core::primitive::u8), - #[codec(index = 34)] - Mortal34(::core::primitive::u8), - #[codec(index = 35)] - Mortal35(::core::primitive::u8), - #[codec(index = 36)] - Mortal36(::core::primitive::u8), - #[codec(index = 37)] - Mortal37(::core::primitive::u8), - #[codec(index = 38)] - Mortal38(::core::primitive::u8), - #[codec(index = 39)] - Mortal39(::core::primitive::u8), - #[codec(index = 40)] - Mortal40(::core::primitive::u8), - #[codec(index = 41)] - Mortal41(::core::primitive::u8), - #[codec(index = 42)] - Mortal42(::core::primitive::u8), - #[codec(index = 43)] - Mortal43(::core::primitive::u8), - #[codec(index = 44)] - Mortal44(::core::primitive::u8), - #[codec(index = 45)] - Mortal45(::core::primitive::u8), - #[codec(index = 46)] - Mortal46(::core::primitive::u8), - #[codec(index = 47)] - Mortal47(::core::primitive::u8), - #[codec(index = 48)] - Mortal48(::core::primitive::u8), - #[codec(index = 49)] - Mortal49(::core::primitive::u8), - #[codec(index = 50)] - Mortal50(::core::primitive::u8), - #[codec(index = 51)] - Mortal51(::core::primitive::u8), - #[codec(index = 52)] - Mortal52(::core::primitive::u8), - #[codec(index = 53)] - Mortal53(::core::primitive::u8), - #[codec(index = 54)] - Mortal54(::core::primitive::u8), - #[codec(index = 55)] - Mortal55(::core::primitive::u8), - #[codec(index = 56)] - Mortal56(::core::primitive::u8), - #[codec(index = 57)] - Mortal57(::core::primitive::u8), - #[codec(index = 58)] - Mortal58(::core::primitive::u8), - #[codec(index = 59)] - Mortal59(::core::primitive::u8), - #[codec(index = 60)] - Mortal60(::core::primitive::u8), - #[codec(index = 61)] - Mortal61(::core::primitive::u8), - #[codec(index = 62)] - Mortal62(::core::primitive::u8), - #[codec(index = 63)] - Mortal63(::core::primitive::u8), - #[codec(index = 64)] - Mortal64(::core::primitive::u8), - #[codec(index = 65)] - Mortal65(::core::primitive::u8), - #[codec(index = 66)] - Mortal66(::core::primitive::u8), - #[codec(index = 67)] - Mortal67(::core::primitive::u8), - #[codec(index = 68)] - Mortal68(::core::primitive::u8), - #[codec(index = 69)] - Mortal69(::core::primitive::u8), - #[codec(index = 70)] - Mortal70(::core::primitive::u8), - #[codec(index = 71)] - Mortal71(::core::primitive::u8), - #[codec(index = 72)] - Mortal72(::core::primitive::u8), - #[codec(index = 73)] - Mortal73(::core::primitive::u8), - #[codec(index = 74)] - Mortal74(::core::primitive::u8), - #[codec(index = 75)] - Mortal75(::core::primitive::u8), - #[codec(index = 76)] - Mortal76(::core::primitive::u8), - #[codec(index = 77)] - Mortal77(::core::primitive::u8), - #[codec(index = 78)] - Mortal78(::core::primitive::u8), - #[codec(index = 79)] - Mortal79(::core::primitive::u8), - #[codec(index = 80)] - Mortal80(::core::primitive::u8), - #[codec(index = 81)] - Mortal81(::core::primitive::u8), - #[codec(index = 82)] - Mortal82(::core::primitive::u8), - #[codec(index = 83)] - Mortal83(::core::primitive::u8), - #[codec(index = 84)] - Mortal84(::core::primitive::u8), - #[codec(index = 85)] - Mortal85(::core::primitive::u8), - #[codec(index = 86)] - Mortal86(::core::primitive::u8), - #[codec(index = 87)] - Mortal87(::core::primitive::u8), - #[codec(index = 88)] - Mortal88(::core::primitive::u8), - #[codec(index = 89)] - Mortal89(::core::primitive::u8), - #[codec(index = 90)] - Mortal90(::core::primitive::u8), - #[codec(index = 91)] - Mortal91(::core::primitive::u8), - #[codec(index = 92)] - Mortal92(::core::primitive::u8), - #[codec(index = 93)] - Mortal93(::core::primitive::u8), - #[codec(index = 94)] - Mortal94(::core::primitive::u8), - #[codec(index = 95)] - Mortal95(::core::primitive::u8), - #[codec(index = 96)] - Mortal96(::core::primitive::u8), - #[codec(index = 97)] - Mortal97(::core::primitive::u8), - #[codec(index = 98)] - Mortal98(::core::primitive::u8), - #[codec(index = 99)] - Mortal99(::core::primitive::u8), - #[codec(index = 100)] - Mortal100(::core::primitive::u8), - #[codec(index = 101)] - Mortal101(::core::primitive::u8), - #[codec(index = 102)] - Mortal102(::core::primitive::u8), - #[codec(index = 103)] - Mortal103(::core::primitive::u8), - #[codec(index = 104)] - Mortal104(::core::primitive::u8), - #[codec(index = 105)] - Mortal105(::core::primitive::u8), - #[codec(index = 106)] - Mortal106(::core::primitive::u8), - #[codec(index = 107)] - Mortal107(::core::primitive::u8), - #[codec(index = 108)] - Mortal108(::core::primitive::u8), - #[codec(index = 109)] - Mortal109(::core::primitive::u8), - #[codec(index = 110)] - Mortal110(::core::primitive::u8), - #[codec(index = 111)] - Mortal111(::core::primitive::u8), - #[codec(index = 112)] - Mortal112(::core::primitive::u8), - #[codec(index = 113)] - Mortal113(::core::primitive::u8), - #[codec(index = 114)] - Mortal114(::core::primitive::u8), - #[codec(index = 115)] - Mortal115(::core::primitive::u8), - #[codec(index = 116)] - Mortal116(::core::primitive::u8), - #[codec(index = 117)] - Mortal117(::core::primitive::u8), - #[codec(index = 118)] - Mortal118(::core::primitive::u8), - #[codec(index = 119)] - Mortal119(::core::primitive::u8), - #[codec(index = 120)] - Mortal120(::core::primitive::u8), - #[codec(index = 121)] - Mortal121(::core::primitive::u8), - #[codec(index = 122)] - Mortal122(::core::primitive::u8), - #[codec(index = 123)] - Mortal123(::core::primitive::u8), - #[codec(index = 124)] - Mortal124(::core::primitive::u8), - #[codec(index = 125)] - Mortal125(::core::primitive::u8), - #[codec(index = 126)] - Mortal126(::core::primitive::u8), - #[codec(index = 127)] - Mortal127(::core::primitive::u8), - #[codec(index = 128)] - Mortal128(::core::primitive::u8), - #[codec(index = 129)] - Mortal129(::core::primitive::u8), - #[codec(index = 130)] - Mortal130(::core::primitive::u8), - #[codec(index = 131)] - Mortal131(::core::primitive::u8), - #[codec(index = 132)] - Mortal132(::core::primitive::u8), - #[codec(index = 133)] - Mortal133(::core::primitive::u8), - #[codec(index = 134)] - Mortal134(::core::primitive::u8), - #[codec(index = 135)] - Mortal135(::core::primitive::u8), - #[codec(index = 136)] - Mortal136(::core::primitive::u8), - #[codec(index = 137)] - Mortal137(::core::primitive::u8), - #[codec(index = 138)] - Mortal138(::core::primitive::u8), - #[codec(index = 139)] - Mortal139(::core::primitive::u8), - #[codec(index = 140)] - Mortal140(::core::primitive::u8), - #[codec(index = 141)] - Mortal141(::core::primitive::u8), - #[codec(index = 142)] - Mortal142(::core::primitive::u8), - #[codec(index = 143)] - Mortal143(::core::primitive::u8), - #[codec(index = 144)] - Mortal144(::core::primitive::u8), - #[codec(index = 145)] - Mortal145(::core::primitive::u8), - #[codec(index = 146)] - Mortal146(::core::primitive::u8), - #[codec(index = 147)] - Mortal147(::core::primitive::u8), - #[codec(index = 148)] - Mortal148(::core::primitive::u8), - #[codec(index = 149)] - Mortal149(::core::primitive::u8), - #[codec(index = 150)] - Mortal150(::core::primitive::u8), - #[codec(index = 151)] - Mortal151(::core::primitive::u8), - #[codec(index = 152)] - Mortal152(::core::primitive::u8), - #[codec(index = 153)] - Mortal153(::core::primitive::u8), - #[codec(index = 154)] - Mortal154(::core::primitive::u8), - #[codec(index = 155)] - Mortal155(::core::primitive::u8), - #[codec(index = 156)] - Mortal156(::core::primitive::u8), - #[codec(index = 157)] - Mortal157(::core::primitive::u8), - #[codec(index = 158)] - Mortal158(::core::primitive::u8), - #[codec(index = 159)] - Mortal159(::core::primitive::u8), - #[codec(index = 160)] - Mortal160(::core::primitive::u8), - #[codec(index = 161)] - Mortal161(::core::primitive::u8), - #[codec(index = 162)] - Mortal162(::core::primitive::u8), - #[codec(index = 163)] - Mortal163(::core::primitive::u8), - #[codec(index = 164)] - Mortal164(::core::primitive::u8), - #[codec(index = 165)] - Mortal165(::core::primitive::u8), - #[codec(index = 166)] - Mortal166(::core::primitive::u8), - #[codec(index = 167)] - Mortal167(::core::primitive::u8), - #[codec(index = 168)] - Mortal168(::core::primitive::u8), - #[codec(index = 169)] - Mortal169(::core::primitive::u8), - #[codec(index = 170)] - Mortal170(::core::primitive::u8), - #[codec(index = 171)] - Mortal171(::core::primitive::u8), - #[codec(index = 172)] - Mortal172(::core::primitive::u8), - #[codec(index = 173)] - Mortal173(::core::primitive::u8), - #[codec(index = 174)] - Mortal174(::core::primitive::u8), - #[codec(index = 175)] - Mortal175(::core::primitive::u8), - #[codec(index = 176)] - Mortal176(::core::primitive::u8), - #[codec(index = 177)] - Mortal177(::core::primitive::u8), - #[codec(index = 178)] - Mortal178(::core::primitive::u8), - #[codec(index = 179)] - Mortal179(::core::primitive::u8), - #[codec(index = 180)] - Mortal180(::core::primitive::u8), - #[codec(index = 181)] - Mortal181(::core::primitive::u8), - #[codec(index = 182)] - Mortal182(::core::primitive::u8), - #[codec(index = 183)] - Mortal183(::core::primitive::u8), - #[codec(index = 184)] - Mortal184(::core::primitive::u8), - #[codec(index = 185)] - Mortal185(::core::primitive::u8), - #[codec(index = 186)] - Mortal186(::core::primitive::u8), - #[codec(index = 187)] - Mortal187(::core::primitive::u8), - #[codec(index = 188)] - Mortal188(::core::primitive::u8), - #[codec(index = 189)] - Mortal189(::core::primitive::u8), - #[codec(index = 190)] - Mortal190(::core::primitive::u8), - #[codec(index = 191)] - Mortal191(::core::primitive::u8), - #[codec(index = 192)] - Mortal192(::core::primitive::u8), - #[codec(index = 193)] - Mortal193(::core::primitive::u8), - #[codec(index = 194)] - Mortal194(::core::primitive::u8), - #[codec(index = 195)] - Mortal195(::core::primitive::u8), - #[codec(index = 196)] - Mortal196(::core::primitive::u8), - #[codec(index = 197)] - Mortal197(::core::primitive::u8), - #[codec(index = 198)] - Mortal198(::core::primitive::u8), - #[codec(index = 199)] - Mortal199(::core::primitive::u8), - #[codec(index = 200)] - Mortal200(::core::primitive::u8), - #[codec(index = 201)] - Mortal201(::core::primitive::u8), - #[codec(index = 202)] - Mortal202(::core::primitive::u8), - #[codec(index = 203)] - Mortal203(::core::primitive::u8), - #[codec(index = 204)] - Mortal204(::core::primitive::u8), - #[codec(index = 205)] - Mortal205(::core::primitive::u8), - #[codec(index = 206)] - Mortal206(::core::primitive::u8), - #[codec(index = 207)] - Mortal207(::core::primitive::u8), - #[codec(index = 208)] - Mortal208(::core::primitive::u8), - #[codec(index = 209)] - Mortal209(::core::primitive::u8), - #[codec(index = 210)] - Mortal210(::core::primitive::u8), - #[codec(index = 211)] - Mortal211(::core::primitive::u8), - #[codec(index = 212)] - Mortal212(::core::primitive::u8), - #[codec(index = 213)] - Mortal213(::core::primitive::u8), - #[codec(index = 214)] - Mortal214(::core::primitive::u8), - #[codec(index = 215)] - Mortal215(::core::primitive::u8), - #[codec(index = 216)] - Mortal216(::core::primitive::u8), - #[codec(index = 217)] - Mortal217(::core::primitive::u8), - #[codec(index = 218)] - Mortal218(::core::primitive::u8), - #[codec(index = 219)] - Mortal219(::core::primitive::u8), - #[codec(index = 220)] - Mortal220(::core::primitive::u8), - #[codec(index = 221)] - Mortal221(::core::primitive::u8), - #[codec(index = 222)] - Mortal222(::core::primitive::u8), - #[codec(index = 223)] - Mortal223(::core::primitive::u8), - #[codec(index = 224)] - Mortal224(::core::primitive::u8), - #[codec(index = 225)] - Mortal225(::core::primitive::u8), - #[codec(index = 226)] - Mortal226(::core::primitive::u8), - #[codec(index = 227)] - Mortal227(::core::primitive::u8), - #[codec(index = 228)] - Mortal228(::core::primitive::u8), - #[codec(index = 229)] - Mortal229(::core::primitive::u8), - #[codec(index = 230)] - Mortal230(::core::primitive::u8), - #[codec(index = 231)] - Mortal231(::core::primitive::u8), - #[codec(index = 232)] - Mortal232(::core::primitive::u8), - #[codec(index = 233)] - Mortal233(::core::primitive::u8), - #[codec(index = 234)] - Mortal234(::core::primitive::u8), - #[codec(index = 235)] - Mortal235(::core::primitive::u8), - #[codec(index = 236)] - Mortal236(::core::primitive::u8), - #[codec(index = 237)] - Mortal237(::core::primitive::u8), - #[codec(index = 238)] - Mortal238(::core::primitive::u8), - #[codec(index = 239)] - Mortal239(::core::primitive::u8), - #[codec(index = 240)] - Mortal240(::core::primitive::u8), - #[codec(index = 241)] - Mortal241(::core::primitive::u8), - #[codec(index = 242)] - Mortal242(::core::primitive::u8), - #[codec(index = 243)] - Mortal243(::core::primitive::u8), - #[codec(index = 244)] - Mortal244(::core::primitive::u8), - #[codec(index = 245)] - Mortal245(::core::primitive::u8), - #[codec(index = 246)] - Mortal246(::core::primitive::u8), - #[codec(index = 247)] - Mortal247(::core::primitive::u8), - #[codec(index = 248)] - Mortal248(::core::primitive::u8), - #[codec(index = 249)] - Mortal249(::core::primitive::u8), - #[codec(index = 250)] - Mortal250(::core::primitive::u8), - #[codec(index = 251)] - Mortal251(::core::primitive::u8), - #[codec(index = 252)] - Mortal252(::core::primitive::u8), - #[codec(index = 253)] - Mortal253(::core::primitive::u8), - #[codec(index = 254)] - Mortal254(::core::primitive::u8), - #[codec(index = 255)] - Mortal255(::core::primitive::u8), - } - } - pub mod header { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Header<_0> { - pub parent_hash: ::subxt::utils::H256, - #[codec(compact)] - pub number: _0, - pub state_root: ::subxt::utils::H256, - pub extrinsics_root: ::subxt::utils::H256, - pub digest: runtime_types::sp_runtime::generic::digest::Digest, - } - } - } - pub mod transaction_validity { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum InvalidTransaction { - #[codec(index = 0)] - Call, - #[codec(index = 1)] - Payment, - #[codec(index = 2)] - Future, - #[codec(index = 3)] - Stale, - #[codec(index = 4)] - BadProof, - #[codec(index = 5)] - AncientBirthBlock, - #[codec(index = 6)] - ExhaustsResources, - #[codec(index = 7)] - Custom(::core::primitive::u8), - #[codec(index = 8)] - BadMandatory, - #[codec(index = 9)] - MandatoryValidation, - #[codec(index = 10)] - BadSigner, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TransactionSource { - #[codec(index = 0)] - InBlock, - #[codec(index = 1)] - Local, - #[codec(index = 2)] - External, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TransactionValidityError { - #[codec(index = 0)] - Invalid(runtime_types::sp_runtime::transaction_validity::InvalidTransaction), - #[codec(index = 1)] - Unknown(runtime_types::sp_runtime::transaction_validity::UnknownTransaction), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum UnknownTransaction { - #[codec(index = 0)] - CannotLookup, - #[codec(index = 1)] - NoUnsignedValidator, - #[codec(index = 2)] - Custom(::core::primitive::u8), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidTransaction { - pub priority: ::core::primitive::u64, - pub requires: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub provides: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub longevity: ::core::primitive::u64, - pub propagate: ::core::primitive::bool, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DispatchError { - #[codec(index = 0)] - Other, - #[codec(index = 1)] - CannotLookup, - #[codec(index = 2)] - BadOrigin, - #[codec(index = 3)] - Module(runtime_types::sp_runtime::ModuleError), - #[codec(index = 4)] - ConsumerRemaining, - #[codec(index = 5)] - NoProviders, - #[codec(index = 6)] - TooManyConsumers, - #[codec(index = 7)] - Token(runtime_types::sp_runtime::TokenError), - #[codec(index = 8)] - Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), - #[codec(index = 9)] - Transactional(runtime_types::sp_runtime::TransactionalError), - #[codec(index = 10)] - Exhausted, - #[codec(index = 11)] - Corruption, - #[codec(index = 12)] - Unavailable, - #[codec(index = 13)] - RootNotAllowed, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ModuleError { - pub index: ::core::primitive::u8, - pub error: [::core::primitive::u8; 4usize], - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiSignature { - #[codec(index = 0)] - Ed25519(runtime_types::sp_core::ed25519::Signature), - #[codec(index = 1)] - Sr25519(runtime_types::sp_core::sr25519::Signature), - #[codec(index = 2)] - Ecdsa(runtime_types::sp_core::ecdsa::Signature), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TokenError { - #[codec(index = 0)] - FundsUnavailable, - #[codec(index = 1)] - OnlyProvider, - #[codec(index = 2)] - BelowMinimum, - #[codec(index = 3)] - CannotCreate, - #[codec(index = 4)] - UnknownAsset, - #[codec(index = 5)] - Frozen, - #[codec(index = 6)] - Unsupported, - #[codec(index = 7)] - CannotCreateHold, - #[codec(index = 8)] - NotExpendable, - #[codec(index = 9)] - Blocked, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TransactionalError { - #[codec(index = 0)] - LimitReached, - #[codec(index = 1)] - NoLayer, - } - } - pub mod sp_trie { - use super::runtime_types; - pub mod storage_proof { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct StorageProof { - pub trie_nodes: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - } - } - } - pub mod sp_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RuntimeVersion { - pub spec_name: ::std::string::String, - pub impl_name: ::std::string::String, - pub authoring_version: ::core::primitive::u32, - pub spec_version: ::core::primitive::u32, - pub impl_version: ::core::primitive::u32, - pub apis: - ::std::vec::Vec<([::core::primitive::u8; 8usize], ::core::primitive::u32)>, - pub transaction_version: ::core::primitive::u32, - pub state_version: ::core::primitive::u8, - } - } - pub mod sp_weights { - use super::runtime_types; - pub mod weight_v2 { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Weight { - #[codec(compact)] - pub ref_time: ::core::primitive::u64, - #[codec(compact)] - pub proof_size: ::core::primitive::u64, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RuntimeDbWeight { - pub read: ::core::primitive::u64, - pub write: ::core::primitive::u64, - } - } - pub mod staging_parachain_info { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call {} - } - } - pub mod staging_xcm { - use super::runtime_types; - pub mod v3 { - use super::runtime_types; - pub mod multilocation { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::xcm::v3::junctions::Junctions, - } - } - } - pub mod v4 { - use super::runtime_types; - pub mod asset { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Asset { - pub id: runtime_types::staging_xcm::v4::asset::AssetId, - pub fun: runtime_types::staging_xcm::v4::asset::Fungibility, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetFilter { - #[codec(index = 0)] - Definite(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 1)] - Wild(runtime_types::staging_xcm::v4::asset::WildAsset), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssetId(pub runtime_types::staging_xcm::v4::location::Location); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Assets( - pub ::std::vec::Vec, - ); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::staging_xcm::v4::asset::AssetInstance), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::staging_xcm::v4::asset::AssetId, - fun: runtime_types::staging_xcm::v4::asset::WildFungibility, - }, - #[codec(index = 2)] - AllCounted(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - AllOfCounted { - id: runtime_types::staging_xcm::v4::asset::AssetId, - fun: runtime_types::staging_xcm::v4::asset::WildFungibility, - #[codec(compact)] - count: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - } - pub mod junction { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: ::core::option::Option< - runtime_types::staging_xcm::v4::junction::NetworkId, - >, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: ::core::option::Option< - runtime_types::staging_xcm::v4::junction::NetworkId, - >, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: ::core::option::Option< - runtime_types::staging_xcm::v4::junction::NetworkId, - >, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey { - length: ::core::primitive::u8, - data: [::core::primitive::u8; 32usize], - }, - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v3::junction::BodyId, - part: runtime_types::xcm::v3::junction::BodyPart, - }, - #[codec(index = 9)] - GlobalConsensus(runtime_types::staging_xcm::v4::junction::NetworkId), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum NetworkId { - #[codec(index = 0)] - ByGenesis([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - ByFork { - block_number: ::core::primitive::u64, - block_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - #[codec(index = 4)] - Westend, - #[codec(index = 5)] - Rococo, - #[codec(index = 6)] - Wococo, - #[codec(index = 7)] - Ethereum { - #[codec(compact)] - chain_id: ::core::primitive::u64, - }, - #[codec(index = 8)] - BitcoinCore, - #[codec(index = 9)] - BitcoinCash, - #[codec(index = 10)] - PolkadotBulletin, - } - } - pub mod junctions { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1([runtime_types::staging_xcm::v4::junction::Junction; 1usize]), - #[codec(index = 2)] - X2([runtime_types::staging_xcm::v4::junction::Junction; 2usize]), - #[codec(index = 3)] - X3([runtime_types::staging_xcm::v4::junction::Junction; 3usize]), - #[codec(index = 4)] - X4([runtime_types::staging_xcm::v4::junction::Junction; 4usize]), - #[codec(index = 5)] - X5([runtime_types::staging_xcm::v4::junction::Junction; 5usize]), - #[codec(index = 6)] - X6([runtime_types::staging_xcm::v4::junction::Junction; 6usize]), - #[codec(index = 7)] - X7([runtime_types::staging_xcm::v4::junction::Junction; 7usize]), - #[codec(index = 8)] - X8([runtime_types::staging_xcm::v4::junction::Junction; 8usize]), - } - } - pub mod location { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Location { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::staging_xcm::v4::junctions::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Outcome { - #[codec(index = 0)] - Complete { used: runtime_types::sp_weights::weight_v2::Weight }, - #[codec(index = 1)] - Incomplete { - used: runtime_types::sp_weights::weight_v2::Weight, - error: runtime_types::xcm::v3::traits::Error, - }, - #[codec(index = 2)] - Error { error: runtime_types::xcm::v3::traits::Error }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v4::Response, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - beneficiary: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v4::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::staging_xcm::v4::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - beneficiary: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v4::asset::AssetFilter, - want: runtime_types::staging_xcm::v4::asset::Assets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - reserve: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v4::asset::Asset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v4::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v4::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - ticket: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 29)] - ExpectAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::staging_xcm::v4::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::staging_xcm::v4::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::staging_xcm::v4::junction::NetworkId, - destination: runtime_types::staging_xcm::v4::junctions::Junctions, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::staging_xcm::v4::asset::Asset, - unlocker: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::staging_xcm::v4::asset::Asset, - target: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::staging_xcm::v4::asset::Asset, - owner: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::staging_xcm::v4::asset::Asset, - locker: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v4::location::Location), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v4::Response, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - beneficiary: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v4::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::staging_xcm::v4::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - beneficiary: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v4::asset::AssetFilter, - want: runtime_types::staging_xcm::v4::asset::Assets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - reserve: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v4::asset::Asset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v4::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v4::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - ticket: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 29)] - ExpectAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::staging_xcm::v4::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::staging_xcm::v4::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::staging_xcm::v4::junction::NetworkId, - destination: runtime_types::staging_xcm::v4::junctions::Junctions, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::staging_xcm::v4::asset::Asset, - unlocker: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::staging_xcm::v4::asset::Asset, - target: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::staging_xcm::v4::asset::Asset, - owner: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::staging_xcm::v4::asset::Asset, - locker: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v4::location::Location), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PalletInfo { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - #[codec(compact)] - pub major: ::core::primitive::u32, - #[codec(compact)] - pub minor: ::core::primitive::u32, - #[codec(compact)] - pub patch: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryResponseInfo { - pub destination: runtime_types::staging_xcm::v4::location::Location, - #[codec(compact)] - pub query_id: ::core::primitive::u64, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - #[codec(index = 4)] - PalletsInfo( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::staging_xcm::v4::PalletInfo, - >, - ), - #[codec(index = 5)] - DispatchResult(runtime_types::xcm::v3::MaybeErrorCode), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm(pub ::std::vec::Vec); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm2(pub ::std::vec::Vec); - } - } - pub mod xcm { - use super::runtime_types; - pub mod double_encoded { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DoubleEncoded { - pub encoded: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DoubleEncoded2 { - pub encoded: ::std::vec::Vec<::core::primitive::u8>, - } - } - pub mod v2 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: runtime_types::xcm::v2::NetworkId, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: runtime_types::xcm::v2::NetworkId, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: runtime_types::xcm::v2::NetworkId, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v2::BodyId, - part: runtime_types::xcm::v2::BodyPart, - }, - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::xcm::v2::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract(::std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - #[codec(index = 6)] - Blob(::std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::xcm::v2::multiasset::AssetInstance), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiAsset { - pub id: runtime_types::xcm::v2::multiasset::AssetId, - pub fun: runtime_types::xcm::v2::multiasset::Fungibility, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::xcm::v2::multiasset::WildMultiAsset), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiAssets( - pub ::std::vec::Vec, - ); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::xcm::v2::multiasset::AssetId, - fun: runtime_types::xcm::v2::multiasset::WildFungibility, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::xcm::v2::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::xcm::v2::multilocation::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - MultiLocationFull, - #[codec(index = 5)] - MultiLocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - UnhandledXcmVersion, - #[codec(index = 23)] - WeightLimitReached(::core::primitive::u64), - #[codec(index = 24)] - Barrier, - #[codec(index = 25)] - WeightNotComputable, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v2::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v2::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v2::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v2::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum NetworkId { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum OriginKind { - #[codec(index = 0)] - Native, - #[codec(index = 1)] - SovereignAccount, - #[codec(index = 2)] - Superuser, - #[codec(index = 3)] - Xcm, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v2::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(#[codec(compact)] ::core::primitive::u64), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm(pub ::std::vec::Vec); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm2(pub ::std::vec::Vec); - } - pub mod v3 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Moniker([::core::primitive::u8; 4usize]), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: - ::core::option::Option, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: - ::core::option::Option, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: - ::core::option::Option, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey { - length: ::core::primitive::u8, - data: [::core::primitive::u8; 32usize], - }, - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v3::junction::BodyId, - part: runtime_types::xcm::v3::junction::BodyPart, - }, - #[codec(index = 9)] - GlobalConsensus(runtime_types::xcm::v3::junction::NetworkId), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum NetworkId { - #[codec(index = 0)] - ByGenesis([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - ByFork { - block_number: ::core::primitive::u64, - block_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - #[codec(index = 4)] - Westend, - #[codec(index = 5)] - Rococo, - #[codec(index = 6)] - Wococo, - #[codec(index = 7)] - Ethereum { - #[codec(compact)] - chain_id: ::core::primitive::u64, - }, - #[codec(index = 8)] - BitcoinCore, - #[codec(index = 9)] - BitcoinCash, - #[codec(index = 10)] - PolkadotBulletin, - } - } - pub mod junctions { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::xcm::v3::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract([::core::primitive::u8; 32usize]), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::xcm::v3::multiasset::AssetInstance), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiAsset { - pub id: runtime_types::xcm::v3::multiasset::AssetId, - pub fun: runtime_types::xcm::v3::multiasset::Fungibility, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::xcm::v3::multiasset::WildMultiAsset), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiAssets( - pub ::std::vec::Vec, - ); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::xcm::v3::multiasset::AssetId, - fun: runtime_types::xcm::v3::multiasset::WildFungibility, - }, - #[codec(index = 2)] - AllCounted(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - AllOfCounted { - id: runtime_types::xcm::v3::multiasset::AssetId, - fun: runtime_types::xcm::v3::multiasset::WildFungibility, - #[codec(compact)] - count: ::core::primitive::u32, - }, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - LocationFull, - #[codec(index = 5)] - LocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - ExpectationFalse, - #[codec(index = 23)] - PalletNotFound, - #[codec(index = 24)] - NameMismatch, - #[codec(index = 25)] - VersionIncompatible, - #[codec(index = 26)] - HoldingWouldOverflow, - #[codec(index = 27)] - ExportError, - #[codec(index = 28)] - ReanchorFailed, - #[codec(index = 29)] - NoDeal, - #[codec(index = 30)] - FeesNotMet, - #[codec(index = 31)] - LockError, - #[codec(index = 32)] - NoPermission, - #[codec(index = 33)] - Unanchored, - #[codec(index = 34)] - NotDepositable, - #[codec(index = 35)] - UnhandledXcmVersion, - #[codec(index = 36)] - WeightLimitReached(runtime_types::sp_weights::weight_v2::Weight), - #[codec(index = 37)] - Barrier, - #[codec(index = 38)] - WeightNotComputable, - #[codec(index = 39)] - ExceedsStackLimit, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v3::Response, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v3::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - want: runtime_types::xcm::v3::multiasset::MultiAssets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::xcm::v3::QueryResponseInfo, - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v3::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v3::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v3::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 29)] - ExpectAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::xcm::v3::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::xcm::v3::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::xcm::v3::junction::NetworkId, - destination: runtime_types::xcm::v3::junctions::Junctions, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v3::Response, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v3::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - want: runtime_types::xcm::v3::multiasset::MultiAssets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::xcm::v3::QueryResponseInfo, - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v3::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v3::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v3::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 29)] - ExpectAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::xcm::v3::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::xcm::v3::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::xcm::v3::junction::NetworkId, - destination: runtime_types::xcm::v3::junctions::Junctions, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MaybeErrorCode { - #[codec(index = 0)] - Success, - #[codec(index = 1)] - Error( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - TruncatedError( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PalletInfo { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - #[codec(compact)] - pub major: ::core::primitive::u32, - #[codec(compact)] - pub minor: ::core::primitive::u32, - #[codec(compact)] - pub patch: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryResponseInfo { - pub destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - #[codec(compact)] - pub query_id: ::core::primitive::u64, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - #[codec(index = 4)] - PalletsInfo( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::xcm::v3::PalletInfo, - >, - ), - #[codec(index = 5)] - DispatchResult(runtime_types::xcm::v3::MaybeErrorCode), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(runtime_types::sp_weights::weight_v2::Weight), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm(pub ::std::vec::Vec); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm2(pub ::std::vec::Vec); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedAssetId { - #[codec(index = 3)] - V3(runtime_types::xcm::v3::multiasset::AssetId), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::asset::AssetId), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedAssets { - #[codec(index = 1)] - V2(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::asset::Assets), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedLocation { - #[codec(index = 1)] - V2(runtime_types::xcm::v2::multilocation::MultiLocation), - #[codec(index = 3)] - V3(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::location::Location), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedResponse { - #[codec(index = 2)] - V2(runtime_types::xcm::v2::Response), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::Response), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::Response), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedXcm { - #[codec(index = 2)] - V2(runtime_types::xcm::v2::Xcm), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::Xcm), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::Xcm), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedXcm2 { - #[codec(index = 2)] - V2(runtime_types::xcm::v2::Xcm2), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::Xcm2), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::Xcm2), - } - } - } +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! Coretime parachain runtime metadata. +//! +//! The data type here is generated by the subxt tool and represents the event-related data of the coretime parachain. +//! +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub enum CoreAssignment { + #[codec(index = 0)] + Idle, + #[codec(index = 1)] + Pool, + #[codec(index = 2)] + Task(u32), +} + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct CoreAssigned { + pub core: u16, + pub when: u32, + pub assignment: Vec<(CoreAssignment, u16)>, +} + +impl subxt::events::StaticEvent for CoreAssigned { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "CoreAssigned"; +} + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct CoreMask(pub [u8; 10usize]); + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct RegionId { + pub begin: u32, + pub core: u16, + pub mask: CoreMask, +} + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct Assigned { + pub region_id: RegionId, + pub duration: u32, + pub task: u32, +} + +impl ::subxt::events::StaticEvent for Assigned { + const PALLET: &'static str = "Broker"; + const EVENT: &'static str = "Assigned"; } diff --git a/client/coretime/common/Cargo.toml b/client/coretime/common/Cargo.toml index ef8b15c..d9d4a4d 100644 --- a/client/coretime/common/Cargo.toml +++ b/client/coretime/common/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "mc-coretime-common" -authors = ["Anonymous"] +authors = ["Magnet"] description = "magnet-coretime" license = "Apache License 2.0" homepage = "https://magnet.magport.io/" diff --git a/client/coretime/common/src/lib.rs b/client/coretime/common/src/lib.rs index 6c9ff84..3ba3c4b 100644 --- a/client/coretime/common/src/lib.rs +++ b/client/coretime/common/src/lib.rs @@ -13,36 +13,25 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -use codec::{Codec, Decode}; -use cumulus_primitives_core::BlockT; + +//! Coretime common function of client. +//! + +use codec::Decode; use cumulus_primitives_core::ParaId; use cumulus_relay_chain_interface::RelayChainInterface; use mp_coretime_common::well_known_keys::paras_para_lifecycles; -use pallet_broker::RegionRecord; -use pallet_broker::{CoreMask, RegionId}; -use polkadot_primitives::AccountId; -use polkadot_primitives::Balance; -use runtime_parachains::{configuration::HostConfiguration, paras::ParaLifecycle}; -use sc_client_api::UsageProvider; -use sc_service::TaskManager; -use sp_api::ProvideRuntimeApi; -use sp_core::crypto::{ByteArray, Pair}; -use sp_core::H256; +use runtime_parachains::paras::ParaLifecycle; +use sp_core::{ + crypto::{ByteArray, Pair}, + H256, +}; use sp_keystore::KeystorePtr; -use sp_state_machine::StorageProof; -use sp_storage::StorageKey; use std::error::Error; -use std::sync::Arc; -use subxt::client::OfflineClientT; -use subxt::{ - backend::{legacy::LegacyRpcMethods, rpc::RpcClient}, - config::polkadot::PolkadotExtrinsicParamsBuilder as Params, - tx::Signer, - utils::MultiSignature, - Config, OnlineClient, PolkadotConfig, -}; + type AuthorityId

=

::Public; +/// Is it now a parathread. pub async fn is_parathread( relay_chain: impl RelayChainInterface + Clone, p_hash: H256, @@ -66,6 +55,7 @@ pub async fn is_parathread( Ok(is_parathread) } +/// Randomly select a collator to place an order. pub async fn order_slot( idx: u32, authorities: &[AuthorityId

], diff --git a/node/src/service.rs b/node/src/service.rs index 412e52b..1e0ed41 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -500,7 +500,6 @@ async fn start_node_impl( relay_chain_interface.clone(), &task_manager, bulk_mem_record.clone(), - params.keystore_container.keystore().clone(), )?; start_consensus( client.clone(), diff --git a/pallets/bulk/Cargo.toml b/pallets/bulk/Cargo.toml index db6da54..637ef19 100644 --- a/pallets/bulk/Cargo.toml +++ b/pallets/bulk/Cargo.toml @@ -19,7 +19,7 @@ hex-literal = { workspace = true } # Local mp-coretime-bulk = { path = "../../primitives/coretime/bulk", default-features = false } -dp-chain-state-snapshot = { path = "../../primitives/chain-state-snapshot", default-features = false} +mp-coretime-common = { path = "../../primitives/coretime/common", default-features = false} # Cumulus cumulus-pallet-parachain-system = { workspace = true, default-features = false} @@ -85,7 +85,7 @@ std = [ "sp-trie/std", "pallet-balances/std", "sp-core/std", - "dp-chain-state-snapshot/std", + "mp-coretime-common/std", "pallet-broker/std", ] try-runtime = [ diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index c70c80d..69cf8a0 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -14,16 +14,10 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -//! # Order Pallet +//! # Bulk Pallet //! -//! This pallet implements the recording and query functions of purchasing ondemand core. +//! This pallet implements the recording and query functions of purchasing bulk core. //! -//! By obtaining the inherent nature of the block, parsing it out of the validation_data of the relaychain, -//! and querying whether there is an OnDemandOrderPlaced event, obtaining the order account and price from the event, -//! and then writing this record to the blockchain. -//! -//! Provides many query methods for node or other pallets to use, such as querying the gas consumed by placing an order in a certain block, -//! whether the order has been executed, whether the order threshold has been reached, etc. #![cfg_attr(not(feature = "std"), no_std)] use codec::{Decode, MaxEncodedLen}; @@ -44,7 +38,7 @@ use sp_runtime::sp_std::{prelude::*, vec}; use sp_runtime::{traits::Member, RuntimeAppPublic}; pub mod weights; use cumulus_pallet_parachain_system::RelaychainStateProvider; -use dp_chain_state_snapshot::GenericStateProof; +use mp_coretime_common::chain_state_snapshot::GenericStateProof; use pallet_broker::RegionRecord; use sp_core::crypto::ByteArray; use weights::WeightInfo; diff --git a/primitives/chain-state-snapshot/Cargo.toml b/primitives/chain-state-snapshot/Cargo.toml deleted file mode 100644 index eb20666..0000000 --- a/primitives/chain-state-snapshot/Cargo.toml +++ /dev/null @@ -1,24 +0,0 @@ -[package] -name = "dp-chain-state-snapshot" -authors = { workspace = true } -description = "Primitives related to chain state snapshot" -edition = "2021" -license = "GPL-3.0-only" -version = "0.1.0" - -[package.metadata.docs.rs] -targets = [ "x86_64-unknown-linux-gnu" ] -[dependencies] - -# Substrate -parity-scale-codec = { workspace = true } -sp-runtime = { workspace = true } -sp-state-machine = { workspace = true } -sp-trie = { workspace = true } - -# Cumulus -cumulus-primitives-core = { workspace = true } - -[features] -default = [ "std" ] -std = [ "cumulus-primitives-core/std", "parity-scale-codec/std", "sp-runtime/std", "sp-state-machine/std", "sp-trie/std" ] diff --git a/primitives/coretime/bulk/Cargo.toml b/primitives/coretime/bulk/Cargo.toml index b1719ce..2724931 100644 --- a/primitives/coretime/bulk/Cargo.toml +++ b/primitives/coretime/bulk/Cargo.toml @@ -3,8 +3,8 @@ name = "mp-coretime-bulk" authors.workspace = true description = "primitives related to bulk inherent" edition.workspace = true -license = "Unlicense" -version = "0.2.0" +license = "Apache-2.0" +version = "0.1.0" [dependencies] log = { workspace = true, default-features = false } diff --git a/primitives/coretime/bulk/src/inherent_client.rs b/primitives/coretime/bulk/src/inherent_client.rs index 3ad57b3..45ec087 100644 --- a/primitives/coretime/bulk/src/inherent_client.rs +++ b/primitives/coretime/bulk/src/inherent_client.rs @@ -14,15 +14,8 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -use crate::well_known_keys::broker_regions; -use cumulus_primitives_core::relay_chain::Balance; use pallet_broker::RegionId; -use sp_consensus_aura::sr25519::AuthorityId; -use { - crate::BulkInherentData, - cumulus_primitives_core::{ParaId, PersistedValidationData}, - cumulus_relay_chain_interface::{PHash, RelayChainInterface}, -}; +use {crate::BulkInherentData, cumulus_relay_chain_interface::PHash}; impl BulkInherentData { /// Create the [`BulkInherentData`] at the given `relay_parent`. diff --git a/primitives/coretime/bulk/src/lib.rs b/primitives/coretime/bulk/src/lib.rs index de7880d..259b6ba 100644 --- a/primitives/coretime/bulk/src/lib.rs +++ b/primitives/coretime/bulk/src/lib.rs @@ -14,26 +14,22 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -//! # Order Inherent Primitives +//! # Bulk Inherent Primitives //! //! This crate defines those primitives that should be taken into account when building -//! the order pallet inherent +//! the bulk pallet inherent //! #![cfg_attr(not(feature = "std"), no_std)] -use cumulus_primitives_core::{ - relay_chain::BlockNumber as RelayBlockNumber, relay_chain::Hash as PHash, ParaId, - PersistedValidationData, -}; -use sp_core::H256; +use cumulus_primitives_core::relay_chain::Hash as PHash; use sp_runtime::sp_std::vec::Vec; -use sp_runtime::traits::MaybeDisplay; #[cfg(feature = "std")] pub mod inherent_client; pub mod well_known_keys; -use codec::{Codec, Decode, Encode}; +use codec::{Decode, Encode}; use pallet_broker::RegionId; use {scale_info::TypeInfo, sp_inherents::InherentIdentifier}; +/// Inherent data of bulk mode. #[derive(Encode, Decode, sp_core::RuntimeDebug, Clone, PartialEq, TypeInfo)] pub struct BulkInherentData { /// Proof of coretime parachain storage. @@ -73,18 +69,22 @@ pub struct BulkMemRecord { pub start_relaychain_height: u32, /// Relaychain block number of end schedule coretime core. pub end_relaychain_height: u32, + /// Coretime duration. pub duration: u32, + /// Status of bulk record. pub status: BulkStatus, } -// Identifier of the order inherent +// Identifier of the bulk inherent pub const INHERENT_IDENTIFIER: InherentIdentifier = *b"bulkihrt"; sp_api::decl_runtime_apis! { #[api_version(2)] pub trait BulkRuntimeApi { + // Rpc url of coretime parachain. fn rpc_url() -> Vec; + // Block number of relaychain. fn relaychain_block_number()->u32; } } diff --git a/primitives/coretime/bulk/src/well_known_keys.rs b/primitives/coretime/bulk/src/well_known_keys.rs index 952c190..b2d98bf 100644 --- a/primitives/coretime/bulk/src/well_known_keys.rs +++ b/primitives/coretime/bulk/src/well_known_keys.rs @@ -17,14 +17,7 @@ //! Keys of well known. #![cfg_attr(not(feature = "std"), no_std)] -use cumulus_primitives_core::relay_chain::CoreIndex; -use { - cumulus_primitives_core::ParaId, - pallet_broker::RegionId, - sp_core::Encode, - sp_io::hashing::{blake2_128, twox_256, twox_64}, - sp_std::vec::Vec, -}; +use {pallet_broker::RegionId, sp_core::Encode, sp_io::hashing::blake2_128, sp_std::vec::Vec}; // XXHash a String:Broker Regions pub const REGIONS: &[u8] = diff --git a/primitives/coretime/common/Cargo.toml b/primitives/coretime/common/Cargo.toml index 23822f4..52fa023 100644 --- a/primitives/coretime/common/Cargo.toml +++ b/primitives/coretime/common/Cargo.toml @@ -1,10 +1,10 @@ [package] name = "mp-coretime-common" authors.workspace = true -description = "primitives related to coretime" +description = "common primitives related to coretime" edition.workspace = true -license = "Unlicense" -version = "0.2.0" +license = "Apache-2.0" +version = "0.1.0" [dependencies] log = { workspace = true, default-features = false } diff --git a/primitives/chain-state-snapshot/src/lib.rs b/primitives/coretime/common/src/chain_state_snapshot.rs similarity index 94% rename from primitives/chain-state-snapshot/src/lib.rs rename to primitives/coretime/common/src/chain_state_snapshot.rs index 30ce68a..94c25c4 100644 --- a/primitives/chain-state-snapshot/src/lib.rs +++ b/primitives/coretime/common/src/chain_state_snapshot.rs @@ -1,18 +1,18 @@ -// Copyright (C) Moondance Labs Ltd. -// This file is part of Tanssi. +// Copyright (C) Magnet. +// This file is part of Magnet. -// Tanssi is free software: you can redistribute it and/or modify +// Magnet is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. -// Tanssi is distributed in the hope that it will be useful, +// Magnet is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // You should have received a copy of the GNU General Public License -// along with Tanssi. If not, see +// along with Magnet. If not, see . //! # Chain Snapshot Primitives //! @@ -21,7 +21,7 @@ #![cfg_attr(not(feature = "std"), no_std)] use { - parity_scale_codec::Decode, + codec::Decode, sp_runtime::traits::HashingFor, sp_state_machine::{Backend, TrieBackend, TrieBackendBuilder}, sp_trie::{HashDBT, MemoryDB, StorageProof, EMPTY_PREFIX}, diff --git a/primitives/coretime/common/src/lib.rs b/primitives/coretime/common/src/lib.rs index 236265b..53b7ae3 100644 --- a/primitives/coretime/common/src/lib.rs +++ b/primitives/coretime/common/src/lib.rs @@ -14,10 +14,9 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -//! # Order Inherent Primitives +//! Common Magnet Primitives //! -//! This crate defines those primitives that should be taken into account when building -//! the order pallet inherent //! #![cfg_attr(not(feature = "std"), no_std)] +pub mod chain_state_snapshot; pub mod well_known_keys; From 418d65ee7507393a1de1c1e4d33a3942e05acafa Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sat, 29 Jun 2024 18:01:46 +0800 Subject: [PATCH 13/44] add bulk pallet comment , update bulk pallet code of create record, add bechmark function of create_record --- client/coretime/bulk/src/lib.rs | 3 +- pallets/bulk/Cargo.toml | 3 +- pallets/bulk/src/benchmarking.rs | 46 ++++++++++++- pallets/bulk/src/lib.rs | 115 +++++++++++++++++++------------ pallets/bulk/src/mock.rs | 3 +- pallets/bulk/src/tests.rs | 4 -- pallets/bulk/src/weights.rs | 38 ++++++++-- weights.rs | 69 +++++++++++++++++++ 8 files changed, 224 insertions(+), 57 deletions(-) create mode 100644 weights.rs diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index c4f11b9..37950b2 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -42,7 +42,6 @@ use sp_api::ProvideRuntimeApi; use sp_application_crypto::AppPublic; use sp_consensus_aura::AuraApi; use sp_core::{crypto::Pair, H256}; -use sp_keystore::KeystorePtr; use sp_runtime::traits::{Block as BlockT, Member}; use sp_state_machine::StorageProof; use std::{error::Error, sync::Arc}; @@ -64,7 +63,7 @@ fn u8_array_to_u128(array: [u8; 10]) -> u128 { pub async fn coretime_bulk_task( parachain: &P, relay_chain: R, - height: RelayBlockNumber, + _height: RelayBlockNumber, p_hash: H256, para_id: ParaId, bulk_record: Arc>, diff --git a/pallets/bulk/Cargo.toml b/pallets/bulk/Cargo.toml index 637ef19..a21384f 100644 --- a/pallets/bulk/Cargo.toml +++ b/pallets/bulk/Cargo.toml @@ -15,6 +15,7 @@ targets = ["x86_64-unknown-linux-gnu"] codec = { package = "parity-scale-codec", workspace = true, features = ["derive"], default-features = false } scale-info = { workspace = true, default-features = false, features = ["derive"] } log = { workspace = true, default-features = false } +hex = { workspace = true } hex-literal = { workspace = true } # Local @@ -43,7 +44,7 @@ pallet-broker = { workspace = true, default-features = false } [dev-dependencies] serde = { workspace = true } codec = { workspace = true, features = ["derive"], default-features = false } -hex = { workspace = true, default-features = false } +hex = { workspace = true } # Substrate sp-core = { workspace = true, default-features = false} diff --git a/pallets/bulk/src/benchmarking.rs b/pallets/bulk/src/benchmarking.rs index 2344657..cbecad3 100644 --- a/pallets/bulk/src/benchmarking.rs +++ b/pallets/bulk/src/benchmarking.rs @@ -20,10 +20,54 @@ use super::*; #[allow(unused)] use crate::Pallet as Bulk; -use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller}; +use frame_benchmarking::{benchmarks, impl_benchmark_test_suite}; use frame_system::RawOrigin; +use pallet_broker::{CoreMask, RegionId}; + +mod test_sproof { + use sp_trie::StorageProof; + #[derive(Clone, Default)] + pub struct ParaHeaderSproofBuilder { + pub num_items: usize, + } + + impl ParaHeaderSproofBuilder { + pub fn into_state_root_and_proof( + self, + ) -> (cumulus_primitives_core::relay_chain::Hash, StorageProof) { + let encoded = crate::proof_data::STORAGE_ROOT[self.num_items]; + + let root = hex::decode(encoded).unwrap(); + let proof = StorageProof::new( + crate::proof_data::STORAGE_PROOF.iter().map(|s| hex::decode(s).unwrap()), + ); + + (<[u8; 32]>::try_from(root).unwrap().into(), proof) + } + } +} benchmarks! { + create_record { + let s in 0..100; + let mut sproof_builder = test_sproof::ParaHeaderSproofBuilder::default(); + sproof_builder.num_items = 0; + + let (storage_root, coretime_chain_state_proof) = sproof_builder.into_state_root_and_proof(); + let core_mask = CoreMask::from(0xFFFFFFFFFFFFFFFFFFFF); + let region_id = RegionId { begin: 12, core: 1, mask: core_mask }; + let bulk_inherent_data = mp_coretime_bulk::BulkInherentData { + storage_proof: Some(coretime_chain_state_proof), + storage_root, + region_id, + start_relaychain_height: 120, + end_relaychain_height: 220, + }; + }: _(RawOrigin::None, bulk_inherent_data) + verify { + assert_eq!(RecordIndex::::get(), 1); + } + set_rpc_url { let s in 0 .. 100; let url = BoundedVec::try_from("ws://127.0.0.1:8855".as_bytes().to_vec()).unwrap(); diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index 69cf8a0..bbe06df 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -21,29 +21,27 @@ #![cfg_attr(not(feature = "std"), no_std)] use codec::{Decode, MaxEncodedLen}; -use cumulus_pallet_parachain_system::{ - relay_state_snapshot::Error as Relay_Error, RelayChainStateProof, -}; +use cumulus_pallet_parachain_system::RelaychainStateProvider; use frame_support::{ dispatch::DispatchResultWithPostInfo, dispatch::PostDispatchInfo, pallet_prelude::*, traits::Currency, }; use frame_system::pallet_prelude::*; -use frame_system::{self, EventRecord}; -use mp_coretime_bulk::well_known_keys::{broker_regions, REGIONS}; -pub use pallet::*; -use primitives::Balance; -use primitives::{Id as ParaId, PersistedValidationData}; -use sp_runtime::sp_std::{prelude::*, vec}; -use sp_runtime::{traits::Member, RuntimeAppPublic}; -pub mod weights; -use cumulus_pallet_parachain_system::RelaychainStateProvider; +use mp_coretime_bulk::well_known_keys::broker_regions; use mp_coretime_common::chain_state_snapshot::GenericStateProof; +pub use pallet::*; use pallet_broker::RegionRecord; -use sp_core::crypto::ByteArray; +use primitives::Balance; +use sp_runtime::{ + sp_std::{prelude::*, vec}, + traits::Member, + RuntimeAppPublic, +}; use weights::WeightInfo; + #[cfg(test)] mod mock; +pub mod weights; #[cfg(test)] mod tests; @@ -55,7 +53,7 @@ mod proof_data; type BalanceOf = <::Currency as Currency<::AccountId>>::Balance; -/// ondemand order information. +/// Purchase coretime information. #[derive(Encode, Decode, Default, Clone, Copy, TypeInfo, MaxEncodedLen, Debug)] pub struct BulkRecord { /// Account for purchase. @@ -112,11 +110,12 @@ pub mod pallet { 0 } + /// The index of the record, plus one for each additional record. #[pallet::storage] #[pallet::getter(fn record_index)] pub type RecordIndex = StorageValue<_, u32, ValueQuery, RecordIndexOnEmpty>; - /// Order Information Map. + /// Bulk purchase Information Map. #[pallet::storage] #[pallet::getter(fn bulk_records)] pub type BulkRecords = @@ -144,20 +143,35 @@ pub mod pallet { #[pallet::event] #[pallet::generate_deposit(pub(super) fn deposit_event)] pub enum Event { - /// Create order event. - OrderCreate { sequence_number: u64, orderer: T::AuthorityId }, + /// Create record event. + RecordCreated { + /// Account for purchase. + purchaser: T::AuthorityId, + /// Purchase price. + price: BalanceOf, + /// Purchase duration. + duration: u32, + /// Relaychain block number of start schedule coretime core. + start_relaychain_height: u32, + /// Relaychain block number of end schedule coretime core. + end_relaychain_height: u32, + }, } #[pallet::error] pub enum Error { /// Error reading data. FailedReading, + /// Storage proof is none. + ProofNone, + /// Create root proof failed. + FailedCreateProof, + /// Purchaser is none. + PurchaserNone, } #[pallet::hooks] - impl Hooks> for Pallet { - fn on_finalize(block_number: BlockNumberFor) {} - } + impl Hooks> for Pallet {} #[pallet::inherent] impl ProvideInherent for Pallet { @@ -187,14 +201,14 @@ pub mod pallet { #[pallet::call] impl Pallet { - /// Create an order, which is called by the pallet. + /// Create an bulk record, which is called by the pallet. /// Users cannot actively call this function. - /// Obtain order information by parsing inherited data. + /// Obtain record information by parsing inherited data. /// /// Parameters: /// - `data`: The inherent data. #[pallet::call_index(0)] - #[pallet::weight((0, DispatchClass::Mandatory))] + #[pallet::weight((::WeightInfo::create_record(1), DispatchClass::Mandatory))] pub fn create_record( origin: OriginFor, data: mp_coretime_bulk::BulkInherentData, @@ -202,36 +216,51 @@ pub mod pallet { ensure_none(origin)?; let mp_coretime_bulk::BulkInherentData { - storage_proof, + storage_proof: p_storage_proof, storage_root, region_id, start_relaychain_height, end_relaychain_height, } = data; - let relay_storage_rooted_proof: GenericStateProof< + let storage_proof = p_storage_proof.ok_or(Error::::ProofNone)?; + // Create coretime parachain root proof + let storage_rooted_proof: GenericStateProof< cumulus_primitives_core::relay_chain::Block, - > = GenericStateProof::new(storage_root, storage_proof.unwrap()).unwrap(); + > = GenericStateProof::new(storage_root, storage_proof) + .map_err(|_| Error::::FailedCreateProof)?; + let key = broker_regions(region_id); - let region_record_data = relay_storage_rooted_proof + // Read RegionRecord from proof. + let region_record = storage_rooted_proof .read_entry::>>(key.as_slice(), None) - .ok(); - if let Some(region_record) = region_record_data { - let old_record_index = RecordIndex::::get(); - BulkRecords::::insert( - old_record_index, - BulkRecord::, T::AuthorityId> { - purchaser: region_record.owner, - price: region_record.paid.unwrap(), - duration: region_record.end, - start_relaychain_height, - end_relaychain_height, - }, - ); - RecordIndex::::set(old_record_index + 1); - } + .ok() + .ok_or(Error::::FailedReading)?; + + let old_record_index = RecordIndex::::get(); + let balance = region_record.paid.ok_or(Error::::PurchaserNone)?; + let purchaser = region_record.owner; + // Create record of purchase coretime. + BulkRecords::::insert( + old_record_index, + BulkRecord::, T::AuthorityId> { + purchaser: purchaser.clone(), + price: balance, + duration: region_record.end, + start_relaychain_height, + end_relaychain_height, + }, + ); + RecordIndex::::set(old_record_index + 1); + Self::deposit_event(Event::RecordCreated { + purchaser, + price: balance, + duration: region_record.end, + start_relaychain_height, + end_relaychain_height, + }); - let total_weight = T::DbWeight::get().reads_writes(2, 1); + let total_weight = T::WeightInfo::create_record(1); Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) } diff --git a/pallets/bulk/src/mock.rs b/pallets/bulk/src/mock.rs index ecec2e9..b93f58e 100644 --- a/pallets/bulk/src/mock.rs +++ b/pallets/bulk/src/mock.rs @@ -15,7 +15,6 @@ // along with Magnet. If not, see . use crate::{self as bulk_pallet, BulkGasCost}; -use codec::Encode; use cumulus_pallet_parachain_system::{RelayChainState, RelaychainStateProvider}; pub use frame_support::{ construct_runtime, derive_impl, parameter_types, @@ -137,7 +136,7 @@ where T::AccountId: From<[u8; 32]>, { fn gas_cost( - block_number: BlockNumberFor, + _block_number: BlockNumberFor, ) -> Result, sp_runtime::DispatchError> { Ok(None) } diff --git a/pallets/bulk/src/tests.rs b/pallets/bulk/src/tests.rs index 0f5c3d2..8477a0f 100644 --- a/pallets/bulk/src/tests.rs +++ b/pallets/bulk/src/tests.rs @@ -16,16 +16,12 @@ use crate::mock::*; use crate::proof_data::{STORAGE_PROOF, STORAGE_ROOT}; -use codec::Decode; -use cumulus_primitives_core::{ParaId, PersistedValidationData}; use frame_support::{ inherent::{InherentData, ProvideInherent}, traits::UnfilteredDispatchable, }; use frame_system::RawOrigin; use pallet_broker::{CoreMask, RegionId}; -use parachains_common::AccountId; -use primitives::HeadData; use sp_trie::StorageProof; #[test] diff --git a/pallets/bulk/src/weights.rs b/pallets/bulk/src/weights.rs index 0c6bf90..dd99c4a 100644 --- a/pallets/bulk/src/weights.rs +++ b/pallets/bulk/src/weights.rs @@ -36,10 +36,28 @@ use core::marker::PhantomData; /// Weight functions needed for pallet. pub trait WeightInfo { fn set_rpc_url() -> Weight; + fn create_record(s: u32, ) -> Weight; } /// Weight functions for `pallet_bulk`. pub struct SubstrateWeight(PhantomData); impl WeightInfo for SubstrateWeight { + /// Storage: `BulkPallet::RecordIndex` (r:1 w:1) + /// Proof: `BulkPallet::RecordIndex` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `BulkPallet::BulkRecords` (r:0 w:1) + /// Proof: `BulkPallet::BulkRecords` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn create_record(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `147` + // Estimated: `1489` + // Minimum execution time: 30_127_000 picoseconds. + Weight::from_parts(33_526_304, 0) + .saturating_add(Weight::from_parts(0, 1489)) + // Standard Error: 1_136 + .saturating_add(Weight::from_parts(2_315, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } /// Storage: `BulkPallet::RpcUrl` (r:0 w:1) /// Proof: `BulkPallet::RpcUrl` (`max_values`: Some(1), `max_size`: Some(302), added: 797, mode: `MaxEncodedLen`) /// The range of component `s` is `[0, 100]`. @@ -47,20 +65,32 @@ impl WeightInfo for SubstrateWeight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_486_000 picoseconds. - Weight::from_parts(4_089_957, 0) + // Minimum execution time: 4_729_000 picoseconds. + Weight::from_parts(5_325_688, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } } impl WeightInfo for () { + fn create_record(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `147` + // Estimated: `1489` + // Minimum execution time: 30_127_000 picoseconds. + Weight::from_parts(33_526_304, 0) + .saturating_add(Weight::from_parts(0, 1489)) + // Standard Error: 1_136 + .saturating_add(Weight::from_parts(2_315, 0).saturating_mul(s.into())) + .saturating_add(RocksDbWeight::get().reads(1)) + .saturating_add(RocksDbWeight::get().writes(2)) + } fn set_rpc_url() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 3_486_000 picoseconds. - Weight::from_parts(4_089_957, 0) + // Minimum execution time: 4_729_000 picoseconds. + Weight::from_parts(5_325_688, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(RocksDbWeight::get().writes(1)) } diff --git a/weights.rs b/weights.rs new file mode 100644 index 0000000..fc08080 --- /dev/null +++ b/weights.rs @@ -0,0 +1,69 @@ + +//! Autogenerated weights for `pallet_bulk` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 +//! DATE: 2024-06-29, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `sulijia-PC`, CPU: `AMD Ryzen 7 5800U with Radeon Graphics` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// ./target/release/parachain-magnet-node +// benchmark +// pallet +// --chain +// dev +// --execution=wasm +// --wasm-execution=compiled +// --pallet +// pallet_bulk +// --extrinsic +// * +// --steps +// 50 +// --repeat +// 20 +// --output +// weights.rs + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; + +/// Weight functions for `pallet_bulk`. +pub struct WeightInfo(PhantomData); +impl pallet_bulk::WeightInfo for WeightInfo { + /// Storage: `BulkPallet::RecordIndex` (r:1 w:1) + /// Proof: `BulkPallet::RecordIndex` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `BulkPallet::BulkRecords` (r:0 w:1) + /// Proof: `BulkPallet::BulkRecords` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn create_record(s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `147` + // Estimated: `1489` + // Minimum execution time: 30_127_000 picoseconds. + Weight::from_parts(33_526_304, 0) + .saturating_add(Weight::from_parts(0, 1489)) + // Standard Error: 1_136 + .saturating_add(Weight::from_parts(2_315, 0).saturating_mul(s.into())) + .saturating_add(T::DbWeight::get().reads(1)) + .saturating_add(T::DbWeight::get().writes(2)) + } + /// Storage: `BulkPallet::RpcUrl` (r:0 w:1) + /// Proof: `BulkPallet::RpcUrl` (`max_values`: Some(1), `max_size`: Some(302), added: 797, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn set_rpc_url(_s: u32, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_729_000 picoseconds. + Weight::from_parts(5_325_688, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(1)) + } +} From 693fa29990262aa3927d105cb920c432d7784648 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sun, 30 Jun 2024 17:35:15 +0800 Subject: [PATCH 14/44] Added a function to check whether the genesis block hash of the coretime parachain is consistent, can record bulk purchase repeatedly --- client/coretime/bulk/src/lib.rs | 196 +++++++++--------- node/src/chain_spec.rs | 3 +- node/src/service.rs | 51 +++-- pallets/bulk/src/benchmarking.rs | 6 +- pallets/bulk/src/lib.rs | 42 +++- pallets/bulk/src/mock.rs | 12 ++ pallets/bulk/src/proof_data.rs | 19 +- pallets/bulk/src/tests.rs | 10 +- pallets/bulk/src/weights.rs | 44 ++-- primitives/coretime/bulk/src/lib.rs | 12 +- .../coretime/common/src/well_known_keys.rs | 21 ++ weights.rs | 69 ------ 12 files changed, 254 insertions(+), 231 deletions(-) delete mode 100644 weights.rs diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 37950b2..1e5d064 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -31,9 +31,12 @@ use cumulus_relay_chain_interface::RelayChainInterface; use futures::{lock::Mutex, pin_mut, select, FutureExt, StreamExt}; use mc_coretime_common::is_parathread; use mp_coretime_bulk::{ - self, well_known_keys::broker_regions, BulkMemRecord, BulkRuntimeApi, BulkStatus, + self, well_known_keys::broker_regions, BulkMemRecord, BulkMemRecordItem, BulkRuntimeApi, + BulkStatus, +}; +use mp_coretime_common::{ + chain_state_snapshot::GenericStateProof, well_known_keys::SYSTEM_BLOCKHASH_GENESIS, }; -use mp_coretime_common::chain_state_snapshot::GenericStateProof; use pallet_broker::{CoreMask, RegionId, RegionRecord}; use polkadot_primitives::{AccountId, Balance}; use sc_client_api::UsageProvider; @@ -87,7 +90,6 @@ where let mut bulk_record_local = bulk_record.lock().await; - let bulk_status = bulk_record_local.status.clone(); // Get the final block of the coretime parachain through subxt. let url = parachain.runtime_api().rpc_url(hash)?; @@ -111,102 +113,110 @@ where let events = block.events().await?; for event in events.iter() { let event = event?; - // Init status is Purchased,assume that a user has already purchased coretime. - if bulk_status == BulkStatus::Purchased { - // Query Broker Assigned Event - let ev_assigned = event.as_event::(); - - if let Ok(assigned_event) = ev_assigned { - if let Some(ev) = assigned_event { - log::info!( - "Find Assigned event:{:?},{:?},{:?}", - ev.region_id, - ev.task, - ev.duration - ); - - let pid: u32 = para_id.into(); - - if ev.task == pid { - // Call rpc state_getReadProof. - let rpc_client = RpcClient::from_url(rpc_url).await?; - - let rpc = LegacyRpcMethods::::new(rpc_client.clone()); - - let mask = u8_array_to_u128(ev.region_id.mask.0); - - let core_mask = CoreMask::from(mask); - - let region_id = RegionId { - begin: ev.region_id.begin, - core: ev.region_id.core, - mask: core_mask, + // Query Broker Assigned Event + let ev_assigned = event.as_event::(); + + if let Ok(assigned_event) = ev_assigned { + if let Some(ev) = assigned_event { + log::info!( + "=====================Find Assigned event:{:?},{:?},{:?}================", + ev.region_id, + ev.task, + ev.duration + ); + + let pid: u32 = para_id.into(); + + if ev.task == pid { + // Call rpc state_getReadProof. + let rpc_client = RpcClient::from_url(rpc_url).await?; + + let rpc = LegacyRpcMethods::::new(rpc_client.clone()); + + let mask = u8_array_to_u128(ev.region_id.mask.0); + + let core_mask = CoreMask::from(mask); + + let region_id = RegionId { + begin: ev.region_id.begin, + core: ev.region_id.core, + mask: core_mask, + }; + + let region_key = broker_regions(region_id); + // coretime parachain genesis hash key + let block_hash_key = SYSTEM_BLOCKHASH_GENESIS; + let mut relevant_keys = Vec::new(); + relevant_keys.push(region_key.as_slice()); + relevant_keys.push(block_hash_key); + + let proof = rpc + .state_get_read_proof(relevant_keys, Some(events.block_hash())) + .await + .unwrap(); + let storage_proof = + StorageProof::new(proof.proof.into_iter().map(|bytes| bytes.to_vec())); + + let storage_root = block.header().state_root; + // Create coretime parachain storage root proof. + let relay_storage_rooted_proof: GenericStateProof< + cumulus_primitives_core::relay_chain::Block, + > = GenericStateProof::new(storage_root, storage_proof.clone()).unwrap(); + + let head_data = relay_storage_rooted_proof + .read_entry::>(region_key.as_slice(), None) + .ok(); + // Check proof is ok. + if head_data.is_some() { + // Record some data. + let record_item = BulkMemRecordItem { + storage_proof, + storage_root, + region_id, + duration: ev.duration, + status: BulkStatus::Assigned, + start_relaychain_height: 0, + end_relaychain_height: 0, }; - - let key = broker_regions(region_id); - - let mut relevant_keys = Vec::new(); - relevant_keys.push(key.as_slice()); - - let proof = rpc - .state_get_read_proof(relevant_keys, Some(events.block_hash())) - .await - .unwrap(); - let storage_proof = - StorageProof::new(proof.proof.into_iter().map(|bytes| bytes.to_vec())); - - let storage_root = block.header().state_root; - // Create coretime parachain storage root proof. - let relay_storage_rooted_proof: GenericStateProof< - cumulus_primitives_core::relay_chain::Block, - > = GenericStateProof::new(storage_root, storage_proof.clone()).unwrap(); - - let head_data = relay_storage_rooted_proof - .read_entry::>(key.as_slice(), None) - .ok(); - // Check proof is ok. - if head_data.is_some() { - bulk_record_local.storage_proof = storage_proof; - bulk_record_local.storage_root = storage_root; - bulk_record_local.region_id = region_id; - bulk_record_local.status = BulkStatus::Assigned; - bulk_record_local.duration = ev.duration; - } + bulk_record_local.items.push(record_item); } } continue; } } - // Should first record Assigned event info. - if bulk_status == BulkStatus::Assigned { - // Query CoreAssigned event. - let ev_core_assigned = event.as_event::(); - - if let Ok(core_assigned_event) = ev_core_assigned { - if let Some(ev) = core_assigned_event { - log::info!( - "Find CoreAssigned event: {:?},{:?},{:?}", - ev.core, - ev.when, - ev.assignment - ); - - for (core_assign, _) in ev.assignment { - if let metadata::CoreAssignment::Task(id) = core_assign { - let pid: u32 = para_id.into(); - if id == pid { - bulk_record_local.start_relaychain_height = ev.when; - - let constant_query = - subxt::dynamic::constant("Broker", "TimeslicePeriod"); - - let time_slice = - api.constants().at(&constant_query)?.to_value()?.context; - - bulk_record_local.end_relaychain_height = - ev.when + bulk_record_local.duration * time_slice; - // find it. - bulk_record_local.status = BulkStatus::CoreAssigned; + + // Query CoreAssigned event. + let ev_core_assigned = event.as_event::(); + + if let Ok(core_assigned_event) = ev_core_assigned { + if let Some(ev) = core_assigned_event { + log::info!( + "=====================Find CoreAssigned event: {:?},{:?},{:?}=================", + ev.core, + ev.when, + ev.assignment + ); + + for (core_assign, _) in ev.assignment { + if let metadata::CoreAssignment::Task(id) = core_assign { + let pid: u32 = para_id.into(); + if id == pid { + let items = &mut bulk_record_local.items; + for item in items { + if item.status == BulkStatus::Assigned { + item.start_relaychain_height = ev.when; + + let constant_query = + subxt::dynamic::constant("Broker", "TimeslicePeriod"); + + let time_slice = + api.constants().at(&constant_query)?.to_value()?.context; + + item.end_relaychain_height = + ev.when + item.duration * time_slice; + // find it. + item.status = BulkStatus::CoreAssigned; + } } } } diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index 1749e9a..cf1a7ab 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -283,7 +283,8 @@ fn testnet_genesis( "evm": { "accounts": evm_accounts }, "bulkPallet":{ - "rpcUrl": b"ws://127.0.0.1:8855".to_vec() + "rpcUrl": b"ws://127.0.0.1:8855".to_vec(), + "genesisHash": U256::from_str("0x4ea18c8f295ba903acbbed39c70ea0569cf1705fa954a537ffa3b8b7125eaf58").expect("internal U256 is valid; qed") }, }) } diff --git a/node/src/service.rs b/node/src/service.rs index 1e0ed41..6a1ac26 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -484,16 +484,8 @@ async fn start_node_impl( // order_record.clone(), // rpc_address, // )?; - let bulk_mem_record = Arc::new(Mutex::new(BulkMemRecord { - storage_proof: StorageProof::empty(), - storage_root: Default::default(), - coretime_para_height: 0, - region_id: 0u128.into(), - start_relaychain_height: 0, - end_relaychain_height: 0, - status: BulkStatus::Purchased, - duration: 0, - })); + let bulk_mem_record = + Arc::new(Mutex::new(BulkMemRecord { coretime_para_height: 0, items: Vec::new() })); spawn_bulk_task::<_, _, _, sp_consensus_aura::sr25519::AuthorityPair>( client.clone(), para_id, @@ -610,22 +602,39 @@ fn start_consensus( let bulk_mem_record_clone = bulk_mem_record.clone(); async move { let mut bulk_mem_record_clone_local = bulk_mem_record_clone.lock().await; - let storage_proof = - if bulk_mem_record_clone_local.status == BulkStatus::CoreAssigned { - Some(&bulk_mem_record_clone_local.storage_proof) - } else { - None - }; + let record_items = &mut bulk_mem_record_clone_local.items; + let item = record_items.iter().find(|item| item.status == BulkStatus::CoreAssigned); + let ( + storage_proof, + storage_root, + region_id, + start_relaychain_height, + end_relaychain_height, + ) = if let Some(item) = item { + ( + Some(&item.storage_proof), + item.storage_root, + item.region_id, + item.start_relaychain_height, + item.end_relaychain_height, + ) + } else { + (None, Default::default(), 0u128.into(), 0, 0) + }; let bulk_inherent = mp_coretime_bulk::BulkInherentData::create_at( storage_proof, - bulk_mem_record_clone_local.storage_root, - bulk_mem_record_clone_local.region_id, - bulk_mem_record_clone_local.start_relaychain_height, - bulk_mem_record_clone_local.end_relaychain_height, + storage_root, + region_id, + start_relaychain_height, + end_relaychain_height, ) .await; if storage_proof.is_some() { - bulk_mem_record_clone_local.status = BulkStatus::Purchased; + if let Some(pos) = + record_items.iter().position(|item| item.status == BulkStatus::CoreAssigned) + { + record_items.remove(pos); + } } let bulk_inherent = bulk_inherent.ok_or_else(|| { Box::::from( diff --git a/pallets/bulk/src/benchmarking.rs b/pallets/bulk/src/benchmarking.rs index cbecad3..cd88655 100644 --- a/pallets/bulk/src/benchmarking.rs +++ b/pallets/bulk/src/benchmarking.rs @@ -55,13 +55,13 @@ benchmarks! { let (storage_root, coretime_chain_state_proof) = sproof_builder.into_state_root_and_proof(); let core_mask = CoreMask::from(0xFFFFFFFFFFFFFFFFFFFF); - let region_id = RegionId { begin: 12, core: 1, mask: core_mask }; + let region_id = RegionId { begin: 13, core: 1, mask: core_mask }; let bulk_inherent_data = mp_coretime_bulk::BulkInherentData { storage_proof: Some(coretime_chain_state_proof), storage_root, region_id, - start_relaychain_height: 120, - end_relaychain_height: 220, + start_relaychain_height: 130, + end_relaychain_height: 170, }; }: _(RawOrigin::None, bulk_inherent_data) verify { diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index bbe06df..7917900 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -22,13 +22,16 @@ #![cfg_attr(not(feature = "std"), no_std)] use codec::{Decode, MaxEncodedLen}; use cumulus_pallet_parachain_system::RelaychainStateProvider; +use cumulus_primitives_core::relay_chain::Hash as PHash; use frame_support::{ dispatch::DispatchResultWithPostInfo, dispatch::PostDispatchInfo, pallet_prelude::*, traits::Currency, }; use frame_system::pallet_prelude::*; use mp_coretime_bulk::well_known_keys::broker_regions; -use mp_coretime_common::chain_state_snapshot::GenericStateProof; +use mp_coretime_common::{ + chain_state_snapshot::GenericStateProof, well_known_keys::SYSTEM_BLOCKHASH_GENESIS, +}; pub use pallet::*; use pallet_broker::RegionRecord; use primitives::Balance; @@ -115,6 +118,11 @@ pub mod pallet { #[pallet::getter(fn record_index)] pub type RecordIndex = StorageValue<_, u32, ValueQuery, RecordIndexOnEmpty>; + /// Coretime parachain genesis block hash,for check. + #[pallet::storage] + #[pallet::getter(fn genesis_hash)] + pub type GenesisHash = StorageValue<_, PHash, ValueQuery>; + /// Bulk purchase Information Map. #[pallet::storage] #[pallet::getter(fn bulk_records)] @@ -124,12 +132,17 @@ pub mod pallet { #[pallet::genesis_config] pub struct GenesisConfig { pub rpc_url: BoundedVec, + pub genesis_hash: PHash, pub _marker: PhantomData, } impl Default for GenesisConfig { fn default() -> Self { - Self { rpc_url: BoundedVec::new(), _marker: Default::default() } + Self { + rpc_url: BoundedVec::new(), + genesis_hash: Default::default(), + _marker: Default::default(), + } } } @@ -137,6 +150,7 @@ pub mod pallet { impl BuildGenesisConfig for GenesisConfig { fn build(&self) { RpcUrl::::put(&self.rpc_url); + GenesisHash::::put(&self.genesis_hash); } } @@ -168,6 +182,8 @@ pub mod pallet { FailedCreateProof, /// Purchaser is none. PurchaserNone, + /// Genesis hash inconsistency + GenesisHashInconsistency, } #[pallet::hooks] @@ -208,7 +224,7 @@ pub mod pallet { /// Parameters: /// - `data`: The inherent data. #[pallet::call_index(0)] - #[pallet::weight((::WeightInfo::create_record(1), DispatchClass::Mandatory))] + #[pallet::weight((::WeightInfo::create_record(), DispatchClass::Mandatory))] pub fn create_record( origin: OriginFor, data: mp_coretime_bulk::BulkInherentData, @@ -230,13 +246,27 @@ pub mod pallet { > = GenericStateProof::new(storage_root, storage_proof) .map_err(|_| Error::::FailedCreateProof)?; - let key = broker_regions(region_id); + let region_key = broker_regions(region_id); // Read RegionRecord from proof. let region_record = storage_rooted_proof - .read_entry::>>(key.as_slice(), None) + .read_entry::>>( + region_key.as_slice(), + None, + ) .ok() .ok_or(Error::::FailedReading)?; + let genesis_hash_key = SYSTEM_BLOCKHASH_GENESIS; + let genesis_hash = storage_rooted_proof + .read_entry::(genesis_hash_key, None) + .ok() + .ok_or(Error::::FailedReading)?; + + let stored_hash = GenesisHash::::get(); + if genesis_hash != stored_hash { + Err(Error::::GenesisHashInconsistency)?; + } + let old_record_index = RecordIndex::::get(); let balance = region_record.paid.ok_or(Error::::PurchaserNone)?; let purchaser = region_record.owner; @@ -260,7 +290,7 @@ pub mod pallet { end_relaychain_height, }); - let total_weight = T::WeightInfo::create_record(1); + let total_weight = T::WeightInfo::create_record(); Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) } diff --git a/pallets/bulk/src/mock.rs b/pallets/bulk/src/mock.rs index b93f58e..9629658 100644 --- a/pallets/bulk/src/mock.rs +++ b/pallets/bulk/src/mock.rs @@ -19,6 +19,7 @@ use cumulus_pallet_parachain_system::{RelayChainState, RelaychainStateProvider}; pub use frame_support::{ construct_runtime, derive_impl, parameter_types, traits::{Everything, Hooks}, + BoundedVec, }; use frame_system as system; use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; @@ -28,6 +29,7 @@ use sp_runtime::{ traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, BuildStorage, MultiSignature, }; +use std::str::FromStr; type Block = frame_system::mocking::MockBlock; type Signature = MultiSignature; @@ -184,6 +186,16 @@ impl ExtBuilder { pallet_balances::GenesisConfig:: { balances: self.balances } .assimilate_storage(&mut t) .unwrap(); + crate::GenesisConfig:: { + rpc_url: BoundedVec::try_from("ws://127.0.0.1:8855".as_bytes().to_vec()).unwrap(), + genesis_hash: H256::from_str( + "0x4ea18c8f295ba903acbbed39c70ea0569cf1705fa954a537ffa3b8b7125eaf58", + ) + .expect("internal U256 is valid; qed"), + _marker: Default::default(), + } + .assimilate_storage(&mut t) + .unwrap(); let mut ext = sp_io::TestExternalities::new(t); ext.execute_with(|| System::set_block_number(1)); ext diff --git a/pallets/bulk/src/proof_data.rs b/pallets/bulk/src/proof_data.rs index 93d41cd..5e4847f 100644 --- a/pallets/bulk/src/proof_data.rs +++ b/pallets/bulk/src/proof_data.rs @@ -16,13 +16,18 @@ #[allow(dead_code)] pub const STORAGE_PROOF: &[&str] = &[ -"16000000d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d01000e2707000000000000000000000000", -"3f2007d04ec0ed1186e131723f64ef181e1c0c0000000100ffffffffffffffffffff358b741885135ef388abcf1fffd8290678a3a09a9b044f19e46f900f5ffc052f", -"80202080c526dfbf4a65e5d298e8b6c1cdac88ca71fd54975b7c6421b42973529c8e122980b57459b0fad405fcc8486156b1470fbf5da3e704b1905743fa11c028b774b890", -"80bff88002196afa3517dd88d98df436d300706cba9f2508c809bdd2cb2b556869b52d6780c4f7d82fa54c259feb751f64d63cc93749ee0d1f597b163c528d28d137907e3580c0cdd088d3767a4996a380bac2a88c7741b45b4b928c47f8d6ea84536f37e8bf80d53186d94b57d88622a71b3f7734455caedbdd97140df7b5056af030a28c8b6580d6b012f7b6fe3aa5e92edd95403a941a475f81d169e337e28e3f858e31cda40e808bbfc9f2049917e614e48154e3514abd53eabf6abf9a03fbfa079216c2ad0c478009a2de8fe94fc80a905b30932d17cf3490b0e1c46450870631882c287a13dea680adaad05a15ff0002ee84c917bcdbb7d7e97da1921f09c236e613c8f67bf907f380d62b78e6c0701b9acd2abb83656deedca91088aebcd26bb1a763ef7dab77d47880e8cafbef50a072daa5de180d2be3869dcb1187f5fb62e391aa55d235ef772c38808a3d2f156da5d357a1a063bb1d300aaa8cde71a200bcbf86f7512e9640d42f3380ad26a440ead6e38e025ea27e4c61d8f74734893728e00f9d57eb4521e576ec97", -"9ecb50595177a3177648411a42aca0f53b2880ccfcb9650f1764ce72092cd8c2a9b2a237dee22b6a4b42facfbddc0d2dded2bc8038eaec222e3ad57272dadec1b6f8b33b1f2c831f3e1280662847bb6080e8d5ec80ab19bc967e9c7be013655549197002712b4e3cba3803c35236badc872fdf3f2f505f0e7b9012096b41c4eb3aaf947f6ea429080000805c4823a2c831fae207465959acd4250e8edb3b4c5f6ab6e4344aca3baa9eaf2280acc3fdd3a823110b0a67f332f6a4c2588c2e3a7bbba188464f4a28cfbd13b41f80deaed939d20f6089a99e8cf9a2d6fb1117bc1bfbe3592553bf1288fe2d59c6de", -"9f0dc63b0b76ffd6f80704a090da6f8719180080dc89902e909ee4918e5b69cf45cdf2dbc64681fc967849e20d901aa3baf97880806844f5ceff6f4e914d758565e90802e3739ed53e7b7c91727fcd10ce1bbb6d10", + "17000000d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d0180fe210a000000000000000000000000", + "3f200b323504c3b3848bed8d370741085ebd0d0000000100ffffffffffffffffffff605dd58eac6b750fec2e9a2b7d51f907ac6e597cf821d803ea7a7d087f9a1166", + "56def25cfda6ef3a00000000804ea18c8f295ba903acbbed39c70ea0569cf1705fa954a537ffa3b8b7125eaf58", + "8020208051fd1b7464b9f678a3723c3a7ba8b5df2f2a8d5d8ee97403ddae92dc20251f5a80361e7e2188aa97c1d5e890af773d90f0e69af961b36a1f58f907749c66f47cf2", + "8050c080f8fb4dcf097cd41b8f1f4f73244a136538105d56b0df1fc478f8c2cf2c75a2a980c026dbee7a58acee151804e6ce4c3c5ea311865e6613904300c81c3ae1d65c3d80f7de82deb14576e4714771fbe6b678b19c65daa2385da56335afabcc091a3f3f8008737357f273cd263608d4657760d166648f3cf079bc51e1574c78ad1b44d5ba", + "80900080d5e406a437accb251a4af90489463cf1e5b39dbd80d303a67f59801a908df93e485efd6c28836b9a28522dc924110cf4390401", + "80bff88002196afa3517dd88d98df436d300706cba9f2508c809bdd2cb2b556869b52d6780e8023f3f14c67d41708439bc84e4d1f3dabd2bf3943e8096aeb53d4562d159ec804c4928062634282ae7d1134b65ad238555fd3d5390f4eda40739fa54f5caa4db802f64fabd9528b954be7ea2218380e3691da752bc9f6d4b28b478ca131227aada806baa391ffb857e11e6bc78c859ba8978801dfd4ae0d55e52428c9037db41913a80b22efc5744e76c8c1fa014b654921f8e76618751384d91762c6edf6923e8c8c58009a2de8fe94fc80a905b30932d17cf3490b0e1c46450870631882c287a13dea68031b30197fae7c5066741c047230ea07700060bc5baf86a5c23d1feaf92e09c1380d62b78e6c0701b9acd2abb83656deedca91088aebcd26bb1a763ef7dab77d47880e8cafbef50a072daa5de180d2be3869dcb1187f5fb62e391aa55d235ef772c38808a3d2f156da5d357a1a063bb1d300aaa8cde71a200bcbf86f7512e9640d42f3380c144a65f766ed0333d82d0f2111c91b613e6ae86285bb9a9e98094f76197ceee", + "9e4704b568d21667356a5a050c118746f97e8057f3a78b102cd434017e961ac4e10f60173c14bc0164c173782d6b7d4cff32b48011b7638f3e317e1f339c2e3265eabedeac85c134b0f3346f91bb15167e4517e38002e58c62536cb075cbdcf307c0448c3a309155cf7bc60c2f901e8d3f3aeed85880f18de88d9879e81e2837fd28d51ef5a34d3fbdc3ae7908523516986cf562e8b380d359cf69f8ec1b3031ad1ea39f5e0040a228d6046a506441ceb58abe1c3db60d806768845f9a01bce1522bcfeab633684d56bad0617ab3d552795b5da2895a4b88808c586b963b483b65b6123c0b4f6f1033d2658dc5e535048524a2a62a9e764bdc80c3c0f531137f91d46b1e361f81aaa960aaf44497b9366b3ade167559b39e487b803206a12c65296d5d4234fdb71631f4a66cecef3242d82c881511e7587b116fa280caea5a883a68c9e9b55b7492fe35486d1e9ad7f9cc6edd440f508ec199bd2d4e8017b3e7d5aebae73fafadf0df8f9a9b038ea18779352650419f50378e753d441f809d5e54ce6ed371ca9c0ab3f7d643ff65807f57b337da8c96e26c42e3206e20fc", + "9ecb50595177a3177648411a42aca0f53b2880ccfcb9650f1764ce72092cd8c2a9b2a237dee22b6a4b42facfbddc0d2dded2bc8009df4623f1e23e55b53334b6b0c68a7ab0ed7179af3aea62b90df0c86012457380032beae5f6488a4f67e5ed589e8b72ce5ae67a45ae48cfbe5a0c63d12d278811505f0e7b9012096b41c4eb3aaf947f6ea42908000080c6eba7297ee9c9a41fb08c4ac298cead1396f7e151564694fc79b9ccd1ff9d82800cbe2ddb78363571b3257c2c9e06349bb431d070cef5072313aa998bcd486a3d809563ddab40a90438ad8c70ca61581cca4b277e523074f25e274618ee3276aff4", + "9f06aa394eea5630e07c48ae0c9558cef7398f806bd01fa850c5271eea78c4432cee595ff4d24a2a8ab95bf0f1e9a46d061e1032804f514d8ff349a6b66d808ae4afa5dc0d38168979fa277b3491d0778e8a959e11505f0e7b9012096b41c4eb3aaf947f6ea4290800004c5f0684a022a34dd8bfa2baaf44f172b710040180ccc7d2c4de07b1d69ae1134070c007b95d48b0d0532997cce8294bb5b3ed24f280386943c28a62c2250ae23cb05e09648e12dab440539b307af286007b5174d95b80a7f24047bafabe7d20fa9df4d78db2099554e58a7f6108b4f73bc54c9f5cc40c801c768e5c91d896d11cbb0acecdaf8a71935d6b3ccaa377bff0a7fafac8191c1780922705d90a6daea5a8592cc22c12d179834e65242de0c7443fce51c7e7fb5f93", + "9f0dc63b0b76ffd6f80704a090da6f871981008079abbe6d7d4e0e08f3dae2668aec9f8196f85ee33e1cb22d942c8f478bcb7ae680668e18a82053f6da614b8ed588405a21b7c15edca705e9de71f617f14418e422", ]; #[allow(dead_code)] pub const STORAGE_ROOT: &[&str] = - &["3fa15d051c9e13076dbfc98f5aaac3b60dc07f208c1dd652a1abb3a2badabcf1"]; + &["a2172874220b97c5dc50ab7bc93fda8a467bac6ee01c25f1a307fe82fb28806d"]; diff --git a/pallets/bulk/src/tests.rs b/pallets/bulk/src/tests.rs index 8477a0f..cc279b9 100644 --- a/pallets/bulk/src/tests.rs +++ b/pallets/bulk/src/tests.rs @@ -34,14 +34,14 @@ fn bulk_inherent_test() { let storage_root: cumulus_primitives_core::relay_chain::Hash = <[u8; 32]>::try_from(root).unwrap().into(); let core_mask = CoreMask::from(0xFFFFFFFFFFFFFFFFFFFF); - let region_id = RegionId { begin: 12, core: 1, mask: core_mask }; + let region_id = RegionId { begin: 13, core: 1, mask: core_mask }; let mut inherent_data = InherentData::default(); let bulk_inherent_data = mp_coretime_bulk::BulkInherentData { storage_proof: Some(coretime_chain_state_proof), storage_root, region_id, - start_relaychain_height: 120, - end_relaychain_height: 220, + start_relaychain_height: 130, + end_relaychain_height: 170, }; inherent_data .put_data(mp_coretime_bulk::INHERENT_IDENTIFIER, &bulk_inherent_data) @@ -53,7 +53,7 @@ fn bulk_inherent_test() { BulkPallet::on_finalize(1); assert_eq!(BulkPallet::record_index(), 1); let record = BulkPallet::bulk_records(0).unwrap(); - assert_eq!(record.start_relaychain_height, 120); - assert_eq!(record.end_relaychain_height, 220); + assert_eq!(record.start_relaychain_height, 130); + assert_eq!(record.end_relaychain_height, 170); }); } diff --git a/pallets/bulk/src/weights.rs b/pallets/bulk/src/weights.rs index dd99c4a..7728878 100644 --- a/pallets/bulk/src/weights.rs +++ b/pallets/bulk/src/weights.rs @@ -36,26 +36,26 @@ use core::marker::PhantomData; /// Weight functions needed for pallet. pub trait WeightInfo { fn set_rpc_url() -> Weight; - fn create_record(s: u32, ) -> Weight; + fn create_record() -> Weight; } /// Weight functions for `pallet_bulk`. pub struct SubstrateWeight(PhantomData); impl WeightInfo for SubstrateWeight { + /// Storage: `BulkPallet::GenesisHash` (r:1 w:0) + /// Proof: `BulkPallet::GenesisHash` (`max_values`: Some(1), `max_size`: Some(32), added: 527, mode: `MaxEncodedLen`) /// Storage: `BulkPallet::RecordIndex` (r:1 w:1) /// Proof: `BulkPallet::RecordIndex` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) /// Storage: `BulkPallet::BulkRecords` (r:0 w:1) /// Proof: `BulkPallet::BulkRecords` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) /// The range of component `s` is `[0, 100]`. - fn create_record(s: u32, ) -> Weight { + fn create_record() -> Weight { // Proof Size summary in bytes: - // Measured: `147` - // Estimated: `1489` - // Minimum execution time: 30_127_000 picoseconds. - Weight::from_parts(33_526_304, 0) - .saturating_add(Weight::from_parts(0, 1489)) - // Standard Error: 1_136 - .saturating_add(Weight::from_parts(2_315, 0).saturating_mul(s.into())) - .saturating_add(T::DbWeight::get().reads(1)) + // Measured: `199` + // Estimated: `1517` + // Minimum execution time: 39_063_000 picoseconds. + Weight::from_parts(42_640_056, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(T::DbWeight::get().reads(2)) .saturating_add(T::DbWeight::get().writes(2)) } /// Storage: `BulkPallet::RpcUrl` (r:0 w:1) @@ -65,32 +65,30 @@ impl WeightInfo for SubstrateWeight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_729_000 picoseconds. - Weight::from_parts(5_325_688, 0) + // Minimum execution time: 3_858_000 picoseconds. + Weight::from_parts(4_289_031, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(T::DbWeight::get().writes(1)) } } impl WeightInfo for () { - fn create_record(s: u32, ) -> Weight { + fn create_record() -> Weight { // Proof Size summary in bytes: - // Measured: `147` - // Estimated: `1489` - // Minimum execution time: 30_127_000 picoseconds. - Weight::from_parts(33_526_304, 0) - .saturating_add(Weight::from_parts(0, 1489)) - // Standard Error: 1_136 - .saturating_add(Weight::from_parts(2_315, 0).saturating_mul(s.into())) - .saturating_add(RocksDbWeight::get().reads(1)) + // Measured: `199` + // Estimated: `1517` + // Minimum execution time: 39_063_000 picoseconds. + Weight::from_parts(42_640_056, 0) + .saturating_add(Weight::from_parts(0, 1517)) + .saturating_add(RocksDbWeight::get().reads(2)) .saturating_add(RocksDbWeight::get().writes(2)) } fn set_rpc_url() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_729_000 picoseconds. - Weight::from_parts(5_325_688, 0) + // Minimum execution time: 3_858_000 picoseconds. + Weight::from_parts(4_289_031, 0) .saturating_add(Weight::from_parts(0, 0)) .saturating_add(RocksDbWeight::get().writes(1)) } diff --git a/primitives/coretime/bulk/src/lib.rs b/primitives/coretime/bulk/src/lib.rs index 259b6ba..24c3209 100644 --- a/primitives/coretime/bulk/src/lib.rs +++ b/primitives/coretime/bulk/src/lib.rs @@ -56,9 +56,7 @@ pub enum BulkStatus { } #[derive(Clone, Debug)] -pub struct BulkMemRecord { - /// Block height of coretime parachain. - pub coretime_para_height: u32, +pub struct BulkMemRecordItem { /// Proof of coretime parachain storage. pub storage_proof: sp_trie::StorageProof, /// Root of coretime parachain storage. @@ -75,6 +73,14 @@ pub struct BulkMemRecord { pub status: BulkStatus, } +#[derive(Clone, Debug)] +pub struct BulkMemRecord { + /// Block height of coretime parachain. + pub coretime_para_height: u32, + /// Record item. + pub items: Vec, +} + // Identifier of the bulk inherent pub const INHERENT_IDENTIFIER: InherentIdentifier = *b"bulkihrt"; diff --git a/primitives/coretime/common/src/well_known_keys.rs b/primitives/coretime/common/src/well_known_keys.rs index a8bb99e..aa9c7be 100644 --- a/primitives/coretime/common/src/well_known_keys.rs +++ b/primitives/coretime/common/src/well_known_keys.rs @@ -33,3 +33,24 @@ pub fn paras_para_lifecycles(para_id: ParaId) -> Vec { .collect() }) } + +// System pallet BlockHash block number 0 +pub const SYSTEM_BLOCKHASH_GENESIS: &[u8] = &hex_literal::hex![ + "26aa394eea5630e07c48ae0c9558cef7a44704b568d21667356a5a050c118746b4def25cfda6ef3a00000000" +]; + +// System pallet BlockHash +pub const SYSTEM_BLOCKHASH: &[u8] = + &hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef7a44704b568d21667356a5a050c118746"]; + +// System pallet BlockHash +pub fn chain_block_hash(block_number: u32) -> Vec { + block_number.using_encoded(|block_number: &[u8]| { + SYSTEM_BLOCKHASH + .iter() + .chain(twox_64(block_number).iter()) + .chain(block_number.iter()) + .cloned() + .collect() + }) +} diff --git a/weights.rs b/weights.rs deleted file mode 100644 index fc08080..0000000 --- a/weights.rs +++ /dev/null @@ -1,69 +0,0 @@ - -//! Autogenerated weights for `pallet_bulk` -//! -//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 32.0.0 -//! DATE: 2024-06-29, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` -//! WORST CASE MAP SIZE: `1000000` -//! HOSTNAME: `sulijia-PC`, CPU: `AMD Ryzen 7 5800U with Radeon Graphics` -//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 - -// Executed Command: -// ./target/release/parachain-magnet-node -// benchmark -// pallet -// --chain -// dev -// --execution=wasm -// --wasm-execution=compiled -// --pallet -// pallet_bulk -// --extrinsic -// * -// --steps -// 50 -// --repeat -// 20 -// --output -// weights.rs - -#![cfg_attr(rustfmt, rustfmt_skip)] -#![allow(unused_parens)] -#![allow(unused_imports)] -#![allow(missing_docs)] - -use frame_support::{traits::Get, weights::Weight}; -use core::marker::PhantomData; - -/// Weight functions for `pallet_bulk`. -pub struct WeightInfo(PhantomData); -impl pallet_bulk::WeightInfo for WeightInfo { - /// Storage: `BulkPallet::RecordIndex` (r:1 w:1) - /// Proof: `BulkPallet::RecordIndex` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `BulkPallet::BulkRecords` (r:0 w:1) - /// Proof: `BulkPallet::BulkRecords` (`max_values`: None, `max_size`: Some(72), added: 2547, mode: `MaxEncodedLen`) - /// The range of component `s` is `[0, 100]`. - fn create_record(s: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `147` - // Estimated: `1489` - // Minimum execution time: 30_127_000 picoseconds. - Weight::from_parts(33_526_304, 0) - .saturating_add(Weight::from_parts(0, 1489)) - // Standard Error: 1_136 - .saturating_add(Weight::from_parts(2_315, 0).saturating_mul(s.into())) - .saturating_add(T::DbWeight::get().reads(1)) - .saturating_add(T::DbWeight::get().writes(2)) - } - /// Storage: `BulkPallet::RpcUrl` (r:0 w:1) - /// Proof: `BulkPallet::RpcUrl` (`max_values`: Some(1), `max_size`: Some(302), added: 797, mode: `MaxEncodedLen`) - /// The range of component `s` is `[0, 100]`. - fn set_rpc_url(_s: u32, ) -> Weight { - // Proof Size summary in bytes: - // Measured: `0` - // Estimated: `0` - // Minimum execution time: 4_729_000 picoseconds. - Weight::from_parts(5_325_688, 0) - .saturating_add(Weight::from_parts(0, 0)) - .saturating_add(T::DbWeight::get().writes(1)) - } -} From 8f37da3a5edc93c6c6d059d817847efe0b2c8b34 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sun, 30 Jun 2024 20:13:23 +0800 Subject: [PATCH 15/44] resolved conflicts --- Cargo.lock | 3039 +++++++++++------ Cargo.toml | 10 +- node/Cargo.toml | 3 + node/src/chain_spec.rs | 13 +- node/src/rpc/mod.rs | 5 +- node/src/service.rs | 89 +- pallets/assets-bridge/src/lib.rs | 57 +- pallets/assets-bridge/src/mock.rs | 12 +- .../precompile/transfer-to-magnet/src/lib.rs | 25 +- .../precompile/transfer-to-magnet/src/mock.rs | 7 - .../transfer-to-magnet/src/tests.rs | 68 +- runtime/Cargo.toml | 10 +- runtime/src/lib.rs | 100 +- runtime/src/precompiles.rs | 18 +- 14 files changed, 2420 insertions(+), 1036 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index dd6212f..2bd4071 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -23,11 +23,11 @@ dependencies = [ [[package]] name = "addr2line" -version = "0.21.0" +version = "0.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" dependencies = [ - "gimli 0.28.1", + "gimli 0.29.0", ] [[package]] @@ -68,7 +68,7 @@ dependencies = [ "cipher 0.4.4", "ctr", "ghash", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -77,7 +77,7 @@ version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "891477e0c6a8957309ee5c45a6368af3ae14bb510732d2684ffa19af310920f9" dependencies = [ - "getrandom 0.2.14", + "getrandom 0.2.15", "once_cell", "version_check", ] @@ -89,7 +89,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" dependencies = [ "cfg-if", - "getrandom 0.2.14", + "getrandom 0.2.15", "once_cell", "version_check", "zerocopy", @@ -142,47 +142,48 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.13" +version = "0.6.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d96bd03f33fe50a863e394ee9718a706f988b9079b20c3784fb726e7678b62fb" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" dependencies = [ "anstyle", "anstyle-parse", "anstyle-query", "anstyle-wincon", "colorchoice", + "is_terminal_polyfill", "utf8parse", ] [[package]] name = "anstyle" -version = "1.0.6" +version = "1.0.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8901269c6307e8d93993578286ac0edf7f195079ffff5ebdeea6a59ffb7e36bc" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" [[package]] name = "anstyle-parse" -version = "0.2.3" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c75ac65da39e5fe5ab759307499ddad880d724eed2f6ce5b5e8a26f4f387928c" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.0.2" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e28923312444cdd728e4738b3f9c9cac739500909bb3d3c94b43551b16517648" +checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" dependencies = [ "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.2" +version = "3.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cd54b81ec8d6180e24654d0b371ad22fc3dd083b6ff8ba325b72e00c87660a7" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" dependencies = [ "anstyle", "windows-sys 0.52.0", @@ -190,9 +191,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f538837af36e6f6a9be0faa67f9a314f8119e4e4b5867c6ab40ed60360142519" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" [[package]] name = "approx" @@ -214,7 +215,7 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -501,7 +502,7 @@ dependencies = [ "ark-std", "digest 0.10.7", "rand_core 0.6.4", - "sha3", + "sha3 0.10.8", ] [[package]] @@ -512,9 +513,9 @@ checksum = "f52f63c5c1316a16a4b35eaac8b76a98248961a533f061684cb2a7cb0eafb6c6" [[package]] name = "array-bytes" -version = "6.2.2" +version = "6.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f840fb7195bcfc5e17ea40c26e5ce6d5b9ce5d584466e17703209657e459ae0" +checksum = "5d5dde061bd34119e902bbb2d9b90c5692635cf59fb91d582c2b68043f1b8293" [[package]] name = "arrayref" @@ -568,7 +569,7 @@ dependencies = [ "proc-macro2", "quote", "syn 1.0.109", - "synstructure", + "synstructure 0.12.6", ] [[package]] @@ -601,26 +602,25 @@ dependencies = [ [[package]] name = "async-channel" -version = "2.2.1" +version = "2.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "136d4d23bcc79e27423727b36823d86233aad06dfea531837b038394d11e9928" +checksum = "89b47800b0be77592da0afd425cc03468052844aff33b84e33cc696f64e77b6a" dependencies = [ "concurrent-queue", - "event-listener 5.3.0", - "event-listener-strategy 0.5.1", + "event-listener-strategy", "futures-core", "pin-project-lite 0.2.14", ] [[package]] name = "async-executor" -version = "1.11.0" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b10202063978b3351199d68f8b22c4e47e4b1b822f8d43fd862d5ea8c006b29a" +checksum = "c8828ec6e544c02b0d6691d21ed9f9218d0384a82542855073c2a3f58304aaf0" dependencies = [ "async-task", "concurrent-queue", - "fastrand 2.0.2", + "fastrand 2.1.0", "futures-lite 2.3.0", "slab", ] @@ -659,18 +659,18 @@ dependencies = [ [[package]] name = "async-io" -version = "2.3.2" +version = "2.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcccb0f599cfa2f8ace422d3555572f47424da5648a4382a9dd0310ff8210884" +checksum = "0d6baa8f0178795da0e71bc42c9e5d13261aac7ee549853162e66a241ba17964" dependencies = [ - "async-lock 3.3.0", + "async-lock 3.4.0", "cfg-if", "concurrent-queue", "futures-io", "futures-lite 2.3.0", "parking", - "polling 3.6.0", - "rustix 0.38.32", + "polling 3.7.2", + "rustix 0.38.34", "slab", "tracing", "windows-sys 0.52.0", @@ -687,12 +687,12 @@ dependencies = [ [[package]] name = "async-lock" -version = "3.3.0" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d034b430882f8381900d3fe6f0aaa3ad94f2cb4ac519b429692a1bc2dda4ae7b" +checksum = "ff6e472cdea888a4bd64f342f09b3f50e1886d32afe8df3d663c01140b811b18" dependencies = [ - "event-listener 4.0.3", - "event-listener-strategy 0.4.0", + "event-listener 5.3.1", + "event-listener-strategy", "pin-project-lite 0.2.14", ] @@ -720,33 +720,33 @@ dependencies = [ "cfg-if", "event-listener 3.1.0", "futures-lite 1.13.0", - "rustix 0.38.32", + "rustix 0.38.34", "windows-sys 0.48.0", ] [[package]] name = "async-signal" -version = "0.2.5" +version = "0.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e47d90f65a225c4527103a8d747001fc56e375203592b25ad103e1ca13124c5" +checksum = "794f185324c2f00e771cd9f1ae8b5ac68be2ca7abb129a87afd6e86d228bc54d" dependencies = [ - "async-io 2.3.2", - "async-lock 2.8.0", + "async-io 2.3.3", + "async-lock 3.4.0", "atomic-waker", "cfg-if", "futures-core", "futures-io", - "rustix 0.38.32", + "rustix 0.38.34", "signal-hook-registry", "slab", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "async-task" -version = "4.7.0" +version = "4.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbb36e985947064623dbd357f727af08ffd077f93d696782f3c56365fa2e2799" +checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de" [[package]] name = "async-trait" @@ -756,7 +756,7 @@ checksum = "c6fa2087f2753a7da8cc1c0dbfcf89579dd57458e36769de5ac750b4671737ca" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -793,6 +793,17 @@ version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" +[[package]] +name = "atty" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8" +dependencies = [ + "hermit-abi 0.1.19", + "libc", + "winapi", +] + [[package]] name = "auto_impl" version = "1.2.0" @@ -801,27 +812,27 @@ checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "autocfg" -version = "1.2.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1fdabc7756949593fe60f30ec81974b613357de856987752631dea1e3394c80" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "backtrace" -version = "0.3.71" +version = "0.3.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b05800d2e817c8b3b4b54abd461726265fa9789ae34330622f2db9ee696f9d" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" dependencies = [ - "addr2line 0.21.0", + "addr2line 0.22.0", "cc", "cfg-if", "libc", "miniz_oxide", - "object 0.32.2", + "object 0.36.1", "rustc-demangle", ] @@ -884,6 +895,24 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" +[[package]] +name = "bcs" +version = "0.1.4" +source = "git+https://github.com/eigerco/bcs.git?branch=master#850598d0cb128f10ecf4ce87ff94281ee46e6524" +dependencies = [ + "serde", +] + +[[package]] +name = "bcs" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85b6598a2f5d564fb7855dc6b06fd1c38cff5a72bd8b863a4d021938497b440a" +dependencies = [ + "serde", + "thiserror", +] + [[package]] name = "beef" version = "0.5.2" @@ -893,10 +922,29 @@ dependencies = [ "serde", ] +[[package]] +name = "better_any" +version = "0.2.0" +source = "git+https://github.com/eigerco/better_any.git?branch=main#a4a2ed0ead905e7acd46bdfc38d9f94f5e431bc4" +dependencies = [ + "better_typeid_derive", +] + +[[package]] +name = "better_typeid_derive" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3deeecb812ca5300b7d3f66f730cc2ebd3511c3d36c691dd79c165d5b19a26e3" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "binary-merkle-tree" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "hash-db", "log", @@ -923,13 +971,13 @@ dependencies = [ "lazy_static", "lazycell", "peeking_take_while", - "prettyplease 0.2.19", + "prettyplease 0.2.20", "proc-macro2", "quote", "regex", "rustc-hash", "shlex", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -959,9 +1007,18 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" + +[[package]] +name = "bitmaps" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "031043d04099746d8db04daf1fa424b2bc8bd69d92b25962dcde24da39ab64a2" +dependencies = [ + "typenum", +] [[package]] name = "bitvec" @@ -1048,7 +1105,7 @@ version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0940dc441f31689269e10ac70eb1002a3a1d3ad1390e030043662eb7fe4688b" dependencies = [ - "block-padding", + "block-padding 0.1.5", "byte-tools", "byteorder", "generic-array 0.12.4", @@ -1060,6 +1117,7 @@ version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" dependencies = [ + "block-padding 0.2.1", "generic-array 0.14.7", ] @@ -1081,20 +1139,23 @@ dependencies = [ "byte-tools", ] +[[package]] +name = "block-padding" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d696c370c750c948ada61c69a0ee2cbbb9c50b1019ddb86d9317157a99c2cae" + [[package]] name = "blocking" -version = "1.5.1" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a37913e8dc4ddcc604f0c6d3bf2887c995153af3611de9e23c352b44c1b9118" +checksum = "703f41c54fc768e63e091340b424302bb1c29ef4aa0c7f10fe849dfb114d29ea" dependencies = [ - "async-channel 2.2.1", - "async-lock 3.3.0", + "async-channel 2.3.1", "async-task", - "fastrand 2.0.2", "futures-io", "futures-lite 2.3.0", "piper", - "tracing", ] [[package]] @@ -1133,7 +1194,7 @@ dependencies = [ [[package]] name = "bp-xcm-bridge-hub-router" version = "0.6.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "scale-info", @@ -1156,6 +1217,16 @@ dependencies = [ "tinyvec", ] +[[package]] +name = "bstr" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" +dependencies = [ + "memchr", + "serde", +] + [[package]] name = "build-helper" version = "0.1.1" @@ -1185,9 +1256,9 @@ checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" [[package]] name = "bytemuck" -version = "1.15.0" +version = "1.16.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d6d68c57235a3a081186990eca2867354726650f42f7516ca50c28d6281fd15" +checksum = "b236fc92302c97ed75b38da1f4917b5cdda4984745740f153a5d3059e48d725e" [[package]] name = "byteorder" @@ -1224,9 +1295,9 @@ dependencies = [ [[package]] name = "camino" -version = "1.1.6" +version = "1.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c59e92b5a388f549b863a7bea62612c09f24c8393560709a54558a9abdfb3b9c" +checksum = "e0ec6b951b160caa93cc0c7b209e5a3bff7aae9062213451ac99493cd844c239" dependencies = [ "serde", ] @@ -1248,7 +1319,7 @@ checksum = "eee4243f1f26fc7a42710e7439c149e2b10b05472f88090acce52632f231a73a" dependencies = [ "camino", "cargo-platform", - "semver 1.0.22", + "semver 1.0.23", "serde", "serde_json", "thiserror", @@ -1262,12 +1333,13 @@ checksum = "fd6c0e7b807d60291f42f33f58480c0bfafe28ed08286446f45e463728cf9c1c" [[package]] name = "cc" -version = "1.0.94" +version = "1.0.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17f6e324229dc011159fcc089755d1e2e216a90d43a7dea6853ca740b84f35e7" +checksum = "2755ff20a1d93490d26ba33a6f092a38a508398a5320df5d4b3014fcccce9410" dependencies = [ "jobserver", "libc", + "once_cell", ] [[package]] @@ -1348,6 +1420,28 @@ dependencies = [ "windows-targets 0.52.5", ] +[[package]] +name = "chrono-tz" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93698b29de5e97ad0ae26447b344c482a7284c737d9ddc5f9e52b74a336671bb" +dependencies = [ + "chrono", + "chrono-tz-build", + "phf", +] + +[[package]] +name = "chrono-tz-build" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c088aee841df9c3041febbb73934cfc39708749bf96dc827e3359cd39ef11b1" +dependencies = [ + "parse-zoneinfo", + "phf", + "phf_codegen", +] + [[package]] name = "cid" version = "0.9.0" @@ -1392,9 +1486,9 @@ dependencies = [ [[package]] name = "clang-sys" -version = "1.7.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67523a3b4be3ce1989d607a828d036249522dd9c1c8de7f4dd2dae43a37369d1" +checksum = "0b023947811758c97c59bf9d1c188fd619ad4718dcaa767947df1cadb14f39f4" dependencies = [ "glob", "libc", @@ -1403,44 +1497,83 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.4" +version = "3.2.25" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ea181bf566f71cb9a5d17a59e1871af638180a18fb0035c92ae62b705207123" +dependencies = [ + "atty", + "bitflags 1.3.2", + "clap_derive 3.2.25", + "clap_lex 0.2.4", + "indexmap 1.9.3", + "once_cell", + "strsim 0.10.0", + "termcolor", + "textwrap", +] + +[[package]] +name = "clap" +version = "4.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bc066a67923782aa8515dbaea16946c5bcc5addbd668bb80af688e53e548a0" +checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" dependencies = [ "clap_builder", - "clap_derive", + "clap_derive 4.5.8", ] [[package]] name = "clap_builder" -version = "4.5.2" +version = "4.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae129e2e766ae0ec03484e609954119f123cc1fe650337e155d03b022f24f7b4" +checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" dependencies = [ "anstream", "anstyle", - "clap_lex", + "clap_lex 0.7.1", "strsim 0.11.1", "terminal_size", ] [[package]] name = "clap_derive" -version = "4.5.4" +version = "3.2.25" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae6371b8bdc8b7d3959e9cf7b22d4435ef3e79e138688421ec654acf8c81b008" +dependencies = [ + "heck 0.4.1", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "clap_derive" +version = "4.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "528131438037fd55894f62d6e9f068b8f45ac57ffa77517819645d10aed04f64" +checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" dependencies = [ "heck 0.5.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "clap_lex" -version = "0.7.0" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2850f2f5a82cbf437dd5af4d49848fbdfc27c157c3d010345776f952765261c5" +dependencies = [ + "os_str_bytes", +] + +[[package]] +name = "clap_lex" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98cc8fbded0c607b7ba9dd60cd98df59af97e84d24e49c8557331cfc26d301ce" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" [[package]] name = "coarsetime" @@ -1453,42 +1586,63 @@ dependencies = [ "wasm-bindgen", ] +[[package]] +name = "codespan" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3362992a0d9f1dd7c3d0e89e0ab2bb540b7a95fea8cd798090e758fda2899b5e" +dependencies = [ + "codespan-reporting", + "serde", +] + [[package]] name = "codespan-reporting" version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" dependencies = [ + "serde", "termcolor", "unicode-width", ] [[package]] name = "color-print" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a858372ff14bab9b1b30ea504f2a4bc534582aee3e42ba2d41d2a7baba63d5d" +checksum = "1ee543c60ff3888934877a5671f45494dd27ed4ba25c6670b9a7576b7ed7a8c0" dependencies = [ "color-print-proc-macro", ] [[package]] name = "color-print-proc-macro" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57e37866456a721d0a404439a1adae37a31be4e0055590d053dfe6981e05003f" +checksum = "77ff1a80c5f3cb1ca7c06ffdd71b6a6dd6d8f896c42141fbd43f50ed28dcdb93" dependencies = [ "nom", "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.68", ] [[package]] name = "colorchoice" -version = "1.0.0" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" + +[[package]] +name = "colored" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" +checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" +dependencies = [ + "lazy_static", + "windows-sys 0.48.0", +] [[package]] name = "comfy-table" @@ -1496,8 +1650,8 @@ version = "7.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b34115915337defe99b2aff5c2ce6771e5fbc4079f4b506301f5cf394c8452f7" dependencies = [ - "strum 0.26.2", - "strum_macros 0.26.2", + "strum 0.26.3", + "strum_macros 0.26.4", "unicode-width", ] @@ -1525,9 +1679,9 @@ checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" [[package]] name = "concurrent-queue" -version = "2.4.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d16048cd947b08fa32c24458a22f5dc5e835264f689f4f5653210c69fd107363" +checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973" dependencies = [ "crossbeam-utils", ] @@ -1566,7 +1720,7 @@ version = "0.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f9d839f2a20b0aee515dc581a6172f2321f96cab76c1a38a4c584a194955390e" dependencies = [ - "getrandom 0.2.14", + "getrandom 0.2.15", "once_cell", "tiny-keccak", ] @@ -1763,9 +1917,9 @@ checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5" [[package]] name = "crc32fast" -version = "1.4.0" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3855a8a784b474f333699ef2bbca9db2c4a1f6d9088a90a2d25b1eb53111eaa" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" dependencies = [ "cfg-if", ] @@ -1800,9 +1954,9 @@ dependencies = [ [[package]] name = "crossbeam-utils" -version = "0.8.19" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" [[package]] name = "crunchy" @@ -1818,7 +1972,7 @@ checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" dependencies = [ "generic-array 0.14.7", "rand_core 0.6.4", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -1850,17 +2004,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeab" dependencies = [ "generic-array 0.14.7", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] name = "crypto-mac" -version = "0.11.0" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25fab6889090c8133f3deb8f73ba3c65a7f456f66436fc012a1b1e272b1e103e" +checksum = "b1d1a86f49236c215f271d40892d5fc950490551400b02ef360692c29815c714" dependencies = [ "generic-array 0.14.7", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -1875,9 +2029,9 @@ dependencies = [ [[package]] name = "cumulus-client-cli" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "clap", + "clap 4.5.8", "parity-scale-codec", "sc-chain-spec", "sc-cli", @@ -1892,14 +2046,14 @@ dependencies = [ [[package]] name = "cumulus-client-collator" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-client-consensus-common", "cumulus-client-network", "cumulus-primitives-core", "futures", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "polkadot-node-primitives", "polkadot-node-subsystem", "polkadot-overseer", @@ -1915,7 +2069,7 @@ dependencies = [ [[package]] name = "cumulus-client-consensus-aura" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-client-collator", @@ -1957,7 +2111,7 @@ dependencies = [ [[package]] name = "cumulus-client-consensus-common" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-client-pov-recovery", @@ -1986,7 +2140,7 @@ dependencies = [ [[package]] name = "cumulus-client-consensus-proposer" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "anyhow", "async-trait", @@ -2001,14 +2155,14 @@ dependencies = [ [[package]] name = "cumulus-client-network" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-relay-chain-interface", "futures", "futures-timer", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "polkadot-node-primitives", "polkadot-parachain-primitives", "polkadot-primitives", @@ -2024,7 +2178,7 @@ dependencies = [ [[package]] name = "cumulus-client-parachain-inherent" version = "0.1.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2048,7 +2202,7 @@ dependencies = [ [[package]] name = "cumulus-client-pov-recovery" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2072,7 +2226,7 @@ dependencies = [ [[package]] name = "cumulus-client-service" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-client-cli", "cumulus-client-collator", @@ -2108,7 +2262,7 @@ dependencies = [ [[package]] name = "cumulus-pallet-aura-ext" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-pallet-parachain-system", "frame-support", @@ -2126,7 +2280,7 @@ dependencies = [ [[package]] name = "cumulus-pallet-parachain-system" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bytes", "cumulus-pallet-parachain-system-proc-macro", @@ -2160,18 +2314,18 @@ dependencies = [ [[package]] name = "cumulus-pallet-parachain-system-proc-macro" version = "0.6.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "cumulus-pallet-session-benchmarking" version = "9.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -2185,7 +2339,7 @@ dependencies = [ [[package]] name = "cumulus-pallet-xcm" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-primitives-core", "frame-support", @@ -2201,7 +2355,7 @@ dependencies = [ [[package]] name = "cumulus-pallet-xcmp-queue" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bounded-collections 0.2.0", "bp-xcm-bridge-hub-router", @@ -2226,7 +2380,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-aura" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "polkadot-core-primitives", @@ -2240,7 +2394,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-core" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "polkadot-core-primitives", @@ -2257,7 +2411,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-parachain-inherent" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2272,7 +2426,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-proof-size-hostfunction" version = "0.2.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "sp-externalities 0.25.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", "sp-runtime-interface 24.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", @@ -2282,7 +2436,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-timestamp" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-primitives-core", "futures", @@ -2295,7 +2449,7 @@ dependencies = [ [[package]] name = "cumulus-primitives-utility" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-primitives-core", "frame-support", @@ -2316,7 +2470,7 @@ dependencies = [ [[package]] name = "cumulus-relay-chain-inprocess-interface" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2340,7 +2494,7 @@ dependencies = [ [[package]] name = "cumulus-relay-chain-interface" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2358,15 +2512,15 @@ dependencies = [ [[package]] name = "cumulus-relay-chain-minimal-node" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "async-trait", "cumulus-primitives-core", "cumulus-relay-chain-interface", "cumulus-relay-chain-rpc-interface", "futures", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "polkadot-availability-recovery", "polkadot-collator-protocol", "polkadot-core-primitives", @@ -2399,7 +2553,7 @@ dependencies = [ [[package]] name = "cumulus-relay-chain-rpc-interface" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "cumulus-primitives-core", @@ -2438,7 +2592,7 @@ dependencies = [ [[package]] name = "cumulus-test-relay-sproof-builder" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-primitives-core", "parity-scale-codec", @@ -2458,7 +2612,7 @@ dependencies = [ "byteorder", "digest 0.8.1", "rand_core 0.5.1", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -2471,24 +2625,23 @@ dependencies = [ "byteorder", "digest 0.9.0", "rand_core 0.5.1", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] [[package]] name = "curve25519-dalek" -version = "4.1.2" +version = "4.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a677b8922c94e01bdbb12126b0bc852f00447528dee1782229af9c720c3f348" +checksum = "97fb8b7c4503de7d6ae7b42ab72a5a59857b4c937ec27a3d4539dba95b5ab2be" dependencies = [ "cfg-if", "cpufeatures", "curve25519-dalek-derive", "digest 0.10.7", "fiat-crypto", - "platforms", "rustc_version 0.4.0", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -2500,7 +2653,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -2518,9 +2671,9 @@ dependencies = [ [[package]] name = "cxx" -version = "1.0.121" +version = "1.0.124" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21db378d04296a84d8b7d047c36bb3954f0b46529db725d7e62fb02f9ba53ccc" +checksum = "273dcfd3acd4e1e276af13ed2a43eea7001318823e7a726a6b3ed39b4acc0b82" dependencies = [ "cc", "cxxbridge-flags", @@ -2530,9 +2683,9 @@ dependencies = [ [[package]] name = "cxx-build" -version = "1.0.121" +version = "1.0.124" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e5262a7fa3f0bae2a55b767c223ba98032d7c328f5c13fa5cdc980b77fc0658" +checksum = "d8b2766fbd92be34e9ed143898fce6c572dc009de39506ed6903e5a05b68914e" dependencies = [ "cc", "codespan-reporting", @@ -2540,24 +2693,24 @@ dependencies = [ "proc-macro2", "quote", "scratch", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "cxxbridge-flags" -version = "1.0.121" +version = "1.0.124" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be8dcadd2e2fb4a501e1d9e93d6e88e6ea494306d8272069c92d5a9edf8855c0" +checksum = "839fcd5e43464614ffaa989eaf1c139ef1f0c51672a1ed08023307fa1b909ccd" [[package]] name = "cxxbridge-macro" -version = "1.0.121" +version = "1.0.124" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad08a837629ad949b73d032c637653d069e909cffe4ee7870b02301939ce39cc" +checksum = "4b2c1c1776b986979be68bb2285da855f8d8a35851a769fca8740df7c3d07877" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -2572,12 +2725,12 @@ dependencies = [ [[package]] name = "darling" -version = "0.20.8" +version = "0.20.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54e36fcd13ed84ffdfda6f5be89b31287cbb80c439841fe69e04841435464391" +checksum = "83b2eb4d90d12bdda5ed17de686c2acb4c57914f8f921b8da7e112b5a36f3fe1" dependencies = [ - "darling_core 0.20.8", - "darling_macro 0.20.8", + "darling_core 0.20.9", + "darling_macro 0.20.9", ] [[package]] @@ -2596,16 +2749,16 @@ dependencies = [ [[package]] name = "darling_core" -version = "0.20.8" +version = "0.20.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c2cf1c23a687a1feeb728783b993c4e1ad83d99f351801977dd809b48d0a70f" +checksum = "622687fe0bac72a04e5599029151f5796111b90f1baaa9b544d807a5e31cd120" dependencies = [ "fnv", "ident_case", "proc-macro2", "quote", - "strsim 0.10.0", - "syn 2.0.60", + "strsim 0.11.1", + "syn 2.0.68", ] [[package]] @@ -2621,26 +2774,39 @@ dependencies = [ [[package]] name = "darling_macro" -version = "0.20.8" +version = "0.20.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a668eda54683121533a393014d8692171709ff57a7d61f187b6e782719f8933f" +checksum = "733cabb43482b1a1b53eee8583c2b9e8684d592215ea83efd305dd31bc2f0178" dependencies = [ - "darling_core 0.20.8", + "darling_core 0.20.9", "quote", - "syn 2.0.60", + "syn 2.0.68", +] + +[[package]] +name = "dashmap" +version = "5.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "978747c1d849a7d2ee5e8adc0159961c48fb7e5db2f06af6723b80123bb53856" +dependencies = [ + "cfg-if", + "hashbrown 0.14.5", + "lock_api", + "once_cell", + "parking_lot_core 0.9.10", ] [[package]] name = "data-encoding" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e962a19be5cfc3f3bf6dd8f61eb50107f356ad6270fbb3ed41476571db78be5" +checksum = "e8566979429cf69b49a5c740c60791108e86440e8be149bbea4fe54d2c32d6e2" [[package]] name = "data-encoding-macro" -version = "0.1.14" +version = "0.1.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20c01c06f5f429efdf2bae21eb67c28b3df3cf85b7dd2d8ef09c0838dac5d33e" +checksum = "f1559b6cba622276d6d63706db152618eeb15b89b3e4041446b05876e352e639" dependencies = [ "data-encoding", "data-encoding-macro-internal", @@ -2648,9 +2814,9 @@ dependencies = [ [[package]] name = "data-encoding-macro-internal" -version = "0.1.12" +version = "0.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0047d07f2c89b17dd631c80450d69841a6b5d7fb17278cbc43d7e4cfcf2576f3" +checksum = "332d754c0af53bc87c108fed664d121ecf59207ec4196041f04d6ab9002ad33f" dependencies = [ "data-encoding", "syn 1.0.109", @@ -2719,22 +2885,34 @@ checksum = "d65d7ce8132b7c0e54497a4d9a55a1c2a0912a0d786cf894472ba818fba45762" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "derive_more" -version = "0.99.17" +version = "0.99.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" +checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" dependencies = [ "convert_case", "proc-macro2", "quote", "rustc_version 0.4.0", - "syn 1.0.109", + "syn 2.0.68", ] +[[package]] +name = "deunicode" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "339544cc9e2c4dc3fc7149fd630c5f22263a4fdf18a98afd0075784968b5cf00" + +[[package]] +name = "difference" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "524cbf6897b527295dff137cec09ecf3a05f4fddffd7dfcd1585403449e74198" + [[package]] name = "difflib" version = "0.4.0" @@ -2768,7 +2946,7 @@ dependencies = [ "block-buffer 0.10.4", "const-oid", "crypto-common", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -2790,6 +2968,16 @@ dependencies = [ "dirs-sys-next", ] +[[package]] +name = "dirs-next" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" +dependencies = [ + "cfg-if", + "dirs-sys-next", +] + [[package]] name = "dirs-sys" version = "0.4.1" @@ -2815,13 +3003,13 @@ dependencies = [ [[package]] name = "displaydoc" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -2861,9 +3049,9 @@ dependencies = [ "proc-macro2", "quote", "regex", - "syn 2.0.60", + "syn 2.0.68", "termcolor", - "toml 0.8.12", + "toml 0.8.14", "walkdir", ] @@ -2948,12 +3136,12 @@ version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4a3daa8e81a3963a60642bcc1f90a670680bd4a77535faa384e9d1c79d620871" dependencies = [ - "curve25519-dalek 4.1.2", + "curve25519-dalek 4.1.3", "ed25519", "rand_core 0.6.4", "serde", "sha2 0.10.8", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -2977,7 +3165,7 @@ version = "4.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7d9ce6874da5d4415896cd45ffbc4d1cfc0c4f9c079427bd870742c30f2f65a9" dependencies = [ - "curve25519-dalek 4.1.2", + "curve25519-dalek 4.1.3", "ed25519", "hashbrown 0.14.5", "hex", @@ -2988,9 +3176,9 @@ dependencies = [ [[package]] name = "either" -version = "1.12.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dca9240753cf90908d7e4aac30f630662b02aebaa1b58a3cadabdb23385b58b" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" dependencies = [ "serde", ] @@ -3010,7 +3198,7 @@ dependencies = [ "pkcs8", "rand_core 0.6.4", "sec1", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -3034,22 +3222,22 @@ dependencies = [ [[package]] name = "enumflags2" -version = "0.7.9" +version = "0.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3278c9d5fb675e0a51dabcf4c0d355f692b064171535ba72361be1528a9d8e8d" +checksum = "d232db7f5956f3f14313dc2f87985c58bd2c695ce124c8cdd984e08e15ac133d" dependencies = [ "enumflags2_derive", ] [[package]] name = "enumflags2_derive" -version = "0.7.9" +version = "0.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c785274071b1b420972453b306eeca06acf4633829db4223b58a2a8c5953bc4" +checksum = "de0d48a183585823424a4ce1aa132d174a6a81bd540895822eb4c8373a8e49e8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -3060,7 +3248,7 @@ checksum = "6fd000fd6988e73bbe993ea3db9b1aa64906ab88766d654973924340c8cddb42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -3090,9 +3278,9 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a258e46cdc063eb8519c00b9fc845fc47bcfca4130e2f08e88665ceda8474245" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" dependencies = [ "libc", "windows-sys 0.52.0", @@ -3110,7 +3298,7 @@ dependencies = [ "regex", "serde", "serde_json", - "sha3", + "sha3 0.10.8", "thiserror", "uint", ] @@ -3144,7 +3332,7 @@ dependencies = [ "rlp", "scale-info", "serde", - "sha3", + "sha3 0.10.8", "trie-root", ] @@ -3164,6 +3352,12 @@ dependencies = [ "uint", ] +[[package]] +name = "ethnum" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b90ca2580b73ab6a1f724b76ca11ab632df820fd6040c336200d2c1df7b3c82c" + [[package]] name = "event-listener" version = "2.5.3" @@ -3183,20 +3377,9 @@ dependencies = [ [[package]] name = "event-listener" -version = "4.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67b215c49b2b248c855fb73579eb1f4f26c38ffdc12973e20e07b91d78d5646e" -dependencies = [ - "concurrent-queue", - "parking", - "pin-project-lite 0.2.14", -] - -[[package]] -name = "event-listener" -version = "5.3.0" +version = "5.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d9944b8ca13534cdfb2800775f8dd4902ff3fc75a50101466decadfdf322a24" +checksum = "6032be9bd27023a771701cc49f9f053c751055f71efb2e0ae5c15809093675ba" dependencies = [ "concurrent-queue", "parking", @@ -3205,21 +3388,11 @@ dependencies = [ [[package]] name = "event-listener-strategy" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "958e4d70b6d5e81971bebec42271ec641e7ff4e170a6fa605f2b8a8b65cb97d3" -dependencies = [ - "event-listener 4.0.3", - "pin-project-lite 0.2.14", -] - -[[package]] -name = "event-listener-strategy" -version = "0.5.1" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "332f51cb23d20b0de8458b86580878211da09bcd4503cb579c225b3d124cabb3" +checksum = "0f214dc438f977e6d4e3500aaa277f5ad94ca83fbbd9b1a15713ce2344ccc5a1" dependencies = [ - "event-listener 5.3.0", + "event-listener 5.3.1", "pin-project-lite 0.2.14", ] @@ -3241,7 +3414,7 @@ dependencies = [ "rlp", "scale-info", "serde", - "sha3", + "sha3 0.10.8", ] [[package]] @@ -3278,7 +3451,7 @@ dependencies = [ "environmental", "evm-core", "primitive-types", - "sha3", + "sha3 0.10.8", ] [[package]] @@ -3304,16 +3477,28 @@ dependencies = [ [[package]] name = "expander" -version = "2.1.0" +version = "2.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00e83c02035136f1592a47964ea60c05a50e4ed8b5892cfac197063850898d4d" +checksum = "e2c470c71d91ecbd179935b24170459e926382eaaa86b590b78814e180d8a8e2" dependencies = [ "blake2 0.10.6", + "file-guard", "fs-err", - "prettier-please", + "prettyplease 0.2.20", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", +] + +[[package]] +name = "fail" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe5e43d0f78a42ad591453aedb1d7ae631ce7ee445c7643691055a9ed8d3b01c" +dependencies = [ + "log", + "once_cell", + "rand 0.8.5", ] [[package]] @@ -3339,9 +3524,9 @@ dependencies = [ [[package]] name = "fastrand" -version = "2.0.2" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "658bd65b1cf4c852a3cc96f18a8ce7b5640f6b703f905c7d74532294c2a63984" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" [[package]] name = "fatality" @@ -3361,7 +3546,7 @@ checksum = "f5aa1e3ae159e592ad222dc90c5acbad632b527779ba88486abe92782ab268bd" dependencies = [ "expander 0.0.4", "indexmap 1.9.3", - "proc-macro-crate 1.3.1", + "proc-macro-crate 1.1.3", "proc-macro2", "quote", "syn 1.0.109", @@ -3385,7 +3570,7 @@ name = "fc-cli" version = "1.0.0-dev" source = "git+https://github.com/paritytech/frontier?branch=polkadot-v1.7.0#c5d6daa9ffd46c0a85915526aa26d200fd635e30" dependencies = [ - "clap", + "clap 4.5.8", "ethereum-types", "fc-db", "fp-rpc", @@ -3431,7 +3616,7 @@ dependencies = [ "log", "parity-db", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-client-api", "sc-client-db", "smallvec", @@ -3457,7 +3642,7 @@ dependencies = [ "futures", "futures-timer", "log", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-client-api", "sc-utils", "sp-api", @@ -3573,7 +3758,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" dependencies = [ "rand_core 0.6.4", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -3591,9 +3776,19 @@ dependencies = [ [[package]] name = "fiat-crypto" -version = "0.2.7" +version = "0.2.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "28dea519a9695b9977216879a3ebfddf92f1c08c05d984f8996aecd6ecdc811d" + +[[package]] +name = "file-guard" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c007b1ae3abe1cb6f85a16305acd418b7ca6343b953633fee2b76d8f108b830f" +checksum = "21ef72acf95ec3d7dbf61275be556299490a245f017cf084bd23b4f68cf9407c" +dependencies = [ + "libc", + "winapi", +] [[package]] name = "file-per-thread-logger" @@ -3629,7 +3824,7 @@ dependencies = [ "log", "num-traits", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "scale-info", ] @@ -3645,6 +3840,12 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "fixedbitset" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "37ab347416e802de484e4d03c7316c48f1ecb56574dfd4a46a80f173ce1de04d" + [[package]] name = "fixedbitset" version = "0.4.2" @@ -3653,9 +3854,9 @@ checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" [[package]] name = "flate2" -version = "1.0.28" +version = "1.0.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46303f565772937ffe1d394a4fac6f411c6013172fadde9dcdb1e147a086940e" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" dependencies = [ "crc32fast", "libz-sys", @@ -3706,7 +3907,7 @@ checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" [[package]] name = "fork-tree" version = "12.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", ] @@ -3837,7 +4038,7 @@ checksum = "6c2141d6d6c8512188a7891b4b01590a45f6dac67afb4f255c4124dbb86d4eaa" [[package]] name = "frame-benchmarking" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-support-procedural", @@ -3862,12 +4063,12 @@ dependencies = [ [[package]] name = "frame-benchmarking-cli" version = "32.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "Inflector", - "array-bytes 6.2.2", + "array-bytes 6.2.3", "chrono", - "clap", + "clap 4.5.8", "comfy-table", "frame-benchmarking", "frame-support", @@ -3910,18 +4111,18 @@ dependencies = [ [[package]] name = "frame-election-provider-solution-type" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "frame-election-provider-support" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-election-provider-solution-type", "frame-support", @@ -3938,7 +4139,7 @@ dependencies = [ [[package]] name = "frame-executive" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -3977,14 +4178,29 @@ dependencies = [ ] [[package]] -name = "frame-remote-externalities" -version = "0.35.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +name = "frame-metadata-hash-extension" +version = "0.1.0" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "futures", - "indicatif", - "jsonrpsee", - "log", + "array-bytes 6.2.3", + "docify", + "frame-support", + "frame-system", + "log", + "parity-scale-codec", + "scale-info", + "sp-runtime 31.0.1", +] + +[[package]] +name = "frame-remote-externalities" +version = "0.35.0" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" +dependencies = [ + "futures", + "indicatif", + "jsonrpsee", + "log", "parity-scale-codec", "serde", "sp-core 28.0.0", @@ -4001,10 +4217,10 @@ dependencies = [ [[package]] name = "frame-support" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "aquamarine", - "array-bytes 6.2.2", + "array-bytes 6.2.3", "bitflags 1.3.2", "docify", "environmental", @@ -4042,12 +4258,12 @@ dependencies = [ [[package]] name = "frame-support-procedural" version = "23.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "Inflector", "cfg-expr", "derive-syn-parse 0.1.5", - "expander 2.1.0", + "expander 2.2.1", "frame-support-procedural-tools", "itertools 0.10.5", "macro_magic", @@ -4055,35 +4271,35 @@ dependencies = [ "proc-macro2", "quote", "sp-crypto-hashing", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "frame-support-procedural-tools" version = "10.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support-procedural-tools-derive", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "frame-support-procedural-tools-derive" version = "11.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "frame-system" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cfg-if", "docify", @@ -4103,7 +4319,7 @@ dependencies = [ [[package]] name = "frame-system-benchmarking" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -4118,7 +4334,7 @@ dependencies = [ [[package]] name = "frame-system-rpc-runtime-api" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "sp-api", @@ -4127,7 +4343,7 @@ dependencies = [ [[package]] name = "frame-try-runtime" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "parity-scale-codec", @@ -4161,7 +4377,7 @@ version = "0.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "29f9df8a11882c4e3335eb2d18a0137c505d9ca927470b0cac9c6f0ae07d28f7" dependencies = [ - "rustix 0.38.32", + "rustix 0.38.34", "windows-sys 0.48.0", ] @@ -4222,7 +4438,7 @@ checksum = "1d930c203dd0b6ff06e0201a4a2fe9149b43c684fd4420555b26d21b1a02956f" dependencies = [ "futures-core", "lock_api", - "parking_lot 0.12.1", + "parking_lot 0.12.3", ] [[package]] @@ -4252,7 +4468,7 @@ version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "52527eb5074e35e9339c6b4e8d12600c7128b68fb25dcb9fa9dec18f7c25f3a5" dependencies = [ - "fastrand 2.0.2", + "fastrand 2.1.0", "futures-core", "futures-io", "parking", @@ -4267,7 +4483,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -4369,9 +4585,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.14" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94b22e06ecb0110981051723910cbf0b5f5e09a2062dd7663334ee79a9d1286c" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if", "libc", @@ -4411,9 +4627,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.28.1" +version = "0.29.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4271d37baee1b8c7e4b708028c57d816cf9d2434acb33a549475f78c181f6253" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" [[package]] name = "glob" @@ -4421,6 +4637,30 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" +[[package]] +name = "globset" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" +dependencies = [ + "aho-corasick", + "bstr", + "log", + "regex-automata 0.4.7", + "regex-syntax 0.8.4", +] + +[[package]] +name = "globwalk" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0bf760ebf69878d9fd8f110c89703d90ce35095324d1f1edcb595c63945ee757" +dependencies = [ + "bitflags 2.6.0", + "ignore", + "walkdir", +] + [[package]] name = "group" version = "0.13.0" @@ -4429,7 +4669,7 @@ checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" dependencies = [ "ff", "rand_core 0.6.4", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -4518,6 +4758,15 @@ dependencies = [ "hashbrown 0.14.5", ] +[[package]] +name = "heck" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" +dependencies = [ + "unicode-segmentation", +] + [[package]] name = "heck" version = "0.4.1" @@ -4533,12 +4782,27 @@ version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" +[[package]] +name = "hermit-abi" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" +dependencies = [ + "libc", +] + [[package]] name = "hermit-abi" version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" +[[package]] +name = "hermit-abi" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbf6a919d6cf397374f7dfeeea91d974c7c0a7221d0d0f4f20d859d329e53fcc" + [[package]] name = "hex" version = "0.4.3" @@ -4576,7 +4840,7 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" dependencies = [ - "crypto-mac 0.11.0", + "crypto-mac 0.11.1", "digest 0.9.0", ] @@ -4650,9 +4914,9 @@ checksum = "add0ab9360ddbd88cfeb3bd9574a1d85cfdfa14db10b3e21d3700dbc4328758f" [[package]] name = "httparse" -version = "1.8.0" +version = "1.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" [[package]] name = "httpdate" @@ -4660,6 +4924,15 @@ version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" +[[package]] +name = "humansize" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6cb51c9a029ddc91b07a787f1d86b53ccfa49b0e86688c946ebe8d3555685dd7" +dependencies = [ + "libm", +] + [[package]] name = "humantime" version = "2.1.0" @@ -4668,9 +4941,9 @@ checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] name = "hyper" -version = "0.14.28" +version = "0.14.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf96e135eb83a2a8ddf766e426a841d8ddd7449d5f00d34ea02b41d2f19eef80" +checksum = "f361cde2f109281a220d4307746cdfd5ee3f410da58a70377762396775634b33" dependencies = [ "bytes", "futures-channel", @@ -4683,7 +4956,7 @@ dependencies = [ "httpdate", "itoa", "pin-project-lite 0.2.14", - "socket2 0.5.6", + "socket2 0.5.7", "tokio", "tower-service", "tracing", @@ -4700,7 +4973,7 @@ dependencies = [ "http", "hyper", "log", - "rustls 0.21.10", + "rustls 0.21.12", "rustls-native-certs", "tokio", "tokio-rustls", @@ -4772,7 +5045,7 @@ version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d6b0422c86d7ce0e97169cc42e04ae643caf278874a7a3c87b8150a220dc7e1e" dependencies = [ - "async-io 2.3.2", + "async-io 2.3.3", "core-foundation", "fnv", "futures", @@ -4785,6 +5058,36 @@ dependencies = [ "windows", ] +[[package]] +name = "ignore" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" +dependencies = [ + "crossbeam-deque", + "globset", + "log", + "memchr", + "regex-automata 0.4.7", + "same-file", + "walkdir", + "winapi-util", +] + +[[package]] +name = "im" +version = "15.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d0acd33ff0285af998aaf9b57342af478078f53492322fafc47450e09397e0e9" +dependencies = [ + "bitmaps", + "rand_core 0.6.4", + "rand_xoshiro", + "sized-chunks", + "typenum", + "version_check", +] + [[package]] name = "impl-codec" version = "0.6.0" @@ -4825,18 +5128,18 @@ dependencies = [ [[package]] name = "include_dir" -version = "0.7.3" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18762faeff7122e89e0857b02f7ce6fcc0d101d5e9ad2ad7846cc01d61b7f19e" +checksum = "923d117408f1e49d914f1a379a309cffe4f18c05cf4e3d12e613a15fc81bd0dd" dependencies = [ "include_dir_macros", ] [[package]] name = "include_dir_macros" -version = "0.7.3" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f" +checksum = "7cab85a7ed0bd5f0e76d93846e0147172bed2e2d3f859bcc33a8d9699cad1a75" dependencies = [ "proc-macro2", "quote", @@ -4915,13 +5218,26 @@ dependencies = [ "num-traits", ] +[[package]] +name = "internment" +version = "0.5.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ab388864246d58a276e60e7569a833d9cc4cd75c66e5ca77c177dad38e59996" +dependencies = [ + "ahash 0.7.8", + "dashmap", + "hashbrown 0.12.3", + "once_cell", + "parking_lot 0.12.3", +] + [[package]] name = "io-lifetimes" version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" dependencies = [ - "hermit-abi", + "hermit-abi 0.3.9", "libc", "windows-sys 0.48.0", ] @@ -4938,7 +5254,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b58db92f96b720de98181bbbe63c831e87005ab460c1bf306eb2622b4707997f" dependencies = [ - "socket2 0.5.6", + "socket2 0.5.7", "widestring", "windows-sys 0.48.0", "winreg", @@ -4956,7 +5272,7 @@ version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f23ff5ef2b80d608d61efee834934d862cd92461afc0560dedf493e4c033738b" dependencies = [ - "hermit-abi", + "hermit-abi 0.3.9", "libc", "windows-sys 0.52.0", ] @@ -4970,6 +5286,12 @@ dependencies = [ "winapi", ] +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + [[package]] name = "itertools" version = "0.10.5" @@ -5005,9 +5327,9 @@ checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" [[package]] name = "jobserver" -version = "0.1.30" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "685a7d121ee3f65ae4fddd72b25a04bb36b6af81bc0828f7d5434c0fe60fa3a2" +checksum = "d2b099aaa34a9751c5bf0878add70444e1ed2dd73f347be99003d4577277de6e" dependencies = [ "libc", ] @@ -5072,7 +5394,7 @@ dependencies = [ "futures-util", "hyper", "jsonrpsee-types", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "rustc-hash", "serde", @@ -5110,7 +5432,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "29110019693a4fa2dbda04876499d098fa16d70eba06b1e6e2b3f1b251419515" dependencies = [ "heck 0.4.1", - "proc-macro-crate 1.3.1", + "proc-macro-crate 1.1.3", "proc-macro2", "quote", "syn 1.0.109", @@ -5210,7 +5532,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bf7a85fe66f9ff9cd74e169fdd2c94c6e1e74c412c99a73b4df3200b5d3760b2" dependencies = [ "kvdb", - "parking_lot 0.12.1", + "parking_lot 0.12.3", ] [[package]] @@ -5221,7 +5543,7 @@ checksum = "b644c70b92285f66bfc2032922a79000ea30af7bc2ab31902992a5dcb9b434f6" dependencies = [ "kvdb", "num_cpus", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "regex", "rocksdb", "smallvec", @@ -5240,9 +5562,12 @@ dependencies = [ [[package]] name = "lazy_static" -version = "1.4.0" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" +dependencies = [ + "spin 0.9.8", +] [[package]] name = "lazycell" @@ -5252,15 +5577,15 @@ checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" [[package]] name = "libc" -version = "0.2.153" +version = "0.2.155" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" [[package]] name = "libloading" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c2a198fb6b0eada2a8df47933734e6d35d350665a33a3593d7164fa52c75c19" +checksum = "e310b3a6b5907f99202fcdb4960ff45b93735d7c7d96b760fcff8db2dc0e103d" dependencies = [ "cfg-if", "windows-targets 0.52.5", @@ -5281,7 +5606,7 @@ dependencies = [ "bytes", "futures", "futures-timer", - "getrandom 0.2.14", + "getrandom 0.2.15", "instant", "libp2p-allow-block-list", "libp2p-connection-limits", @@ -5346,7 +5671,7 @@ dependencies = [ "multihash 0.17.0", "multistream-select", "once_cell", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "pin-project", "quick-protobuf", "rand 0.8.5", @@ -5366,7 +5691,7 @@ dependencies = [ "futures", "libp2p-core", "log", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "smallvec", "trust-dns-resolver", ] @@ -5528,7 +5853,7 @@ dependencies = [ "libp2p-identity", "libp2p-tls", "log", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "quinn-proto", "rand 0.8.5", "rustls 0.20.9", @@ -5644,7 +5969,7 @@ dependencies = [ "futures-rustls", "libp2p-core", "log", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "quicksink", "rw-stream-sink", "soketto", @@ -5671,7 +5996,7 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "libc", ] @@ -5717,7 +6042,7 @@ checksum = "5be9b9bb642d8522a44d533eab56c16c738301965504753b03ad1de3425d5451" dependencies = [ "crunchy", "digest 0.9.0", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -5751,9 +6076,9 @@ dependencies = [ [[package]] name = "libz-sys" -version = "1.1.16" +version = "1.1.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e143b5e666b2695d28f6bca6497720813f699c9602dd7f5cac91008b8ada7f9" +checksum = "c15da26e5af7e25c90b37a2d75cdbf940cf4a55316de9d84c679c9b8bfabf82e" dependencies = [ "cc", "pkg-config", @@ -5807,9 +6132,9 @@ checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" [[package]] name = "linux-raw-sys" -version = "0.4.13" +version = "0.4.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" [[package]] name = "lioness" @@ -5825,9 +6150,9 @@ dependencies = [ [[package]] name = "lock_api" -version = "0.4.11" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c168f8615b12bc01f9c17e2eb0cc07dcae1940121185446edc3744920e8ef45" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" dependencies = [ "autocfg", "scopeguard", @@ -5835,9 +6160,12 @@ dependencies = [ [[package]] name = "log" -version = "0.4.21" +version = "0.4.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" +dependencies = [ + "serde", +] [[package]] name = "lru" @@ -5874,9 +6202,9 @@ dependencies = [ [[package]] name = "lz4" -version = "1.24.0" +version = "1.25.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e9e2dd86df36ce760a60f6ff6ad526f7ba1f14ba0356f8254fb6905e6494df1" +checksum = "d6eab492fe7f8651add23237ea56dbf11b3c4ff762ab83d40a47f11433421f91" dependencies = [ "libc", "lz4-sys", @@ -5884,9 +6212,9 @@ dependencies = [ [[package]] name = "lz4-sys" -version = "1.9.4" +version = "1.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57d27b317e207b10f69f5e75494119e391a96f48861ae870d1da6edac98ca900" +checksum = "e9764018d143cc854c9f17f0b907de70f14393b1f502da6375dce70f00514eb3" dependencies = [ "cc", "libc", @@ -5910,7 +6238,7 @@ dependencies = [ "macro_magic_core", "macro_magic_macros", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -5924,7 +6252,7 @@ dependencies = [ "macro_magic_core_macros", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -5935,7 +6263,7 @@ checksum = "9ea73aa640dc01d62a590d48c0c3521ed739d53b27f919b25c3551e233481654" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -5946,7 +6274,7 @@ checksum = "ef9d79ae96aaba821963320eb2b6e34d17df1e5a83d8a1985c29cc5be59577b3" dependencies = [ "macro_magic_core", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -6098,9 +6426,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.7.2" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "memfd" @@ -6108,7 +6436,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b2cffa4ad52c6f791f4f8b15f0c05f9824b2ced1160e88cc393d64fff9a8ac64" dependencies = [ - "rustix 0.38.32", + "rustix 0.38.34", ] [[package]] @@ -6190,9 +6518,9 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.7.2" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" dependencies = [ "adler", ] @@ -6219,16 +6547,16 @@ dependencies = [ "bitflags 1.3.2", "blake2 0.10.6", "c2-chacha", - "curve25519-dalek 4.1.2", + "curve25519-dalek 4.1.3", "either", "hashlink", "lioness", "log", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "rand_chacha 0.3.1", "rand_distr", - "subtle 2.5.0", + "subtle 2.4.1", "thiserror", "zeroize", ] @@ -6236,7 +6564,7 @@ dependencies = [ [[package]] name = "mmr-gadget" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "log", @@ -6255,7 +6583,7 @@ dependencies = [ [[package]] name = "mmr-rpc" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "jsonrpsee", "parity-scale-codec", @@ -6294,6 +6622,510 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "move-abigen" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "bcs 0.1.6", + "heck 0.3.3", + "log", + "move-binary-format", + "move-bytecode-verifier", + "move-command-line-common", + "move-core-types", + "move-model", + "serde", +] + +[[package]] +name = "move-binary-format" +version = "0.0.3" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "hashbrown 0.14.5", + "move-core-types", + "ref-cast", + "serde", + "variant_count", +] + +[[package]] +name = "move-borrow-graph" +version = "0.0.1" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" + +[[package]] +name = "move-bytecode-source-map" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "bcs 0.1.6", + "move-binary-format", + "move-command-line-common", + "move-core-types", + "move-ir-types", + "move-symbol-pool", + "serde", +] + +[[package]] +name = "move-bytecode-verifier" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "fail", + "hashbrown 0.14.5", + "move-binary-format", + "move-borrow-graph", + "move-core-types", + "petgraph 0.6.4", +] + +[[package]] +name = "move-command-line-common" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "difference", + "dirs-next", + "hex", + "move-core-types", + "move-vm-support", + "num-bigint", + "once_cell", + "serde", + "sha2 0.9.9", + "walkdir", +] + +[[package]] +name = "move-compiler" +version = "0.0.1" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "bcs 0.1.6", + "clap 3.2.25", + "codespan-reporting", + "difference", + "hex", + "move-binary-format", + "move-borrow-graph", + "move-bytecode-source-map", + "move-bytecode-verifier", + "move-command-line-common", + "move-core-types", + "move-ir-to-bytecode", + "move-ir-types", + "move-symbol-pool", + "move-vm-support", + "num-bigint", + "once_cell", + "petgraph 0.5.1", + "regex", + "sha3 0.9.1", + "tempfile", + "walkdir", +] + +[[package]] +name = "move-core-types" +version = "0.0.4" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "bcs 0.1.4", + "ethnum", + "hashbrown 0.14.5", + "hex", + "num", + "parity-scale-codec", + "primitive-types", + "rand 0.8.5", + "ref-cast", + "scale-info", + "serde", + "serde_bytes", + "uint", +] + +[[package]] +name = "move-coverage" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "bcs 0.1.6", + "clap 3.2.25", + "codespan", + "colored", + "move-binary-format", + "move-bytecode-source-map", + "move-command-line-common", + "move-core-types", + "move-ir-types", + "once_cell", + "petgraph 0.5.1", + "serde", +] + +[[package]] +name = "move-disassembler" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "clap 3.2.25", + "colored", + "move-binary-format", + "move-bytecode-source-map", + "move-bytecode-verifier", + "move-command-line-common", + "move-compiler", + "move-core-types", + "move-coverage", + "move-ir-types", +] + +[[package]] +name = "move-docgen" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "codespan", + "codespan-reporting", + "itertools 0.10.5", + "log", + "move-compiler", + "move-model", + "num", + "once_cell", + "regex", + "serde", +] + +[[package]] +name = "move-errmapgen" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "bcs 0.1.6", + "log", + "move-command-line-common", + "move-core-types", + "move-model", + "serde", +] + +[[package]] +name = "move-ir-to-bytecode" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "codespan-reporting", + "log", + "move-binary-format", + "move-bytecode-source-map", + "move-command-line-common", + "move-core-types", + "move-ir-to-bytecode-syntax", + "move-ir-types", + "move-symbol-pool", + "ouroboros", + "thiserror", +] + +[[package]] +name = "move-ir-to-bytecode-syntax" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "hex", + "move-command-line-common", + "move-core-types", + "move-ir-types", + "move-symbol-pool", +] + +[[package]] +name = "move-ir-types" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "hex", + "move-command-line-common", + "move-core-types", + "move-symbol-pool", + "once_cell", + "serde", +] + +[[package]] +name = "move-model" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "codespan", + "codespan-reporting", + "internment", + "itertools 0.10.5", + "log", + "move-binary-format", + "move-bytecode-source-map", + "move-bytecode-verifier", + "move-command-line-common", + "move-compiler", + "move-core-types", + "move-disassembler", + "move-ir-types", + "move-symbol-pool", + "num", + "once_cell", + "regex", + "serde", +] + +[[package]] +name = "move-prover" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "async-trait", + "atty", + "clap 3.2.25", + "codespan", + "codespan-reporting", + "futures", + "hex", + "itertools 0.10.5", + "log", + "move-abigen", + "move-binary-format", + "move-command-line-common", + "move-compiler", + "move-core-types", + "move-docgen", + "move-errmapgen", + "move-ir-types", + "move-model", + "move-prover-boogie-backend", + "move-stackless-bytecode", + "num", + "once_cell", + "pretty", + "rand 0.8.5", + "serde", + "serde_json", + "simplelog", + "tokio", + "toml 0.5.11", +] + +[[package]] +name = "move-prover-boogie-backend" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "async-trait", + "codespan", + "codespan-reporting", + "futures", + "itertools 0.10.5", + "log", + "move-binary-format", + "move-command-line-common", + "move-compiler", + "move-core-types", + "move-model", + "move-stackless-bytecode", + "num", + "once_cell", + "pretty", + "rand 0.8.5", + "regex", + "serde", + "serde_json", + "tera", + "tokio", +] + +[[package]] +name = "move-read-write-set-types" +version = "0.0.3" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "move-binary-format", + "move-core-types", + "serde", +] + +[[package]] +name = "move-stackless-bytecode" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "codespan", + "codespan-reporting", + "ethnum", + "im", + "itertools 0.10.5", + "log", + "move-binary-format", + "move-borrow-graph", + "move-bytecode-verifier", + "move-command-line-common", + "move-compiler", + "move-core-types", + "move-ir-to-bytecode", + "move-model", + "move-read-write-set-types", + "num", + "once_cell", + "paste", + "petgraph 0.5.1", + "serde", +] + +[[package]] +name = "move-stdlib" +version = "0.1.1" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "blake2-rfc", + "hex", + "log", + "move-binary-format", + "move-command-line-common", + "move-compiler", + "move-core-types", + "move-docgen", + "move-errmapgen", + "move-prover", + "move-vm-runtime", + "move-vm-types", + "ripemd", + "sha2 0.10.8", + "sha3 0.10.8", + "siphasher 1.0.1", + "smallvec", + "tiny-keccak", +] + +[[package]] +name = "move-symbol-pool" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "once_cell", + "serde", +] + +[[package]] +name = "move-vm-backend" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "bcs 0.1.4", + "hashbrown 0.14.5", + "move-binary-format", + "move-core-types", + "move-stdlib", + "move-vm-backend-common", + "move-vm-runtime", + "move-vm-test-utils", + "move-vm-types", + "num-integer", + "serde", +] + +[[package]] +name = "move-vm-backend-common" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "bcs 0.1.4", + "lazy_static", + "move-binary-format", + "move-core-types", + "move-stdlib", + "move-vm-runtime", + "move-vm-test-utils", + "move-vm-types", + "parity-scale-codec", + "scale-info", + "serde", + "serde_bytes", +] + +[[package]] +name = "move-vm-runtime" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "better_any", + "fail", + "hashbrown 0.14.5", + "move-binary-format", + "move-bytecode-verifier", + "move-core-types", + "move-vm-types", + "sha3 0.10.8", + "tracing", +] + +[[package]] +name = "move-vm-support" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "blake2 0.10.6", + "bs58 0.5.1", + "move-core-types", +] + +[[package]] +name = "move-vm-test-utils" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "anyhow", + "lazy_static", + "move-binary-format", + "move-core-types", + "move-vm-types", + "serde", +] + +[[package]] +name = "move-vm-types" +version = "0.1.0" +source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" +dependencies = [ + "bcs 0.1.4", + "move-binary-format", + "move-core-types", + "serde", + "smallvec", +] + [[package]] name = "mp-coretime-bulk" version = "0.1.0" @@ -6395,9 +7227,9 @@ dependencies = [ "blake3", "core2", "digest 0.10.7", - "multihash-derive 0.8.0", + "multihash-derive 0.8.1", "sha2 0.10.8", - "sha3", + "sha3 0.10.8", "unsigned-varint", ] @@ -6409,7 +7241,7 @@ checksum = "cfd8a792c1694c6da4f68db0a9d707c72bd260994da179e6030a5dcee00bb815" dependencies = [ "core2", "digest 0.10.7", - "multihash-derive 0.8.0", + "multihash-derive 0.8.1", "sha2 0.10.8", "unsigned-varint", ] @@ -6440,22 +7272,22 @@ dependencies = [ "serde", "sha1", "sha2 0.10.8", - "sha3", + "sha3 0.10.8", "strobe-rs", ] [[package]] name = "multihash-derive" -version = "0.8.0" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc076939022111618a5026d3be019fd8b366e76314538ff9a1b59ffbcbf98bcd" +checksum = "1d6d4752e6230d8ef7adf7bd5d8c4b1f6561c1014c5ba9a37445ccefe18aa1db" dependencies = [ - "proc-macro-crate 1.3.1", + "proc-macro-crate 1.1.3", "proc-macro-error", "proc-macro2", "quote", "syn 1.0.109", - "synstructure", + "synstructure 0.12.6", ] [[package]] @@ -6471,16 +7303,16 @@ dependencies = [ [[package]] name = "multihash-derive-impl" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d38685e08adb338659871ecfc6ee47ba9b22dcc8abcf6975d379cc49145c3040" +checksum = "3958713ce794e12f7c6326fac9aa274c68d74c4881dd37b3e2662b8a2046bb19" dependencies = [ - "proc-macro-crate 1.3.1", + "proc-macro-crate 2.0.0", "proc-macro-error", "proc-macro2", "quote", - "syn 1.0.109", - "synstructure", + "syn 2.0.68", + "synstructure 0.13.1", ] [[package]] @@ -6505,9 +7337,9 @@ dependencies = [ [[package]] name = "nalgebra" -version = "0.32.5" +version = "0.32.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ea4908d4f23254adda3daa60ffef0f1ac7b8c3e9a864cf3cc154b251908a2ef" +checksum = "7b5c17de023a86f59ed79891b2e5d5a94c705dbe904a5b5c9c952ea6221b03e4" dependencies = [ "approx", "matrixmultiply", @@ -6521,13 +7353,13 @@ dependencies = [ [[package]] name = "nalgebra-macros" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91761aed67d03ad966ef783ae962ef9bbaca728d2dd7ceb7939ec110fffad998" +checksum = "254a5372af8fc138e36684761d3c0cdb758a4410e938babcff1c860ce14ddbfc" dependencies = [ "proc-macro2", "quote", - "syn 1.0.109", + "syn 2.0.68", ] [[package]] @@ -6547,11 +7379,10 @@ checksum = "6a51313c5820b0b02bd422f4b44776fbf47961755c74ce64afc73bfad10226c3" [[package]] name = "native-tls" -version = "0.2.11" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07226173c32f2926027b63cce4bcd8076c3552846cbe7925f3aaffeac0a3b92e" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" dependencies = [ - "lazy_static", "libc", "log", "openssl", @@ -6646,7 +7477,7 @@ version = "0.27.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "cfg-if", "libc", ] @@ -6697,9 +7528,9 @@ dependencies = [ [[package]] name = "num" -version = "0.4.2" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3135b08af27d103b0a51f2ae0f8632117b7b185ccf931445affa8df530576a41" +checksum = "35bd024e8b2ff75562e5f34e7f4905839deb4b22955ef5e73d2fea1b9813cb23" dependencies = [ "num-bigint", "num-complex", @@ -6711,20 +7542,19 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.4" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "608e7659b5c3d7cba262d894801b9ec9d00de989e8a82bd4bef91d08da45cdc0" +checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" dependencies = [ - "autocfg", "num-integer", "num-traits", ] [[package]] name = "num-complex" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23c6602fda94a57c990fe0df199a035d83576b496aa29f4e634a8ac6004e68a6" +checksum = "73f88a1307638156682bada9d7604135552957b7818057dcef22705b4d509495" dependencies = [ "num-traits", ] @@ -6756,9 +7586,9 @@ dependencies = [ [[package]] name = "num-iter" -version = "0.1.44" +version = "0.1.45" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d869c01cc0c455284163fd0092f1f93835385ccab5a98a0dcc497b2f8bf055a9" +checksum = "1429034a0490724d0075ebb2bc9e875d6503c3cf69e235a8941aa757d83ef5bf" dependencies = [ "autocfg", "num-integer", @@ -6767,11 +7597,10 @@ dependencies = [ [[package]] name = "num-rational" -version = "0.4.1" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" +checksum = "f83d14da390562dca69fc84082e73e548e1ad308d24accdedd2720017cb37824" dependencies = [ - "autocfg", "num-bigint", "num-integer", "num-traits", @@ -6779,9 +7608,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.18" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da0df0e5185db44f69b44f26786fe401b6c293d1907744beaa7fa62b2e5a517a" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", "libm", @@ -6793,7 +7622,7 @@ version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" dependencies = [ - "hermit-abi", + "hermit-abi 0.3.9", "libc", ] @@ -6815,7 +7644,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -6838,9 +7667,9 @@ dependencies = [ [[package]] name = "object" -version = "0.32.2" +version = "0.36.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6a622008b6e321afc04970976f62ee297fdbaa6f95318ca343e3eebb9648441" +checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" dependencies = [ "memchr", ] @@ -6878,7 +7707,7 @@ version = "0.10.64" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "cfg-if", "foreign-types", "libc", @@ -6895,7 +7724,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -6924,9 +7753,9 @@ checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" [[package]] name = "orchestra" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2356622ffdfe72362a45a1e5e87bb113b8327e596e39b91f11f0ef4395c8da79" +checksum = "92829eef0328a3d1cd22a02c0e51deb92a5362df3e7d21a4e9bdc38934694e66" dependencies = [ "async-trait", "dyn-clonable", @@ -6941,15 +7770,15 @@ dependencies = [ [[package]] name = "orchestra-proc-macro" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eedb646674596266dc9bb2b5c7eea7c36b32ecc7777eba0d510196972d72c4fd" +checksum = "1344346d5af32c95bbddea91b18a88cc83eac394192d20ef2fc4c40a74332355" dependencies = [ - "expander 2.1.0", + "expander 2.2.1", "indexmap 2.2.6", "itertools 0.11.0", - "petgraph", - "proc-macro-crate 1.3.1", + "petgraph 0.6.5", + "proc-macro-crate 3.1.0", "proc-macro2", "quote", "syn 1.0.109", @@ -6964,6 +7793,35 @@ dependencies = [ "num-traits", ] +[[package]] +name = "os_str_bytes" +version = "6.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2355d85b9a3786f481747ced0e0ff2ba35213a1f9bd406ed906554d7af805a1" + +[[package]] +name = "ouroboros" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbeff60e3e37407a80ead3e9458145b456e978c4068cddbfea6afb48572962ca" +dependencies = [ + "ouroboros_macro", + "stable_deref_trait", +] + +[[package]] +name = "ouroboros_macro" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "03f2cb802b5bdfdf52f1ffa0b54ce105e4d346e91990dd571f86c91321ad49e2" +dependencies = [ + "Inflector", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "overload" version = "0.1.1" @@ -6973,7 +7831,7 @@ checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" [[package]] name = "pallet-asset-conversion" version = "10.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -6991,7 +7849,7 @@ dependencies = [ [[package]] name = "pallet-asset-rate" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7006,7 +7864,7 @@ dependencies = [ [[package]] name = "pallet-asset-tx-payment" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7024,7 +7882,7 @@ dependencies = [ [[package]] name = "pallet-assets" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7083,7 +7941,7 @@ dependencies = [ [[package]] name = "pallet-aura" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -7100,7 +7958,7 @@ dependencies = [ [[package]] name = "pallet-authority-discovery" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -7116,7 +7974,7 @@ dependencies = [ [[package]] name = "pallet-authorship" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -7130,7 +7988,7 @@ dependencies = [ [[package]] name = "pallet-babe" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7154,7 +8012,7 @@ dependencies = [ [[package]] name = "pallet-bags-list" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "aquamarine", "docify", @@ -7176,7 +8034,7 @@ dependencies = [ [[package]] name = "pallet-balances" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "docify", "frame-benchmarking", @@ -7206,7 +8064,7 @@ dependencies = [ [[package]] name = "pallet-beefy" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -7226,9 +8084,9 @@ dependencies = [ [[package]] name = "pallet-beefy-mmr" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "binary-merkle-tree", "frame-support", "frame-system", @@ -7251,7 +8109,7 @@ dependencies = [ [[package]] name = "pallet-bounties" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7269,7 +8127,7 @@ dependencies = [ [[package]] name = "pallet-broker" version = "0.6.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "frame-benchmarking", @@ -7319,7 +8177,7 @@ dependencies = [ [[package]] name = "pallet-child-bounties" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7338,13 +8196,14 @@ dependencies = [ [[package]] name = "pallet-collator-selection" version = "9.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", "frame-system", "log", "pallet-authorship", + "pallet-balances", "pallet-session", "parity-scale-codec", "rand 0.8.5", @@ -7357,7 +8216,7 @@ dependencies = [ [[package]] name = "pallet-collective" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7374,7 +8233,7 @@ dependencies = [ [[package]] name = "pallet-contracts" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitflags 1.3.2", "environmental", @@ -7406,17 +8265,17 @@ dependencies = [ [[package]] name = "pallet-contracts-proc-macro" version = "18.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "pallet-contracts-uapi" version = "5.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitflags 1.3.2", "parity-scale-codec", @@ -7428,7 +8287,7 @@ dependencies = [ [[package]] name = "pallet-conviction-voting" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "assert_matches", "frame-benchmarking", @@ -7445,7 +8304,7 @@ dependencies = [ [[package]] name = "pallet-democracy" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7479,7 +8338,7 @@ dependencies = [ [[package]] name = "pallet-election-provider-multi-phase" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -7502,7 +8361,7 @@ dependencies = [ [[package]] name = "pallet-election-provider-support-benchmarking" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -7516,7 +8375,7 @@ dependencies = [ [[package]] name = "pallet-elections-phragmen" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7644,7 +8503,7 @@ dependencies = [ [[package]] name = "pallet-fast-unstake" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "docify", "frame-benchmarking", @@ -7663,7 +8522,7 @@ dependencies = [ [[package]] name = "pallet-grandpa" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7702,7 +8561,7 @@ dependencies = [ [[package]] name = "pallet-identity" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "enumflags2", "frame-benchmarking", @@ -7719,7 +8578,7 @@ dependencies = [ [[package]] name = "pallet-im-online" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7739,7 +8598,7 @@ dependencies = [ [[package]] name = "pallet-indices" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7756,7 +8615,7 @@ dependencies = [ [[package]] name = "pallet-insecure-randomness-collective-flip" version = "16.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -7799,7 +8658,7 @@ dependencies = [ [[package]] name = "pallet-membership" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7816,7 +8675,7 @@ dependencies = [ [[package]] name = "pallet-message-queue" version = "31.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "environmental", "frame-benchmarking", @@ -7836,7 +8695,7 @@ dependencies = [ [[package]] name = "pallet-mmr" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7848,13 +8707,54 @@ dependencies = [ "sp-io 30.0.0", "sp-mmr-primitives", "sp-runtime 31.0.1", - "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", + "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", +] + +[[package]] +name = "pallet-move" +version = "0.1.0" +source = "git+https://github.com/Magport/pallet-move?branch=main#3c477380e724de6c0290694874cce999cfa768d8" +dependencies = [ + "anyhow", + "bcs 0.1.4", + "blake2 0.10.6", + "frame-benchmarking", + "frame-support", + "frame-system", + "hashbrown 0.14.5", + "log", + "move-core-types", + "move-vm-backend", + "move-vm-backend-common", + "pallet-balances", + "parity-scale-codec", + "scale-info", + "serde", + "sp-api", + "sp-core 28.0.0", + "sp-runtime 31.0.1", + "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", +] + +[[package]] +name = "pallet-move-rpc" +version = "0.1.0" +source = "git+https://github.com/Magport/pallet-move?branch=main#3c477380e724de6c0290694874cce999cfa768d8" +dependencies = [ + "frame-support", + "jsonrpsee", + "pallet-move", + "parity-scale-codec", + "serde", + "sp-api", + "sp-blockchain", + "sp-runtime 31.0.1", ] [[package]] name = "pallet-multisig" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7870,7 +8770,7 @@ dependencies = [ [[package]] name = "pallet-nis" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -7886,7 +8786,7 @@ dependencies = [ [[package]] name = "pallet-nomination-pools" version = "25.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -7905,7 +8805,7 @@ dependencies = [ [[package]] name = "pallet-nomination-pools-benchmarking" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -7925,7 +8825,7 @@ dependencies = [ [[package]] name = "pallet-nomination-pools-runtime-api" version = "23.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "pallet-nomination-pools", "parity-scale-codec", @@ -7936,7 +8836,7 @@ dependencies = [ [[package]] name = "pallet-offences" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -7953,7 +8853,7 @@ dependencies = [ [[package]] name = "pallet-offences-benchmarking" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -8059,7 +8959,7 @@ dependencies = [ [[package]] name = "pallet-preimage" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8076,7 +8976,7 @@ dependencies = [ [[package]] name = "pallet-proxy" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8091,7 +8991,7 @@ dependencies = [ [[package]] name = "pallet-ranked-collective" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8110,7 +9010,7 @@ dependencies = [ [[package]] name = "pallet-recovery" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8125,7 +9025,7 @@ dependencies = [ [[package]] name = "pallet-referenda" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "assert_matches", "frame-benchmarking", @@ -8144,7 +9044,7 @@ dependencies = [ [[package]] name = "pallet-root-testing" version = "4.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -8159,7 +9059,7 @@ dependencies = [ [[package]] name = "pallet-scheduler" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "docify", "frame-benchmarking", @@ -8177,7 +9077,7 @@ dependencies = [ [[package]] name = "pallet-session" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -8199,7 +9099,7 @@ dependencies = [ [[package]] name = "pallet-session-benchmarking" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8216,7 +9116,7 @@ dependencies = [ [[package]] name = "pallet-society" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8234,7 +9134,7 @@ dependencies = [ [[package]] name = "pallet-staking" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-election-provider-support", @@ -8257,18 +9157,18 @@ dependencies = [ [[package]] name = "pallet-staking-reward-curve" version = "11.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "pallet-staking-reward-fn" version = "19.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "log", "sp-arithmetic 23.0.0", @@ -8277,7 +9177,7 @@ dependencies = [ [[package]] name = "pallet-staking-runtime-api" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "sp-api", @@ -8287,7 +9187,7 @@ dependencies = [ [[package]] name = "pallet-state-trie-migration" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8304,7 +9204,7 @@ dependencies = [ [[package]] name = "pallet-sudo" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "docify", "frame-benchmarking", @@ -8320,7 +9220,7 @@ dependencies = [ [[package]] name = "pallet-timestamp" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "docify", "frame-benchmarking", @@ -8340,7 +9240,7 @@ dependencies = [ [[package]] name = "pallet-tips" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8359,7 +9259,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -8375,7 +9275,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc" version = "30.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "jsonrpsee", "pallet-transaction-payment-rpc-runtime-api", @@ -8391,7 +9291,7 @@ dependencies = [ [[package]] name = "pallet-transaction-payment-rpc-runtime-api" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "pallet-transaction-payment", "parity-scale-codec", @@ -8403,7 +9303,7 @@ dependencies = [ [[package]] name = "pallet-treasury" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "docify", "frame-benchmarking", @@ -8422,7 +9322,7 @@ dependencies = [ [[package]] name = "pallet-utility" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8438,7 +9338,7 @@ dependencies = [ [[package]] name = "pallet-vesting" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8453,7 +9353,7 @@ dependencies = [ [[package]] name = "pallet-whitelist" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8468,7 +9368,7 @@ dependencies = [ [[package]] name = "pallet-xcm" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bounded-collections 0.2.0", "frame-benchmarking", @@ -8491,7 +9391,7 @@ dependencies = [ [[package]] name = "pallet-xcm-benchmarks" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-benchmarking", "frame-support", @@ -8511,8 +9411,8 @@ dependencies = [ name = "parachain-magnet-node" version = "0.6.0" dependencies = [ - "array-bytes 6.2.2", - "clap", + "array-bytes 6.2.3", + "clap 4.5.8", "color-print", "cumulus-client-cli", "cumulus-client-collator", @@ -8546,6 +9446,7 @@ dependencies = [ "mp-coretime-bulk", "mp-system", "pallet-balances", + "pallet-move-rpc", "pallet-pot-rpc", "pallet-transaction-payment", "pallet-transaction-payment-rpc", @@ -8614,6 +9515,7 @@ dependencies = [ "cumulus-pallet-session-benchmarking", "cumulus-pallet-xcm", "cumulus-pallet-xcmp-queue", + "cumulus-primitives-aura", "cumulus-primitives-core", "cumulus-primitives-timestamp", "cumulus-primitives-utility", @@ -8657,6 +9559,7 @@ dependencies = [ "pallet-insecure-randomness-collective-flip", "pallet-liquidation", "pallet-message-queue", + "pallet-move", "pallet-pot", "pallet-pot-runtime-api", "pallet-precompile-substrate-utils", @@ -8705,7 +9608,7 @@ dependencies = [ [[package]] name = "parachains-common" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-primitives-core", "cumulus-primitives-utility", @@ -8747,7 +9650,7 @@ dependencies = [ "log", "lz4", "memmap2 0.5.10", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "siphasher 0.3.11", "snap", @@ -8756,9 +9659,9 @@ dependencies = [ [[package]] name = "parity-scale-codec" -version = "3.6.9" +version = "3.6.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "881331e34fa842a2fb61cc2db9643a8fedc615e47cfcc52597d1af0db9a7e8fe" +checksum = "306800abfa29c7f16596b5970a588435e3d5b3149683d00c12b699cc19f895ee" dependencies = [ "arrayvec 0.7.4", "bitvec", @@ -8771,11 +9674,11 @@ dependencies = [ [[package]] name = "parity-scale-codec-derive" -version = "3.6.9" +version = "3.6.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be30eaf4b0a9fba5336683b38de57bb86d179a35862ba6bfcf57625d006bde5b" +checksum = "d830939c76d294956402033aee57a6da7b438f2294eb94864c37b0569053a42c" dependencies = [ - "proc-macro-crate 2.0.0", + "proc-macro-crate 3.1.0", "proc-macro2", "quote", "syn 1.0.109", @@ -8812,12 +9715,12 @@ dependencies = [ [[package]] name = "parking_lot" -version = "0.12.1" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" dependencies = [ "lock_api", - "parking_lot_core 0.9.9", + "parking_lot_core 0.9.10", ] [[package]] @@ -8836,15 +9739,24 @@ dependencies = [ [[package]] name = "parking_lot_core" -version = "0.9.9" +version = "0.9.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c42a9226546d68acdd9c0a280d17ce19bfe27a46bf68784e4066115788d008e" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" dependencies = [ "cfg-if", "libc", - "redox_syscall 0.4.1", + "redox_syscall 0.5.2", "smallvec", - "windows-targets 0.48.5", + "windows-targets 0.52.5", +] + +[[package]] +name = "parse-zoneinfo" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f2a05b18d44e2957b88f96ba460715e295bc1d7510468a2f3d3b44535d26c24" +dependencies = [ + "regex", ] [[package]] @@ -8855,9 +9767,9 @@ checksum = "7924d1d0ad836f665c9065e26d016c673ece3993f30d340068b16f282afc1156" [[package]] name = "paste" -version = "1.0.14" +version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" [[package]] name = "pbkdf2" @@ -8865,7 +9777,7 @@ version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d95f5254224e617595d2cc3cc73ff0a5eaf2637519e25f03388154e9378b6ffa" dependencies = [ - "crypto-mac 0.11.0", + "crypto-mac 0.11.1", ] [[package]] @@ -8900,9 +9812,9 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "pest" -version = "2.7.9" +version = "2.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "311fb059dee1a7b802f036316d790138c613a4e8b180c822e3925a662e9f0c95" +checksum = "560131c633294438da9f7c4b08189194b20946c8274c6b9e38881a7874dc8ee8" dependencies = [ "memchr", "thiserror", @@ -8911,9 +9823,9 @@ dependencies = [ [[package]] name = "pest_derive" -version = "2.7.9" +version = "2.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f73541b156d32197eecda1a4014d7f868fd2bcb3c550d5386087cfba442bf69c" +checksum = "26293c9193fbca7b1a3bf9b79dc1e388e927e6cacaa78b4a3ab705a1d3d41459" dependencies = [ "pest", "pest_generator", @@ -8921,38 +9833,96 @@ dependencies = [ [[package]] name = "pest_generator" -version = "2.7.9" +version = "2.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c35eeed0a3fab112f75165fdc026b3913f4183133f19b49be773ac9ea966e8bd" +checksum = "3ec22af7d3fb470a85dd2ca96b7c577a1eb4ef6f1683a9fe9a8c16e136c04687" dependencies = [ "pest", "pest_meta", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "pest_meta" -version = "2.7.9" +version = "2.7.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2adbf29bb9776f28caece835398781ab24435585fe0d4dc1374a61db5accedca" +checksum = "d7a240022f37c361ec1878d646fc5b7d7c4d28d5946e1a80ad5a7a4f4ca0bdcd" dependencies = [ "once_cell", "pest", "sha2 0.10.8", ] +[[package]] +name = "petgraph" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "467d164a6de56270bd7c4d070df81d07beace25012d5103ced4e9ff08d6afdb7" +dependencies = [ + "fixedbitset 0.2.0", + "indexmap 1.9.3", +] + [[package]] name = "petgraph" version = "0.6.4" +source = "git+https://github.com/eigerco/petgraph.git?branch=master#1d8299983104e293b5343b930bb086e6b49b2d85" +dependencies = [ + "fixedbitset 0.4.2", + "hashbrown 0.14.5", + "indexmap 2.2.6", +] + +[[package]] +name = "petgraph" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1d3afd2628e69da2be385eb6f2fd57c8ac7977ceeff6dc166ff1657b0e386a9" +checksum = "b4c5cc86750666a3ed20bdaf5ca2a0344f9c67674cae0515bec2da16fbaa47db" dependencies = [ - "fixedbitset", + "fixedbitset 0.4.2", "indexmap 2.2.6", ] +[[package]] +name = "phf" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ade2d8b8f33c7333b51bcf0428d37e217e9f32192ae4772156f65063b8ce03dc" +dependencies = [ + "phf_shared", +] + +[[package]] +name = "phf_codegen" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8d39688d359e6b34654d328e262234662d16cc0f60ec8dcbe5e718709342a5a" +dependencies = [ + "phf_generator", + "phf_shared", +] + +[[package]] +name = "phf_generator" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48e4cc64c2ad9ebe670cb8fd69dd50ae301650392e81c05f9bfcb2d5bdbc24b0" +dependencies = [ + "phf_shared", + "rand 0.8.5", +] + +[[package]] +name = "phf_shared" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90fcb95eef784c2ac79119d1dd819e162b5da872ce6f3c3abe1e8ca1c082f72b" +dependencies = [ + "siphasher 0.3.11", +] + [[package]] name = "pin-project" version = "1.1.5" @@ -8970,7 +9940,7 @@ checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -8993,12 +9963,12 @@ checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" [[package]] name = "piper" -version = "0.2.1" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "668d31b1c4eba19242f2088b2bf3316b82ca31082a8335764db4e083db7485d4" +checksum = "ae1d5c74c9876f070d3e8fd503d748c7d974c3e48da8f41350fa5222ef9b4391" dependencies = [ "atomic-waker", - "fastrand 2.0.2", + "fastrand 2.1.0", "futures-io", ] @@ -9018,16 +9988,10 @@ version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" -[[package]] -name = "platforms" -version = "3.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db23d408679286588f4d4644f965003d056e3dd5abcaaa938116871d7ce2fee7" - [[package]] name = "polkadot-approval-distribution" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "futures", @@ -9047,7 +10011,7 @@ dependencies = [ [[package]] name = "polkadot-availability-bitfield-distribution" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "always-assert", "futures", @@ -9063,7 +10027,7 @@ dependencies = [ [[package]] name = "polkadot-availability-distribution" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "derive_more", "fatality", @@ -9086,7 +10050,7 @@ dependencies = [ [[package]] name = "polkadot-availability-recovery" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "fatality", @@ -9109,10 +10073,10 @@ dependencies = [ [[package]] name = "polkadot-cli" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cfg-if", - "clap", + "clap 4.5.8", "frame-benchmarking-cli", "futures", "log", @@ -9137,7 +10101,7 @@ dependencies = [ [[package]] name = "polkadot-collator-protocol" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "fatality", @@ -9159,7 +10123,7 @@ dependencies = [ [[package]] name = "polkadot-core-primitives" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "scale-info", @@ -9171,7 +10135,7 @@ dependencies = [ [[package]] name = "polkadot-dispute-distribution" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "derive_more", "fatality", @@ -9196,7 +10160,7 @@ dependencies = [ [[package]] name = "polkadot-erasure-coding" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "polkadot-node-primitives", @@ -9210,7 +10174,7 @@ dependencies = [ [[package]] name = "polkadot-gossip-support" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "futures-timer", @@ -9232,7 +10196,7 @@ dependencies = [ [[package]] name = "polkadot-network-bridge" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "always-assert", "async-trait", @@ -9240,7 +10204,7 @@ dependencies = [ "fatality", "futures", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "polkadot-node-metrics", "polkadot-node-network-protocol", "polkadot-node-subsystem", @@ -9255,7 +10219,7 @@ dependencies = [ [[package]] name = "polkadot-node-collation-generation" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "parity-scale-codec", @@ -9273,7 +10237,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-approval-voting" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "derive_more", @@ -9306,7 +10270,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-av-store" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "futures", @@ -9328,7 +10292,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-backing" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "fatality", @@ -9347,7 +10311,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-bitfield-signing" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "polkadot-node-subsystem", @@ -9362,7 +10326,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-candidate-validation" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -9383,7 +10347,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-chain-api" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "polkadot-node-metrics", @@ -9397,7 +10361,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-chain-selection" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "futures-timer", @@ -9414,7 +10378,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-dispute-coordinator" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "fatality", "futures", @@ -9433,7 +10397,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-parachains-inherent" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -9450,7 +10414,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-prospective-parachains" version = "6.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "fatality", @@ -9467,7 +10431,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-provisioner" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "fatality", @@ -9484,10 +10448,10 @@ dependencies = [ [[package]] name = "polkadot-node-core-pvf" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "always-assert", - "array-bytes 6.2.2", + "array-bytes 6.2.3", "blake3", "cfg-if", "futures", @@ -9517,7 +10481,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-pvf-checker" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "polkadot-node-primitives", @@ -9533,7 +10497,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-pvf-common" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cfg-if", "cpu-time", @@ -9560,7 +10524,7 @@ dependencies = [ [[package]] name = "polkadot-node-core-runtime-api" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "polkadot-node-metrics", @@ -9575,13 +10539,13 @@ dependencies = [ [[package]] name = "polkadot-node-jaeger" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "lazy_static", "log", "mick-jaeger", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "polkadot-node-primitives", "polkadot-primitives", "sc-network", @@ -9593,7 +10557,7 @@ dependencies = [ [[package]] name = "polkadot-node-metrics" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bs58 0.5.1", "futures", @@ -9612,7 +10576,7 @@ dependencies = [ [[package]] name = "polkadot-node-network-protocol" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-channel 1.9.0", "async-trait", @@ -9636,7 +10600,7 @@ dependencies = [ [[package]] name = "polkadot-node-primitives" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "bounded-vec", @@ -9659,7 +10623,7 @@ dependencies = [ [[package]] name = "polkadot-node-subsystem" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "polkadot-node-jaeger", "polkadot-node-subsystem-types", @@ -9669,7 +10633,7 @@ dependencies = [ [[package]] name = "polkadot-node-subsystem-types" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "bitvec", @@ -9697,7 +10661,7 @@ dependencies = [ [[package]] name = "polkadot-node-subsystem-util" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "derive_more", @@ -9708,7 +10672,7 @@ dependencies = [ "kvdb", "parity-db", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "pin-project", "polkadot-node-jaeger", "polkadot-node-metrics", @@ -9732,13 +10696,13 @@ dependencies = [ [[package]] name = "polkadot-overseer" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", "futures-timer", "orchestra", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "polkadot-node-metrics", "polkadot-node-network-protocol", "polkadot-node-primitives", @@ -9754,7 +10718,7 @@ dependencies = [ [[package]] name = "polkadot-parachain-primitives" version = "6.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bounded-collections 0.2.0", "derive_more", @@ -9771,7 +10735,7 @@ dependencies = [ [[package]] name = "polkadot-primitives" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "hex-literal", @@ -9797,7 +10761,7 @@ dependencies = [ [[package]] name = "polkadot-rpc" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "jsonrpsee", "mmr-rpc", @@ -9830,7 +10794,7 @@ dependencies = [ [[package]] name = "polkadot-runtime-common" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitvec", "frame-benchmarking", @@ -9882,7 +10846,7 @@ dependencies = [ [[package]] name = "polkadot-runtime-metrics" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bs58 0.5.1", "frame-benchmarking", @@ -9895,7 +10859,7 @@ dependencies = [ [[package]] name = "polkadot-runtime-parachains" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bitflags 1.3.2", "bitvec", @@ -9944,11 +10908,12 @@ dependencies = [ [[package]] name = "polkadot-service" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "frame-benchmarking", "frame-benchmarking-cli", + "frame-metadata-hash-extension", "frame-support", "frame-system", "frame-system-rpc-runtime-api", @@ -9966,7 +10931,7 @@ dependencies = [ "pallet-transaction-payment-rpc-runtime-api", "parity-db", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "polkadot-approval-distribution", "polkadot-availability-bitfield-distribution", "polkadot-availability-distribution", @@ -10062,7 +11027,7 @@ dependencies = [ [[package]] name = "polkadot-statement-distribution" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "arrayvec 0.7.4", "bitvec", @@ -10085,7 +11050,7 @@ dependencies = [ [[package]] name = "polkadot-statement-table" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "polkadot-primitives", @@ -10111,7 +11076,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6380dbe1fb03ecc74ad55d841cfc75480222d153ba69ddcb00977866cbdabdb8" dependencies = [ "polkavm-derive-impl 0.5.0", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -10132,7 +11097,7 @@ dependencies = [ "polkavm-common 0.5.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -10144,7 +11109,7 @@ dependencies = [ "polkavm-common 0.9.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -10154,7 +11119,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8ba81f7b5faac81e528eb6158a6f3c9e0bb1008e0ffa19653bc8dea925ecb429" dependencies = [ "polkavm-derive-impl 0.9.0", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -10175,15 +11140,15 @@ dependencies = [ [[package]] name = "polling" -version = "3.6.0" +version = "3.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0c976a60b2d7e99d6f229e414670a9b85d13ac305cc6d1e9c134de58c5aaaf6" +checksum = "a3ed00ed3fbf728b5816498ecd316d1716eecaced9c0c8d2c5a6740ca214985b" dependencies = [ "cfg-if", "concurrent-queue", - "hermit-abi", + "hermit-abi 0.4.0", "pin-project-lite 0.2.14", - "rustix 0.38.32", + "rustix 0.38.34", "tracing", "windows-sys 0.52.0", ] @@ -10261,7 +11226,7 @@ source = "git+https://github.com/paritytech/frontier?branch=polkadot-v1.7.0#c5d6 dependencies = [ "case", "num_enum", - "prettyplease 0.2.19", + "prettyplease 0.2.20", "proc-macro2", "quote", "sp-core-hashing 15.0.0", @@ -10299,20 +11264,20 @@ dependencies = [ ] [[package]] -name = "prettier-please" -version = "0.2.0" +name = "pretty" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22020dfcf177fcc7bf5deaf7440af371400c67c0de14c399938d8ed4fb4645d3" +checksum = "ad9940b913ee56ddd94aec2d3cd179dd47068236f42a1a6415ccf9d880ce2a61" dependencies = [ - "proc-macro2", - "syn 2.0.60", + "arrayvec 0.5.2", + "typed-arena", ] [[package]] name = "prettyplease" -version = "0.1.11" +version = "0.1.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f28f53e8b192565862cf99343194579a022eb9c7dd3a8d03134734803c7b3125" +checksum = "6c8646e95016a7a6c4adea95bafa8a16baab64b583356217f2c85db4a39d9a86" dependencies = [ "proc-macro2", "syn 1.0.109", @@ -10320,12 +11285,12 @@ dependencies = [ [[package]] name = "prettyplease" -version = "0.2.19" +version = "0.2.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ac2cf0f2e4f42b49f5ffd07dae8d746508ef7526c13940e5f524012ae6c6550" +checksum = "5f12335488a2f3b0a83b14edad48dca9879ce89b2edd10e80237e4e852dd645e" dependencies = [ "proc-macro2", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -10360,12 +11325,12 @@ dependencies = [ [[package]] name = "proc-macro-crate" -version = "1.3.1" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" +checksum = "e17d47ce914bf4de440332250b0edd23ce48c005f59fab39d3335866b114f11a" dependencies = [ - "once_cell", - "toml_edit 0.19.15", + "thiserror", + "toml 0.5.11", ] [[package]] @@ -10418,29 +11383,29 @@ checksum = "834da187cfe638ae8abb0203f0b33e5ccdb02a28e7199f2f47b3e2754f50edca" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "proc-macro2" -version = "1.0.85" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22244ce15aa966053a896d1accb3a6e68469b97c7f33f284b99f0d576879fc23" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] [[package]] name = "prometheus" -version = "0.13.3" +version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "449811d15fbdf5ceb5c1144416066429cf82316e2ec8ce0c1f6f8a02e7bbcf8c" +checksum = "3d33c28a30771f7f96db69893f78b857f7450d7e0237e9c8fc6427a81bae7ed1" dependencies = [ "cfg-if", "fnv", "lazy_static", "memchr", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "thiserror", ] @@ -10452,7 +11417,7 @@ checksum = "5d6fa99d535dd930d1249e6c79cb3c2915f9172a540fe2b02a4c8f9ca954721e" dependencies = [ "dtoa", "itoa", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "prometheus-client-derive-encode", ] @@ -10464,7 +11429,7 @@ checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -10479,12 +11444,12 @@ dependencies = [ [[package]] name = "prost" -version = "0.12.4" +version = "0.12.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0f5d036824e4761737860779c906171497f6d55681139d8312388f8fe398922" +checksum = "deb1435c188b76130da55f17a466d252ff7b1418b2ad3e037d127b94e3411f29" dependencies = [ "bytes", - "prost-derive 0.12.4", + "prost-derive 0.12.6", ] [[package]] @@ -10499,8 +11464,8 @@ dependencies = [ "lazy_static", "log", "multimap", - "petgraph", - "prettyplease 0.1.11", + "petgraph 0.6.5", + "prettyplease 0.1.25", "prost 0.11.9", "prost-types", "regex", @@ -10524,15 +11489,15 @@ dependencies = [ [[package]] name = "prost-derive" -version = "0.12.4" +version = "0.12.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19de2de2a00075bf566bee3bd4db014b11587e84184d3f7a791bc17f1a8e9e48" +checksum = "81bddcdb20abf9501610992b6759a4c888aef7d1a7247ef75e2404275ac24af1" dependencies = [ "anyhow", "itertools 0.12.1", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -10684,7 +11649,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.14", + "getrandom 0.2.15", ] [[package]] @@ -10715,6 +11680,15 @@ dependencies = [ "rand_core 0.6.4", ] +[[package]] +name = "rand_xoshiro" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f97cdb2a36ed4183de61b2f824cc45c9f1037f28afe0a322e9fff4c108b5aaa" +dependencies = [ + "rand_core 0.6.4", +] + [[package]] name = "rawpointer" version = "0.2.1" @@ -10771,13 +11745,22 @@ dependencies = [ "bitflags 1.3.2", ] +[[package]] +name = "redox_syscall" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" +dependencies = [ + "bitflags 2.6.0", +] + [[package]] name = "redox_users" version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bd283d9651eeda4b2a83a43c1c91b266c40fd76ecd39a50a8c630ae69dc72891" dependencies = [ - "getrandom 0.2.14", + "getrandom 0.2.15", "libredox", "thiserror", ] @@ -10796,22 +11779,22 @@ dependencies = [ [[package]] name = "ref-cast" -version = "1.0.22" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4846d4c50d1721b1a3bef8af76924eef20d5e723647333798c1b519b3a9473f" +checksum = "ccf0a6f84d5f1d581da8b41b47ec8600871962f2a528115b542b362d4b744931" dependencies = [ "ref-cast-impl", ] [[package]] name = "ref-cast-impl" -version = "1.0.22" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5fddb4f8d99b0a2ebafc65a87a69a7b9875e4b1ae1f00db265d300ef7f28bccc" +checksum = "bcc303e793d3734489387d205e9b186fac9c6cfacedd98cbb2e8a5943595f3e6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -10828,14 +11811,14 @@ dependencies = [ [[package]] name = "regex" -version = "1.10.4" +version = "1.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c117dbdfde9c8308975b6a18d71f3f385c89461f7b3fb054288ecf2a2058ba4c" +checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.4.6", - "regex-syntax 0.8.3", + "regex-automata 0.4.7", + "regex-syntax 0.8.4", ] [[package]] @@ -10849,13 +11832,13 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.6" +version = "0.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b83b8b9847f9bf95ef68afb0b8e6cdb80f498442f5179a29fad448fcc1eaea" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" dependencies = [ "aho-corasick", "memchr", - "regex-syntax 0.8.3", + "regex-syntax 0.8.4", ] [[package]] @@ -10866,9 +11849,9 @@ checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] name = "regex-syntax" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adad44e29e4c806119491a7f06f03de4d1af22c3a680dd47f1e6e179439d1f56" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" [[package]] name = "resolv-conf" @@ -10887,7 +11870,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" dependencies = [ "hmac 0.12.1", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -10929,7 +11912,7 @@ checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" dependencies = [ "cc", "cfg-if", - "getrandom 0.2.14", + "getrandom 0.2.15", "libc", "spin 0.9.8", "untrusted 0.9.0", @@ -10980,11 +11963,12 @@ dependencies = [ [[package]] name = "rococo-runtime" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "binary-merkle-tree", "frame-benchmarking", "frame-executive", + "frame-metadata-hash-extension", "frame-support", "frame-system", "frame-system-benchmarking", @@ -11076,7 +12060,7 @@ dependencies = [ [[package]] name = "rococo-runtime-constants" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "polkadot-primitives", @@ -11133,9 +12117,9 @@ dependencies = [ [[package]] name = "rustc-demangle" -version = "0.1.23" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" [[package]] name = "rustc-hash" @@ -11164,7 +12148,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" dependencies = [ - "semver 1.0.22", + "semver 1.0.23", ] [[package]] @@ -11206,14 +12190,14 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.32" +version = "0.38.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65e04861e65f21776e67888bfbea442b3642beaa0138fdb1dd7a84a52dffdb89" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "errno", "libc", - "linux-raw-sys 0.4.13", + "linux-raw-sys 0.4.14", "windows-sys 0.52.0", ] @@ -11231,9 +12215,9 @@ dependencies = [ [[package]] name = "rustls" -version = "0.21.10" +version = "0.21.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9d5a6813c0759e4609cd494e8e725babae6a2ca7b62a5536a13daaec6fcb7ba" +checksum = "3f56a14d1f48b391359b22f731fd4bd7e43c97f3c50eee276f3aa09c94784d3e" dependencies = [ "log", "ring 0.17.8", @@ -11274,9 +12258,9 @@ dependencies = [ [[package]] name = "rustversion" -version = "1.0.15" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80af6f9131f277a45a3fba6ce8e2258037bb0477a67e610d3c1fe046ab31de47" +checksum = "955d28af4278de8121b7ebeb796b6a45735dc01436d898801014aced2773a3d6" [[package]] name = "ruzstd" @@ -11313,9 +12297,9 @@ dependencies = [ [[package]] name = "ryu" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e86697c916019a8588c99b5fac3cead74ec0b4b819707a682fd4d23fa0ce1ba1" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" [[package]] name = "safe-mix" @@ -11328,9 +12312,9 @@ dependencies = [ [[package]] name = "safe_arch" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f398075ce1e6a179b46f51bd88d0598b92b00d3551f1a2d4ac49e771b56ac354" +checksum = "c3460605018fdc9612bce72735cba0d27efbcd9904780d44c7e3a9948f96148a" dependencies = [ "bytemuck", ] @@ -11347,7 +12331,7 @@ dependencies = [ [[package]] name = "sc-allocator" version = "23.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "log", "sp-core 28.0.0", @@ -11358,7 +12342,7 @@ dependencies = [ [[package]] name = "sc-authority-discovery" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -11369,7 +12353,7 @@ dependencies = [ "multihash 0.18.1", "multihash-codetable", "parity-scale-codec", - "prost 0.12.4", + "prost 0.12.6", "prost-build", "rand 0.8.5", "sc-client-api", @@ -11387,7 +12371,7 @@ dependencies = [ [[package]] name = "sc-basic-authorship" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "futures-timer", @@ -11409,7 +12393,7 @@ dependencies = [ [[package]] name = "sc-block-builder" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "sp-api", @@ -11424,9 +12408,9 @@ dependencies = [ [[package]] name = "sc-chain-spec" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "docify", "log", "memmap2 0.9.4", @@ -11450,23 +12434,23 @@ dependencies = [ [[package]] name = "sc-chain-spec-derive" version = "11.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "sc-cli" version = "0.36.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "bip39", "chrono", - "clap", + "clap 4.5.8", "fdlimit", "futures", "itertools 0.10.5", @@ -11502,13 +12486,13 @@ dependencies = [ [[package]] name = "sc-client-api" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "fnv", "futures", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-executor", "sc-transaction-pool-api", "sc-utils", @@ -11529,7 +12513,7 @@ dependencies = [ [[package]] name = "sc-client-db" version = "0.35.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "hash-db", "kvdb", @@ -11539,7 +12523,7 @@ dependencies = [ "log", "parity-db", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-client-api", "sc-state-db", "schnellru", @@ -11555,7 +12539,7 @@ dependencies = [ [[package]] name = "sc-consensus" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -11563,7 +12547,7 @@ dependencies = [ "libp2p-identity", "log", "mockall", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-client-api", "sc-utils", "serde", @@ -11580,7 +12564,7 @@ dependencies = [ [[package]] name = "sc-consensus-aura" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -11609,7 +12593,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "fork-tree", @@ -11619,7 +12603,7 @@ dependencies = [ "num-rational", "num-traits", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-client-api", "sc-consensus", "sc-consensus-epochs", @@ -11645,7 +12629,7 @@ dependencies = [ [[package]] name = "sc-consensus-babe-rpc" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "jsonrpsee", @@ -11667,16 +12651,16 @@ dependencies = [ [[package]] name = "sc-consensus-beefy" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "async-channel 1.9.0", "async-trait", "fnv", "futures", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-client-api", "sc-consensus", "sc-network", @@ -11703,13 +12687,13 @@ dependencies = [ [[package]] name = "sc-consensus-beefy-rpc" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "jsonrpsee", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-consensus-beefy", "sc-rpc", "serde", @@ -11722,7 +12706,7 @@ dependencies = [ [[package]] name = "sc-consensus-epochs" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "fork-tree", "parity-scale-codec", @@ -11735,10 +12719,10 @@ dependencies = [ [[package]] name = "sc-consensus-grandpa" version = "0.19.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "ahash 0.8.11", - "array-bytes 6.2.2", + "array-bytes 6.2.3", "async-trait", "dyn-clone", "finality-grandpa", @@ -11747,7 +12731,7 @@ dependencies = [ "futures-timer", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "sc-block-builder", "sc-chain-spec", @@ -11778,7 +12762,7 @@ dependencies = [ [[package]] name = "sc-consensus-grandpa-rpc" version = "0.19.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "finality-grandpa", "futures", @@ -11798,7 +12782,7 @@ dependencies = [ [[package]] name = "sc-consensus-manual-seal" version = "0.35.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "assert_matches", "async-trait", @@ -11833,7 +12817,7 @@ dependencies = [ [[package]] name = "sc-consensus-slots" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -11856,10 +12840,10 @@ dependencies = [ [[package]] name = "sc-executor" version = "0.32.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-executor-common", "sc-executor-wasmtime", "schnellru", @@ -11878,7 +12862,7 @@ dependencies = [ [[package]] name = "sc-executor-common" version = "0.29.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "sc-allocator", "sp-maybe-compressed-blob", @@ -11890,13 +12874,13 @@ dependencies = [ [[package]] name = "sc-executor-wasmtime" version = "0.29.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "anyhow", "cfg-if", "libc", "log", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rustix 0.36.17", "sc-allocator", "sc-executor-common", @@ -11908,7 +12892,7 @@ dependencies = [ [[package]] name = "sc-informant" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "ansi_term", "futures", @@ -11925,10 +12909,10 @@ dependencies = [ [[package]] name = "sc-keystore" version = "25.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", - "parking_lot 0.12.1", + "array-bytes 6.2.3", + "parking_lot 0.12.3", "serde_json", "sp-application-crypto 30.0.0", "sp-core 28.0.0", @@ -11939,7 +12923,7 @@ dependencies = [ [[package]] name = "sc-mixnet" version = "0.4.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "array-bytes 4.2.0", "arrayvec 0.7.4", @@ -11952,7 +12936,7 @@ dependencies = [ "mixnet", "multiaddr", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-client-api", "sc-network", "sc-transaction-pool-api", @@ -11968,9 +12952,9 @@ dependencies = [ [[package]] name = "sc-network" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "async-channel 1.9.0", "async-trait", "asynchronous-codec", @@ -11985,7 +12969,7 @@ dependencies = [ "log", "mockall", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "partial_sort", "pin-project", "rand 0.8.5", @@ -12011,14 +12995,14 @@ dependencies = [ [[package]] name = "sc-network-bitswap" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-channel 1.9.0", "cid", "futures", "libp2p-identity", "log", - "prost 0.12.4", + "prost 0.12.6", "prost-build", "sc-client-api", "sc-network", @@ -12031,7 +13015,7 @@ dependencies = [ [[package]] name = "sc-network-common" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "bitflags 1.3.2", @@ -12048,7 +13032,7 @@ dependencies = [ [[package]] name = "sc-network-gossip" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "ahash 0.8.11", "futures", @@ -12067,15 +13051,15 @@ dependencies = [ [[package]] name = "sc-network-light" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "async-channel 1.9.0", "futures", "libp2p-identity", "log", "parity-scale-codec", - "prost 0.12.4", + "prost 0.12.6", "prost-build", "sc-client-api", "sc-network", @@ -12088,9 +13072,9 @@ dependencies = [ [[package]] name = "sc-network-sync" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "async-channel 1.9.0", "async-trait", "fork-tree", @@ -12100,7 +13084,7 @@ dependencies = [ "log", "mockall", "parity-scale-codec", - "prost 0.12.4", + "prost 0.12.6", "prost-build", "sc-client-api", "sc-consensus", @@ -12124,9 +13108,9 @@ dependencies = [ [[package]] name = "sc-network-transactions" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "futures", "libp2p", "log", @@ -12143,9 +13127,9 @@ dependencies = [ [[package]] name = "sc-offchain" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "bytes", "fnv", "futures", @@ -12157,7 +13141,7 @@ dependencies = [ "num_cpus", "once_cell", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "sc-client-api", "sc-network", @@ -12177,7 +13161,7 @@ dependencies = [ [[package]] name = "sc-proposer-metrics" version = "0.17.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "log", "substrate-prometheus-endpoint", @@ -12186,13 +13170,13 @@ dependencies = [ [[package]] name = "sc-rpc" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "jsonrpsee", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-block-builder", "sc-chain-spec", "sc-client-api", @@ -12218,7 +13202,7 @@ dependencies = [ [[package]] name = "sc-rpc-api" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "jsonrpsee", "parity-scale-codec", @@ -12238,7 +13222,7 @@ dependencies = [ [[package]] name = "sc-rpc-server" version = "11.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "http", "jsonrpsee", @@ -12253,16 +13237,16 @@ dependencies = [ [[package]] name = "sc-rpc-spec-v2" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "futures", "futures-util", "hex", "jsonrpsee", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-chain-spec", "sc-client-api", "sc-rpc", @@ -12283,7 +13267,7 @@ dependencies = [ [[package]] name = "sc-service" version = "0.35.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "directories", @@ -12293,7 +13277,7 @@ dependencies = [ "jsonrpsee", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "pin-project", "rand 0.8.5", "sc-chain-spec", @@ -12346,20 +13330,20 @@ dependencies = [ [[package]] name = "sc-state-db" version = "0.30.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sp-core 28.0.0", ] [[package]] name = "sc-storage-monitor" version = "0.16.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "clap", + "clap 4.5.8", "fs4", "log", "sp-core 28.0.0", @@ -12370,7 +13354,7 @@ dependencies = [ [[package]] name = "sc-sync-state-rpc" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "jsonrpsee", "parity-scale-codec", @@ -12389,7 +13373,7 @@ dependencies = [ [[package]] name = "sc-sysinfo" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "derive_more", "futures", @@ -12410,13 +13394,13 @@ dependencies = [ [[package]] name = "sc-telemetry" version = "15.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "chrono", "futures", "libp2p", "log", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "pin-project", "rand 0.8.5", "sc-utils", @@ -12429,7 +13413,7 @@ dependencies = [ [[package]] name = "sc-tracing" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "ansi_term", "chrono", @@ -12438,7 +13422,7 @@ dependencies = [ "libc", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "regex", "rustc-hash", "sc-client-api", @@ -12459,18 +13443,18 @@ dependencies = [ [[package]] name = "sc-tracing-proc-macro" version = "11.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "sc-transaction-pool" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -12478,7 +13462,7 @@ dependencies = [ "linked-hash-map", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sc-client-api", "sc-transaction-pool-api", "sc-utils", @@ -12497,7 +13481,7 @@ dependencies = [ [[package]] name = "sc-transaction-pool-api" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -12513,14 +13497,14 @@ dependencies = [ [[package]] name = "sc-utils" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-channel 1.9.0", "futures", "futures-timer", "lazy_static", "log", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "prometheus", "sp-arithmetic 23.0.0", ] @@ -12558,7 +13542,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3475108a1b62c7efd1b5c65974f30109a598b2f45f23c9ae030acb9686966db" dependencies = [ "darling 0.14.4", - "proc-macro-crate 1.3.1", + "proc-macro-crate 1.1.3", "proc-macro2", "quote", "syn 1.0.109", @@ -12586,7 +13570,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "995491f110efdc6bea96d6a746140e32bfceb4ea47510750a5467295a4707a25" dependencies = [ "darling 0.14.4", - "proc-macro-crate 1.3.1", + "proc-macro-crate 1.1.3", "proc-macro2", "quote", "syn 1.0.109", @@ -12649,9 +13633,9 @@ dependencies = [ [[package]] name = "schnellru" -version = "0.2.1" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "772575a524feeb803e5b0fcbc6dd9f367e579488197c94c6e4023aad2305774d" +checksum = "c9a8ef13a93c54d20580de1e5c413e624e53121d42fc7e2c11d10ef7f8b02367" dependencies = [ "ahash 0.8.11", "cfg-if", @@ -12672,7 +13656,7 @@ dependencies = [ "rand 0.7.3", "rand_core 0.5.1", "sha2 0.8.2", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -12701,13 +13685,13 @@ dependencies = [ "aead", "arrayref", "arrayvec 0.7.4", - "curve25519-dalek 4.1.2", + "curve25519-dalek 4.1.3", "getrandom_or_panic", "merlin 3.0.0", "rand_core 0.6.4", "serde_bytes", "sha2 0.10.8", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -12743,7 +13727,7 @@ dependencies = [ "der", "generic-array 0.14.7", "pkcs8", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -12803,11 +13787,11 @@ dependencies = [ [[package]] name = "security-framework" -version = "2.10.0" +version = "2.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "770452e37cad93e0a50d5abc3990d2bc351c36d0328f86cefec2f2fb206eaef6" +checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.6.0", "core-foundation", "core-foundation-sys", "libc", @@ -12816,9 +13800,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.10.0" +version = "2.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41f3cc463c0ef97e11c3461a9d3787412d30e8e7eb907c79180c4a57bf7c04ef" +checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" dependencies = [ "core-foundation-sys", "libc", @@ -12844,9 +13828,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.22" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92d43fe69e652f3df9bdc2b85b2854a0825b86e4fb76bc44d945137d053639ca" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" dependencies = [ "serde", ] @@ -12868,9 +13852,9 @@ dependencies = [ [[package]] name = "serde_bytes" -version = "0.11.14" +version = "0.11.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b8497c313fd43ab992087548117643f6fcd935cbf36f176ffda0aacf9591734" +checksum = "387cc504cb06bb40a96c8e04e951fe01854cf6bc921053c954e4a606d9675c6a" dependencies = [ "serde", ] @@ -12883,14 +13867,14 @@ checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "serde_json" -version = "1.0.117" +version = "1.0.118" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3" +checksum = "d947f6b3163d8857ea16c4fa0dd4840d52f3041039a85decd46867eb1abef2e4" dependencies = [ "itoa", "ryu", @@ -12899,9 +13883,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "0.6.5" +version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb3622f419d1296904700073ea6cc23ad690adbd66f13ea683df73298736f0c1" +checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" dependencies = [ "serde", ] @@ -12966,6 +13950,18 @@ dependencies = [ "digest 0.10.7", ] +[[package]] +name = "sha3" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f81199417d4e5de3f04b1e871023acea7389672c4135918f05aa9cbf2f2fa809" +dependencies = [ + "block-buffer 0.9.0", + "digest 0.9.0", + "keccak", + "opaque-debug 0.3.1", +] + [[package]] name = "sha3" version = "0.10.8" @@ -12993,9 +13989,9 @@ checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" [[package]] name = "signal-hook-registry" -version = "1.4.1" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" dependencies = [ "libc", ] @@ -13028,6 +14024,17 @@ name = "simple-mermaid" version = "0.1.0" source = "git+https://github.com/kianenigma/simple-mermaid.git?rev=e48b187bcfd5cc75111acd9d241f1bd36604344b#e48b187bcfd5cc75111acd9d241f1bd36604344b" +[[package]] +name = "simplelog" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4bc0ffd69814a9b251d43afcabf96dad1b29f5028378056257be9e3fecc9f720" +dependencies = [ + "chrono", + "log", + "termcolor", +] + [[package]] name = "siphasher" version = "0.3.11" @@ -13040,6 +14047,16 @@ version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" +[[package]] +name = "sized-chunks" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "16d69225bde7a69b235da73377861095455d298f2b970996eec25ddbb42b3d1e" +dependencies = [ + "bitmaps", + "typenum", +] + [[package]] name = "slab" version = "0.4.9" @@ -13058,7 +14075,7 @@ checksum = "826167069c09b99d56f31e9ae5c99049e932a98c9dc2dac47645b08dbbf76ba7" [[package]] name = "slot-range-helper" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "enumn", "parity-scale-codec", @@ -13076,6 +14093,16 @@ dependencies = [ "version_check", ] +[[package]] +name = "slug" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3bd94acec9c8da640005f8e135a39fc0372e74535e6b368b7a04b875f784c8c4" +dependencies = [ + "deunicode", + "wasm-bindgen", +] + [[package]] name = "smallvec" version = "1.13.2" @@ -13142,7 +14169,7 @@ dependencies = [ "serde", "serde_json", "sha2 0.10.8", - "sha3", + "sha3 0.10.8", "siphasher 0.3.11", "slab", "smallvec", @@ -13160,7 +14187,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eca99148e026936bbc444c3708748207033968e4ef1c33bfc885660ae4d44d21" dependencies = [ "arrayvec 0.7.4", - "async-lock 3.3.0", + "async-lock 3.4.0", "atomic-take", "base64 0.21.7", "bip39", @@ -13197,7 +14224,7 @@ dependencies = [ "serde", "serde_json", "sha2 0.10.8", - "sha3", + "sha3 0.10.8", "siphasher 1.0.1", "slab", "smallvec", @@ -13231,7 +14258,7 @@ dependencies = [ "log", "lru 0.11.1", "no-std-net", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "pin-project", "rand 0.8.5", "rand_chacha 0.3.1", @@ -13250,8 +14277,8 @@ version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0e6f1898682b618b81570047b9d870b3faaff6ae1891b468eddd94d7f903c2fe" dependencies = [ - "async-channel 2.2.1", - "async-lock 3.3.0", + "async-channel 2.3.1", + "async-lock 3.4.0", "base64 0.21.7", "blake2-rfc", "derive_more", @@ -13267,7 +14294,7 @@ dependencies = [ "log", "lru 0.12.3", "no-std-net", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "pin-project", "rand 0.8.5", "rand_chacha 0.3.1", @@ -13295,12 +14322,12 @@ dependencies = [ "aes-gcm", "blake2 0.10.6", "chacha20poly1305", - "curve25519-dalek 4.1.2", + "curve25519-dalek 4.1.3", "rand_core 0.6.4", "ring 0.17.8", "rustc_version 0.4.0", "sha2 0.10.8", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -13315,9 +14342,9 @@ dependencies = [ [[package]] name = "socket2" -version = "0.5.6" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05ffd9c0a93b7543e062e759284fcf5f5e3b098501104bfbdde4d404db792871" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" dependencies = [ "libc", "windows-sys 0.52.0", @@ -13343,7 +14370,7 @@ dependencies = [ [[package]] name = "sp-api" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "hash-db", "log", @@ -13364,15 +14391,15 @@ dependencies = [ [[package]] name = "sp-api-proc-macro" version = "15.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "Inflector", "blake2 0.10.6", - "expander 2.1.0", + "expander 2.2.1", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -13392,7 +14419,7 @@ dependencies = [ [[package]] name = "sp-application-crypto" version = "30.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "scale-info", @@ -13420,7 +14447,7 @@ dependencies = [ [[package]] name = "sp-arithmetic" version = "23.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "integer-sqrt", "num-traits", @@ -13452,7 +14479,7 @@ dependencies = [ [[package]] name = "sp-authority-discovery" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "scale-info", @@ -13465,7 +14492,7 @@ dependencies = [ [[package]] name = "sp-block-builder" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "sp-api", "sp-inherents", @@ -13476,12 +14503,12 @@ dependencies = [ [[package]] name = "sp-blockchain" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "futures", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "schnellru", "sp-api", "sp-consensus", @@ -13494,7 +14521,7 @@ dependencies = [ [[package]] name = "sp-consensus" version = "0.32.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "futures", @@ -13509,7 +14536,7 @@ dependencies = [ [[package]] name = "sp-consensus-aura" version = "0.32.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "parity-scale-codec", @@ -13526,7 +14553,7 @@ dependencies = [ [[package]] name = "sp-consensus-babe" version = "0.32.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "parity-scale-codec", @@ -13545,7 +14572,7 @@ dependencies = [ [[package]] name = "sp-consensus-beefy" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "lazy_static", "parity-scale-codec", @@ -13565,7 +14592,7 @@ dependencies = [ [[package]] name = "sp-consensus-grandpa" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "finality-grandpa", "log", @@ -13583,7 +14610,7 @@ dependencies = [ [[package]] name = "sp-consensus-slots" version = "0.32.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "scale-info", @@ -13598,7 +14625,7 @@ version = "26.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d0db34a19be2efa0398a9506a365392d93a85220856d55e0eb78165ad2e1bedc" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "bip39", "bitflags 1.3.2", "blake2 0.10.6", @@ -13616,7 +14643,7 @@ dependencies = [ "log", "merlin 2.0.1", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "paste", "primitive-types", "rand 0.8.5", @@ -13643,9 +14670,9 @@ dependencies = [ [[package]] name = "sp-core" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "bandersnatch_vrfs", "bip39", "bitflags 1.3.2", @@ -13663,7 +14690,7 @@ dependencies = [ "log", "merlin 3.0.0", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "paste", "primitive-types", "rand 0.8.5", @@ -13696,14 +14723,14 @@ dependencies = [ "byteorder", "digest 0.10.7", "sha2 0.10.8", - "sha3", + "sha3 0.10.8", "twox-hash", ] [[package]] name = "sp-core-hashing" version = "15.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "sp-crypto-hashing", ] @@ -13711,7 +14738,7 @@ dependencies = [ [[package]] name = "sp-crypto-ec-utils" version = "0.10.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" dependencies = [ "ark-bls12-377", "ark-bls12-377-ext", @@ -13731,33 +14758,33 @@ dependencies = [ [[package]] name = "sp-crypto-hashing" version = "0.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "blake2b_simd", "byteorder", "digest 0.10.7", "sha2 0.10.8", - "sha3", + "sha3 0.10.8", "twox-hash", ] [[package]] name = "sp-crypto-hashing-proc-macro" version = "0.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "quote", "sp-crypto-hashing", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "sp-database" version = "10.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "kvdb", - "parking_lot 0.12.1", + "parking_lot 0.12.3", ] [[package]] @@ -13768,27 +14795,27 @@ checksum = "50535e1a5708d3ba5c1195b59ebefac61cc8679c2c24716b87a86e8b7ed2e4a1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "sp-debug-derive" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "sp-debug-derive" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -13806,7 +14833,7 @@ dependencies = [ [[package]] name = "sp-externalities" version = "0.25.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "environmental", "parity-scale-codec", @@ -13817,7 +14844,7 @@ dependencies = [ [[package]] name = "sp-externalities" version = "0.25.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" dependencies = [ "environmental", "parity-scale-codec", @@ -13827,7 +14854,7 @@ dependencies = [ [[package]] name = "sp-genesis-builder" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "serde_json", "sp-api", @@ -13838,7 +14865,7 @@ dependencies = [ [[package]] name = "sp-inherents" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "impl-trait-for-tuples", @@ -13877,7 +14904,7 @@ dependencies = [ [[package]] name = "sp-io" version = "30.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bytes", "ed25519-dalek", @@ -13902,7 +14929,7 @@ dependencies = [ [[package]] name = "sp-keyring" version = "31.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "sp-core 28.0.0", "sp-runtime 31.0.1", @@ -13916,7 +14943,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1db18ab01b2684856904c973d2be7dbf9ab3607cf706a7bd6648812662e5e7c5" dependencies = [ "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sp-core 26.0.0", "sp-externalities 0.23.0", "thiserror", @@ -13925,10 +14952,10 @@ dependencies = [ [[package]] name = "sp-keystore" version = "0.34.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "sp-core 28.0.0", "sp-externalities 0.25.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", "thiserror", @@ -13937,7 +14964,7 @@ dependencies = [ [[package]] name = "sp-maybe-compressed-blob" version = "11.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "thiserror", "zstd 0.12.4", @@ -13946,7 +14973,7 @@ dependencies = [ [[package]] name = "sp-metadata-ir" version = "0.6.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-metadata 16.0.0", "parity-scale-codec", @@ -13957,7 +14984,7 @@ dependencies = [ [[package]] name = "sp-mixnet" version = "0.4.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "scale-info", @@ -13969,7 +14996,7 @@ dependencies = [ [[package]] name = "sp-mmr-primitives" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "ckb-merkle-mountain-range", "log", @@ -13987,7 +15014,7 @@ dependencies = [ [[package]] name = "sp-npos-elections" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "scale-info", @@ -14001,7 +15028,7 @@ dependencies = [ [[package]] name = "sp-offchain" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "sp-api", "sp-core 28.0.0", @@ -14022,7 +15049,7 @@ dependencies = [ [[package]] name = "sp-panic-handler" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "backtrace", "lazy_static", @@ -14032,7 +15059,7 @@ dependencies = [ [[package]] name = "sp-rpc" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "rustc-hash", "serde", @@ -14065,7 +15092,7 @@ dependencies = [ [[package]] name = "sp-runtime" version = "31.0.1" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "docify", "either", @@ -14108,7 +15135,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface" version = "24.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bytes", "impl-trait-for-tuples", @@ -14126,7 +15153,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface" version = "24.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" dependencies = [ "bytes", "impl-trait-for-tuples", @@ -14149,42 +15176,42 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9b2afcbd1bd18d323371111b66b7ac2870bdc1c86c3d7b0dae67b112ca52b4d8" dependencies = [ "Inflector", - "proc-macro-crate 1.3.1", + "proc-macro-crate 1.1.3", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "sp-runtime-interface-proc-macro" version = "17.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "Inflector", - "expander 2.1.0", + "expander 2.2.1", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "sp-runtime-interface-proc-macro" version = "17.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" dependencies = [ "Inflector", - "expander 2.1.0", + "expander 2.2.1", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "sp-session" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "scale-info", @@ -14199,7 +15226,7 @@ dependencies = [ [[package]] name = "sp-staking" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "impl-trait-for-tuples", "parity-scale-codec", @@ -14219,7 +15246,7 @@ dependencies = [ "hash-db", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "smallvec", "sp-core 26.0.0", @@ -14235,12 +15262,12 @@ dependencies = [ [[package]] name = "sp-state-machine" version = "0.35.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "hash-db", "log", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "smallvec", "sp-core 28.0.0", @@ -14256,10 +15283,10 @@ dependencies = [ [[package]] name = "sp-statement-store" version = "10.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "aes-gcm", - "curve25519-dalek 4.1.2", + "curve25519-dalek 4.1.3", "ed25519-dalek", "hkdf", "parity-scale-codec", @@ -14287,12 +15314,12 @@ checksum = "54c78c5a66682568cc7b153603c5d01a2cc8f5c221c7b1e921517a0eef18ae05" [[package]] name = "sp-std" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" [[package]] name = "sp-std" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" [[package]] name = "sp-storage" @@ -14311,7 +15338,7 @@ dependencies = [ [[package]] name = "sp-storage" version = "19.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "impl-serde", "parity-scale-codec", @@ -14324,7 +15351,7 @@ dependencies = [ [[package]] name = "sp-storage" version = "19.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" dependencies = [ "impl-serde", "parity-scale-codec", @@ -14336,7 +15363,7 @@ dependencies = [ [[package]] name = "sp-timestamp" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "parity-scale-codec", @@ -14362,7 +15389,7 @@ dependencies = [ [[package]] name = "sp-tracing" version = "16.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", @@ -14374,7 +15401,7 @@ dependencies = [ [[package]] name = "sp-tracing" version = "16.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" dependencies = [ "parity-scale-codec", "tracing", @@ -14385,7 +15412,7 @@ dependencies = [ [[package]] name = "sp-transaction-pool" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "sp-api", "sp-runtime 31.0.1", @@ -14394,7 +15421,7 @@ dependencies = [ [[package]] name = "sp-transaction-storage-proof" version = "26.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "parity-scale-codec", @@ -14419,7 +15446,7 @@ dependencies = [ "memory-db", "nohash-hasher", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "scale-info", "schnellru", @@ -14434,7 +15461,7 @@ dependencies = [ [[package]] name = "sp-trie" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "ahash 0.8.11", "hash-db", @@ -14442,7 +15469,7 @@ dependencies = [ "memory-db", "nohash-hasher", "parity-scale-codec", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "scale-info", "schnellru", @@ -14458,7 +15485,7 @@ dependencies = [ [[package]] name = "sp-version" version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "impl-serde", "parity-scale-codec", @@ -14475,12 +15502,12 @@ dependencies = [ [[package]] name = "sp-version-proc-macro" version = "13.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "parity-scale-codec", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -14500,7 +15527,7 @@ dependencies = [ [[package]] name = "sp-wasm-interface" version = "20.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "anyhow", "impl-trait-for-tuples", @@ -14513,7 +15540,7 @@ dependencies = [ [[package]] name = "sp-wasm-interface" version = "20.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#98a364fe6e7abf10819f5fddd3de0588f7c38700" +source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" dependencies = [ "impl-trait-for-tuples", "log", @@ -14539,7 +15566,7 @@ dependencies = [ [[package]] name = "sp-weights" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "bounded-collections 0.2.0", "parity-scale-codec", @@ -14589,11 +15616,10 @@ dependencies = [ [[package]] name = "sqlformat" -version = "0.2.3" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce81b7bd7c4493975347ef60d8c7e8b742d4694f4c49f93e0a12ea263938176c" +checksum = "f895e3734318cc55f1fe66258926c9b910c124d47520339efecbb6c59cec7c1f" dependencies = [ - "itertools 0.12.1", "nom", "unicode_categories", ] @@ -14732,7 +15758,7 @@ checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" [[package]] name = "staging-parachain-info" version = "0.7.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cumulus-primitives-core", "frame-support", @@ -14746,9 +15772,9 @@ dependencies = [ [[package]] name = "staging-xcm" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "array-bytes 6.2.2", + "array-bytes 6.2.3", "bounded-collections 0.2.0", "derivative", "environmental", @@ -14764,7 +15790,7 @@ dependencies = [ [[package]] name = "staging-xcm-builder" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "frame-system", @@ -14786,7 +15812,7 @@ dependencies = [ [[package]] name = "staging-xcm-executor" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "environmental", "frame-benchmarking", @@ -14847,7 +15873,7 @@ dependencies = [ "bitflags 1.3.2", "byteorder", "keccak", - "subtle 2.5.0", + "subtle 2.4.1", "zeroize", ] @@ -14874,9 +15900,9 @@ dependencies = [ [[package]] name = "strum" -version = "0.26.2" +version = "0.26.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d8cec3501a5194c432b2b7976db6b7d10ec95c253208b45f83f7136aa985e29" +checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06" [[package]] name = "strum_macros" @@ -14893,15 +15919,15 @@ dependencies = [ [[package]] name = "strum_macros" -version = "0.26.2" +version = "0.26.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6cf59daf282c0a494ba14fd21610a0325f9f90ec9d1231dea26bcb1d696c946" +checksum = "4c6bee85a5a24955dc440386795aa378cd9cf82acd5f764469152d2270e581be" dependencies = [ - "heck 0.4.1", + "heck 0.5.0", "proc-macro2", "quote", "rustversion", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -14920,12 +15946,12 @@ dependencies = [ [[package]] name = "substrate-build-script-utils" version = "11.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" [[package]] name = "substrate-frame-rpc-system" version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-system-rpc-runtime-api", "futures", @@ -14944,7 +15970,7 @@ dependencies = [ [[package]] name = "substrate-prometheus-endpoint" version = "0.17.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "hyper", "log", @@ -14956,7 +15982,7 @@ dependencies = [ [[package]] name = "substrate-rpc-client" version = "0.33.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", "jsonrpsee", @@ -14969,7 +15995,7 @@ dependencies = [ [[package]] name = "substrate-state-trie-migration-rpc" version = "27.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "jsonrpsee", "parity-scale-codec", @@ -14986,7 +16012,7 @@ dependencies = [ [[package]] name = "substrate-wasm-builder" version = "17.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "build-helper", "cargo_metadata", @@ -14996,7 +16022,7 @@ dependencies = [ "sp-maybe-compressed-blob", "strum 0.24.1", "tempfile", - "toml 0.8.12", + "toml 0.8.14", "walkdir", "wasm-opt", ] @@ -15009,9 +16035,9 @@ checksum = "2d67a5a62ba6e01cb2192ff309324cb4875d0c451d55fe2319433abe7a05a8ee" [[package]] name = "subtle" -version = "2.5.0" +version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" +checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" [[package]] name = "subtle-ng" @@ -15069,7 +16095,7 @@ dependencies = [ "quote", "scale-info", "subxt-metadata", - "syn 2.0.60", + "syn 2.0.68", "thiserror", "tokio", ] @@ -15097,11 +16123,11 @@ version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d5086ce2a90e723083ff19b77f06805d00e732eac3e19c86f6cd643d4255d334" dependencies = [ - "darling 0.20.8", + "darling 0.20.9", "parity-scale-codec", "proc-macro-error", "subxt-codegen", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -15152,9 +16178,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.60" +version = "2.0.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "909518bc7b1c9b779f1bbf07f2929d35af9f0f37e47c6e9ef7f9dddc1e1821f3" +checksum = "901fa70d88b9d6c98022e23b4136f9f3e54e4662c3bc1bd1d84a42a9a0f0c1e9" dependencies = [ "proc-macro2", "quote", @@ -15173,6 +16199,17 @@ dependencies = [ "unicode-xid", ] +[[package]] +name = "synstructure" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.68", +] + [[package]] name = "system-configuration" version = "0.5.1" @@ -15213,16 +16250,38 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" dependencies = [ "cfg-if", - "fastrand 2.0.2", - "rustix 0.38.32", + "fastrand 2.1.0", + "rustix 0.38.34", "windows-sys 0.52.0", ] +[[package]] +name = "tera" +version = "1.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ab9d851b45e865f178319da0abdbfe6acbc4328759ff18dafc3a41c16b4cd2ee" +dependencies = [ + "chrono", + "chrono-tz", + "globwalk", + "humansize", + "lazy_static", + "percent-encoding", + "pest", + "pest_derive", + "rand 0.8.5", + "regex", + "serde", + "serde_json", + "slug", + "unic-segment", +] + [[package]] name = "termcolor" -version = "1.4.1" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755" +checksum = "bab24d30b911b2376f3a13cc2cd443142f0c81dda04c118693e35b3835757755" dependencies = [ "winapi-util", ] @@ -15233,7 +16292,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "21bebf2b7c9e0a515f6e0f8c51dc0f8e4696391e6f1ff30379559f8365fb0df7" dependencies = [ - "rustix 0.38.32", + "rustix 0.38.34", "windows-sys 0.48.0", ] @@ -15243,6 +16302,12 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3369f5ac52d5eb6ab48c6b4ffdc8efbcad6b89c765749064ba298f2c68a16a76" +[[package]] +name = "textwrap" +version = "0.16.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23d434d3f8967a09480fb04132ebe0a3e088c173e6d0ee7897abbdf4eab0f8b9" + [[package]] name = "thiserror" version = "1.0.61" @@ -15269,7 +16334,7 @@ checksum = "e4c60d69f36615a077cc7663b9cb8e42275722d23e58a7fa3d2c7f2915d09d04" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -15280,7 +16345,7 @@ checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -15384,9 +16449,9 @@ dependencies = [ [[package]] name = "tinyvec" -version = "1.6.0" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" +checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" dependencies = [ "tinyvec_macros", ] @@ -15399,32 +16464,32 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.37.0" +version = "1.38.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1adbebffeca75fcfd058afa480fb6c0b81e165a0323f9c9d39c9697e37c46787" +checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" dependencies = [ "backtrace", "bytes", "libc", "mio", "num_cpus", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "pin-project-lite 0.2.14", "signal-hook-registry", - "socket2 0.5.6", + "socket2 0.5.7", "tokio-macros", "windows-sys 0.48.0", ] [[package]] name = "tokio-macros" -version = "2.2.0" +version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" +checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -15444,7 +16509,7 @@ version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" dependencies = [ - "rustls 0.21.10", + "rustls 0.21.12", "tokio", ] @@ -15485,36 +16550,25 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.12" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9dd1545e8208b4a5af1aa9bbd0b4cf7e9ea08fabc5d0a5c67fcaafa17433aa3" +checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit 0.22.11", + "toml_edit 0.22.14", ] [[package]] name = "toml_datetime" -version = "0.6.5" +version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" +checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" dependencies = [ "serde", ] -[[package]] -name = "toml_edit" -version = "0.19.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" -dependencies = [ - "indexmap 2.2.6", - "toml_datetime", - "winnow 0.5.40", -] - [[package]] name = "toml_edit" version = "0.20.7" @@ -15539,15 +16593,15 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.22.11" +version = "0.22.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb686a972ccef8537b39eead3968b0e8616cb5040dbb9bba93007c8e07c9215f" +checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" dependencies = [ "indexmap 2.2.6", "serde", "serde_spanned", "toml_datetime", - "winnow 0.6.6", + "winnow 0.6.13", ] [[package]] @@ -15571,7 +16625,7 @@ version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "61c5bb1d698276a2443e5ecfabc1008bf15a36c12e6a7176e7bf089ea9131140" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "bytes", "futures-core", "futures-util", @@ -15615,7 +16669,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -15641,7 +16695,7 @@ dependencies = [ [[package]] name = "tracing-gum" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "coarsetime", "polkadot-primitives", @@ -15652,13 +16706,13 @@ dependencies = [ [[package]] name = "tracing-gum-proc-macro" version = "5.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "expander 2.1.0", + "expander 2.2.1", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -15793,7 +16847,7 @@ dependencies = [ "ipconfig", "lazy_static", "lru-cache", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "resolv-conf", "smallvec", "thiserror", @@ -15811,10 +16865,10 @@ checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" [[package]] name = "try-runtime-cli" version = "0.38.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", - "clap", + "clap 4.5.8", "frame-remote-externalities", "frame-try-runtime", "hex", @@ -15862,6 +16916,12 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "typed-arena" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6af6ae20167a9ece4bcb41af5b80f8a1f1df981f6391189ce00fd257af04126a" + [[package]] name = "typenum" version = "1.17.0" @@ -15886,6 +16946,56 @@ dependencies = [ "static_assertions", ] +[[package]] +name = "unic-char-property" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8c57a407d9b6fa02b4795eb81c5b6652060a15a7903ea981f3d723e6c0be221" +dependencies = [ + "unic-char-range", +] + +[[package]] +name = "unic-char-range" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0398022d5f700414f6b899e10b8348231abf9173fa93144cbc1a43b9793c1fbc" + +[[package]] +name = "unic-common" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "80d7ff825a6a654ee85a63e80f92f054f904f21e7d12da4e22f9834a4aaa35bc" + +[[package]] +name = "unic-segment" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4ed5d26be57f84f176157270c112ef57b86debac9cd21daaabbe56db0f88f23" +dependencies = [ + "unic-ucd-segment", +] + +[[package]] +name = "unic-ucd-segment" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2079c122a62205b421f499da10f3ee0f7697f012f55b675e002483c73ea34700" +dependencies = [ + "unic-char-property", + "unic-char-range", + "unic-ucd-version", +] + +[[package]] +name = "unic-ucd-version" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96bd2f2237fe450fcd0a1d2f5f4e91711124f7857ba2e964247776ebeeb7b0c4" +dependencies = [ + "unic-common", +] + [[package]] name = "unicode-bidi" version = "0.3.15" @@ -15915,9 +17025,9 @@ checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" [[package]] name = "unicode-width" -version = "0.1.11" +version = "0.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51733f11c9c4f72aa0c160008246859e340b00807569a0da0e7a1079b27ba85" +checksum = "0336d538f7abc86d282a4189614dfaa90810dfc2c6f6427eaf88e16311dd225d" [[package]] name = "unicode-xid" @@ -15938,7 +17048,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fc1de2c688dc15305988b563c3854064043356019f97a4b46276fe734c4f07ea" dependencies = [ "crypto-common", - "subtle 2.5.0", + "subtle 2.4.1", ] [[package]] @@ -15967,9 +17077,9 @@ checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "url" -version = "2.5.0" +version = "2.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31e6302e3bb753d46e83516cae55ae196fc0c309407cf11ab35cc51a4c2a4633" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" dependencies = [ "form_urlencoded", "idna 0.5.0", @@ -15984,9 +17094,9 @@ checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da" [[package]] name = "utf8parse" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "valuable" @@ -15994,6 +17104,16 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" +[[package]] +name = "variant_count" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aae2faf80ac463422992abf4de234731279c058aaf33171ca70277c98406b124" +dependencies = [ + "quote", + "syn 1.0.109", +] + [[package]] name = "vcpkg" version = "0.2.15" @@ -16014,9 +17134,9 @@ checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" [[package]] name = "w3f-bls" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7335e4c132c28cc43caef6adb339789e599e39adbe78da0c4d547fad48cbc331" +checksum = "9c5da5fa2c6afa2c9158eaa7cd9aee249765eb32b5fb0c63ad8b9e79336a47ec" dependencies = [ "ark-bls12-377", "ark-bls12-381", @@ -16031,16 +17151,16 @@ dependencies = [ "rand_chacha 0.3.1", "rand_core 0.6.4", "sha2 0.10.8", - "sha3", + "sha3 0.10.8", "thiserror", "zeroize", ] [[package]] name = "waker-fn" -version = "1.1.1" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3c4517f54858c779bbcbf228f4fca63d121bf85fbecb2dc578cdf4a39395690" +checksum = "317211a0dc0ceedd78fb2ca9a44aed3d7b9b26f81870d485c07122b4350673b7" [[package]] name = "walkdir" @@ -16103,7 +17223,7 @@ dependencies = [ "once_cell", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", "wasm-bindgen-shared", ] @@ -16137,7 +17257,7 @@ checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -16255,9 +17375,9 @@ dependencies = [ [[package]] name = "wasmparser-nostd" -version = "0.100.1" +version = "0.100.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9157cab83003221bfd385833ab587a039f5d6fa7304854042ba358a3b09e0724" +checksum = "d5a015fe95f3504a94bb1462c717aae75253e39b9dd6c3fb1062c934535c64aa" dependencies = [ "indexmap-nostd", ] @@ -16489,13 +17609,14 @@ dependencies = [ [[package]] name = "westend-runtime" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "binary-merkle-tree", "bitvec", "frame-benchmarking", "frame-election-provider-support", "frame-executive", + "frame-metadata-hash-extension", "frame-support", "frame-system", "frame-system-benchmarking", @@ -16595,7 +17716,7 @@ dependencies = [ [[package]] name = "westend-runtime-constants" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "frame-support", "polkadot-primitives", @@ -16617,14 +17738,14 @@ dependencies = [ "either", "home", "once_cell", - "rustix 0.38.32", + "rustix 0.38.34", ] [[package]] name = "wide" -version = "0.7.16" +version = "0.7.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81a1851a719f11d1d2fea40e15c72f6c00de8c142d7ac47c1441cc7e4d0d5bc6" +checksum = "8a040b111774ab63a19ef46bbc149398ab372b4ccdcfd719e9814dbd7dfd76c8" dependencies = [ "bytemuck", "safe_arch", @@ -16654,11 +17775,11 @@ checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" [[package]] name = "winapi-util" -version = "0.1.6" +version = "0.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f29e6f9198ba0d26b4c9f07dbe6f9ed633e1f3d5b8b414090084349e46a52596" +checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" dependencies = [ - "winapi", + "windows-sys 0.52.0", ] [[package]] @@ -16911,9 +18032,9 @@ dependencies = [ [[package]] name = "winnow" -version = "0.6.6" +version = "0.6.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0c976aaaa0e1f90dbb21e9587cdaf1d9679a1cde8875c0d6bd83ab96a208352" +checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" dependencies = [ "memchr", ] @@ -16954,7 +18075,7 @@ version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c7e468321c81fb07fa7f4c636c3972b9100f0346e5b6a9f2bd0603a52f7ed277" dependencies = [ - "curve25519-dalek 4.1.2", + "curve25519-dalek 4.1.3", "rand_core 0.6.4", "serde", "zeroize", @@ -16981,12 +18102,12 @@ dependencies = [ [[package]] name = "xcm-procedural" version = "7.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#162c6796bac740802fe11c9e39f3094677d1f08f" +source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "Inflector", "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -16998,7 +18119,7 @@ dependencies = [ "futures", "log", "nohash-hasher", - "parking_lot 0.12.1", + "parking_lot 0.12.3", "rand 0.8.5", "static_assertions", ] @@ -17020,29 +18141,29 @@ dependencies = [ [[package]] name = "zerocopy" -version = "0.7.32" +version = "0.7.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74d4d3961e53fa4c9a25a8637fc2bfaf2595b3d3ae34875568a5cf64787716be" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.7.32" +version = "0.7.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] name = "zeroize" -version = "1.7.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" dependencies = [ "zeroize_derive", ] @@ -17055,7 +18176,7 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.60", + "syn 2.0.68", ] [[package]] @@ -17098,9 +18219,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "2.0.10+zstd.1.5.6" +version = "2.0.11+zstd.1.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c253a4914af5bafc8fa8c86ee400827e83cf6ec01195ec1f1ed8441bf00d65aa" +checksum = "75652c55c0b6f3e6f12eb786fe1bc960396bf05a1eb3bf1f3691c3610ac2e6d4" dependencies = [ "cc", "pkg-config", diff --git a/Cargo.toml b/Cargo.toml index c3c54cb..ce9001a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -65,6 +65,10 @@ subxt = {version = "0.33.0"} subxt-signer = {version = "0.33.0"} tracing = "0.1.37" url = "2.4.0" +termcolor = "1.1.3" +rand = "0.8.5" +rand_core = "0.6.4" +rand_chacha = "0.3.1" # Substrate Client sc-basic-authorship = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0" } @@ -166,7 +170,7 @@ cumulus-client-consensus-proposer = { git = "https://github.com/paritytech/polka cumulus-client-parachain-inherent = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0" } cumulus-client-service = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0"} # Cumulus Primitive -cumulus-primitives-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0" } +cumulus-primitives-aura = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } cumulus-primitives-core = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } cumulus-primitives-parachain-inherent = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0" } cumulus-primitives-timestamp ={ git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } @@ -224,3 +228,7 @@ pallet-evm-precompile-sha3fips = { version = "2.0.0-dev", git = "https://github. pallet-evm-precompile-simple = { version = "2.0.0-dev", git = "https://github.com/paritytech/frontier", branch = "polkadot-v1.7.0", default-features = false } pallet-hotfix-sufficients = { version = "1.0.0", git = "https://github.com/paritytech/frontier", branch = "polkadot-v1.7.0", default-features = false } precompile-utils = { git = "https://github.com/paritytech/frontier", branch = "polkadot-v1.7.0", default-features = false } + +#Move pallet +pallet-move = { git = "https://github.com/Magport/pallet-move", branch = "main", default-features = false } +pallet-move-rpc = {package = "pallet-move-rpc", git = "https://github.com/Magport/pallet-move", branch = "main", default-features = false } diff --git a/node/Cargo.toml b/node/Cargo.toml index 89aac85..02135af 100644 --- a/node/Cargo.toml +++ b/node/Cargo.toml @@ -116,6 +116,9 @@ fc-rpc-core = { workspace = true } fc-storage = { workspace = true } fc-consensus = { workspace = true } +#move pallet rpc +pallet-move-rpc = { workspace = true } + [build-dependencies] substrate-build-script-utils = { workspace = true } diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index cf1a7ab..f0eba8f 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -75,7 +75,7 @@ pub fn development_config() -> ChainSpec { Extensions { relay_chain: "rococo-local".into(), // You MUST set this to the correct network! - para_id: 2000, + para_id: 1000, }, ) .with_name("Development") @@ -108,7 +108,7 @@ pub fn development_config() -> ChainSpec { get_account_id_from_seed::("Ferdie//stash"), ], get_account_id_from_seed::("Alice"), - 2000.into(), + 1000.into(), )) .build() } @@ -126,7 +126,7 @@ pub fn local_testnet_config() -> ChainSpec { Extensions { relay_chain: "rococo-local".into(), // You MUST set this to the correct network! - para_id: 2000, + para_id: 1000, }, ) .with_name("Local Testnet") @@ -159,7 +159,7 @@ pub fn local_testnet_config() -> ChainSpec { get_account_id_from_seed::("Ferdie//stash"), ], get_account_id_from_seed::("Alice"), - 2000.into(), + 1000.into(), )) .with_protocol_id("magnet-local") .with_properties(properties) @@ -282,6 +282,11 @@ fn testnet_genesis( }, "evm": { "accounts": evm_accounts }, + //Move VM + "moveModule": { + "changeDefaultMoveStdlibBundleTo": Option::>::None, + "changeDefaultSubstrateStdlibBundleTo": Option::>::None, + }, "bulkPallet":{ "rpcUrl": b"ws://127.0.0.1:8855".to_vec(), "genesisHash": U256::from_str("0x4ea18c8f295ba903acbbed39c70ea0569cf1705fa954a537ffa3b8b7125eaf58").expect("internal U256 is valid; qed") diff --git a/node/src/rpc/mod.rs b/node/src/rpc/mod.rs index de58c75..b1cb868 100644 --- a/node/src/rpc/mod.rs +++ b/node/src/rpc/mod.rs @@ -73,6 +73,7 @@ where C::Api: fp_rpc::ConvertTransactionRuntimeApi, C::Api: fp_rpc::EthereumRuntimeRPCApi, C::Api: pallet_pot_rpc::PotRPCApi, + C::Api: pallet_move_rpc::MoveRuntimeApi, C: HeaderBackend + HeaderMetadata + 'static, C: BlockchainEvents + AuxStore + UsageProvider + StorageProvider, BE: Backend + 'static, @@ -81,6 +82,7 @@ where CIDP: CreateInherentDataProviders + Send + 'static, CT: fp_rpc::ConvertTransaction<::Extrinsic> + Send + Sync + 'static, { + use pallet_move_rpc::{MoveApiServer, MovePallet}; use pallet_transaction_payment_rpc::{TransactionPayment, TransactionPaymentApiServer}; use sc_consensus_manual_seal::rpc::{ManualSeal, ManualSealApiServer}; use substrate_frame_rpc_system::{System, SystemApiServer}; @@ -90,7 +92,8 @@ where io.merge(System::new(client.clone(), pool, deny_unsafe).into_rpc())?; io.merge(TransactionPayment::new(client.clone()).into_rpc())?; - io.merge(pallet_pot_rpc::Pot::new(client).into_rpc())?; + io.merge(pallet_pot_rpc::Pot::new(client.clone()).into_rpc())?; + io.merge(MovePallet::new(client.clone()).into_rpc())?; if let Some(command_sink) = command_sink { io.merge( diff --git a/node/src/service.rs b/node/src/service.rs index 6a1ac26..3f6a1b2 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -19,7 +19,10 @@ use cumulus_client_service::{ build_network, build_relay_chain_interface, prepare_node_config, start_relay_chain_tasks, BuildNetworkParams, CollatorSybilResistance, DARecoveryProfile, StartRelayChainTasksParams, }; -use cumulus_primitives_core::{relay_chain::CollatorPair, ParaId}; +use cumulus_primitives_core::{ + relay_chain::{CollatorPair, ValidationCode}, + ParaId, +}; use cumulus_relay_chain_interface::{OverseerHandle, RelayChainInterface}; // Substrate Imports @@ -397,7 +400,7 @@ async fn start_node_impl( spawn_frontier_tasks( &task_manager, client.clone(), - backend, + backend.clone(), frontier_backend, filter_pool, overrides, @@ -495,6 +498,7 @@ async fn start_node_impl( )?; start_consensus( client.clone(), + backend.clone(), block_import, prometheus_registry.as_ref(), telemetry.as_ref().map(|t| t.handle()), @@ -551,6 +555,7 @@ fn build_import_queue( fn start_consensus( client: Arc, + backend: Arc, block_import: ParachainBlockImport, prometheus_registry: Option<&Registry>, telemetry: Option, @@ -567,9 +572,10 @@ fn start_consensus( // order_record: Arc>>, bulk_mem_record: Arc>, ) -> Result<(), sc_service::Error> { - use cumulus_client_consensus_aura::collators::basic::{ - self as basic_aura, Params as BasicAuraParams, - }; + use cumulus_client_consensus_aura::collators::lookahead::{self as aura, Params as AuraParams}; + // use cumulus_client_consensus_aura::collators::basic::{ + // self as basic_aura, Params as BasicAuraParams, + // }; // use magnet_client_consensus_aura::collators::on_demand::{ // self as on_demand_aura, Params as BasicAuraParams, // }; @@ -596,8 +602,64 @@ fn start_consensus( client.clone(), ); let relay_chain_interface_clone = relay_chain_interface.clone(); - let params = BasicAuraParams { - // create_inherent_data_providers: move |_, ()| async move { Ok(()) }, + // let params = AuraParams { + // create_inherent_data_providers: move |_, ()| { + // let relay_chain_interface = relay_chain_interface.clone(); + // let order_record_clone = order_record.clone(); + // async move { + // let parent_hash = relay_chain_interface.best_block_hash().await?; + // let (relay_parent, validation_data, sequence_number, author_pub) = { + // let order_record_local = order_record_clone.lock().await; + // if order_record_local.validation_data.is_none() { + // (parent_hash, None, order_record_local.sequence_number, None) + // } else { + // ( + // order_record_local.relay_parent.expect("can not get relay_parent hash"), + // order_record_local.validation_data.clone(), + // order_record_local.sequence_number, + // order_record_local.author_pub.clone(), + // ) + // } + // }; + // let order_inherent = magnet_primitives_order::OrderInherentData::create_at( + // relay_parent, + // &relay_chain_interface, + // &validation_data, + // para_id, + // sequence_number, + // &author_pub, + // ) + // .await; + // let order_inherent = order_inherent.ok_or_else(|| { + // Box::::from( + // "Failed to create order inherent", + // ) + // })?; + // Ok(order_inherent) + // } + // }, + + // block_import, + // para_client: client.clone(), + // para_backend: backend.clone(), + // relay_client: relay_chain_interface_clone, + // code_hash_provider: move |block_hash| { + // client.code_at(block_hash).ok().map(|c| ValidationCode::from(c).hash()) + // }, + // sync_oracle, + // keystore, + // collator_key, + // para_id, + // overseer_handle, + // slot_duration, + // relay_chain_slot_duration, + // proposer, + // collator_service, + // // Very limited proposal time. + // authoring_duration: Duration::from_millis(1500), + // reinitialize: false, + // }; + let params = AuraParams { create_inherent_data_providers: move |_, ()| { let bulk_mem_record_clone = bulk_mem_record.clone(); async move { @@ -644,9 +706,14 @@ fn start_consensus( Ok(bulk_inherent) } }, + block_import, - para_client: client, + para_client: client.clone(), + para_backend: backend.clone(), relay_client: relay_chain_interface_clone, + code_hash_provider: move |block_hash| { + client.code_at(block_hash).ok().map(|c| ValidationCode::from(c).hash()) + }, sync_oracle, keystore, collator_key, @@ -657,12 +724,12 @@ fn start_consensus( proposer, collator_service, // Very limited proposal time. - authoring_duration: Duration::from_millis(500), - collation_request_receiver: None, + authoring_duration: Duration::from_millis(1500), + reinitialize: false, }; let fut = - basic_aura::run::( + aura::run::( params, ); task_manager.spawn_essential_handle().spawn("aura", None, fut); diff --git a/pallets/assets-bridge/src/lib.rs b/pallets/assets-bridge/src/lib.rs index 0b2e3a1..df53215 100644 --- a/pallets/assets-bridge/src/lib.rs +++ b/pallets/assets-bridge/src/lib.rs @@ -212,10 +212,6 @@ pub mod pallet { /// How much should be locked up in order to claim account. #[pallet::constant] type ClaimBond: Get>; - - /// The assets-bridge's evm contract deployer. - #[pallet::constant] - type EvmAdmins: Get>; } /// The Substrate Account for Evm Addresses @@ -263,6 +259,10 @@ pub mod pallet { #[pallet::getter(fn emergencies)] pub(super) type Emergencies = StorageValue<_, Vec, ValueQuery>; + #[pallet::storage] + #[pallet::getter(fn evm_contracts)] + pub type EvmContracts = StorageValue<_, BTreeSet, ValueQuery>; + #[pallet::genesis_config] #[derive(frame_support::DefaultNoBound)] pub struct GenesisConfig { @@ -315,6 +315,11 @@ pub mod pallet { UnPausedAll, // (asset_id, remove) BackForeign(T::AssetId, bool), + + ///(new_evm_contract) + AddNewContract(H160), + ///(evm contract) + RemoveContract(H160), } /// Error for evm accounts module. @@ -630,6 +635,50 @@ pub mod pallet { Ok(Pays::No.into()) } + + /// Add evm token contracts which can call precompile + /// Note: for admin + /// + /// - `new_contract`: + #[pallet::call_index(8)] + #[pallet::weight(Weight::from_parts(10_000, 0) + T::DbWeight::get().writes(1))] + pub fn add_evm_contract( + origin: OriginFor, + new_contract: H160, + ) -> DispatchResultWithPostInfo { + let who = ensure_signed(origin)?; + ensure!(Some(who) == Self::admin_key(), Error::::RequireAdmin); + + EvmContracts::::mutate(|contracts| { + contracts.insert(new_contract); + }); + + Self::deposit_event(Event::AddNewContract(new_contract.clone())); + + Ok(Pays::No.into()) + } + + /// Remove evm token contracts which can call precompile + /// Note: for admin + /// + /// - `new_contract`: + #[pallet::call_index(9)] + #[pallet::weight(Weight::from_parts(10_000, 0) + T::DbWeight::get().writes(1))] + pub fn remove_evm_contract( + origin: OriginFor, + contract: H160, + ) -> DispatchResultWithPostInfo { + let who = ensure_signed(origin)?; + ensure!(Some(who) == Self::admin_key(), Error::::RequireAdmin); + + EvmContracts::::mutate(|contracts| { + contracts.remove(&contract); + }); + + Self::deposit_event(Event::RemoveContract(contract)); + + Ok(Pays::No.into()) + } } } diff --git a/pallets/assets-bridge/src/mock.rs b/pallets/assets-bridge/src/mock.rs index a4e226a..4bec7f4 100644 --- a/pallets/assets-bridge/src/mock.rs +++ b/pallets/assets-bridge/src/mock.rs @@ -12,9 +12,7 @@ // along with this program. If not, see . pub use crate as assets_bridge; -pub use assets_bridge::{Config, Error, Event as AssetsBridgeEvent}; - -use sp_std::collections::btree_set::BTreeSet; +pub use assets_bridge::{Error, Event as AssetsBridgeEvent}; use frame_support::{ derive_impl, @@ -27,7 +25,6 @@ use frame_system::EnsureSigned; use sp_core::{H160, H256}; pub use sp_runtime::{ - testing::Header, traits::{BlakeTwo256, IdentityLookup}, AccountId32, BuildStorage, }; @@ -129,12 +126,6 @@ parameter_types! { // 0x1111111111111111111111111111111111111111 pub EvmCaller: H160 = H160::from_slice(&[17u8;20][..]); pub ClaimBond: u128 = 2; - //pub EvmAdmin: H160 = H160([0x05, 0xF9, 0xb8, 0xC7, 0x6E, 0x89, 0x87, 0xB8, 0x15, 0xC9, 0x3C, 0x27, 0xD1, 0x45, 0x20, 0xb6, 0xeD, 0x57, 0x39, 0x02]); - pub EvmAdmins: BTreeSet = { - let mut set = BTreeSet::new(); - set.insert(H160([0x05, 0xF9, 0xb8, 0xC7, 0x6E, 0x89, 0x87, 0xB8, 0x15, 0xC9, 0x3C, 0x27, 0xD1, 0x45, 0x20, 0xb6, 0xeD, 0x57, 0x39, 0x02])); - set - }; pub const WeightPerGas: Weight = Weight::from_parts(20_000, 0); pub const GasLimitPovSizeRatio: u64 = BLOCK_GAS_LIMIT.saturating_div(MAX_POV_SIZE); @@ -193,7 +184,6 @@ impl assets_bridge::Config for Test { type RuntimeEvent = RuntimeEvent; type EvmCaller = EvmCaller; type ClaimBond = ClaimBond; - type EvmAdmins = EvmAdmins; } pub const ALICE: [u8; 32] = [1u8; 32]; diff --git a/pallets/evm/precompile/transfer-to-magnet/src/lib.rs b/pallets/evm/precompile/transfer-to-magnet/src/lib.rs index 1fd7383..7c66d67 100644 --- a/pallets/evm/precompile/transfer-to-magnet/src/lib.rs +++ b/pallets/evm/precompile/transfer-to-magnet/src/lib.rs @@ -86,25 +86,24 @@ where let target_gas = handle.gas_limit(); let context = handle.context(); - log::info!( + log::debug!( "codeAddress:{:?}, input:{:?}, targetGas:{:?}", &code_address, &input, &target_gas ); let caller = context.caller.clone(); - if T::EvmAdmins::get().contains(&caller) == false { - log::error!("Caller is not the admin: {:?}", caller); + if pallet_assets_bridge::EvmContracts::::get().contains(&caller) == false { + log::error!("Caller {:?} is not in the admin allow set.", caller); + //log::error!("EvmContracts:{:?}", pallet_assets_bridge::EvmContracts::::get()); return Err(PrecompileFailure::Error { - exit_status: ExitError::Other("Caller is not the admin".into()), + exit_status: ExitError::Other("Caller is not in the admin allow set".into()), }); } let token_addr = solidity::decode_arguments::

(&input[4..36])?; let amount = solidity::decode_arguments::(&input[36..68])?; - log::info!("Caller:{:?}, tokenAddr:{:?}, amount:{:?}", &caller, &token_addr, &amount); - - log::info!("who bstr data len:{:?}", &input[100..].len()); + log::debug!("Caller:{:?}, tokenAddr:{:?}, amount:{:?}", &caller, &token_addr, &amount); if handle.is_static() { log::error!("Can't be static call error"); @@ -122,12 +121,12 @@ where }); }, }; - log::info!("to who ss58:{:?}", &to_who_ss58); + log::debug!("to who ss58:{:?}", &to_who_ss58); let to_who_id32 = AccountId32::from_ss58check(&to_who_ss58).map_err(|_| PrecompileFailure::Error { exit_status: ExitError::Other("AccountId32 from ss58check(string) failed".into()), })?; - log::info!("to_who_ss58:{:?}, to_who_id32:{:?}", &to_who_ss58, &to_who_id32); + log::debug!("to_who_ss58:{:?}, to_who_id32:{:?}", &to_who_ss58, &to_who_id32); let to_who: ::AccountId = to_who_id32.clone().into(); @@ -152,7 +151,7 @@ where let amount_saturated: T::Balance = amount.into(); - log::info!( + log::debug!( "Preparing to mint: AssetId: {:?}, Beneficiary: {:?}, Amount: {:?}", &asset_id, &to_who_ss58, @@ -237,9 +236,9 @@ where } let length_bytes = &input[offset..offset + 32]; - log::info!("length_bytes:{:?}", &length_bytes); + log::debug!("length_bytes:{:?}", &length_bytes); let length = u32::from_be_bytes(length_bytes[28..32].try_into().unwrap()) as usize; - log::info!("ss58 string len:{:?}", length); + log::debug!("ss58 string len:{:?}", length); if input.len() < offset + 32 + length { return Err("Input too short to contain string data"); @@ -248,7 +247,7 @@ where let string_data_start = offset + 32; let string_data_end = string_data_start + length; let string_data = &input[string_data_start..string_data_end]; - log::info!("ss58 string data:{:?}", &string_data); + log::debug!("ss58 string data:{:?}", &string_data); let mut result_string = from_utf8(string_data) .map_err(|_| "String data is not valid UTF-8")? diff --git a/pallets/evm/precompile/transfer-to-magnet/src/mock.rs b/pallets/evm/precompile/transfer-to-magnet/src/mock.rs index fab01a2..b1a9f47 100644 --- a/pallets/evm/precompile/transfer-to-magnet/src/mock.rs +++ b/pallets/evm/precompile/transfer-to-magnet/src/mock.rs @@ -35,7 +35,6 @@ use sp_runtime::{ traits::{BlakeTwo256, IdentityLookup}, BuildStorage, }; -use sp_std::collections::{btree_map::BTreeMap, btree_set::BTreeSet}; use std::str::FromStr; use xcm::latest::prelude::BodyId; @@ -137,18 +136,12 @@ parameter_types! { // 0x1111111111111111111111111111111111111111 pub EvmCaller: H160 = H160::from_slice(&[17u8;20][..]); pub ClaimBond: u64 = 10_000_000_000_000_000; - pub EvmAdmins: BTreeSet = { - let mut set = BTreeSet::new(); - set.insert(H160([0x05, 0xF9, 0xb8, 0xC7, 0x6E, 0x89, 0x87, 0xB8, 0x15, 0xC9, 0x3C, 0x27, 0xD1, 0x45, 0x20, 0xb6, 0xeD, 0x57, 0x39, 0x02])); - set - }; } impl pallet_assets_bridge::Config for Test { type RuntimeEvent = RuntimeEvent; type EvmCaller = EvmCaller; type ClaimBond = ClaimBond; - type EvmAdmins = EvmAdmins; } pub const UNIT: u64 = 1_000_000_000_000_000_000; diff --git a/pallets/evm/precompile/transfer-to-magnet/src/tests.rs b/pallets/evm/precompile/transfer-to-magnet/src/tests.rs index 6e0b0d3..6344bf1 100644 --- a/pallets/evm/precompile/transfer-to-magnet/src/tests.rs +++ b/pallets/evm/precompile/transfer-to-magnet/src/tests.rs @@ -21,6 +21,7 @@ use super::*; use crate::mock::*; use frame_support::assert_ok; use frame_support::traits::Currency; +use frame_system::RawOrigin; use pallet_evm::{AddressMapping, CallInfo, Error, ExitError, ExitReason, Runner}; use codec::Encode; @@ -280,6 +281,19 @@ fn transfer_to_substrate_works() { let asset_id = create_and_register_asset(token_addr); log::info!("asset id:{:?}", asset_id); + let admin_key = AccountId32::from([1u8; 32]); + let root_origin: frame_system::Origin = frame_system::RawOrigin::Root; + let _ = + pallet_assets_bridge::Pallet::::set_admin(root_origin.into(), admin_key.clone()); + let r = pallet_assets_bridge::Pallet::::add_evm_contract( + RawOrigin::Signed(admin_key.clone()).into(), + bob_evm, + ); + log::info!("add evm contract result:{:?}", r); + + let callers = pallet_assets_bridge::EvmContracts::::get(); + log::info!("callers:{:?}", callers); + let alice_token_amount_before = Assets::balance(asset_id, &ALICE); log::info!("alice token amount before mint:{:?}", alice_token_amount_before); @@ -390,6 +404,19 @@ fn gas_not_enough_error_works() { let token_addr = deploy_contract(bob_evm); log::info!("token addr:{:?}", token_addr); + let admin_key = AccountId32::from([1u8; 32]); + let root_origin: frame_system::Origin = frame_system::RawOrigin::Root; + let _ = + pallet_assets_bridge::Pallet::::set_admin(root_origin.into(), admin_key.clone()); + let r = pallet_assets_bridge::Pallet::::add_evm_contract( + RawOrigin::Signed(admin_key.clone()).into(), + bob_evm, + ); + log::info!("add evm contract result:{:?}", r); + + let callers = pallet_assets_bridge::EvmContracts::::get(); + log::info!("callers:{:?}", callers); + let asset_id = create_and_register_asset(token_addr); log::info!("asset id:{:?}", asset_id); @@ -491,6 +518,19 @@ fn gas_price_too_low_error_works() { let token_addr = deploy_contract(bob_evm); log::info!("token addr:{:?}", token_addr); + let admin_key = AccountId32::from([1u8; 32]); + let root_origin: frame_system::Origin = frame_system::RawOrigin::Root; + let _ = + pallet_assets_bridge::Pallet::::set_admin(root_origin.into(), admin_key.clone()); + let r = pallet_assets_bridge::Pallet::::add_evm_contract( + RawOrigin::Signed(admin_key.clone()).into(), + bob_evm, + ); + log::info!("add evm contract result:{:?}", r); + + let callers = pallet_assets_bridge::EvmContracts::::get(); + log::info!("callers:{:?}", callers); + let asset_id = create_and_register_asset(token_addr); log::info!("asset id:{:?}", asset_id); @@ -745,6 +785,19 @@ fn ss58address_error_works() { let token_addr = deploy_contract(bob_evm); log::info!("token addr:{:?}", token_addr); + let admin_key = AccountId32::from([1u8; 32]); + let root_origin: frame_system::Origin = frame_system::RawOrigin::Root; + let _ = + pallet_assets_bridge::Pallet::::set_admin(root_origin.into(), admin_key.clone()); + let r = pallet_assets_bridge::Pallet::::add_evm_contract( + RawOrigin::Signed(admin_key.clone()).into(), + bob_evm, + ); + log::info!("add evm contract result:{:?}", r); + + let callers = pallet_assets_bridge::EvmContracts::::get(); + log::info!("callers:{:?}", callers); + let asset_id = create_and_register_asset(token_addr); log::info!("asset id:{:?}", asset_id); @@ -929,7 +982,7 @@ fn not_evm_admin_works() { assert_eq!( reason, ExitReason::Error(ExitError::Other(std::borrow::Cow::Borrowed( - "Caller is not the admin" + "Caller is not in the admin allow set" ))) ); }, @@ -967,6 +1020,19 @@ fn token_and_assets_not_bound_works() { let token_addr = deploy_contract(bob_evm); log::info!("token addr:{:?}", token_addr); + let admin_key = AccountId32::from([1u8; 32]); + let root_origin: frame_system::Origin = frame_system::RawOrigin::Root; + let _ = + pallet_assets_bridge::Pallet::::set_admin(root_origin.into(), admin_key.clone()); + let r = pallet_assets_bridge::Pallet::::add_evm_contract( + RawOrigin::Signed(admin_key.clone()).into(), + bob_evm, + ); + log::info!("add evm contract result:{:?}", r); + + let callers = pallet_assets_bridge::EvmContracts::::get(); + log::info!("callers:{:?}", callers); + let asset_id = create_without_register_asset(); log::info!("asset id:{:?}", asset_id); diff --git a/runtime/Cargo.toml b/runtime/Cargo.toml index 8b46185..74c8739 100644 --- a/runtime/Cargo.toml +++ b/runtime/Cargo.toml @@ -100,6 +100,7 @@ pallet-collator-selection = { workspace = true, default-features = false } parachain-info = { workspace = true, default-features = false } parachains-common = { workspace = true, default-features = false } cumulus-primitives-timestamp ={ workspace = true, default-features = false } +cumulus-primitives-aura ={ workspace = true, default-features = false } #Frontier FRAME pallet-evm-chain-id = { workspace = true, default-features = false } @@ -118,6 +119,9 @@ fp-dynamic-fee = { workspace = true, default-features = false } fp-rpc = { workspace = true, default-features = false } fp-self-contained = { workspace = true, default-features = false, features = ["serde", "try-runtime"] } +#move pallet +pallet-move = { workspace = true, default-features = false } + [features] default = ["std", "with-rocksdb-weights"] with-rocksdb-weights = [] @@ -206,6 +210,8 @@ std = [ "pallet-scheduler/std", "pallet-insecure-randomness-collective-flip/std", "pallet-contracts/std", + "cumulus-primitives-aura/std", + "pallet-move/std", "pallet-bulk/std", "mp-coretime-bulk/std", ] @@ -249,6 +255,7 @@ runtime-benchmarks = [ "pallet-ranked-collective/runtime-benchmarks", "pallet-scheduler/runtime-benchmarks", "pallet-contracts/runtime-benchmarks", + "pallet-move/runtime-benchmarks", "pallet-bulk/runtime-benchmarks", ] @@ -301,7 +308,8 @@ try-runtime = [ "pallet-ranked-collective/try-runtime", "pallet-scheduler/try-runtime", "pallet-insecure-randomness-collective-flip/try-runtime", - "pallet-contracts/try-runtime", + "pallet-contracts/try-runtime", + "pallet-move/try-runtime", ] experimental = [ "pallet-aura/experimental" ] diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index f3b1932..2d15086 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -15,6 +15,7 @@ use core::ops::Div; use codec::{Decode, Encode}; +use cumulus_pallet_parachain_system::RelayNumberMonotonicallyIncreases; use cumulus_pallet_parachain_system::RelayNumberStrictlyIncreases; use smallvec::smallvec; use sp_api::impl_runtime_apis; @@ -29,7 +30,7 @@ use sp_runtime::{ IdentifyAccount, PostDispatchInfoOf, Saturating, UniqueSaturatedInto, Verify, }, transaction_validity::{TransactionSource, TransactionValidity, TransactionValidityError}, - ApplyExtrinsicResult, ConsensusEngineId, MultiSignature, Percent, + ApplyExtrinsicResult, ConsensusEngineId, DispatchError, MultiSignature, Percent, }; use scale_info::prelude::string::String; @@ -68,6 +69,7 @@ use frame_system::{ EnsureRoot, EnsureSigned, }; pub use pallet_balances::{Call as BalancesCall, NegativeImbalance}; +use pallet_move::api::{ModuleAbi, MoveApiEstimation}; use pallet_xcm::{EnsureXcm, IsVoiceOfBody}; pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; pub use sp_runtime::{MultiAddress, Perbill, Permill}; @@ -105,6 +107,7 @@ use pallet_ethereum::{ use pallet_evm::{ Account as EVMAccount, EnsureAddressTruncated, FeeCalculator, HashedAddressMapping, Runner, }; +pub use pallet_move; mod precompiles; use precompiles::FrontierPrecompiles; @@ -368,15 +371,15 @@ const AVERAGE_ON_INITIALIZE_RATIO: Perbill = Perbill::from_percent(5); /// `Operational` extrinsics. const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75); -/// We allow for 0.5 of a second of compute with a 12 second average block time. +/// We allow for 2 seconds of compute with a 6 second average block time. const MAXIMUM_BLOCK_WEIGHT: Weight = Weight::from_parts( - WEIGHT_REF_TIME_PER_SECOND.saturating_div(2), + WEIGHT_REF_TIME_PER_SECOND.saturating_mul(2), cumulus_primitives_core::relay_chain::MAX_POV_SIZE as u64, ); /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included /// into the relay chain. -const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1; +const UNINCLUDED_SEGMENT_CAPACITY: u32 = 3; /// How many parachain blocks are processed by the relay chain per parent. Limits the /// number of blocks authored per slot. const BLOCK_PROCESSING_VELOCITY: u32 = 1; @@ -482,6 +485,9 @@ impl pallet_timestamp::Config for Runtime { /// A timestamp: milliseconds since the unix epoch. type Moment = u64; type OnTimestampSet = Aura; + #[cfg(feature = "experimental")] + type MinimumPeriod = ConstU64<0>; + #[cfg(not(feature = "experimental"))] type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>; type WeightInfo = (); } @@ -573,6 +579,13 @@ parameter_types! { pub const RelayOrigin: AggregateMessageOrigin = AggregateMessageOrigin::Parent; } +type ConsensusHook = cumulus_pallet_aura_ext::FixedVelocityConsensusHook< + Runtime, + RELAY_CHAIN_SLOT_DURATION_MILLIS, + BLOCK_PROCESSING_VELOCITY, + UNINCLUDED_SEGMENT_CAPACITY, +>; + impl cumulus_pallet_parachain_system::Config for Runtime { type WeightInfo = (); type RuntimeEvent = RuntimeEvent; @@ -583,13 +596,8 @@ impl cumulus_pallet_parachain_system::Config for Runtime { type ReservedDmpWeight = ReservedDmpWeight; type XcmpMessageHandler = XcmpQueue; type ReservedXcmpWeight = ReservedXcmpWeight; - type CheckAssociatedRelayNumber = RelayNumberStrictlyIncreases; - type ConsensusHook = cumulus_pallet_aura_ext::FixedVelocityConsensusHook< - Runtime, - RELAY_CHAIN_SLOT_DURATION_MILLIS, - BLOCK_PROCESSING_VELOCITY, - UNINCLUDED_SEGMENT_CAPACITY, - >; + type CheckAssociatedRelayNumber = RelayNumberMonotonicallyIncreases; + type ConsensusHook = ConsensusHook; } impl parachain_info::Config for Runtime {} @@ -658,9 +666,9 @@ impl pallet_aura::Config for Runtime { type AuthorityId = AuraId; type DisabledValidators = (); type MaxAuthorities = ConstU32<100_000>; - type AllowMultipleBlocksPerSlot = ConstBool; + type AllowMultipleBlocksPerSlot = ConstBool; #[cfg(feature = "experimental")] - type SlotDuration = pallet_aura::MinimumPeriodTimesTwo; + type SlotDuration = ConstU64; } parameter_types! { @@ -952,18 +960,11 @@ parameter_types! { // 0x1111111111111111111111111111111111111111 pub EvmCaller: H160 = H160::from_slice(&[17u8;20][..]); pub ClaimBond: Balance = 10 * EXISTENTIAL_DEPOSIT; - //pub EvmAdmin: H160 = H160([0x05, 0xF9, 0xb8, 0xC7, 0x6E, 0x89, 0x87, 0xB8, 0x15, 0xC9, 0x3C, 0x27, 0xD1, 0x45, 0x20, 0xb6, 0xeD, 0x57, 0x39, 0x02]); - pub EvmAdmins: BTreeSet = { - let mut set = BTreeSet::new(); - set.insert(H160([0x05, 0xF9, 0xb8, 0xC7, 0x6E, 0x89, 0x87, 0xB8, 0x15, 0xC9, 0x3C, 0x27, 0xD1, 0x45, 0x20, 0xb6, 0xeD, 0x57, 0x39, 0x02])); - set - }; } impl pallet_assets_bridge::Config for Runtime { type RuntimeEvent = RuntimeEvent; type EvmCaller = EvmCaller; type ClaimBond = ClaimBond; - type EvmAdmins = EvmAdmins; } impl pallet_evm_utils::Config for Runtime { @@ -1159,6 +1160,20 @@ impl pallet_treasury::Config for Runtime { impl pallet_insecure_randomness_collective_flip::Config for Runtime {} +parameter_types! { + pub const MultisigReqExpireTime: BlockNumber = 50400; + pub const MaxScriptSigners: u32 = 8; +} + +impl pallet_move::Config for Runtime { + type Currency = Balances; + type CurrencyBalance = Balance; + type MultisigReqExpireTime = MultisigReqExpireTime; + type MaxScriptSigners = MaxScriptSigners; + type RuntimeEvent = RuntimeEvent; + type WeightInfo = pallet_move::weights::SubstrateWeight; +} + // Create the runtime by composing the FRAME pallets that were previously configured. construct_runtime!( pub enum Runtime @@ -1227,6 +1242,9 @@ construct_runtime!( //Contracts RandomnessCollectiveFlip: pallet_insecure_randomness_collective_flip = 70, Contracts: pallet_contracts = 71, + + //Move-vm + MoveModule: pallet_move = 80, BulkPallet: pallet_bulk = 72, } ); @@ -1243,6 +1261,7 @@ mod benches { [cumulus_pallet_xcmp_queue, XcmpQueue] [pallet_bulk, BulkPallet] // [pallet_order, OrderPallet] + [pallet_move, MoveModule] ); } @@ -1254,7 +1273,7 @@ type EventRecord = frame_system::EventRecord< impl_runtime_apis! { impl sp_consensus_aura::AuraApi for Runtime { fn slot_duration() -> sp_consensus_aura::SlotDuration { - sp_consensus_aura::SlotDuration::from_millis(Aura::slot_duration()) + sp_consensus_aura::SlotDuration::from_millis(SLOT_DURATION) } fn authorities() -> Vec { @@ -1590,6 +1609,14 @@ impl_runtime_apis! { ParachainSystem::collect_collation_info(header) } } + impl cumulus_primitives_aura::AuraUnincludedSegmentApi for Runtime { + fn can_build_upon( + included_hash: ::Hash, + slot: cumulus_primitives_aura::Slot, + ) -> bool { + ConsensusHook::can_build_upon(included_hash, slot) + } + } // impl magnet_primitives_order::OrderRuntimeApi for Runtime { // fn slot_width()-> u32{ @@ -1716,6 +1743,35 @@ impl_runtime_apis! { } } + impl pallet_move::api::MoveApi for Runtime { + fn estimate_gas_publish_module(account: AccountId, bytecode: Vec) -> Result { + MoveModule::rpc_estimate_gas_publish_module(&account, bytecode) + } + + fn estimate_gas_publish_bundle(account: AccountId, bytecode: Vec) -> Result { + MoveModule::rpc_estimate_gas_publish_bundle(&account, bytecode) + } + + fn estimate_gas_execute_script(transaction_bc: Vec) -> Result { + MoveModule::rpc_estimate_gas_execute_script(transaction_bc) + } + + fn get_module(account: AccountId, name: String) -> Result>, Vec> { + MoveModule::rpc_get_module(account, name) + } + + fn get_module_abi(account: AccountId, name: String) -> Result, Vec> { + MoveModule::rpc_get_module_abi(account, name) + } + + fn get_resource( + account: AccountId, + tag: Vec, + ) -> Result>, Vec> { + MoveModule::rpc_get_resource(account, tag) + } + } + #[cfg(feature = "try-runtime")] impl frame_try_runtime::TryRuntime for Runtime { fn on_runtime_upgrade(checks: frame_try_runtime::UpgradeCheckSelect) -> (Weight, Weight) { @@ -1819,5 +1875,5 @@ impl cumulus_pallet_parachain_system::CheckInherents for CheckInherents { cumulus_pallet_parachain_system::register_validate_block! { Runtime = Runtime, BlockExecutor = cumulus_pallet_aura_ext::BlockExecutor::, - CheckInherents = CheckInherents, + // CheckInherents = CheckInherents, } diff --git a/runtime/src/precompiles.rs b/runtime/src/precompiles.rs index c7e7560..a69590a 100644 --- a/runtime/src/precompiles.rs +++ b/runtime/src/precompiles.rs @@ -1,5 +1,6 @@ use pallet_evm::{ - IsPrecompileResult, Precompile, PrecompileHandle, PrecompileResult, PrecompileSet, + ExitRevert, IsPrecompileResult, Precompile, PrecompileFailure, PrecompileHandle, + PrecompileResult, PrecompileSet, }; use sp_core::{crypto::AccountId32, H160, U256}; use sp_runtime::traits::UniqueSaturatedInto; @@ -45,6 +46,21 @@ where U256: UniqueSaturatedInto>, { fn execute(&self, handle: &mut impl PrecompileHandle) -> Option { + let remaining_gas = handle.remaining_gas(); + + let is_precompile_result = self.is_precompile(handle.code_address(), remaining_gas); + if let IsPrecompileResult::Answer { is_precompile, .. } = is_precompile_result { + if is_precompile + && handle.code_address() > hash(5) + && handle.code_address() != handle.context().address + { + return Some(Err(PrecompileFailure::Revert { + exit_status: ExitRevert::Reverted, + output: "cannot be called with DELEGATECALL or CALLCODE".into(), + })); + } + } + match handle.code_address() { // Ethereum precompiles : a if a == hash(1) => Some(ECRecover::execute(handle)), From 0e2d30c8dcc99881ce586fe33f55255b1fbb8c2e Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sun, 30 Jun 2024 20:39:18 +0800 Subject: [PATCH 16/44] Modify cargo.lock file --- Cargo.lock | 717 +++++++++++++++++++++++++++++++++++------------------ 1 file changed, 472 insertions(+), 245 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 2bd4071..210e390 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -68,7 +68,7 @@ dependencies = [ "cipher 0.4.4", "ctr", "ghash", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -215,7 +215,7 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -669,7 +669,7 @@ dependencies = [ "futures-io", "futures-lite 2.3.0", "parking", - "polling 3.7.2", + "polling 3.7.1", "rustix 0.38.34", "slab", "tracing", @@ -756,7 +756,7 @@ checksum = "c6fa2087f2753a7da8cc1c0dbfcf89579dd57458e36769de5ac750b4671737ca" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -812,7 +812,7 @@ checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -832,7 +832,7 @@ dependencies = [ "cfg-if", "libc", "miniz_oxide", - "object 0.36.1", + "object 0.36.0", "rustc-demangle", ] @@ -977,7 +977,7 @@ dependencies = [ "regex", "rustc-hash", "shlex", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -1007,9 +1007,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.6.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "bitmaps" @@ -1256,9 +1256,9 @@ checksum = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7" [[package]] name = "bytemuck" -version = "1.16.1" +version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b236fc92302c97ed75b38da1f4917b5cdda4984745740f153a5d3059e48d725e" +checksum = "78834c15cb5d5efe3452d58b1e8ba890dd62d21907f867f383358198e56ebca5" [[package]] name = "byteorder" @@ -1333,9 +1333,9 @@ checksum = "fd6c0e7b807d60291f42f33f58480c0bfafe28ed08286446f45e463728cf9c1c" [[package]] name = "cc" -version = "1.0.103" +version = "1.0.99" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2755ff20a1d93490d26ba33a6f092a38a508398a5320df5d4b3014fcccce9410" +checksum = "96c51067fd44124faa7f870b4b1c969379ad32b2ba805aa959430ceaa384f695" dependencies = [ "jobserver", "libc", @@ -1514,19 +1514,19 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.8" +version = "4.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" +checksum = "5db83dced34638ad474f39f250d7fea9598bdd239eaced1bdf45d597da0f433f" dependencies = [ "clap_builder", - "clap_derive 4.5.8", + "clap_derive 4.5.5", ] [[package]] name = "clap_builder" -version = "4.5.8" +version = "4.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" +checksum = "f7e204572485eb3fbf28f871612191521df159bc3e15a9f5064c66dba3a8c05f" dependencies = [ "anstream", "anstyle", @@ -1550,14 +1550,14 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.8" +version = "4.5.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" +checksum = "c780290ccf4fb26629baa7a1081e68ced113f1d3ec302fa5948f1c381ebf06c6" dependencies = [ "heck 0.5.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -1625,7 +1625,7 @@ dependencies = [ "nom", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -1650,7 +1650,7 @@ version = "7.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b34115915337defe99b2aff5c2ce6771e5fbc4079f4b506301f5cf394c8452f7" dependencies = [ - "strum 0.26.3", + "strum 0.26.2", "strum_macros 0.26.4", "unicode-width", ] @@ -1972,7 +1972,7 @@ checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" dependencies = [ "generic-array 0.14.7", "rand_core 0.6.4", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -2004,17 +2004,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeab" dependencies = [ "generic-array 0.14.7", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] name = "crypto-mac" -version = "0.11.1" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1d1a86f49236c215f271d40892d5fc950490551400b02ef360692c29815c714" +checksum = "25fab6889090c8133f3deb8f73ba3c65a7f456f66436fc012a1b1e272b1e103e" dependencies = [ "generic-array 0.14.7", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -2031,7 +2031,7 @@ name = "cumulus-client-cli" version = "0.7.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "clap 4.5.8", + "clap 4.5.7", "parity-scale-codec", "sc-chain-spec", "sc-cli", @@ -2319,7 +2319,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -2612,7 +2612,7 @@ dependencies = [ "byteorder", "digest 0.8.1", "rand_core 0.5.1", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -2625,23 +2625,24 @@ dependencies = [ "byteorder", "digest 0.9.0", "rand_core 0.5.1", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] [[package]] name = "curve25519-dalek" -version = "4.1.3" +version = "4.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97fb8b7c4503de7d6ae7b42ab72a5a59857b4c937ec27a3d4539dba95b5ab2be" +checksum = "0a677b8922c94e01bdbb12126b0bc852f00447528dee1782229af9c720c3f348" dependencies = [ "cfg-if", "cpufeatures", "curve25519-dalek-derive", "digest 0.10.7", "fiat-crypto", + "platforms", "rustc_version 0.4.0", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -2653,7 +2654,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -2671,9 +2672,9 @@ dependencies = [ [[package]] name = "cxx" -version = "1.0.124" +version = "1.0.123" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "273dcfd3acd4e1e276af13ed2a43eea7001318823e7a726a6b3ed39b4acc0b82" +checksum = "8194f089b6da4751d6c1da1ef37c17255df51f9346cdb160f8b096562ae4a85c" dependencies = [ "cc", "cxxbridge-flags", @@ -2683,9 +2684,9 @@ dependencies = [ [[package]] name = "cxx-build" -version = "1.0.124" +version = "1.0.123" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8b2766fbd92be34e9ed143898fce6c572dc009de39506ed6903e5a05b68914e" +checksum = "1e8df9a089caae66634d754672d5f909395f30f38af6ff19366980d8a8b57501" dependencies = [ "cc", "codespan-reporting", @@ -2693,24 +2694,24 @@ dependencies = [ "proc-macro2", "quote", "scratch", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] name = "cxxbridge-flags" -version = "1.0.124" +version = "1.0.123" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "839fcd5e43464614ffaa989eaf1c139ef1f0c51672a1ed08023307fa1b909ccd" +checksum = "25290be4751803672a70b98c68b51c1e7d0a640ab5a4377f240f9d2e70054cd1" [[package]] name = "cxxbridge-macro" -version = "1.0.124" +version = "1.0.123" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b2c1c1776b986979be68bb2285da855f8d8a35851a769fca8740df7c3d07877" +checksum = "b8cb317cb13604b4752416783bb25070381c36e844743e4146b7f8e55de7d140" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -2758,7 +2759,7 @@ dependencies = [ "proc-macro2", "quote", "strsim 0.11.1", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -2780,7 +2781,7 @@ checksum = "733cabb43482b1a1b53eee8583c2b9e8684d592215ea83efd305dd31bc2f0178" dependencies = [ "darling_core 0.20.9", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -2885,20 +2886,20 @@ checksum = "d65d7ce8132b7c0e54497a4d9a55a1c2a0912a0d786cf894472ba818fba45762" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] name = "derive_more" -version = "0.99.18" +version = "0.99.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" +checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" dependencies = [ "convert_case", "proc-macro2", "quote", "rustc_version 0.4.0", - "syn 2.0.68", + "syn 1.0.109", ] [[package]] @@ -2946,7 +2947,7 @@ dependencies = [ "block-buffer 0.10.4", "const-oid", "crypto-common", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -3003,13 +3004,13 @@ dependencies = [ [[package]] name = "displaydoc" -version = "0.2.5" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -3049,7 +3050,7 @@ dependencies = [ "proc-macro2", "quote", "regex", - "syn 2.0.68", + "syn 2.0.66", "termcolor", "toml 0.8.14", "walkdir", @@ -3136,12 +3137,12 @@ version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4a3daa8e81a3963a60642bcc1f90a670680bd4a77535faa384e9d1c79d620871" dependencies = [ - "curve25519-dalek 4.1.3", + "curve25519-dalek 4.1.2", "ed25519", "rand_core 0.6.4", "serde", "sha2 0.10.8", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -3165,7 +3166,7 @@ version = "4.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7d9ce6874da5d4415896cd45ffbc4d1cfc0c4f9c079427bd870742c30f2f65a9" dependencies = [ - "curve25519-dalek 4.1.3", + "curve25519-dalek 4.1.2", "ed25519", "hashbrown 0.14.5", "hex", @@ -3176,9 +3177,9 @@ dependencies = [ [[package]] name = "either" -version = "1.13.0" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" +checksum = "3dca9240753cf90908d7e4aac30f630662b02aebaa1b58a3cadabdb23385b58b" dependencies = [ "serde", ] @@ -3198,7 +3199,7 @@ dependencies = [ "pkcs8", "rand_core 0.6.4", "sec1", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -3237,7 +3238,7 @@ checksum = "de0d48a183585823424a4ce1aa132d174a6a81bd540895822eb4c8373a8e49e8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -3248,7 +3249,7 @@ checksum = "6fd000fd6988e73bbe993ea3db9b1aa64906ab88766d654973924340c8cddb42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -3477,17 +3478,16 @@ dependencies = [ [[package]] name = "expander" -version = "2.2.1" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2c470c71d91ecbd179935b24170459e926382eaaa86b590b78814e180d8a8e2" +checksum = "00e83c02035136f1592a47964ea60c05a50e4ed8b5892cfac197063850898d4d" dependencies = [ "blake2 0.10.6", - "file-guard", "fs-err", - "prettyplease 0.2.20", + "prettier-please", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -3570,7 +3570,7 @@ name = "fc-cli" version = "1.0.0-dev" source = "git+https://github.com/paritytech/frontier?branch=polkadot-v1.7.0#c5d6daa9ffd46c0a85915526aa26d200fd635e30" dependencies = [ - "clap 4.5.8", + "clap 4.5.7", "ethereum-types", "fc-db", "fp-rpc", @@ -3758,7 +3758,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" dependencies = [ "rand_core 0.6.4", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -3780,16 +3780,6 @@ version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "28dea519a9695b9977216879a3ebfddf92f1c08c05d984f8996aecd6ecdc811d" -[[package]] -name = "file-guard" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21ef72acf95ec3d7dbf61275be556299490a245f017cf084bd23b4f68cf9407c" -dependencies = [ - "libc", - "winapi", -] - [[package]] name = "file-per-thread-logger" version = "0.1.6" @@ -4068,7 +4058,7 @@ dependencies = [ "Inflector", "array-bytes 6.2.3", "chrono", - "clap 4.5.8", + "clap 4.5.7", "comfy-table", "frame-benchmarking", "frame-support", @@ -4116,7 +4106,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -4263,7 +4253,7 @@ dependencies = [ "Inflector", "cfg-expr", "derive-syn-parse 0.1.5", - "expander 2.2.1", + "expander 2.1.0", "frame-support-procedural-tools", "itertools 0.10.5", "macro_magic", @@ -4271,7 +4261,7 @@ dependencies = [ "proc-macro2", "quote", "sp-crypto-hashing", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -4283,7 +4273,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -4293,7 +4283,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -4483,7 +4473,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -4656,7 +4646,7 @@ version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0bf760ebf69878d9fd8f110c89703d90ce35095324d1f1edcb595c63945ee757" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.5.0", "ignore", "walkdir", ] @@ -4669,7 +4659,7 @@ checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" dependencies = [ "ff", "rand_core 0.6.4", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -4797,12 +4787,6 @@ version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" -[[package]] -name = "hermit-abi" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbf6a919d6cf397374f7dfeeea91d974c7c0a7221d0d0f4f20d859d329e53fcc" - [[package]] name = "hex" version = "0.4.3" @@ -4840,7 +4824,7 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2a2a2320eb7ec0ebe8da8f744d7812d9fc4cb4d09344ac01898dbcb6a20ae69b" dependencies = [ - "crypto-mac 0.11.1", + "crypto-mac 0.11.0", "digest 0.9.0", ] @@ -4914,9 +4898,9 @@ checksum = "add0ab9360ddbd88cfeb3bd9574a1d85cfdfa14db10b3e21d3700dbc4328758f" [[package]] name = "httparse" -version = "1.9.4" +version = "1.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" +checksum = "d0e7a4dd27b9476dc40cb050d3632d3bba3a70ddbff012285f7f8559a1e7e545" [[package]] name = "httpdate" @@ -5002,6 +4986,124 @@ dependencies = [ "cc", ] +[[package]] +name = "icu_collections" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db2fa452206ebee18c4b5c2274dbf1de17008e874b4dc4f0aea9d01ca79e4526" +dependencies = [ + "displaydoc", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_locid" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13acbb8371917fc971be86fc8057c41a64b521c184808a698c02acc242dbf637" +dependencies = [ + "displaydoc", + "litemap", + "tinystr", + "writeable", + "zerovec", +] + +[[package]] +name = "icu_locid_transform" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "01d11ac35de8e40fdeda00d9e1e9d92525f3f9d887cdd7aa81d727596788b54e" +dependencies = [ + "displaydoc", + "icu_locid", + "icu_locid_transform_data", + "icu_provider", + "tinystr", + "zerovec", +] + +[[package]] +name = "icu_locid_transform_data" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fdc8ff3388f852bede6b579ad4e978ab004f139284d7b28715f773507b946f6e" + +[[package]] +name = "icu_normalizer" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19ce3e0da2ec68599d193c93d088142efd7f9c5d6fc9b803774855747dc6a84f" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_normalizer_data", + "icu_properties", + "icu_provider", + "smallvec", + "utf16_iter", + "utf8_iter", + "write16", + "zerovec", +] + +[[package]] +name = "icu_normalizer_data" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8cafbf7aa791e9b22bec55a167906f9e1215fd475cd22adfcf660e03e989516" + +[[package]] +name = "icu_properties" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f8ac670d7422d7f76b32e17a5db556510825b29ec9154f235977c9caba61036" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_locid_transform", + "icu_properties_data", + "icu_provider", + "tinystr", + "zerovec", +] + +[[package]] +name = "icu_properties_data" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67a8effbc3dd3e4ba1afa8ad918d5684b8868b3b26500753effea8d2eed19569" + +[[package]] +name = "icu_provider" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ed421c8a8ef78d3e2dbc98a973be2f3770cb42b606e3ab18d6237c4dfde68d9" +dependencies = [ + "displaydoc", + "icu_locid", + "icu_provider_macros", + "stable_deref_trait", + "tinystr", + "writeable", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_provider_macros" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ec89e9337638ecdc08744df490b221a7399bf8d164eb52a665454e60e075ad6" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.66", +] + [[package]] name = "ident_case" version = "1.0.1" @@ -5021,12 +5123,14 @@ dependencies = [ [[package]] name = "idna" -version = "0.5.0" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +checksum = "4716a3a0933a1d01c2f72450e89596eb51dd34ef3c211ccd875acdf1f8fe47ed" dependencies = [ - "unicode-bidi", - "unicode-normalization", + "icu_normalizer", + "icu_properties", + "smallvec", + "utf8_iter", ] [[package]] @@ -5128,18 +5232,18 @@ dependencies = [ [[package]] name = "include_dir" -version = "0.7.4" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "923d117408f1e49d914f1a379a309cffe4f18c05cf4e3d12e613a15fc81bd0dd" +checksum = "18762faeff7122e89e0857b02f7ce6fcc0d101d5e9ad2ad7846cc01d61b7f19e" dependencies = [ "include_dir_macros", ] [[package]] name = "include_dir_macros" -version = "0.7.4" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cab85a7ed0bd5f0e76d93846e0147172bed2e2d3f859bcc33a8d9699cad1a75" +checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f" dependencies = [ "proc-macro2", "quote", @@ -5562,11 +5666,11 @@ dependencies = [ [[package]] name = "lazy_static" -version = "1.5.0" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" +checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" dependencies = [ - "spin 0.9.8", + "spin 0.5.2", ] [[package]] @@ -5583,9 +5687,9 @@ checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" [[package]] name = "libloading" -version = "0.8.4" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e310b3a6b5907f99202fcdb4960ff45b93735d7c7d96b760fcff8db2dc0e103d" +checksum = "0c2a198fb6b0eada2a8df47933734e6d35d350665a33a3593d7164fa52c75c19" dependencies = [ "cfg-if", "windows-targets 0.52.5", @@ -5996,7 +6100,7 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.5.0", "libc", ] @@ -6042,7 +6146,7 @@ checksum = "5be9b9bb642d8522a44d533eab56c16c738301965504753b03ad1de3425d5451" dependencies = [ "crunchy", "digest 0.9.0", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -6148,6 +6252,12 @@ dependencies = [ "keystream", ] +[[package]] +name = "litemap" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "643cb0b8d4fcc284004d5fd0d67ccf61dfffadb7f75e1e71bc420f4688a3a704" + [[package]] name = "lock_api" version = "0.4.12" @@ -6160,9 +6270,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.22" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" dependencies = [ "serde", ] @@ -6238,7 +6348,7 @@ dependencies = [ "macro_magic_core", "macro_magic_macros", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -6252,7 +6362,7 @@ dependencies = [ "macro_magic_core_macros", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -6263,7 +6373,7 @@ checksum = "9ea73aa640dc01d62a590d48c0c3521ed739d53b27f919b25c3551e233481654" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -6274,7 +6384,7 @@ checksum = "ef9d79ae96aaba821963320eb2b6e34d17df1e5a83d8a1985c29cc5be59577b3" dependencies = [ "macro_magic_core", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -6426,9 +6536,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.7.4" +version = "2.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" +checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" [[package]] name = "memfd" @@ -6518,9 +6628,9 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.7.4" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" +checksum = "87dfd01fe195c66b572b37921ad8803d010623c0aca821bea2302239d155cdae" dependencies = [ "adler", ] @@ -6547,7 +6657,7 @@ dependencies = [ "bitflags 1.3.2", "blake2 0.10.6", "c2-chacha", - "curve25519-dalek 4.1.3", + "curve25519-dalek 4.1.2", "either", "hashlink", "lioness", @@ -6556,7 +6666,7 @@ dependencies = [ "rand 0.8.5", "rand_chacha 0.3.1", "rand_distr", - "subtle 2.4.1", + "subtle 2.5.0", "thiserror", "zeroize", ] @@ -7311,7 +7421,7 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", "synstructure 0.13.1", ] @@ -7337,9 +7447,9 @@ dependencies = [ [[package]] name = "nalgebra" -version = "0.32.6" +version = "0.32.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b5c17de023a86f59ed79891b2e5d5a94c705dbe904a5b5c9c952ea6221b03e4" +checksum = "3ea4908d4f23254adda3daa60ffef0f1ac7b8c3e9a864cf3cc154b251908a2ef" dependencies = [ "approx", "matrixmultiply", @@ -7353,13 +7463,13 @@ dependencies = [ [[package]] name = "nalgebra-macros" -version = "0.2.2" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "254a5372af8fc138e36684761d3c0cdb758a4410e938babcff1c860ce14ddbfc" +checksum = "91761aed67d03ad966ef783ae962ef9bbaca728d2dd7ceb7939ec110fffad998" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 1.0.109", ] [[package]] @@ -7477,7 +7587,7 @@ version = "0.27.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2eb04e9c688eff1c89d72b407f168cf79bb9e867a9d3323ed6c01519eb9cc053" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.5.0", "cfg-if", "libc", ] @@ -7542,9 +7652,9 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.6" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" dependencies = [ "num-integer", "num-traits", @@ -7644,7 +7754,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -7667,9 +7777,9 @@ dependencies = [ [[package]] name = "object" -version = "0.36.1" +version = "0.36.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" +checksum = "576dfe1fc8f9df304abb159d767a29d0476f7750fbf8aa7ad07816004a207434" dependencies = [ "memchr", ] @@ -7707,7 +7817,7 @@ version = "0.10.64" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.5.0", "cfg-if", "foreign-types", "libc", @@ -7724,7 +7834,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -7774,7 +7884,7 @@ version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1344346d5af32c95bbddea91b18a88cc83eac394192d20ef2fc4c40a74332355" dependencies = [ - "expander 2.2.1", + "expander 2.1.0", "indexmap 2.2.6", "itertools 0.11.0", "petgraph 0.6.5", @@ -8269,7 +8379,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -9162,7 +9272,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -9412,7 +9522,7 @@ name = "parachain-magnet-node" version = "0.6.0" dependencies = [ "array-bytes 6.2.3", - "clap 4.5.8", + "clap 4.5.7", "color-print", "cumulus-client-cli", "cumulus-client-collator", @@ -9745,7 +9855,7 @@ checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" dependencies = [ "cfg-if", "libc", - "redox_syscall 0.5.2", + "redox_syscall 0.5.1", "smallvec", "windows-targets 0.52.5", ] @@ -9777,7 +9887,7 @@ version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d95f5254224e617595d2cc3cc73ff0a5eaf2637519e25f03388154e9378b6ffa" dependencies = [ - "crypto-mac 0.11.1", + "crypto-mac 0.11.0", ] [[package]] @@ -9841,7 +9951,7 @@ dependencies = [ "pest_meta", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -9940,7 +10050,7 @@ checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -9988,6 +10098,12 @@ version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" +[[package]] +name = "platforms" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db23d408679286588f4d4644f965003d056e3dd5abcaaa938116871d7ce2fee7" + [[package]] name = "polkadot-approval-distribution" version = "7.0.0" @@ -10076,7 +10192,7 @@ version = "7.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "cfg-if", - "clap 4.5.8", + "clap 4.5.7", "frame-benchmarking-cli", "futures", "log", @@ -11076,7 +11192,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6380dbe1fb03ecc74ad55d841cfc75480222d153ba69ddcb00977866cbdabdb8" dependencies = [ "polkavm-derive-impl 0.5.0", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -11097,7 +11213,7 @@ dependencies = [ "polkavm-common 0.5.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -11109,7 +11225,7 @@ dependencies = [ "polkavm-common 0.9.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -11119,7 +11235,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8ba81f7b5faac81e528eb6158a6f3c9e0bb1008e0ffa19653bc8dea925ecb429" dependencies = [ "polkavm-derive-impl 0.9.0", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -11140,13 +11256,13 @@ dependencies = [ [[package]] name = "polling" -version = "3.7.2" +version = "3.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3ed00ed3fbf728b5816498ecd316d1716eecaced9c0c8d2c5a6740ca214985b" +checksum = "5e6a007746f34ed64099e88783b0ae369eaa3da6392868ba262e2af9b8fbaea1" dependencies = [ "cfg-if", "concurrent-queue", - "hermit-abi 0.4.0", + "hermit-abi 0.3.9", "pin-project-lite 0.2.14", "rustix 0.38.34", "tracing", @@ -11263,6 +11379,16 @@ dependencies = [ "termtree", ] +[[package]] +name = "prettier-please" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22020dfcf177fcc7bf5deaf7440af371400c67c0de14c399938d8ed4fb4645d3" +dependencies = [ + "proc-macro2", + "syn 2.0.66", +] + [[package]] name = "pretty" version = "0.10.0" @@ -11275,9 +11401,9 @@ dependencies = [ [[package]] name = "prettyplease" -version = "0.1.25" +version = "0.1.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8646e95016a7a6c4adea95bafa8a16baab64b583356217f2c85db4a39d9a86" +checksum = "f28f53e8b192565862cf99343194579a022eb9c7dd3a8d03134734803c7b3125" dependencies = [ "proc-macro2", "syn 1.0.109", @@ -11290,7 +11416,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5f12335488a2f3b0a83b14edad48dca9879ce89b2edd10e80237e4e852dd645e" dependencies = [ "proc-macro2", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -11383,14 +11509,14 @@ checksum = "834da187cfe638ae8abb0203f0b33e5ccdb02a28e7199f2f47b3e2754f50edca" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] name = "proc-macro2" -version = "1.0.86" +version = "1.0.85" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" +checksum = "22244ce15aa966053a896d1accb3a6e68469b97c7f33f284b99f0d576879fc23" dependencies = [ "unicode-ident", ] @@ -11429,7 +11555,7 @@ checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -11465,7 +11591,7 @@ dependencies = [ "log", "multimap", "petgraph 0.6.5", - "prettyplease 0.1.25", + "prettyplease 0.1.11", "prost 0.11.9", "prost-types", "regex", @@ -11497,7 +11623,7 @@ dependencies = [ "itertools 0.12.1", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -11747,11 +11873,11 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.5.2" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" +checksum = "469052894dcb553421e483e4209ee581a45100d31b4018de03e5a7ad86374a7e" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.5.0", ] [[package]] @@ -11794,7 +11920,7 @@ checksum = "bcc303e793d3734489387d205e9b186fac9c6cfacedd98cbb2e8a5943595f3e6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -11870,7 +11996,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" dependencies = [ "hmac 0.12.1", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -12194,7 +12320,7 @@ version = "0.38.34" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.5.0", "errno", "libc", "linux-raw-sys 0.4.14", @@ -12312,9 +12438,9 @@ dependencies = [ [[package]] name = "safe_arch" -version = "0.7.2" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3460605018fdc9612bce72735cba0d27efbcd9904780d44c7e3a9948f96148a" +checksum = "f398075ce1e6a179b46f51bd88d0598b92b00d3551f1a2d4ac49e771b56ac354" dependencies = [ "bytemuck", ] @@ -12439,7 +12565,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -12450,7 +12576,7 @@ dependencies = [ "array-bytes 6.2.3", "bip39", "chrono", - "clap 4.5.8", + "clap 4.5.7", "fdlimit", "futures", "itertools 0.10.5", @@ -13343,7 +13469,7 @@ name = "sc-storage-monitor" version = "0.16.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "clap 4.5.8", + "clap 4.5.7", "fs4", "log", "sp-core 28.0.0", @@ -13448,7 +13574,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -13656,7 +13782,7 @@ dependencies = [ "rand 0.7.3", "rand_core 0.5.1", "sha2 0.8.2", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -13685,13 +13811,13 @@ dependencies = [ "aead", "arrayref", "arrayvec 0.7.4", - "curve25519-dalek 4.1.3", + "curve25519-dalek 4.1.2", "getrandom_or_panic", "merlin 3.0.0", "rand_core 0.6.4", "serde_bytes", "sha2 0.10.8", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -13727,7 +13853,7 @@ dependencies = [ "der", "generic-array 0.14.7", "pkcs8", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -13791,7 +13917,7 @@ version = "2.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.5.0", "core-foundation", "core-foundation-sys", "libc", @@ -13852,9 +13978,9 @@ dependencies = [ [[package]] name = "serde_bytes" -version = "0.11.15" +version = "0.11.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "387cc504cb06bb40a96c8e04e951fe01854cf6bc921053c954e4a606d9675c6a" +checksum = "8b8497c313fd43ab992087548117643f6fcd935cbf36f176ffda0aacf9591734" dependencies = [ "serde", ] @@ -13867,14 +13993,14 @@ checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] name = "serde_json" -version = "1.0.118" +version = "1.0.117" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d947f6b3163d8857ea16c4fa0dd4840d52f3041039a85decd46867eb1abef2e4" +checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3" dependencies = [ "itoa", "ryu", @@ -14322,12 +14448,12 @@ dependencies = [ "aes-gcm", "blake2 0.10.6", "chacha20poly1305", - "curve25519-dalek 4.1.3", + "curve25519-dalek 4.1.2", "rand_core 0.6.4", "ring 0.17.8", "rustc_version 0.4.0", "sha2 0.10.8", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -14395,11 +14521,11 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot dependencies = [ "Inflector", "blake2 0.10.6", - "expander 2.2.1", + "expander 2.1.0", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -14738,7 +14864,7 @@ dependencies = [ [[package]] name = "sp-crypto-ec-utils" version = "0.10.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" dependencies = [ "ark-bls12-377", "ark-bls12-377-ext", @@ -14775,7 +14901,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot dependencies = [ "quote", "sp-crypto-hashing", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -14795,7 +14921,7 @@ checksum = "50535e1a5708d3ba5c1195b59ebefac61cc8679c2c24716b87a86e8b7ed2e4a1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -14805,17 +14931,17 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] name = "sp-debug-derive" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -14844,7 +14970,7 @@ dependencies = [ [[package]] name = "sp-externalities" version = "0.25.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" dependencies = [ "environmental", "parity-scale-codec", @@ -15153,7 +15279,7 @@ dependencies = [ [[package]] name = "sp-runtime-interface" version = "24.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" dependencies = [ "bytes", "impl-trait-for-tuples", @@ -15179,7 +15305,7 @@ dependencies = [ "proc-macro-crate 1.1.3", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -15188,24 +15314,24 @@ version = "17.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "Inflector", - "expander 2.2.1", + "expander 2.1.0", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] name = "sp-runtime-interface-proc-macro" version = "17.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" dependencies = [ "Inflector", - "expander 2.2.1", + "expander 2.1.0", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -15286,7 +15412,7 @@ version = "10.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "aes-gcm", - "curve25519-dalek 4.1.3", + "curve25519-dalek 4.1.2", "ed25519-dalek", "hkdf", "parity-scale-codec", @@ -15319,7 +15445,7 @@ source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot [[package]] name = "sp-std" version = "14.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" [[package]] name = "sp-storage" @@ -15351,7 +15477,7 @@ dependencies = [ [[package]] name = "sp-storage" version = "19.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" dependencies = [ "impl-serde", "parity-scale-codec", @@ -15401,7 +15527,7 @@ dependencies = [ [[package]] name = "sp-tracing" version = "16.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" dependencies = [ "parity-scale-codec", "tracing", @@ -15507,7 +15633,7 @@ dependencies = [ "parity-scale-codec", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -15540,7 +15666,7 @@ dependencies = [ [[package]] name = "sp-wasm-interface" version = "20.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk#aaf0443591b134a0da217d575161872796e75059" +source = "git+https://github.com/paritytech/polkadot-sdk#ad8620922bd7c0477b25c7dfd6fc233641cb27ae" dependencies = [ "impl-trait-for-tuples", "log", @@ -15873,7 +15999,7 @@ dependencies = [ "bitflags 1.3.2", "byteorder", "keccak", - "subtle 2.4.1", + "subtle 2.5.0", "zeroize", ] @@ -15900,9 +16026,9 @@ dependencies = [ [[package]] name = "strum" -version = "0.26.3" +version = "0.26.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06" +checksum = "5d8cec3501a5194c432b2b7976db6b7d10ec95c253208b45f83f7136aa985e29" [[package]] name = "strum_macros" @@ -15927,7 +16053,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -16035,9 +16161,9 @@ checksum = "2d67a5a62ba6e01cb2192ff309324cb4875d0c451d55fe2319433abe7a05a8ee" [[package]] name = "subtle" -version = "2.4.1" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" +checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" [[package]] name = "subtle-ng" @@ -16095,7 +16221,7 @@ dependencies = [ "quote", "scale-info", "subxt-metadata", - "syn 2.0.68", + "syn 2.0.66", "thiserror", "tokio", ] @@ -16127,7 +16253,7 @@ dependencies = [ "parity-scale-codec", "proc-macro-error", "subxt-codegen", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -16178,9 +16304,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.68" +version = "2.0.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "901fa70d88b9d6c98022e23b4136f9f3e54e4662c3bc1bd1d84a42a9a0f0c1e9" +checksum = "c42f3f41a2de00b01c0aaad383c5a45241efc8b2d1eda5661812fda5f3cdcff5" dependencies = [ "proc-macro2", "quote", @@ -16207,7 +16333,7 @@ checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -16334,7 +16460,7 @@ checksum = "e4c60d69f36615a077cc7663b9cb8e42275722d23e58a7fa3d2c7f2915d09d04" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -16345,7 +16471,7 @@ checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -16447,11 +16573,21 @@ dependencies = [ "crunchy", ] +[[package]] +name = "tinystr" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9117f5d4db391c1cf6927e7bea3db74b9a1c1add8f7eda9ffd5364f40f57b82f" +dependencies = [ + "displaydoc", + "zerovec", +] + [[package]] name = "tinyvec" -version = "1.6.1" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" +checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" dependencies = [ "tinyvec_macros", ] @@ -16489,7 +16625,7 @@ checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -16625,7 +16761,7 @@ version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "61c5bb1d698276a2443e5ecfabc1008bf15a36c12e6a7176e7bf089ea9131140" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.5.0", "bytes", "futures-core", "futures-util", @@ -16669,7 +16805,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -16708,11 +16844,11 @@ name = "tracing-gum-proc-macro" version = "5.0.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ - "expander 2.2.1", + "expander 2.1.0", "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -16868,7 +17004,7 @@ version = "0.38.0" source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" dependencies = [ "async-trait", - "clap 4.5.8", + "clap 4.5.7", "frame-remote-externalities", "frame-try-runtime", "hex", @@ -17048,7 +17184,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fc1de2c688dc15305988b563c3854064043356019f97a4b46276fe734c4f07ea" dependencies = [ "crypto-common", - "subtle 2.4.1", + "subtle 2.5.0", ] [[package]] @@ -17077,12 +17213,12 @@ checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "url" -version = "2.5.2" +version = "2.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +checksum = "f7c25da092f0a868cdf09e8674cd3b7ef3a7d92a24253e663a2fb85e2496de56" dependencies = [ "form_urlencoded", - "idna 0.5.0", + "idna 1.0.0", "percent-encoding", ] @@ -17092,6 +17228,18 @@ version = "2.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da" +[[package]] +name = "utf16_iter" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c8232dd3cdaed5356e0f716d285e4b40b932ac434100fe9b7e0e8e935b9e6246" + +[[package]] +name = "utf8_iter" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be" + [[package]] name = "utf8parse" version = "0.2.2" @@ -17223,7 +17371,7 @@ dependencies = [ "once_cell", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", "wasm-bindgen-shared", ] @@ -17257,7 +17405,7 @@ checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -18049,6 +18197,18 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "write16" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936" + +[[package]] +name = "writeable" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e9df38ee2d2c3c5948ea468a8406ff0db0b29ae1ffde1bcf20ef305bcc95c51" + [[package]] name = "wyz" version = "0.5.1" @@ -18075,7 +18235,7 @@ version = "2.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c7e468321c81fb07fa7f4c636c3972b9100f0346e5b6a9f2bd0603a52f7ed277" dependencies = [ - "curve25519-dalek 4.1.3", + "curve25519-dalek 4.1.2", "rand_core 0.6.4", "serde", "zeroize", @@ -18107,7 +18267,7 @@ dependencies = [ "Inflector", "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", ] [[package]] @@ -18139,6 +18299,30 @@ dependencies = [ "time", ] +[[package]] +name = "yoke" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c5b1314b079b0930c31e3af543d8ee1757b1951ae1e1565ec704403a7240ca5" +dependencies = [ + "serde", + "stable_deref_trait", + "yoke-derive", + "zerofrom", +] + +[[package]] +name = "yoke-derive" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "28cc31741b18cb6f1d5ff12f5b7523e3d6eb0852bbbad19d73905511d9849b95" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.66", + "synstructure 0.13.1", +] + [[package]] name = "zerocopy" version = "0.7.34" @@ -18156,7 +18340,28 @@ checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", +] + +[[package]] +name = "zerofrom" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91ec111ce797d0e0784a1116d0ddcdbea84322cd79e5d5ad173daeba4f93ab55" +dependencies = [ + "zerofrom-derive", +] + +[[package]] +name = "zerofrom-derive" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ea7b4a3637ea8669cedf0f1fd5c286a17f3de97b8dd5a70a6c167a1730e63a5" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.66", + "synstructure 0.13.1", ] [[package]] @@ -18176,7 +18381,29 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.68", + "syn 2.0.66", +] + +[[package]] +name = "zerovec" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb2cc8827d6c0994478a15c53f374f46fbd41bea663d809b14744bc42e6b109c" +dependencies = [ + "yoke", + "zerofrom", + "zerovec-derive", +] + +[[package]] +name = "zerovec-derive" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97cf56601ee5052b4417d90c8755c6683473c926039908196cf35d99f893ebe7" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.66", ] [[package]] @@ -18219,9 +18446,9 @@ dependencies = [ [[package]] name = "zstd-sys" -version = "2.0.11+zstd.1.5.6" +version = "2.0.10+zstd.1.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75652c55c0b6f3e6f12eb786fe1bc960396bf05a1eb3bf1f3691c3610ac2e6d4" +checksum = "c253a4914af5bafc8fa8c86ee400827e83cf6ec01195ec1f1ed8441bf00d65aa" dependencies = [ "cc", "pkg-config", From e489c20af5b961c7058556386526dc6348c8847e Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sun, 30 Jun 2024 20:53:32 +0800 Subject: [PATCH 17/44] Modify cargo.lock file --- Cargo.lock | 583 ----------------------------------------------------- 1 file changed, 583 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 2569394..210e390 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7164,523 +7164,6 @@ dependencies = [ "serde", ] -[[package]] -name = "move-vm-backend-common" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "arrayref", - "arrayvec 0.7.4", - "bitflags 1.3.2", - "blake2 0.10.6", - "c2-chacha", - "curve25519-dalek 4.1.2", - "either", - "hashlink", - "lioness", - "log", - "parking_lot 0.12.3", - "rand 0.8.5", - "rand_chacha 0.3.1", - "rand_distr", - "subtle 2.5.0", - "thiserror", - "zeroize", -] - -[[package]] -name = "mmr-gadget" -version = "29.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" -dependencies = [ - "futures", - "log", - "parity-scale-codec", - "sc-client-api", - "sc-offchain", - "sp-api", - "sp-blockchain", - "sp-consensus", - "sp-consensus-beefy", - "sp-core 28.0.0", - "sp-mmr-primitives", - "sp-runtime 31.0.1", -] - -[[package]] -name = "mmr-rpc" -version = "28.0.0" -source = "git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0#851c824dc7a8e7e6db2d0c9fb29d232f2f45198a" -dependencies = [ - "jsonrpsee", - "parity-scale-codec", - "serde", - "sp-api", - "sp-blockchain", - "sp-core 28.0.0", - "sp-mmr-primitives", - "sp-runtime 31.0.1", -] - -[[package]] -name = "mockall" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c84490118f2ee2d74570d114f3d0493cbf02790df303d2707606c3e14e07c96" -dependencies = [ - "cfg-if", - "downcast", - "fragile", - "lazy_static", - "mockall_derive", - "predicates", - "predicates-tree", -] - -[[package]] -name = "mockall_derive" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ce75669015c4f47b289fd4d4f56e894e4c96003ffdf3ac51313126f94c6cbb" -dependencies = [ - "cfg-if", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "move-abigen" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "bcs 0.1.6", - "heck 0.3.3", - "log", - "move-binary-format", - "move-bytecode-verifier", - "move-command-line-common", - "move-core-types", - "move-model", - "serde", -] - -[[package]] -name = "move-binary-format" -version = "0.0.3" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "hashbrown 0.14.5", - "move-core-types", - "ref-cast", - "serde", - "variant_count", -] - -[[package]] -name = "move-borrow-graph" -version = "0.0.1" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" - -[[package]] -name = "move-bytecode-source-map" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "bcs 0.1.6", - "move-binary-format", - "move-command-line-common", - "move-core-types", - "move-ir-types", - "move-symbol-pool", - "serde", -] - -[[package]] -name = "move-bytecode-verifier" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "fail", - "hashbrown 0.14.5", - "move-binary-format", - "move-borrow-graph", - "move-core-types", - "petgraph 0.6.4", -] - -[[package]] -name = "move-command-line-common" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "difference", - "dirs-next", - "hex", - "move-core-types", - "move-vm-support", - "num-bigint", - "once_cell", - "serde", - "sha2 0.9.9", - "walkdir", -] - -[[package]] -name = "move-compiler" -version = "0.0.1" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "bcs 0.1.6", - "clap 3.2.25", - "codespan-reporting", - "difference", - "hex", - "move-binary-format", - "move-borrow-graph", - "move-bytecode-source-map", - "move-bytecode-verifier", - "move-command-line-common", - "move-core-types", - "move-ir-to-bytecode", - "move-ir-types", - "move-symbol-pool", - "move-vm-support", - "num-bigint", - "once_cell", - "petgraph 0.5.1", - "regex", - "sha3 0.9.1", - "tempfile", - "walkdir", -] - -[[package]] -name = "move-core-types" -version = "0.0.4" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "bcs 0.1.4", - "ethnum", - "hashbrown 0.14.5", - "hex", - "num", - "parity-scale-codec", - "primitive-types", - "rand 0.8.5", - "ref-cast", - "scale-info", - "serde", - "serde_bytes", - "uint", -] - -[[package]] -name = "move-coverage" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "bcs 0.1.6", - "clap 3.2.25", - "codespan", - "colored", - "move-binary-format", - "move-bytecode-source-map", - "move-command-line-common", - "move-core-types", - "move-ir-types", - "once_cell", - "petgraph 0.5.1", - "serde", -] - -[[package]] -name = "move-disassembler" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "clap 3.2.25", - "colored", - "move-binary-format", - "move-bytecode-source-map", - "move-bytecode-verifier", - "move-command-line-common", - "move-compiler", - "move-core-types", - "move-coverage", - "move-ir-types", -] - -[[package]] -name = "move-docgen" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "codespan", - "codespan-reporting", - "itertools 0.10.5", - "log", - "move-compiler", - "move-model", - "num", - "once_cell", - "regex", - "serde", -] - -[[package]] -name = "move-errmapgen" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "bcs 0.1.6", - "log", - "move-command-line-common", - "move-core-types", - "move-model", - "serde", -] - -[[package]] -name = "move-ir-to-bytecode" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "codespan-reporting", - "log", - "move-binary-format", - "move-bytecode-source-map", - "move-command-line-common", - "move-core-types", - "move-ir-to-bytecode-syntax", - "move-ir-types", - "move-symbol-pool", - "ouroboros", - "thiserror", -] - -[[package]] -name = "move-ir-to-bytecode-syntax" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "hex", - "move-command-line-common", - "move-core-types", - "move-ir-types", - "move-symbol-pool", -] - -[[package]] -name = "move-ir-types" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "hex", - "move-command-line-common", - "move-core-types", - "move-symbol-pool", - "once_cell", - "serde", -] - -[[package]] -name = "move-model" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "codespan", - "codespan-reporting", - "internment", - "itertools 0.10.5", - "log", - "move-binary-format", - "move-bytecode-source-map", - "move-bytecode-verifier", - "move-command-line-common", - "move-compiler", - "move-core-types", - "move-disassembler", - "move-ir-types", - "move-symbol-pool", - "num", - "once_cell", - "regex", - "serde", -] - -[[package]] -name = "move-prover" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "async-trait", - "atty", - "clap 3.2.25", - "codespan", - "codespan-reporting", - "futures", - "hex", - "itertools 0.10.5", - "log", - "move-abigen", - "move-binary-format", - "move-command-line-common", - "move-compiler", - "move-core-types", - "move-docgen", - "move-errmapgen", - "move-ir-types", - "move-model", - "move-prover-boogie-backend", - "move-stackless-bytecode", - "num", - "once_cell", - "pretty", - "rand 0.8.5", - "serde", - "serde_json", - "simplelog", - "tokio", - "toml 0.5.11", -] - -[[package]] -name = "move-prover-boogie-backend" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "async-trait", - "codespan", - "codespan-reporting", - "futures", - "itertools 0.10.5", - "log", - "move-binary-format", - "move-command-line-common", - "move-compiler", - "move-core-types", - "move-model", - "move-stackless-bytecode", - "num", - "once_cell", - "pretty", - "rand 0.8.5", - "regex", - "serde", - "serde_json", - "tera", - "tokio", -] - -[[package]] -name = "move-read-write-set-types" -version = "0.0.3" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "move-binary-format", - "move-core-types", - "serde", -] - -[[package]] -name = "move-stackless-bytecode" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "codespan", - "codespan-reporting", - "ethnum", - "im", - "itertools 0.10.5", - "log", - "move-binary-format", - "move-borrow-graph", - "move-bytecode-verifier", - "move-command-line-common", - "move-compiler", - "move-core-types", - "move-ir-to-bytecode", - "move-model", - "move-read-write-set-types", - "num", - "once_cell", - "paste", - "petgraph 0.5.1", - "serde", -] - -[[package]] -name = "move-stdlib" -version = "0.1.1" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "blake2-rfc", - "hex", - "log", - "move-binary-format", - "move-command-line-common", - "move-compiler", - "move-core-types", - "move-docgen", - "move-errmapgen", - "move-prover", - "move-vm-runtime", - "move-vm-types", - "ripemd", - "sha2 0.10.8", - "sha3 0.10.8", - "siphasher 1.0.1", - "smallvec", - "tiny-keccak", -] - -[[package]] -name = "move-symbol-pool" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "once_cell", - "serde", -] - -[[package]] -name = "move-vm-backend" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "bcs 0.1.4", - "hashbrown 0.14.5", - "move-binary-format", - "move-core-types", - "move-stdlib", - "move-vm-backend-common", - "move-vm-runtime", - "move-vm-test-utils", - "move-vm-types", - "num-integer", - "serde", -] - [[package]] name = "move-vm-backend-common" version = "0.1.0" @@ -7802,72 +7285,6 @@ dependencies = [ "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", "sp-trie 29.0.0", "sp-weights 27.0.0", -======= - "anyhow", - "bcs 0.1.4", - "lazy_static", - "move-binary-format", - "move-core-types", - "move-stdlib", - "move-vm-runtime", - "move-vm-test-utils", - "move-vm-types", - "parity-scale-codec", - "scale-info", - "serde", - "serde_bytes", -] - -[[package]] -name = "move-vm-runtime" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "better_any", - "fail", - "hashbrown 0.14.5", - "move-binary-format", - "move-bytecode-verifier", - "move-core-types", - "move-vm-types", - "sha3 0.10.8", - "tracing", -] - -[[package]] -name = "move-vm-support" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "blake2 0.10.6", - "bs58 0.5.1", - "move-core-types", -] - -[[package]] -name = "move-vm-test-utils" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "anyhow", - "lazy_static", - "move-binary-format", - "move-core-types", - "move-vm-types", - "serde", -] - -[[package]] -name = "move-vm-types" -version = "0.1.0" -source = "git+https://github.com/eigerco/substrate-move.git?branch=main#a5333a3db42bdd0e3839e48443e04d411eb198bc" -dependencies = [ - "bcs 0.1.4", - "move-binary-format", - "move-core-types", - "serde", - "smallvec", ] [[package]] From 29199f5619c3b9142684134be776fec0516f45e8 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sun, 30 Jun 2024 21:04:20 +0800 Subject: [PATCH 18/44] fix compile bug --- node/src/chain_spec.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index d4b550c..f0eba8f 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -291,6 +291,5 @@ fn testnet_genesis( "rpcUrl": b"ws://127.0.0.1:8855".to_vec(), "genesisHash": U256::from_str("0x4ea18c8f295ba903acbbed39c70ea0569cf1705fa954a537ffa3b8b7125eaf58").expect("internal U256 is valid; qed") }, - } }) } From 45887915294ab0f987c27f8e77d2422d357af715 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Mon, 1 Jul 2024 17:20:47 +0800 Subject: [PATCH 19/44] Modify the method of obtaining coretime parachain events by listening to the blocks of this chain --- client/coretime/bulk/src/lib.rs | 285 +++++++++++++++--------------- client/coretime/common/src/lib.rs | 2 +- node/src/chain_spec.rs | 8 +- 3 files changed, 146 insertions(+), 149 deletions(-) diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 1e5d064..182a45d 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -16,9 +16,7 @@ //! Coretime bulk mode Spawner //! -//! The technical implementation logic here is to periodically call the background task here based on the interval between -//! parachain releases as the time period. -//! Each time it is called, it first checks the final block of the coretime parachain to see if there is an Assigned event +//! The technical implementation logic is to monitor the best block of the coretime parachain,to see if there is an Assigned event //! and assigns it to the current parachain. If so, it records it and then looks for subsequent block events to see if there //! is a CoreAssigned event. If so, it means that coretime is assigned to the parachain, //! and then the information recorded in the memory is passed to the block through inherent data. @@ -26,9 +24,9 @@ mod metadata; use codec::Codec; -use cumulus_primitives_core::{relay_chain::BlockNumber as RelayBlockNumber, ParaId}; +use cumulus_primitives_core::ParaId; use cumulus_relay_chain_interface::RelayChainInterface; -use futures::{lock::Mutex, pin_mut, select, FutureExt, StreamExt}; +use futures::{lock::Mutex, select, FutureExt}; use mc_coretime_common::is_parathread; use mp_coretime_bulk::{ self, well_known_keys::broker_regions, BulkMemRecord, BulkMemRecordItem, BulkRuntimeApi, @@ -44,7 +42,7 @@ use sc_service::TaskManager; use sp_api::ProvideRuntimeApi; use sp_application_crypto::AppPublic; use sp_consensus_aura::AuraApi; -use sp_core::{crypto::Pair, H256}; +use sp_core::crypto::Pair; use sp_runtime::traits::{Block as BlockT, Member}; use sp_state_machine::StorageProof; use std::{error::Error, sync::Arc}; @@ -66,8 +64,6 @@ fn u8_array_to_u128(array: [u8; 10]) -> u128 { pub async fn coretime_bulk_task( parachain: &P, relay_chain: R, - _height: RelayBlockNumber, - p_hash: H256, para_id: ParaId, bulk_record: Arc>, ) -> Result<(), Box> @@ -80,16 +76,10 @@ where PB::Public: AppPublic + Member + Codec, PB::Signature: TryFrom> + Member + Codec, { - // Determine whether it is a parathread - let parathread = is_parathread(relay_chain, p_hash, para_id).await?; - if !parathread { - return Ok(()); - } + let relay_chain_clone = relay_chain.clone(); let hash = parachain.usage_info().chain.finalized_hash; - let mut bulk_record_local = bulk_record.lock().await; - // Get the final block of the coretime parachain through subxt. let url = parachain.runtime_api().rpc_url(hash)?; @@ -97,125 +87,143 @@ where let api = OnlineClient::::from_url(rpc_url).await?; - let block = api.blocks().at_latest().await?; + let mut blocks_sub = api.blocks().subscribe_best().await?; + + // For each block, print a bunch of information about it: + while let Some(block) = blocks_sub.next().await { + let block = block?; + // Relaychain finalized block hash + let p_hash = relay_chain_clone.finalized_block_hash().await?; + // Determine whether it is a parathread + let parathread = is_parathread(&relay_chain_clone, p_hash, para_id).await?; + if !parathread { + continue; + } + let block_number = block.header().number; - let pre_block_height = bulk_record_local.coretime_para_height; + let mut bulk_record_local = bulk_record.lock().await; + bulk_record_local.coretime_para_height = block_number; + let events = block.events().await?; + for event in events.iter() { + let event = event?; + // Query Broker Assigned Event + let ev_assigned = event.as_event::(); - let block_number = block.number(); + if let Ok(assigned_event) = ev_assigned { + if let Some(ev) = assigned_event { + log::info!( + "=====================Find Assigned event:{:?},{:?},{:?}================", + ev.region_id, + ev.task, + ev.duration + ); - // If the block number has not changed, it will be returned without any processing. - if pre_block_height != block_number { - bulk_record_local.coretime_para_height = block_number; - } else { - return Ok(()); - } + let pid: u32 = para_id.into(); + + if ev.task == pid { + // Call rpc state_getReadProof. + let rpc_client = RpcClient::from_url(rpc_url).await?; + + let rpc = LegacyRpcMethods::::new(rpc_client.clone()); + + let mask = u8_array_to_u128(ev.region_id.mask.0); + + let core_mask = CoreMask::from(mask); - let events = block.events().await?; - for event in events.iter() { - let event = event?; - // Query Broker Assigned Event - let ev_assigned = event.as_event::(); - - if let Ok(assigned_event) = ev_assigned { - if let Some(ev) = assigned_event { - log::info!( - "=====================Find Assigned event:{:?},{:?},{:?}================", - ev.region_id, - ev.task, - ev.duration - ); - - let pid: u32 = para_id.into(); - - if ev.task == pid { - // Call rpc state_getReadProof. - let rpc_client = RpcClient::from_url(rpc_url).await?; - - let rpc = LegacyRpcMethods::::new(rpc_client.clone()); - - let mask = u8_array_to_u128(ev.region_id.mask.0); - - let core_mask = CoreMask::from(mask); - - let region_id = RegionId { - begin: ev.region_id.begin, - core: ev.region_id.core, - mask: core_mask, - }; - - let region_key = broker_regions(region_id); - // coretime parachain genesis hash key - let block_hash_key = SYSTEM_BLOCKHASH_GENESIS; - let mut relevant_keys = Vec::new(); - relevant_keys.push(region_key.as_slice()); - relevant_keys.push(block_hash_key); - - let proof = rpc - .state_get_read_proof(relevant_keys, Some(events.block_hash())) - .await - .unwrap(); - let storage_proof = - StorageProof::new(proof.proof.into_iter().map(|bytes| bytes.to_vec())); - - let storage_root = block.header().state_root; - // Create coretime parachain storage root proof. - let relay_storage_rooted_proof: GenericStateProof< - cumulus_primitives_core::relay_chain::Block, - > = GenericStateProof::new(storage_root, storage_proof.clone()).unwrap(); - - let head_data = relay_storage_rooted_proof - .read_entry::>(region_key.as_slice(), None) - .ok(); - // Check proof is ok. - if head_data.is_some() { - // Record some data. - let record_item = BulkMemRecordItem { - storage_proof, - storage_root, - region_id, - duration: ev.duration, - status: BulkStatus::Assigned, - start_relaychain_height: 0, - end_relaychain_height: 0, + let region_id = RegionId { + begin: ev.region_id.begin, + core: ev.region_id.core, + mask: core_mask, }; - bulk_record_local.items.push(record_item); + + let region_key = broker_regions(region_id); + // coretime parachain genesis hash key + let block_hash_key = SYSTEM_BLOCKHASH_GENESIS; + let mut relevant_keys = Vec::new(); + relevant_keys.push(region_key.as_slice()); + relevant_keys.push(block_hash_key); + + let proof = rpc + .state_get_read_proof(relevant_keys, Some(events.block_hash())) + .await + .unwrap(); + let storage_proof = + StorageProof::new(proof.proof.into_iter().map(|bytes| bytes.to_vec())); + + let storage_root = block.header().state_root; + // Create coretime parachain storage root proof. + let relay_storage_rooted_proof: GenericStateProof< + cumulus_primitives_core::relay_chain::Block, + > = GenericStateProof::new(storage_root, storage_proof.clone()).unwrap(); + + let head_data = relay_storage_rooted_proof + .read_entry::>( + region_key.as_slice(), + None, + ) + .ok(); + // Check proof is ok. + if head_data.is_some() { + // Record some data. + let record_item = BulkMemRecordItem { + storage_proof, + storage_root, + region_id, + duration: ev.duration, + status: BulkStatus::Assigned, + start_relaychain_height: 0, + end_relaychain_height: 0, + }; + bulk_record_local.items.push(record_item); + } } + continue; } - continue; } - } - // Query CoreAssigned event. - let ev_core_assigned = event.as_event::(); - - if let Ok(core_assigned_event) = ev_core_assigned { - if let Some(ev) = core_assigned_event { - log::info!( - "=====================Find CoreAssigned event: {:?},{:?},{:?}=================", - ev.core, - ev.when, - ev.assignment - ); - - for (core_assign, _) in ev.assignment { - if let metadata::CoreAssignment::Task(id) = core_assign { - let pid: u32 = para_id.into(); - if id == pid { - let items = &mut bulk_record_local.items; - for item in items { - if item.status == BulkStatus::Assigned { - item.start_relaychain_height = ev.when; - - let constant_query = - subxt::dynamic::constant("Broker", "TimeslicePeriod"); - - let time_slice = - api.constants().at(&constant_query)?.to_value()?.context; - - item.end_relaychain_height = - ev.when + item.duration * time_slice; - // find it. - item.status = BulkStatus::CoreAssigned; + // Query CoreAssigned event. + let ev_core_assigned = event.as_event::(); + + if let Ok(core_assigned_event) = ev_core_assigned { + if let Some(ev) = core_assigned_event { + log::info!( + "=====================Find CoreAssigned event: {:?},{:?},{:?}=================", + ev.core, + ev.when, + ev.assignment + ); + + for (core_assign, _) in ev.assignment { + if let metadata::CoreAssignment::Task(id) = core_assign { + let pid: u32 = para_id.into(); + if id == pid { + let items = &mut bulk_record_local.items; + for item in items { + if item.status == BulkStatus::Assigned { + item.start_relaychain_height = ev.when; + + let constant_query = + subxt::dynamic::constant("Broker", "TimeslicePeriod"); + + let time_slice = + api.constants() + .at(&constant_query)? + .to_value()? + .as_u128() + .expect("coretime parachain time slice none") as u32; + + item.end_relaychain_height = + ev.when + item.duration * time_slice; + log::info!( + "==============={:?},{:?},{:?},{:?},", + ev.when, + item.duration, + time_slice, + item + ); + // find it. + item.status = BulkStatus::CoreAssigned; + } } } } @@ -224,9 +232,9 @@ where } } } + Ok(()) } - pub async fn run_coretime_bulk_task( parachain: Arc

, relay_chain: R, @@ -242,25 +250,14 @@ pub async fn run_coretime_bulk_task( PB::Signature: TryFrom> + Member + Codec, { let relay_chain_notification = async move { - let new_best_heads = relay_chain - .new_best_notification_stream() - .await? - .filter_map(move |n| async move { Some((n.number, n.hash())) }) - .fuse(); - pin_mut!(new_best_heads); loop { - select! { - h = new_best_heads.next() => { - match h { - Some((height, hash)) => { - coretime_bulk_task::<_,_,_, PB>(&*parachain, relay_chain.clone(), height, hash, para_id, bulk_record.clone()).await?; - }, - None => { - return Ok::<(), Box>(()); - } - } - } - } + let _ = coretime_bulk_task::<_, _, _, PB>( + &*parachain, + relay_chain.clone(), + para_id, + bulk_record.clone(), + ) + .await; } }; select! { diff --git a/client/coretime/common/src/lib.rs b/client/coretime/common/src/lib.rs index 3ba3c4b..18a1988 100644 --- a/client/coretime/common/src/lib.rs +++ b/client/coretime/common/src/lib.rs @@ -33,7 +33,7 @@ type AuthorityId

=

::Public; /// Is it now a parathread. pub async fn is_parathread( - relay_chain: impl RelayChainInterface + Clone, + relay_chain: &(impl RelayChainInterface + Clone), p_hash: H256, para_id: ParaId, ) -> Result> { diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index f0eba8f..df8804b 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -75,7 +75,7 @@ pub fn development_config() -> ChainSpec { Extensions { relay_chain: "rococo-local".into(), // You MUST set this to the correct network! - para_id: 1000, + para_id: 2000, }, ) .with_name("Development") @@ -108,7 +108,7 @@ pub fn development_config() -> ChainSpec { get_account_id_from_seed::("Ferdie//stash"), ], get_account_id_from_seed::("Alice"), - 1000.into(), + 2000.into(), )) .build() } @@ -126,7 +126,7 @@ pub fn local_testnet_config() -> ChainSpec { Extensions { relay_chain: "rococo-local".into(), // You MUST set this to the correct network! - para_id: 1000, + para_id: 2000, }, ) .with_name("Local Testnet") @@ -159,7 +159,7 @@ pub fn local_testnet_config() -> ChainSpec { get_account_id_from_seed::("Ferdie//stash"), ], get_account_id_from_seed::("Alice"), - 1000.into(), + 2000.into(), )) .with_protocol_id("magnet-local") .with_properties(properties) From 677a2c59190ff68f56f13f6e2e34f09e2ec54b9a Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Tue, 2 Jul 2024 13:13:54 +0800 Subject: [PATCH 20/44] record actually relaychain block number of start parachain --- client/coretime/bulk/src/lib.rs | 8 +------- node/src/service.rs | 5 ++++- pallets/bulk/src/benchmarking.rs | 9 +++++++-- pallets/bulk/src/lib.rs | 18 ++++++++++++++++-- pallets/bulk/src/mock.rs | 7 +++++-- pallets/bulk/src/tests.rs | 5 +++-- .../coretime/bulk/src/inherent_client.rs | 2 ++ primitives/coretime/bulk/src/lib.rs | 2 ++ runtime/src/lib.rs | 7 +++---- 9 files changed, 43 insertions(+), 20 deletions(-) diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 182a45d..fde6d37 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -214,13 +214,7 @@ where item.end_relaychain_height = ev.when + item.duration * time_slice; - log::info!( - "==============={:?},{:?},{:?},{:?},", - ev.when, - item.duration, - time_slice, - item - ); + item.duration = item.duration * time_slice; // find it. item.status = BulkStatus::CoreAssigned; } diff --git a/node/src/service.rs b/node/src/service.rs index 3f6a1b2..6ece3fa 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -670,6 +670,7 @@ fn start_consensus( storage_proof, storage_root, region_id, + duration, start_relaychain_height, end_relaychain_height, ) = if let Some(item) = item { @@ -677,16 +678,18 @@ fn start_consensus( Some(&item.storage_proof), item.storage_root, item.region_id, + item.duration, item.start_relaychain_height, item.end_relaychain_height, ) } else { - (None, Default::default(), 0u128.into(), 0, 0) + (None, Default::default(), 0u128.into(), 0, 0, 0) }; let bulk_inherent = mp_coretime_bulk::BulkInherentData::create_at( storage_proof, storage_root, region_id, + duration, start_relaychain_height, end_relaychain_height, ) diff --git a/pallets/bulk/src/benchmarking.rs b/pallets/bulk/src/benchmarking.rs index cd88655..00ba979 100644 --- a/pallets/bulk/src/benchmarking.rs +++ b/pallets/bulk/src/benchmarking.rs @@ -15,7 +15,7 @@ // along with Magnet. If not, see . //! Benchmarking setup for pallet-bulk - +#![cfg(feature = "runtime-benchmarks")] use super::*; #[allow(unused)] @@ -60,9 +60,14 @@ benchmarks! { storage_proof: Some(coretime_chain_state_proof), storage_root, region_id, + duration: 100, start_relaychain_height: 130, - end_relaychain_height: 170, + end_relaychain_height: 230, }; + T::RelayChainStateProvider::set_current_relay_chain_state(cumulus_pallet_parachain_system::RelayChainState { + state_root: storage_root, + number: 0, + }); }: _(RawOrigin::None, bulk_inherent_data) verify { assert_eq!(RecordIndex::::get(), 1); diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index 7917900..ae41573 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -69,6 +69,10 @@ pub struct BulkRecord { pub start_relaychain_height: u32, /// Relaychain block number of end schedule coretime core. pub end_relaychain_height: u32, + /// Relaychain block number of parachain start run. + pub real_start_relaychain_height: u32, + /// Relaychain block number of parachain end run. + pub real_end_relaychain_height: u32, } #[frame_support::pallet] pub mod pallet { @@ -169,6 +173,10 @@ pub mod pallet { start_relaychain_height: u32, /// Relaychain block number of end schedule coretime core. end_relaychain_height: u32, + /// Relaychain block number of parachain start run. + real_start_relaychain_height: u32, + /// Relaychain block number of parachain end run. + real_end_relaychain_height: u32, }, } @@ -235,6 +243,7 @@ pub mod pallet { storage_proof: p_storage_proof, storage_root, region_id, + duration, start_relaychain_height, end_relaychain_height, } = data; @@ -266,7 +275,8 @@ pub mod pallet { if genesis_hash != stored_hash { Err(Error::::GenesisHashInconsistency)?; } - + let real_start_relaychain_height = Self::relaychain_block_number(); + let real_end_relaychain_height = real_start_relaychain_height + duration; let old_record_index = RecordIndex::::get(); let balance = region_record.paid.ok_or(Error::::PurchaserNone)?; let purchaser = region_record.owner; @@ -276,9 +286,11 @@ pub mod pallet { BulkRecord::, T::AuthorityId> { purchaser: purchaser.clone(), price: balance, - duration: region_record.end, + duration, start_relaychain_height, end_relaychain_height, + real_start_relaychain_height, + real_end_relaychain_height, }, ); RecordIndex::::set(old_record_index + 1); @@ -288,6 +300,8 @@ pub mod pallet { duration: region_record.end, start_relaychain_height, end_relaychain_height, + real_start_relaychain_height, + real_end_relaychain_height, }); let total_weight = T::WeightInfo::create_record(); diff --git a/pallets/bulk/src/mock.rs b/pallets/bulk/src/mock.rs index 9629658..555a5e2 100644 --- a/pallets/bulk/src/mock.rs +++ b/pallets/bulk/src/mock.rs @@ -102,8 +102,11 @@ pub struct MockRelayStateProvider; impl RelaychainStateProvider for MockRelayStateProvider { fn current_relay_chain_state() -> RelayChainState { - let root = frame_support::storage::unhashed::get(MOCK_RELAY_ROOT_KEY) - .expect("root should be set by mock"); + let root = if let Some(root) = frame_support::storage::unhashed::get(MOCK_RELAY_ROOT_KEY) { + root + } else { + Default::default() + }; RelayChainState { state_root: root, diff --git a/pallets/bulk/src/tests.rs b/pallets/bulk/src/tests.rs index cc279b9..15ae849 100644 --- a/pallets/bulk/src/tests.rs +++ b/pallets/bulk/src/tests.rs @@ -40,8 +40,9 @@ fn bulk_inherent_test() { storage_proof: Some(coretime_chain_state_proof), storage_root, region_id, + duration: 100, start_relaychain_height: 130, - end_relaychain_height: 170, + end_relaychain_height: 230, }; inherent_data .put_data(mp_coretime_bulk::INHERENT_IDENTIFIER, &bulk_inherent_data) @@ -54,6 +55,6 @@ fn bulk_inherent_test() { assert_eq!(BulkPallet::record_index(), 1); let record = BulkPallet::bulk_records(0).unwrap(); assert_eq!(record.start_relaychain_height, 130); - assert_eq!(record.end_relaychain_height, 170); + assert_eq!(record.end_relaychain_height, 230); }); } diff --git a/primitives/coretime/bulk/src/inherent_client.rs b/primitives/coretime/bulk/src/inherent_client.rs index 45ec087..d91d464 100644 --- a/primitives/coretime/bulk/src/inherent_client.rs +++ b/primitives/coretime/bulk/src/inherent_client.rs @@ -25,6 +25,7 @@ impl BulkInherentData { storage_proof: Option<&sp_trie::StorageProof>, storage_root: PHash, region_id: RegionId, + duration: u32, start: u32, end: u32, ) -> Option { @@ -34,6 +35,7 @@ impl BulkInherentData { storage_proof, storage_root, region_id, + duration, start_relaychain_height: start, end_relaychain_height: end, }) diff --git a/primitives/coretime/bulk/src/lib.rs b/primitives/coretime/bulk/src/lib.rs index 24c3209..96f8fbf 100644 --- a/primitives/coretime/bulk/src/lib.rs +++ b/primitives/coretime/bulk/src/lib.rs @@ -38,6 +38,8 @@ pub struct BulkInherentData { pub storage_root: PHash, /// The identity of the Region. pub region_id: RegionId, + /// Coretime duration. + pub duration: u32, /// Relaychain block number of start schedule coretime core. pub start_relaychain_height: u32, /// Relaychain block number of end schedule coretime core. diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index 2d15086..e8859a0 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -762,12 +762,11 @@ where for i in 0..record_index { let bulk_record = >::bulk_records(i); if let Some(record) = bulk_record { - if block_number.into() >= record.start_relaychain_height.into() - && block_number.into() <= record.end_relaychain_height.into() + if block_number.into() >= record.real_start_relaychain_height.into() + && block_number.into() <= record.real_end_relaychain_height.into() { let price: u128 = record.price.saturated_into(); - let duration = - (record.end_relaychain_height - record.start_relaychain_height) as u128; + let duration = record.duration as u128; let balance = price .checked_div(duration) .ok_or(sp_runtime::DispatchError::Other("duration error"))?; From 8b7bafeb078a09124b180fcf7fd7a1d899b190d0 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Tue, 2 Jul 2024 20:25:35 +0800 Subject: [PATCH 21/44] add on demand primitives and pallet --- Cargo.lock | 56 + Cargo.toml | 2 +- pallets/bulk/Cargo.toml | 2 +- pallets/bulk/README.md | 1 - pallets/on-demand/Cargo.toml | 90 + pallets/on-demand/src/benchmarking.rs | 40 + pallets/on-demand/src/lib.rs | 489 ++ pallets/on-demand/src/mock.rs | 183 + pallets/on-demand/src/proof_data.rs | 29 + pallets/on-demand/src/tests.rs | 82 + pallets/on-demand/src/weights.rs | 70 + primitives/coretime/on-demand/Cargo.toml | 52 + .../coretime/on-demand/src/inherent_client.rs | 89 + primitives/coretime/on-demand/src/lib.rs | 111 + primitives/coretime/on-demand/src/metadata.rs | 5350 +++++++++++++++++ .../coretime/on-demand/src/well_known_keys.rs | 54 + 16 files changed, 6697 insertions(+), 3 deletions(-) delete mode 100644 pallets/bulk/README.md create mode 100644 pallets/on-demand/Cargo.toml create mode 100644 pallets/on-demand/src/benchmarking.rs create mode 100644 pallets/on-demand/src/lib.rs create mode 100644 pallets/on-demand/src/mock.rs create mode 100644 pallets/on-demand/src/proof_data.rs create mode 100644 pallets/on-demand/src/tests.rs create mode 100644 pallets/on-demand/src/weights.rs create mode 100644 primitives/coretime/on-demand/Cargo.toml create mode 100644 primitives/coretime/on-demand/src/inherent_client.rs create mode 100644 primitives/coretime/on-demand/src/lib.rs create mode 100644 primitives/coretime/on-demand/src/metadata.rs create mode 100644 primitives/coretime/on-demand/src/well_known_keys.rs diff --git a/Cargo.lock b/Cargo.lock index 210e390..ac5f349 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7287,6 +7287,31 @@ dependencies = [ "sp-weights 27.0.0", ] +[[package]] +name = "mp-coretime-on-demand" +version = "0.1.0" +dependencies = [ + "async-trait", + "cumulus-primitives-core", + "cumulus-relay-chain-interface", + "hex-literal", + "log", + "parity-scale-codec", + "scale-info", + "sp-api", + "sp-consensus-aura", + "sp-consensus-grandpa", + "sp-core 28.0.0", + "sp-inherents", + "sp-io 30.0.0", + "sp-runtime 31.0.1", + "sp-session", + "sp-state-machine 0.35.0", + "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", + "sp-trie 29.0.0", + "sp-weights 27.0.0", +] + [[package]] name = "mp-system" version = "0.1.0" @@ -8984,6 +9009,37 @@ dependencies = [ "sp-std 14.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", ] +[[package]] +name = "pallet-on-demand" +version = "0.1.0" +dependencies = [ + "cumulus-pallet-parachain-system", + "cumulus-primitives-core", + "frame-benchmarking", + "frame-support", + "frame-system", + "hex", + "hex-literal", + "log", + "mp-coretime-on-demand", + "pallet-balances", + "pallet-collective", + "pallet-society", + "pallet-xcm", + "parachains-common", + "parity-scale-codec", + "polkadot-primitives", + "polkadot-runtime-parachains", + "scale-info", + "serde", + "sp-consensus-aura", + "sp-core 28.0.0", + "sp-io 30.0.0", + "sp-runtime 31.0.1", + "sp-trie 29.0.0", + "staging-xcm-builder", +] + [[package]] name = "pallet-pot" version = "0.1.0" diff --git a/Cargo.toml b/Cargo.toml index ce9001a..839c2d0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,7 +17,7 @@ overflow-checks = true members = [ "node", "runtime", -# "pallets/order", + "pallets/on-demand", "pallets/bulk", "primitives/system", "pallets/evm-utils", diff --git a/pallets/bulk/Cargo.toml b/pallets/bulk/Cargo.toml index a21384f..3d9b768 100644 --- a/pallets/bulk/Cargo.toml +++ b/pallets/bulk/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "pallet-bulk" -authors = ["Anonymous"] +authors = ["Magnet"] description = "bulk mode runtime logic." version = "0.2.0" license = "Apache-2.0" diff --git a/pallets/bulk/README.md b/pallets/bulk/README.md deleted file mode 100644 index 5a64612..0000000 --- a/pallets/bulk/README.md +++ /dev/null @@ -1 +0,0 @@ -License: Unlicense diff --git a/pallets/on-demand/Cargo.toml b/pallets/on-demand/Cargo.toml new file mode 100644 index 0000000..ea3e80f --- /dev/null +++ b/pallets/on-demand/Cargo.toml @@ -0,0 +1,90 @@ +[package] +name = "pallet-on-demand" +authors = ["Magnet"] +description = "On demand order runtime logic." +version = "0.1.0" +license = "Apache-2.0" +homepage = "https://magnet.magport.io/" +repository.workspace = true +edition.workspace = true + +[package.metadata.docs.rs] +targets = ["x86_64-unknown-linux-gnu"] + +[dependencies] +codec = { package = "parity-scale-codec", workspace = true, features = ["derive"], default-features = false } +scale-info = { workspace = true, default-features = false, features = ["derive"] } +log = { workspace = true, default-features = false } +hex-literal = { workspace = true } + +# Local +mp-coretime-on-demand = { path = "../../primitives/coretime/on-demand", default-features = false } + +# Cumulus +cumulus-pallet-parachain-system = { workspace = true, default-features = false} +cumulus-primitives-core= { workspace = true, default-features = false} + +# Polkadot +runtime-parachains = { workspace = true , default-features = false} +primitives = { workspace = true , default-features = false} + + +# Substrate +frame-benchmarking = { workspace = true, default-features = false, optional = true} +frame-support = { workspace = true, default-features = false} +frame-system = { workspace = true, default-features = false} +sp-runtime = { workspace = true, default-features = false} +sp-trie = { workspace = true, default-features = false } +pallet-balances = { workspace = true, default-features = false } +sp-core = { workspace = true , default-features = false} + +[dev-dependencies] +serde = { workspace = true } +codec = { workspace = true, features = ["derive"], default-features = false } +hex = { workspace = true, default-features = false } + +# Substrate +sp-core = { workspace = true, default-features = false} +sp-io = { workspace = true, default-features = false} +sp-runtime = { workspace = true, default-features = false} +sp-consensus-aura = { workspace = true, default-features = false} +pallet-balances = { workspace = true, default-features = false } +pallet-collective = { workspace = true, default-features = false} +pallet-xcm = { workspace = true, default-features = false} +pallet-society ={ workspace = true, default-features = false} +xcm-builder = { workspace = true, default-features = false } +parachains-common = { workspace = true, default-features = false } + +[features] +default = [ "std" ] +runtime-benchmarks = [ + "frame-benchmarking/runtime-benchmarks", + "pallet-collective/runtime-benchmarks", + "pallet-xcm/runtime-benchmarks", + "pallet-society/runtime-benchmarks", + "xcm-builder/runtime-benchmarks", +] +std = [ + "codec/std", + "frame-benchmarking/std", + "frame-support/std", + "frame-system/std", + "scale-info/std", + "sp-core/std", + "sp-io/std", + "sp-runtime/std", + "mp-coretime-on-demand/std", + "log/std", + "cumulus-pallet-parachain-system/std", + "cumulus-primitives-core/std", + "runtime-parachains/std", + "primitives/std", + "sp-trie/std", + "pallet-balances/std", + "sp-core/std", +] +try-runtime = [ + "frame-support/try-runtime", + "frame-system/try-runtime", + "sp-runtime/try-runtime", +] diff --git a/pallets/on-demand/src/benchmarking.rs b/pallets/on-demand/src/benchmarking.rs new file mode 100644 index 0000000..3abea2f --- /dev/null +++ b/pallets/on-demand/src/benchmarking.rs @@ -0,0 +1,40 @@ +// // Copyright (C) Magnet. +// // This file is part of Magnet. + +// // Magnet is free software: you can redistribute it and/or modify +// // it under the terms of the GNU General Public License as published by +// // the Free Software Foundation, either version 3 of the License, or +// // (at your option) any later version. + +// // Magnet is distributed in the hope that it will be useful, +// // but WITHOUT ANY WARRANTY; without even the implied warranty of +// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// // GNU General Public License for more details. + +// // You should have received a copy of the GNU General Public License +// // along with Magnet. If not, see . + +// //! Benchmarking setup for pallet-order + +// use super::*; + +// #[allow(unused)] +// use crate::Pallet as Order; +// use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller}; +// use frame_system::RawOrigin; + +// benchmarks! { +// set_parameter { +// let s in 0 .. 100; +// let caller: T::AccountId = whitelisted_caller(); +// let test_balance = BalanceOf::::from(200000000 as u32); +// let test_threshold = BalanceOf::::from(3000000000 as u32); +// }: _(RawOrigin::Root, Some(4), Some(test_balance), Some(test_threshold)) +// verify { +// assert_eq!(SlotWidth::::get(), 4); +// assert_eq!(OrderMaxAmount::::get(), test_balance); +// assert_eq!(TxPoolThreshold::::get(), test_threshold); +// } +// } + +// impl_benchmark_test_suite!(Order, crate::mock::ExtBuilder::default().build(), crate::mock::Test,); diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs new file mode 100644 index 0000000..df98fab --- /dev/null +++ b/pallets/on-demand/src/lib.rs @@ -0,0 +1,489 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! # Order Pallet +//! +//! This pallet implements the recording and query functions of purchasing ondemand core. +//! +//! By obtaining the inherent nature of the block, parsing it out of the validation_data of the relaychain, +//! and querying whether there is an OnDemandOrderPlaced event, obtaining the order account and price from the event, +//! and then writing this record to the blockchain. +//! +//! Provides many query methods for node or other pallets to use, such as querying the gas consumed by placing an order in a certain block, +//! whether the order has been executed, whether the order threshold has been reached, etc. + +#![cfg_attr(not(feature = "std"), no_std)] +use codec::{Decode, MaxEncodedLen}; +use cumulus_pallet_parachain_system::{ + relay_state_snapshot::Error as Relay_Error, RelayChainStateProof, +}; +use frame_support::{ + dispatch::DispatchResultWithPostInfo, dispatch::PostDispatchInfo, pallet_prelude::*, + traits::Currency, +}; +use frame_system::pallet_prelude::*; +use frame_system::{self, EventRecord}; +// use magnet_primitives_order::{ +// metadata::api::{runtime_types, runtime_types::rococo_runtime as polakdot_runtime}, +// well_known_keys::SYSTEM_EVENTS, +// }; +pub use pallet::*; +use primitives::Balance; +use primitives::{Id as ParaId, PersistedValidationData}; +use sp_runtime::sp_std::{prelude::*, vec}; +use sp_runtime::{traits::Member, RuntimeAppPublic}; +pub mod weights; +use sp_core::crypto::ByteArray; +use weights::WeightInfo; +#[cfg(test)] +mod mock; + +#[cfg(test)] +mod tests; + +#[cfg(any(test, feature = "runtime-benchmarks"))] +mod benchmarking; +mod proof_data; + +type BalanceOf = + <::Currency as Currency<::AccountId>>::Balance; + +/// ondemand order information. +#[derive(Encode, Decode, Default, Clone, Copy, TypeInfo, MaxEncodedLen, Debug)] +pub struct Order { + /// The number used to record the order, incremented each time. + pub sequence_number: u64, + // relaychain_block_hash:Hash, + // relaychain_block_height:u32, + /// Account for placing order. + pub orderer: AuthorityId, + /// Order price. + pub price: Balance, + /// Whether the order was executed. + pub executed: bool, +} +#[frame_support::pallet] +pub mod pallet { + use super::*; + + /// Configure the pallet by specifying the parameters and types on which it depends. + #[pallet::config] + pub trait Config: frame_system::Config { + /// Because this pallet emits events, it depends on the runtime's definition of an event. + type RuntimeEvent: From> + IsType<::RuntimeEvent>; + + type Currency: Currency; + + type AuthorityId: Member + + Parameter + + RuntimeAppPublic + + MaybeSerializeDeserialize + + MaxEncodedLen + + for<'a> TryFrom<&'a [u8]>; + + type UpdateOrigin: EnsureOrigin; + + type WeightInfo: WeightInfo; + /// The default value of w. + #[pallet::constant] + type SlotWidth: Get; + + /// The max value of place order. + #[pallet::constant] + type OrderMaxAmount: Get>; + + /// The gas threshold required to place an order. + #[pallet::constant] + type TxPoolThreshold: Get>; + } + + #[pallet::pallet] + pub struct Pallet(PhantomData); + + /// Sequence number,number of each order. + #[pallet::storage] + #[pallet::getter(fn sequence_number)] + pub type SequenceNumber = StorageValue<_, u64, ValueQuery>; + + /// Record the relaychain block height of the latest order + #[pallet::storage] + #[pallet::getter(fn current_relay_height)] + pub type CurrentRelayHeight = StorageValue<_, u32, ValueQuery>; + + #[pallet::type_value] + pub fn SlotWidthOnEmpty() -> u32 { + T::SlotWidth::get() + } + #[pallet::type_value] + pub fn OrderMaxAmountOnEmpty() -> BalanceOf { + T::OrderMaxAmount::get() + } + #[pallet::type_value] + pub fn TxPoolThresholdOnEmpty() -> BalanceOf { + T::TxPoolThreshold::get() + } + + /// The order interval is 2^slotwidth. + #[pallet::storage] + #[pallet::getter(fn slot_width)] + pub(super) type SlotWidth = StorageValue<_, u32, ValueQuery, SlotWidthOnEmpty>; + + /// The maximum price the user is willing to pay when placing an order. + #[pallet::storage] + #[pallet::getter(fn order_max_amount)] + pub(super) type OrderMaxAmount = + StorageValue<_, BalanceOf, ValueQuery, OrderMaxAmountOnEmpty>; + + /// Gas threshold that triggers order placement. + #[pallet::storage] + #[pallet::getter(fn txpool_threshold)] + pub(super) type TxPoolThreshold = + StorageValue<_, BalanceOf, ValueQuery, TxPoolThresholdOnEmpty>; + + /// Order Information Map. + #[pallet::storage] + #[pallet::getter(fn order_map)] + pub type OrderMap = + StorageMap<_, Twox64Concat, u64, Order, OptionQuery>; + + /// Convert block height to sequence number. + #[pallet::storage] + #[pallet::getter(fn block_2_sequence)] + pub type Block2Sequence = + StorageMap<_, Twox64Concat, BlockNumberFor, u64, OptionQuery>; + + #[pallet::event] + #[pallet::generate_deposit(pub(super) fn deposit_event)] + pub enum Event { + /// Create order event. + OrderCreate { sequence_number: u64, orderer: T::AuthorityId }, + } + + #[pallet::error] + pub enum Error { + /// Error reading data. + FailedReading, + /// Order already exists. + OrderExist, + /// Failed to create order. + CreateOrderFail, + /// Invalid Validation data. + InvalidValidation, + /// Incorrect sequence number + WrongSequenceNumber, + } + + #[pallet::hooks] + impl Hooks> for Pallet { + /// Called at the end of each block to check whether an order has been placed. + /// If so, modify the execution status and increase the sequencer number. + fn on_finalize(block_number: BlockNumberFor) { + // let old_sequence_number = SequenceNumber::::get(); + // let order = OrderMap::::get(old_sequence_number); + // if let Some(t_order) = order { + // let orderer = t_order.orderer; + // OrderMap::::remove(old_sequence_number); + // OrderMap::::insert( + // old_sequence_number, + // Order:: { + // sequence_number: old_sequence_number, + // orderer: orderer.clone(), + // price: t_order.price, + // executed: true, + // }, + // ); + // SequenceNumber::::set(old_sequence_number + 1); + // Block2Sequence::::insert(block_number, old_sequence_number); + // Self::deposit_event(Event::OrderCreate { + // sequence_number: old_sequence_number, + // orderer, + // }); + // } + } + } + + // #[pallet::inherent] + // impl ProvideInherent for Pallet { + // type Call = Call; + // type Error = MakeFatalError<()>; + + // const INHERENT_IDENTIFIER: InherentIdentifier = + // magnet_primitives_order::INHERENT_IDENTIFIER; + // fn create_inherent(data: &InherentData) -> Option { + // let data: magnet_primitives_order::OrderInherentData = data + // .get_data(&magnet_primitives_order::INHERENT_IDENTIFIER) + // .ok() + // .flatten() + // .expect("there is not data to be posted; qed"); + // if data.validation_data.is_some() { + // Some(Call::create_order { data }) + // } else { + // None + // } + // } + // fn is_inherent(call: &Self::Call) -> bool { + // matches!(call, Call::create_order { .. }) + // } + // } + + #[pallet::call] + impl Pallet { + // /// Create an order, which is called by the pallet. + // /// Users cannot actively call this function. + // /// Obtain order information by parsing inherited data. + // /// + // /// Parameters: + // /// - `data`: The inherent data. + // #[pallet::call_index(0)] + // #[pallet::weight((0, DispatchClass::Mandatory))] + // pub fn create_order( + // origin: OriginFor, + // data: magnet_primitives_order::OrderInherentData, + // ) -> DispatchResultWithPostInfo { + // ensure_none(origin)?; + + // let magnet_primitives_order::OrderInherentData { + // relay_storage_proof, + // validation_data, + // sequence_number, + // para_id, + // author_pub, + // } = data; + // let total_weight = match validation_data { + // Some(validation_data) => { + // let (_, price) = Self::check_order_proof( + // relay_storage_proof, + // validation_data.clone(), + // author_pub.clone(), + // para_id, + // ) + // .ok_or(Error::::CreateOrderFail)?; + // let old_sequence_number = SequenceNumber::::get(); + // let order = OrderMap::::get(old_sequence_number); + // if sequence_number != old_sequence_number { + // // In the worst-case scenario, if there are multiple orders at the same + // // time, it may be due to system issues or it may be due to human + // // intervention. Currently, we only support running one order at the same + // // time Err(Error::::WrongSequenceNumber)?; + // // Continuing to produce blocks, recording errors + // log::info!("========WrongSequenceNumber:{:?}========", sequence_number); + // } + // if order.is_none() { + // OrderMap::::insert( + // old_sequence_number, + // Order:: { + // sequence_number: old_sequence_number, + // orderer: author_pub.unwrap(), + // price, + // executed: false, + // }, + // ); + // CurrentRelayHeight::::set(validation_data.relay_parent_number); + // } else { + // Err(Error::::OrderExist)?; + // } + // T::DbWeight::get().reads_writes(2, 1) + // }, + // None => T::DbWeight::get().reads_writes(0, 0), + // }; + // Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) + // } + + // /// Order pallet parameter settings. + // /// It can only be called by accounts with sudo privileges or authorized organization members. + // /// + // /// Parameters: + // /// - `slot_width`: The order interval is 2^slotwidth.. + // /// - `order_max_amount`: The maximum price the user is willing to pay when placing an order. + // /// - `tx_pool_threshold`: Gas threshold that triggers order placement. + // #[pallet::call_index(1)] + // #[pallet::weight(T::WeightInfo::set_parameter(*slot_width))] + // pub fn set_parameter( + // origin: OriginFor, + // slot_width: Option, + // order_max_amount: Option>, + // tx_pool_threshold: Option>, + // ) -> DispatchResultWithPostInfo { + // T::UpdateOrigin::ensure_origin(origin)?; + + // if let Some(t_slot_width) = slot_width { + // >::put(t_slot_width); + // } + // if let Some(t_order_max_amount) = order_max_amount { + // >::put(t_order_max_amount); + // } + // if let Some(t_tx_pool_threshold) = tx_pool_threshold { + // >::put(t_tx_pool_threshold); + // } + // Ok(().into()) + // } + } +} + +impl Pallet { + // /// Obtain the order account and price from the relaychain's validation. + // /// + // /// Parameters: + // /// - `relay_storage_proof`: The proof of relay chain storage. + // ///- `validation_data`: The validation data. + // /// - `para_id`: ID of parachain. + // fn get_author_from_proof( + // relay_storage_proof: sp_trie::StorageProof, + // validation_data: PersistedValidationData, + // para_id: ParaId, + // ) -> Option<(T::AuthorityId, Balance)> { + // let relay_storage_root = validation_data.relay_parent_storage_root; + // let relay_storage_rooted_proof = + // RelayChainStateProof::new(para_id, relay_storage_root, relay_storage_proof) + // .expect("Invalid relay chain state proof"); + // let head_data = relay_storage_rooted_proof + // .read_entry::>>>( + // SYSTEM_EVENTS, + // None, + // ) + // .ok()?; + // let v_price: Vec = head_data + // .iter() + // .filter_map(|item| { + // if let polakdot_runtime::RuntimeEvent::OnDemandAssignmentProvider( + // runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event::OnDemandOrderPlaced{ + // para_id: pid, + // spot_price: sprice, + // }) = &item.event + // { + // if pid.encode() == para_id.encode() { + // Some(*sprice) + // } else { + // None + // } + // } else { + // None + // } + // }) + // .collect(); + // let orderer: Vec<(T::AuthorityId, u128)> = v_price + // .iter() + // .filter_map(|item| { + // let mut orderer = None; + // let _: Vec<_> = head_data + // .iter() + // .filter_map(|event| { + // if let polakdot_runtime::RuntimeEvent::Balances( + // runtime_types::pallet_balances::pallet::Event::Withdraw { + // who: ref order, + // amount: eprice, + // }, + // ) = event.event + // { + // if eprice == *item { + // orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { + // Ok(order) => Some((order, eprice)), + // Err(_) => None, + // }; + // Some(()) + // } else { + // None + // } + // } else { + // None + // } + // }) + // .collect(); + // orderer + // }) + // .collect(); + // if orderer.len() > 0 { + // Some(orderer[0].clone()) + // } else { + // None + // } + // } + + // /// Check whether the account is in the validation of relaychain. + // /// + // /// Parameters: + // /// - `relay_storage_proof`: The proof of relay chain storage. + // /// - `validation_data`: The validation data. + // /// - `author_pub`: Account. + // /// - `para_id`: ID of parachain. + // fn check_order_proof( + // relay_storage_proof: sp_trie::StorageProof, + // validation_data: PersistedValidationData, + // author_pub: Option, + // para_id: ParaId, + // ) -> Option<(T::AuthorityId, Balance)> { + // let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); + // match op_author { + // Some((author, spot_price)) => { + // if author_pub == Some(author.clone()) { + // Some((author, spot_price)) + // } else { + // None + // } + // }, + // None => None, + // } + // } + + // /// Check whether there is an order event in the validation of relaychain. + // /// + // /// Parameters: + // /// - `relay_storage_proof`: The proof of relay chain storage. + // /// - `validation_data`: The validation data. + // /// - `para_id`: ID of parachain. + // pub fn order_placed( + // relay_storage_proof: sp_trie::StorageProof, + // validation_data: PersistedValidationData, + // para_id: ParaId, + // ) -> Option { + // let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); + // match op_author { + // Some((author, _)) => Some(author), + // None => None, + // } + // } + + // /// Whether the gas threshold for placing an order has been reached. + // /// + // /// Parameters: + // /// - `gas_balance`: The total gas. + // pub fn reach_txpool_threshold(gas_balance: BalanceOf) -> bool { + // let txpool_threshold = TxPoolThreshold::::get(); + // gas_balance > txpool_threshold + // } + + // /// Whether the order with the specified sequence number is executed. + // /// + // /// Parameters: + // /// - `sequence_number`: The sequence number. + // pub fn order_executed(sequence_number: u64) -> bool { + // let order_map = OrderMap::::get(sequence_number); + // match order_map { + // Some(order) => order.executed, + // None => false, + // } + // } +} + +pub trait OrderGasCost { + /// Gas consumed by placing an order in a certain block. + /// + /// Parameters: + /// - `block_number`: The block number of para chain. + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, DispatchError>; +} diff --git a/pallets/on-demand/src/mock.rs b/pallets/on-demand/src/mock.rs new file mode 100644 index 0000000..71fa00d --- /dev/null +++ b/pallets/on-demand/src/mock.rs @@ -0,0 +1,183 @@ +// // Copyright (C) Magnet. +// // This file is part of Magnet. + +// // Magnet is free software: you can redistribute it and/or modify +// // it under the terms of the GNU General Public License as published by +// // the Free Software Foundation, either version 3 of the License, or +// // (at your option) any later version. + +// // Magnet is distributed in the hope that it will be useful, +// // but WITHOUT ANY WARRANTY; without even the implied warranty of +// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// // GNU General Public License for more details. + +// // You should have received a copy of the GNU General Public License +// // along with Magnet. If not, see . + +// use crate::{self as order_pallet, OrderGasCost}; +// use codec::Encode; +// pub use frame_support::{ +// construct_runtime, derive_impl, parameter_types, +// traits::{Everything, Hooks}, +// }; +// use frame_system as system; +// use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; +// pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; +// use sp_core::{crypto::AccountId32, H256}; +// use sp_runtime::{ +// traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, +// BuildStorage, MultiSignature, +// }; + +// type Block = frame_system::mocking::MockBlock; +// type Signature = MultiSignature; +// type AccountId = <::Signer as IdentifyAccount>::AccountId; +// type Balance = u128; +// // Configure a mock runtime to test the pallet. +// construct_runtime!( +// pub enum Test +// { +// System: frame_system::{Pallet, Call, Config, Storage, Event}, +// Balances: pallet_balances::{Pallet, Call, Event}, +// OrderPallet: order_pallet::{Pallet, Call, Storage, Event}, +// MockPallet: mock_pallet, +// } +// ); + +// parameter_types! { +// pub const BlockHashCount: u64 = 250; +// pub const SS58Prefix: u8 = 42; +// } + +// #[derive_impl(frame_system::config_preludes::ParaChainDefaultConfig as frame_system::DefaultConfig)] +// impl system::Config for Test { +// type BaseCallFilter = Everything; +// type BlockWeights = (); +// type BlockLength = (); +// type DbWeight = (); +// type RuntimeOrigin = RuntimeOrigin; +// type RuntimeCall = RuntimeCall; +// type Nonce = u64; +// type Hash = H256; +// type Hashing = BlakeTwo256; +// type AccountId = AccountId32; +// type Lookup = IdentityLookup; +// type Block = Block; +// type RuntimeEvent = RuntimeEvent; +// type BlockHashCount = BlockHashCount; +// type Version = (); +// type PalletInfo = PalletInfo; +// type AccountData = pallet_balances::AccountData; +// type OnNewAccount = (); +// type OnKilledAccount = (); +// type SystemWeightInfo = (); +// type SS58Prefix = SS58Prefix; +// type OnSetCode = (); +// type MaxConsumers = frame_support::traits::ConstU32<16>; +// } +// parameter_types! { +// pub const ExistentialDeposit: u64 = 5; +// } +// impl pallet_balances::Config for Test { +// type MaxLocks = (); +// type MaxReserves = (); +// type ReserveIdentifier = [u8; 8]; +// type Balance = u128; +// type RuntimeEvent = RuntimeEvent; +// type DustRemoval = (); +// type ExistentialDeposit = ExistentialDeposit; +// type AccountStore = System; +// type WeightInfo = (); +// type FreezeIdentifier = (); +// type MaxFreezes = (); +// type RuntimeHoldReason = (); +// type RuntimeFreezeReason = (); +// } +// parameter_types! { +// pub const SlotWidth: u32 = 2; +// pub const OrderMaxAmount:Balance = 200000000; +// pub const TxPoolThreshold:Balance = 3000000000; +// } +// impl crate::Config for Test { +// type RuntimeEvent = RuntimeEvent; +// type AuthorityId = AuraId; +// type UpdateOrigin = EnsureRoot; +// type Currency = Balances; +// type OrderMaxAmount = OrderMaxAmount; +// type SlotWidth = SlotWidth; +// type TxPoolThreshold = TxPoolThreshold; +// type WeightInfo = (); +// } +// pub struct OrderGasCostHandler(); + +// impl OrderGasCost for OrderGasCostHandler +// where +// T: crate::Config, +// T::AccountId: From<[u8; 32]>, +// { +// fn gas_cost( +// block_number: BlockNumberFor, +// ) -> Result, sp_runtime::DispatchError> { +// let sequece_number = >::block_2_sequence(block_number); +// if sequece_number.is_none() { +// return Ok(None); +// } +// let order = >::order_map( +// sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, +// ) +// .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; +// let mut r = [0u8; 32]; +// r.copy_from_slice(order.orderer.encode().as_slice()); +// let account = T::AccountId::try_from(r) +// .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; +// Ok(Some((account, order.price))) +// } +// } + +// #[frame_support::pallet] +// pub mod mock_pallet { +// use super::*; +// #[pallet::config] +// pub trait Config: frame_system::Config { +// type OrderGasCost: OrderGasCost; +// } + +// #[pallet::call] +// impl Pallet {} + +// #[pallet::pallet] +// #[pallet::without_storage_info] +// pub struct Pallet(_); + +// impl Pallet { +// pub fn get_gas_cost(block_number: BlockNumberFor) -> Option<(T::AccountId, Balance)> { +// T::OrderGasCost::gas_cost(block_number).unwrap() +// } +// } +// } + +// impl mock_pallet::Config for Test { +// type OrderGasCost = OrderGasCostHandler; +// } +// pub struct ExtBuilder { +// balances: Vec<(AccountId32, u128)>, +// } + +// impl Default for ExtBuilder { +// fn default() -> Self { +// Self { balances: Default::default() } +// } +// } + +// impl ExtBuilder { +// pub fn build(self) -> sp_io::TestExternalities { +// // Build genesis storage according to the mock runtime. +// let mut t = frame_system::GenesisConfig::::default().build_storage().unwrap(); +// pallet_balances::GenesisConfig:: { balances: self.balances } +// .assimilate_storage(&mut t) +// .unwrap(); +// let mut ext = sp_io::TestExternalities::new(t); +// ext.execute_with(|| System::set_block_number(1)); +// ext +// } +// } diff --git a/pallets/on-demand/src/proof_data.rs b/pallets/on-demand/src/proof_data.rs new file mode 100644 index 0000000..5239a0f --- /dev/null +++ b/pallets/on-demand/src/proof_data.rs @@ -0,0 +1,29 @@ +// // Copyright (C) Magnet. +// // This file is part of Magnet. + +// // Magnet is free software: you can redistribute it and/or modify +// // it under the terms of the GNU General Public License as published by +// // the Free Software Foundation, either version 3 of the License, or +// // (at your option) any later version. + +// // Magnet is distributed in the hope that it will be useful, +// // but WITHOUT ANY WARRANTY; without even the implied warranty of +// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// // GNU General Public License for more details. + +// // You should have received a copy of the GNU General Public License +// // along with Magnet. If not, see . + +// #[allow(dead_code)] +// pub const ENCODED_PROOFS: &[(&str, &[&str])] = &[ +// ("6b7db61c1bee66952742baa01b5a16efe3b6dbc015db0bbbc0d50349eb86279e",&[ +// "2000000000000000a2e9b53d55170200000001000000000007c09b001b01390202000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d809698000000000000000000000000000000020000004200e8030000809698000000000000000000000000000000020000000407fe65717dad0447d715f660a0a58411de509b42e6efb8375f562f58a554d5860ee96725030000000000000000000000000000020000002100d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000000000000000000000000000000000000200000000001a037449c93a000000", +// "3ed41e5e16056765bc8461851072c9d74259dee8a67b8efa0538928edcd6d3dc677e250771c8f75fa2e6cc8942f06f84", +// "800104801a93e89e41a278828d5caad67eb07073bca1b6cccc49807dbb0476cb27dced8b80c11c1757f8dc26ef0d97db7c703034b9a9001ad382ed9e1ff900f6ac927cea97", +// "80c19c8040ccdfa3ac9b91388fa827571930b3c1e805eb35304412ff42cc6df33ca548ee806bd20dcb3f9e7c87137961ace69ccd74eb92eb3ca730ea10fc736b7f261cbd7380257442a3193ebf64fb8a0019b2d9fc1d97734011eb5a8d2ea414f5ff9a27952b804a061d1ed9340acbb3bfeeb8dd6662b24e093240981c068dafa7044ed379307f80c692d333d8a2af1468e95d1583f2ff2dcde7a5607f9490af0e17dff8a1330cc48005beaee4aeb1f362f62d090d987e09cee98c4bbafd8042732406115019b3b6b2809c048073a3a4c42b9174519d6fdac372683ca85cc3b0cac1a1a9ddaf243b59b1", +// "80ffff805f00b947f4aaec99e6613e9511e9cda57d739ea73a0f2db02c08509a021ac7c180c63e2c041524586654422f91098a9b35e5d0ea88d44c334c4ffa6112e7aa696f80f40031d9a794a6cd84c0d942827d55968e796a5350b0df1d18c410b8903ce59980b8acbbf86a4082fb580470e18b67d0099be087b38e04c862e8d2ad2b4b984f68801c8066816a9737e80e67d14190ebabfe1f77c68975a57867a3e721759387b16f800cb049cc6bc5b79fb79d7da92aadb3c7d5df71e403364142445ab1e212424b7c80c0c6776ecc8630ecc28971e2155751cdeead63676a6d5313771f902a26a528a0805b682132c52908705526057f73ab7fccab4af6d72a9805634dd8d3cc53f130d18012b1a0dc047d3b9d5e8792fb372059a04d44300f0f667a2a14a8777ccfe7fdff80de00eff4d3f779a7434826e0d0f3a1ec71dd4028c42e90718c657e3f1c2ed23680af18bd988a60b703c96993f291b836fe5f6df4ea5a7d36c9d1e65cd44bc1c5a98037af338c5d64d1babf36777405396255681f8bef661a6cd600052dceffba87ab80f4429c1b9ec6915b41ad4f0b3aa4f0fcf7ef80690cab6590739ce7e415f4e966800117ab1066009e6ab3db03ed63038d60ed339fccef41d35668e22d99ba0a7142806bfdbbf0e0bedcb993b65c9cea1e929a56d78a3b7bc53d1b7ca6fc488e2295ee8011cf4cd49d702989ad1e066e4983740ef04216f8945156021e524d97b57e240a", +// "9eaa394eea5630e07c48ae0c9558cef7398f80a506ec64a470c01c9ac42ea190d29a5f5d900256035bd485a0563a428f7d0369809aea767c8a069c1f1759636c9f4672b4483e36cc35d06881c141bd5e4c40d75e505f0e7b9012096b41c4eb3aaf947f6ea4290800004c5f0684a022a34dd8bfa2baaf44f172b71004018004952dfbd3c381037ea2a1ddd3c7252f15de49dd55db9697c7513fd0750e1ca980a22e4b0da2642d6cda7bd1dc00e5fd760e4d6e18684676b9612f3045023088cf80809890dfdabf4da4f92e0ffab00c1cedd68369e0cc3ce4432de6f8abe9220b5380690a57078e6f7e247b25365dad04c1fef7b0d5401cad9087216ca0f33d7788a06c5f09cce9c888469bb1a0dceaa129672ef824599318726f636f636f" +// ]) +// ]; +// #[allow(dead_code)] +// pub const HEAD_DATA:&[&str] = &["00000000000000000000000000000000000000000000000000000000000000000070049f18759406809dc703bba5534cd06df7453974b4599e08d6709db651e0a203170a2e7597b7b7e3d84c05391d139a62b157e78786d8c082f29dcf4c11131400"]; diff --git a/pallets/on-demand/src/tests.rs b/pallets/on-demand/src/tests.rs new file mode 100644 index 0000000..f12f8c5 --- /dev/null +++ b/pallets/on-demand/src/tests.rs @@ -0,0 +1,82 @@ +// // Copyright (C) Magnet. +// // This file is part of Magnet. + +// // Magnet is free software: you can redistribute it and/or modify +// // it under the terms of the GNU General Public License as published by +// // the Free Software Foundation, either version 3 of the License, or +// // (at your option) any later version. + +// // Magnet is distributed in the hope that it will be useful, +// // but WITHOUT ANY WARRANTY; without even the implied warranty of +// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// // GNU General Public License for more details. + +// // You should have received a copy of the GNU General Public License +// // along with Magnet. If not, see . + +// use crate::mock::*; +// use codec::Decode; +// use cumulus_primitives_core::{ParaId, PersistedValidationData}; +// use frame_support::{ +// inherent::{InherentData, ProvideInherent}, +// traits::UnfilteredDispatchable, +// }; +// use frame_system::RawOrigin; +// use parachains_common::AccountId; +// use primitives::HeadData; +// use sp_trie::StorageProof; + +// use crate::proof_data::{ENCODED_PROOFS, HEAD_DATA}; +// #[test] +// fn order_default_value() { +// ExtBuilder::default().build().execute_with(|| { +// assert_eq!(OrderPallet::slot_width(), 2); +// }); +// } + +// #[test] +// fn order_normal_test() { +// ExtBuilder::default().build().execute_with(|| { +// System::set_block_number(1); + +// let encoded = ENCODED_PROOFS[0]; +// let root = hex::decode(encoded.0).unwrap(); +// let relay_chain_state_proof = +// StorageProof::new(encoded.1.iter().map(|s| hex::decode(s).unwrap())); +// let relay_root: cumulus_primitives_core::relay_chain::Hash = +// <[u8; 32]>::try_from(root).unwrap().into(); +// let mut inherent_data = InherentData::default(); +// let head_data = hex::decode(HEAD_DATA[0]).unwrap(); +// let perist_data = PersistedValidationData { +// parent_head: HeadData::decode(&mut head_data.as_slice()).unwrap(), +// relay_parent_number: 29, +// relay_parent_storage_root: relay_root, +// max_pov_size: 5242880 as u32, +// }; +// let order_inherent_data = magnet_primitives_order::OrderInherentData { +// relay_storage_proof: relay_chain_state_proof, +// validation_data: Some(perist_data), +// para_id: ParaId::from(1000), +// sequence_number: 0, +// author_pub: Some(AccountId::from(hex_literal::hex!( +// "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" +// ))), +// }; +// inherent_data +// .put_data(magnet_primitives_order::INHERENT_IDENTIFIER, &order_inherent_data) +// .expect("failed to put VFP inherent"); +// OrderPallet::create_inherent(&inherent_data) +// .expect("got an inherent") +// .dispatch_bypass_filter(RawOrigin::None.into()) +// .expect("dispatch succeeded"); +// OrderPallet::on_finalize(1); +// assert_eq!(OrderPallet::sequence_number(), 1); +// let gas_cost = MockPallet::get_gas_cost(1).unwrap(); +// assert_eq!( +// gas_cost.0, +// AccountId::from(hex_literal::hex!( +// "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" +// )) +// ); +// }); +// } diff --git a/pallets/on-demand/src/weights.rs b/pallets/on-demand/src/weights.rs new file mode 100644 index 0000000..6563e21 --- /dev/null +++ b/pallets/on-demand/src/weights.rs @@ -0,0 +1,70 @@ + +//! Autogenerated weights for `pallet_order` +//! +//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 4.0.0-dev +//! DATE: 2024-01-19, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]` +//! WORST CASE MAP SIZE: `1000000` +//! HOSTNAME: `sulijia-pc`, CPU: `AMD Ryzen 7 5800U with Radeon Graphics` +//! WASM-EXECUTION: `Compiled`, CHAIN: `Some("dev")`, DB CACHE: 1024 + +// Executed Command: +// ./target/release/parachain-magnet-node +// benchmark +// pallet +// --chain +// dev +// --execution=wasm +// --wasm-execution=compiled +// --pallet +// pallet_order +// --extrinsic +// * +// --steps +// 50 +// --repeat +// 20 +// --output +// pallets/order/src/weights.rs + +#![cfg_attr(rustfmt, rustfmt_skip)] +#![allow(unused_parens)] +#![allow(unused_imports)] +#![allow(missing_docs)] + +use frame_support::{traits::Get, weights::Weight}; +use core::marker::PhantomData; +use frame_support::weights::constants::RocksDbWeight; + +pub trait WeightInfo { + fn set_parameter(s: Option, ) -> Weight; +} +/// Weight functions for `pallet_order`. +pub struct SubstrateWeight(PhantomData); +impl WeightInfo for SubstrateWeight { + /// Storage: `OrderPallet::SlotWidth` (r:0 w:1) + /// Proof: `OrderPallet::SlotWidth` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `OrderPallet::TxPoolThreshold` (r:0 w:1) + /// Proof: `OrderPallet::TxPoolThreshold` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) + /// Storage: `OrderPallet::OrderMaxAmount` (r:0 w:1) + /// Proof: `OrderPallet::OrderMaxAmount` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn set_parameter(_s: Option, ) -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 4_649_000 picoseconds. + Weight::from_parts(5_090_860, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(3)) + } +} + +impl WeightInfo for () { + fn set_parameter(_s: Option, ) -> Weight { + Weight::from_parts(5_090_860, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 2_411 + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(RocksDbWeight::get().writes(3)) + } +} \ No newline at end of file diff --git a/primitives/coretime/on-demand/Cargo.toml b/primitives/coretime/on-demand/Cargo.toml new file mode 100644 index 0000000..4f598be --- /dev/null +++ b/primitives/coretime/on-demand/Cargo.toml @@ -0,0 +1,52 @@ +[package] +name = "mp-coretime-on-demand" +authors.workspace = true +description = "primitives related to on demand inherent" +edition.workspace = true +license = "Apache-2.0" +version = "0.1.0" + +[dependencies] +log = { workspace = true, default-features = false } +hex-literal = { workspace = true } +async-trait = { workspace = true, optional = true } +scale-info = { workspace = true, default-features = false } +codec = { package = "parity-scale-codec", workspace = true, default-features = false, features = [ + "derive","full", "bit-vec" +] } +sp-api = { workspace = true, default-features = false} +sp-runtime = { workspace = true, default-features = false } +sp-inherents = { workspace = true, default-features = false } +sp-core = { workspace = true, default-features = false } +sp-trie = { workspace = true, default-features = false } +cumulus-relay-chain-interface = { workspace = true, default-features = false , optional = true } +sp-state-machine = { workspace = true, default-features = false } +cumulus-primitives-core = { workspace = true , default-features = false } +sp-consensus-aura= { workspace = true, default-features = false } +sp-io ={ workspace = true, default-features = false } +sp-std = { workspace = true, default-features = false } +sp-weights = { workspace = true, default-features = false } +sp-session = { workspace = true, default-features = false } +sp-consensus-grandpa = { workspace = true, default-features = false } + +[features] +default = [ "std" ] +std = [ + "async-trait", + "codec/std", + "sp-api/std", + "sp-runtime/std", + "scale-info/std", + "sp-inherents/std", + "sp-core/std", + "sp-trie/std", + "cumulus-relay-chain-interface", + "sp-state-machine/std", + "cumulus-primitives-core/std", + "sp-consensus-aura/std", + "sp-io/std", + "sp-std/std", + "sp-weights/std", + "sp-session/std", + "sp-consensus-grandpa/std", +] \ No newline at end of file diff --git a/primitives/coretime/on-demand/src/inherent_client.rs b/primitives/coretime/on-demand/src/inherent_client.rs new file mode 100644 index 0000000..56eef2d --- /dev/null +++ b/primitives/coretime/on-demand/src/inherent_client.rs @@ -0,0 +1,89 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +use sp_consensus_aura::sr25519::AuthorityId; +use { + crate::OrderInherentData, + cumulus_primitives_core::{ParaId, PersistedValidationData}, + cumulus_relay_chain_interface::{PHash, RelayChainInterface}, +}; + +/// Collect the relevant relay chain state in form of a proof +/// for putting it into the on demand order inherent. +async fn collect_relay_storage_proof( + relay_chain_interface: &impl RelayChainInterface, + relay_parent: PHash, +) -> Option { + let mut relevant_keys = Vec::new(); + //System Events + relevant_keys.push( + hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7"] + .to_vec(), + ); + + let relay_storage_proof = relay_chain_interface.prove_read(relay_parent, &relevant_keys).await; + match relay_storage_proof { + Ok(proof) => Some(proof), + Err(err) => { + log::info!("RelayChainError:{:?}", err); + None + }, + } +} + +impl OrderInherentData { + /// Create the [`OrderInherentData`] at the given `relay_parent`. + /// + /// Returns `None` if the creation failed. + pub async fn create_at( + relay_parent: PHash, + relay_chain_interface: &impl RelayChainInterface, + validation_data: &Option, + para_id: ParaId, + sequence_number: u64, + author_pub: &Option, + ) -> Option> { + let relay_storage_proof = + collect_relay_storage_proof(relay_chain_interface, relay_parent).await?; + + Some(OrderInherentData { + relay_storage_proof: relay_storage_proof.clone(), + validation_data: validation_data.clone(), + para_id, + sequence_number, + author_pub: author_pub.clone(), + }) + } +} + +// Implementation of InherentDataProvider +#[async_trait::async_trait] +impl sp_inherents::InherentDataProvider for OrderInherentData { + async fn provide_inherent_data( + &self, + inherent_data: &mut sp_inherents::InherentData, + ) -> Result<(), sp_inherents::Error> { + inherent_data.put_data(crate::INHERENT_IDENTIFIER, &self) + } + + async fn try_handle_error( + &self, + _: &sp_inherents::InherentIdentifier, + _: &[u8], + ) -> Option> { + None + } +} diff --git a/primitives/coretime/on-demand/src/lib.rs b/primitives/coretime/on-demand/src/lib.rs new file mode 100644 index 0000000..c8d6dfe --- /dev/null +++ b/primitives/coretime/on-demand/src/lib.rs @@ -0,0 +1,111 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! # On demand Order Inherent Primitives +//! +//! This crate defines those primitives that should be taken into account when building +//! the on demand order pallet inherent +//! +#![cfg_attr(not(feature = "std"), no_std)] +use cumulus_primitives_core::{ + relay_chain::BlockNumber as RelayBlockNumber, relay_chain::Hash as PHash, ParaId, + PersistedValidationData, +}; +use sp_core::H256; +use sp_runtime::sp_std::vec::Vec; +use sp_runtime::traits::MaybeDisplay; +#[cfg(feature = "std")] +pub mod inherent_client; +pub mod metadata; +pub mod well_known_keys; +use codec::{Codec, Decode, Encode}; +use {scale_info::TypeInfo, sp_inherents::InherentIdentifier}; + +#[derive(Encode, Decode, sp_core::RuntimeDebug, Clone, PartialEq, TypeInfo)] +pub struct OrderInherentData { + /// Proof of relaychain storage. + pub relay_storage_proof: sp_trie::StorageProof, + /// Validation data. + pub validation_data: Option, + /// Parachain ID. + pub para_id: ParaId, + /// Sequence number of order. + pub sequence_number: u64, + /// Author of order. + pub author_pub: Option, +} + +// Identifier of the order inherent +pub const INHERENT_IDENTIFIER: InherentIdentifier = *b"orderiht"; + +#[derive(Clone, PartialEq)] +pub enum OrderStatus { + Init, + Order, + Execute, + Complete, +} + +#[derive(Clone)] +pub struct OrderRecord { + /// Hash of relaychain block. + pub relay_parent: Option, + /// Relaychain block height. + pub relay_height: RelayBlockNumber, + /// Hash of relaychain block,block number is special. + pub relay_base: PHash, + /// Relaychain block height,block number is special. + pub relay_base_height: RelayBlockNumber, + /// Order status + pub order_status: OrderStatus, + /// Validation data. + pub validation_data: Option, + /// Parachain ID. + pub para_id: ParaId, + /// Sequence number of order. + pub sequence_number: u64, + /// Author of order. + pub author_pub: Option, + /// Backup transactions hash. + pub txs: Vec, +} + +sp_api::decl_runtime_apis! { + #[api_version(2)] + pub trait OrderRuntimeApi where + Balance: Codec + MaybeDisplay, + AuthorityId:Codec + { + + fn slot_width()-> u32; + + fn sequence_number()-> u64; + + fn current_relay_height()->u32; + + fn order_max_amount() -> Balance; + + fn order_placed( + relay_storage_proof: sp_trie::StorageProof, + validation_data: PersistedValidationData, + para_id:ParaId, + )-> Option; + + fn reach_txpool_threshold(gas_balance:Balance) -> bool; + + fn order_executed(sequence_number:u64) -> bool ; + } +} diff --git a/primitives/coretime/on-demand/src/metadata.rs b/primitives/coretime/on-demand/src/metadata.rs new file mode 100644 index 0000000..cfbd9bc --- /dev/null +++ b/primitives/coretime/on-demand/src/metadata.rs @@ -0,0 +1,5350 @@ +#[allow(dead_code, unused_imports, non_camel_case_types)] +#[allow(clippy::all)] +#[allow(rustdoc::broken_intra_doc_links)] +pub mod api { + #[allow(unused_imports)] + mod root_mod { + pub use super::*; + } + pub mod runtime_types { + use super::runtime_types; + pub mod rococo_runtime { + use super::runtime_types; + pub mod validator_manager { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + ValidatorsRegistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), + #[codec(index = 1)] + ValidatorsDeregistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), + } + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum ProxyType { + #[codec(index = 0)] + Any, + #[codec(index = 1)] + NonTransfer, + #[codec(index = 2)] + Governance, + #[codec(index = 3)] + IdentityJudgement, + #[codec(index = 4)] + CancelProxy, + #[codec(index = 5)] + Auction, + #[codec(index = 6)] + Society, + #[codec(index = 7)] + OnDemandOrdering, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum RuntimeEvent { + #[codec(index = 0)] + System(runtime_types::frame_system::pallet::Event), + #[codec(index = 3)] + Indices(runtime_types::pallet_indices::pallet::Event), + #[codec(index = 4)] + Balances(runtime_types::pallet_balances::pallet::Event), + #[codec(index = 33)] + TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), + #[codec(index = 7)] + Offences(runtime_types::pallet_offences::pallet::Event), + #[codec(index = 8)] + Session(runtime_types::pallet_session::pallet::Event), + #[codec(index = 10)] + Grandpa(runtime_types::pallet_grandpa::pallet::Event), + #[codec(index = 11)] + ImOnline(runtime_types::pallet_im_online::pallet::Event), + #[codec(index = 13)] + Democracy(runtime_types::pallet_democracy::pallet::Event), + #[codec(index = 14)] + Council(runtime_types::pallet_collective::pallet::Event), + #[codec(index = 15)] + TechnicalCommittee(runtime_types::pallet_collective::pallet::Event2), + #[codec(index = 16)] + PhragmenElection(runtime_types::pallet_elections_phragmen::pallet::Event), + #[codec(index = 17)] + TechnicalMembership(runtime_types::pallet_membership::pallet::Event), + #[codec(index = 18)] + Treasury(runtime_types::pallet_treasury::pallet::Event), + #[codec(index = 19)] + Claims(runtime_types::polkadot_runtime_common::claims::pallet::Event), + #[codec(index = 24)] + Utility(runtime_types::pallet_utility::pallet::Event), + #[codec(index = 25)] + Identity(runtime_types::pallet_identity::pallet::Event), + #[codec(index = 26)] + Society(runtime_types::pallet_society::pallet::Event), + #[codec(index = 27)] + Recovery(runtime_types::pallet_recovery::pallet::Event), + #[codec(index = 28)] + Vesting(runtime_types::pallet_vesting::pallet::Event), + #[codec(index = 29)] + Scheduler(runtime_types::pallet_scheduler::pallet::Event), + #[codec(index = 30)] + Proxy(runtime_types::pallet_proxy::pallet::Event), + #[codec(index = 31)] + Multisig(runtime_types::pallet_multisig::pallet::Event), + #[codec(index = 32)] + Preimage(runtime_types::pallet_preimage::pallet::Event), + #[codec(index = 35)] + Bounties(runtime_types::pallet_bounties::pallet::Event), + #[codec(index = 40)] + ChildBounties(runtime_types::pallet_child_bounties::pallet::Event), + #[codec(index = 36)] + Tips(runtime_types::pallet_tips::pallet::Event), + #[codec(index = 38)] + Nis(runtime_types::pallet_nis::pallet::Event), + #[codec(index = 45)] + NisCounterpartBalances(runtime_types::pallet_balances::pallet::Event2), + #[codec(index = 53)] + ParaInclusion(runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event), + #[codec(index = 56)] + Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Event), + #[codec(index = 60)] + Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event), + #[codec(index = 62)] + ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Event), + #[codec(index = 64)] + MessageQueue(runtime_types::pallet_message_queue::pallet::Event), + #[codec(index = 66)] + OnDemandAssignmentProvider( + runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event, + ), + #[codec(index = 70)] + Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event), + #[codec(index = 71)] + Slots(runtime_types::polkadot_runtime_common::slots::pallet::Event), + #[codec(index = 72)] + Auctions(runtime_types::polkadot_runtime_common::auctions::pallet::Event), + #[codec(index = 73)] + Crowdloan(runtime_types::polkadot_runtime_common::crowdloan::pallet::Event), + #[codec(index = 99)] + XcmPallet(runtime_types::pallet_xcm::pallet::Event), + #[codec(index = 251)] + AssignedSlots( + runtime_types::polkadot_runtime_common::assigned_slots::pallet::Event, + ), + #[codec(index = 252)] + ValidatorManager(runtime_types::rococo_runtime::validator_manager::pallet::Event), + #[codec(index = 254)] + StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::Event), + #[codec(index = 255)] + Sudo(runtime_types::pallet_sudo::pallet::Event), + } + } + pub mod pallet_indices { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + IndexAssigned { + who: ::sp_core::crypto::AccountId32, + index: ::core::primitive::u32, + }, + #[codec(index = 1)] + IndexFreed { index: ::core::primitive::u32 }, + #[codec(index = 2)] + IndexFrozen { + index: ::core::primitive::u32, + who: ::sp_core::crypto::AccountId32, + }, + } + } + } + pub mod pallet_transaction_payment { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + TransactionFeePaid { + who: ::sp_core::crypto::AccountId32, + actual_fee: ::core::primitive::u128, + tip: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_offences { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Offence { + kind: [::core::primitive::u8; 16usize], + timeslot: ::sp_std::vec::Vec<::core::primitive::u8>, + }, + } + } + } + pub mod pallet_session { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewSession { session_index: ::core::primitive::u32 }, + } + } + } + pub mod sp_consensus_grandpa { + use super::runtime_types; + pub mod app { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub runtime_types::sp_core::ed25519::Public); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); + } + } + pub mod pallet_grandpa { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewAuthorities { + authority_set: ::sp_std::vec::Vec<( + runtime_types::sp_consensus_grandpa::app::Public, + ::core::primitive::u64, + )>, + }, + #[codec(index = 1)] + Paused, + #[codec(index = 2)] + Resumed, + } + } + } + pub mod pallet_im_online { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + HeartbeatReceived { + authority_id: runtime_types::pallet_im_online::sr25519::app_sr25519::Public, + }, + #[codec(index = 1)] + AllGood, + #[codec(index = 2)] + SomeOffline { + offline: ::sp_std::vec::Vec<(::sp_core::crypto::AccountId32, ())>, + }, + } + } + pub mod sr25519 { + use super::runtime_types; + pub mod app_sr25519 { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub runtime_types::sp_core::sr25519::Public); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); + } + } + } + pub mod pallet_democracy { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Proposed { + proposal_index: ::core::primitive::u32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 1)] + Tabled { + proposal_index: ::core::primitive::u32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 2)] + ExternalTabled, + #[codec(index = 3)] + Started { + ref_index: ::core::primitive::u32, + threshold: runtime_types::pallet_democracy::vote_threshold::VoteThreshold, + }, + #[codec(index = 4)] + Passed { ref_index: ::core::primitive::u32 }, + #[codec(index = 5)] + NotPassed { ref_index: ::core::primitive::u32 }, + #[codec(index = 6)] + Cancelled { ref_index: ::core::primitive::u32 }, + #[codec(index = 7)] + Delegated { + who: ::sp_core::crypto::AccountId32, + target: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 8)] + Undelegated { account: ::sp_core::crypto::AccountId32 }, + #[codec(index = 9)] + Vetoed { + who: ::sp_core::crypto::AccountId32, + proposal_hash: runtime_types::primitive_types::H256, + until: ::core::primitive::u32, + }, + #[codec(index = 10)] + Blacklisted { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 11)] + Voted { + voter: ::sp_core::crypto::AccountId32, + ref_index: ::core::primitive::u32, + vote: runtime_types::pallet_democracy::vote::AccountVote< + ::core::primitive::u128, + >, + }, + #[codec(index = 12)] + Seconded { + seconder: ::sp_core::crypto::AccountId32, + prop_index: ::core::primitive::u32, + }, + #[codec(index = 13)] + ProposalCanceled { prop_index: ::core::primitive::u32 }, + #[codec(index = 14)] + MetadataSet { + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: runtime_types::primitive_types::H256, + }, + #[codec(index = 15)] + MetadataCleared { + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: runtime_types::primitive_types::H256, + }, + #[codec(index = 16)] + MetadataTransferred { + prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: runtime_types::primitive_types::H256, + }, + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MetadataOwner { + #[codec(index = 0)] + External, + #[codec(index = 1)] + Proposal(::core::primitive::u32), + #[codec(index = 2)] + Referendum(::core::primitive::u32), + } + } + pub mod vote { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AccountVote<_0> { + #[codec(index = 0)] + Standard { vote: runtime_types::pallet_democracy::vote::Vote, balance: _0 }, + #[codec(index = 1)] + Split { aye: _0, nay: _0 }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Vote(pub ::core::primitive::u8); + } + pub mod vote_threshold { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum VoteThreshold { + #[codec(index = 0)] + SuperMajorityApprove, + #[codec(index = 1)] + SuperMajorityAgainst, + #[codec(index = 2)] + SimpleMajority, + } + } + } + pub mod pallet_collective { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Proposed { + account: ::sp_core::crypto::AccountId32, + proposal_index: ::core::primitive::u32, + proposal_hash: runtime_types::primitive_types::H256, + threshold: ::core::primitive::u32, + }, + #[codec(index = 1)] + Voted { + account: ::sp_core::crypto::AccountId32, + proposal_hash: runtime_types::primitive_types::H256, + voted: ::core::primitive::bool, + yes: ::core::primitive::u32, + no: ::core::primitive::u32, + }, + #[codec(index = 2)] + Approved { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 3)] + Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 4)] + Executed { + proposal_hash: runtime_types::primitive_types::H256, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 5)] + MemberExecuted { + proposal_hash: runtime_types::primitive_types::H256, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 6)] + Closed { + proposal_hash: runtime_types::primitive_types::H256, + yes: ::core::primitive::u32, + no: ::core::primitive::u32, + }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event2 { + #[codec(index = 0)] + Proposed { + account: ::sp_core::crypto::AccountId32, + proposal_index: ::core::primitive::u32, + proposal_hash: runtime_types::primitive_types::H256, + threshold: ::core::primitive::u32, + }, + #[codec(index = 1)] + Voted { + account: ::sp_core::crypto::AccountId32, + proposal_hash: runtime_types::primitive_types::H256, + voted: ::core::primitive::bool, + yes: ::core::primitive::u32, + no: ::core::primitive::u32, + }, + #[codec(index = 2)] + Approved { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 3)] + Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 4)] + Executed { + proposal_hash: runtime_types::primitive_types::H256, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 5)] + MemberExecuted { + proposal_hash: runtime_types::primitive_types::H256, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 6)] + Closed { + proposal_hash: runtime_types::primitive_types::H256, + yes: ::core::primitive::u32, + no: ::core::primitive::u32, + }, + } + } + } + pub mod pallet_elections_phragmen { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewTerm { + new_members: ::sp_std::vec::Vec<( + ::sp_core::crypto::AccountId32, + ::core::primitive::u128, + )>, + }, + #[codec(index = 1)] + EmptyTerm, + #[codec(index = 2)] + ElectionError, + #[codec(index = 3)] + MemberKicked { member: ::sp_core::crypto::AccountId32 }, + #[codec(index = 4)] + Renounced { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 5)] + CandidateSlashed { + candidate: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + SeatHolderSlashed { + seat_holder: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_membership { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + MemberAdded, + #[codec(index = 1)] + MemberRemoved, + #[codec(index = 2)] + MembersSwapped, + #[codec(index = 3)] + MembersReset, + #[codec(index = 4)] + KeyChanged, + #[codec(index = 5)] + Dummy, + } + } + } + pub mod pallet_treasury { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Proposed { proposal_index: ::core::primitive::u32 }, + #[codec(index = 1)] + Spending { budget_remaining: ::core::primitive::u128 }, + #[codec(index = 2)] + Awarded { + proposal_index: ::core::primitive::u32, + award: ::core::primitive::u128, + account: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + Rejected { + proposal_index: ::core::primitive::u32, + slashed: ::core::primitive::u128, + }, + #[codec(index = 4)] + Burnt { burnt_funds: ::core::primitive::u128 }, + #[codec(index = 5)] + Rollover { rollover_balance: ::core::primitive::u128 }, + #[codec(index = 6)] + Deposit { value: ::core::primitive::u128 }, + #[codec(index = 7)] + SpendApproved { + proposal_index: ::core::primitive::u32, + amount: ::core::primitive::u128, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 8)] + UpdatedInactive { + reactivated: ::core::primitive::u128, + deactivated: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_identity { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + IdentitySet { who: ::sp_core::crypto::AccountId32 }, + #[codec(index = 1)] + IdentityCleared { + who: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 2)] + IdentityKilled { + who: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 3)] + JudgementRequested { + who: ::sp_core::crypto::AccountId32, + registrar_index: ::core::primitive::u32, + }, + #[codec(index = 4)] + JudgementUnrequested { + who: ::sp_core::crypto::AccountId32, + registrar_index: ::core::primitive::u32, + }, + #[codec(index = 5)] + JudgementGiven { + target: ::sp_core::crypto::AccountId32, + registrar_index: ::core::primitive::u32, + }, + #[codec(index = 6)] + RegistrarAdded { registrar_index: ::core::primitive::u32 }, + #[codec(index = 7)] + SubIdentityAdded { + sub: ::sp_core::crypto::AccountId32, + main: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 8)] + SubIdentityRemoved { + sub: ::sp_core::crypto::AccountId32, + main: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 9)] + SubIdentityRevoked { + sub: ::sp_core::crypto::AccountId32, + main: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_society { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Founded { founder: ::sp_core::crypto::AccountId32 }, + #[codec(index = 1)] + Bid { + candidate_id: ::sp_core::crypto::AccountId32, + offer: ::core::primitive::u128, + }, + #[codec(index = 2)] + Vouch { + candidate_id: ::sp_core::crypto::AccountId32, + offer: ::core::primitive::u128, + vouching: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + AutoUnbid { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 4)] + Unbid { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 5)] + Unvouch { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 6)] + Inducted { + primary: ::sp_core::crypto::AccountId32, + candidates: ::sp_std::vec::Vec<::sp_core::crypto::AccountId32>, + }, + #[codec(index = 7)] + SuspendedMemberJudgement { + who: ::sp_core::crypto::AccountId32, + judged: ::core::primitive::bool, + }, + #[codec(index = 8)] + CandidateSuspended { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 9)] + MemberSuspended { member: ::sp_core::crypto::AccountId32 }, + #[codec(index = 10)] + Challenged { member: ::sp_core::crypto::AccountId32 }, + #[codec(index = 11)] + Vote { + candidate: ::sp_core::crypto::AccountId32, + voter: ::sp_core::crypto::AccountId32, + vote: ::core::primitive::bool, + }, + #[codec(index = 12)] + DefenderVote { + voter: ::sp_core::crypto::AccountId32, + vote: ::core::primitive::bool, + }, + #[codec(index = 13)] + NewParams { + params: runtime_types::pallet_society::GroupParams<::core::primitive::u128>, + }, + #[codec(index = 14)] + Unfounded { founder: ::sp_core::crypto::AccountId32 }, + #[codec(index = 15)] + Deposit { value: ::core::primitive::u128 }, + #[codec(index = 16)] + Elevated { + member: ::sp_core::crypto::AccountId32, + rank: ::core::primitive::u32, + }, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct GroupParams<_0> { + pub max_members: ::core::primitive::u32, + pub max_intake: ::core::primitive::u32, + pub max_strikes: ::core::primitive::u32, + pub candidate_deposit: _0, + } + } + pub mod pallet_recovery { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + RecoveryCreated { account: ::sp_core::crypto::AccountId32 }, + #[codec(index = 1)] + RecoveryInitiated { + lost_account: ::sp_core::crypto::AccountId32, + rescuer_account: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 2)] + RecoveryVouched { + lost_account: ::sp_core::crypto::AccountId32, + rescuer_account: ::sp_core::crypto::AccountId32, + sender: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + RecoveryClosed { + lost_account: ::sp_core::crypto::AccountId32, + rescuer_account: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 4)] + AccountRecovered { + lost_account: ::sp_core::crypto::AccountId32, + rescuer_account: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 5)] + RecoveryRemoved { lost_account: ::sp_core::crypto::AccountId32 }, + } + } + } + pub mod pallet_utility { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + BatchInterrupted { + index: ::core::primitive::u32, + error: runtime_types::sp_runtime::DispatchError, + }, + #[codec(index = 1)] + BatchCompleted, + #[codec(index = 2)] + BatchCompletedWithErrors, + #[codec(index = 3)] + ItemCompleted, + #[codec(index = 4)] + ItemFailed { error: runtime_types::sp_runtime::DispatchError }, + #[codec(index = 5)] + DispatchedAs { + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + } + } + } + pub mod pallet_vesting { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + VestingUpdated { + account: ::sp_core::crypto::AccountId32, + unvested: ::core::primitive::u128, + }, + #[codec(index = 1)] + VestingCompleted { account: ::sp_core::crypto::AccountId32 }, + } + } + } + pub mod pallet_scheduler { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Scheduled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, + #[codec(index = 1)] + Canceled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, + #[codec(index = 2)] + Dispatched { + task: (::core::primitive::u32, ::core::primitive::u32), + id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 3)] + CallUnavailable { + task: (::core::primitive::u32, ::core::primitive::u32), + id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + }, + #[codec(index = 4)] + PeriodicFailed { + task: (::core::primitive::u32, ::core::primitive::u32), + id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + }, + #[codec(index = 5)] + PermanentlyOverweight { + task: (::core::primitive::u32, ::core::primitive::u32), + id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + }, + } + } + } + pub mod pallet_proxy { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + ProxyExecuted { + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 1)] + PureCreated { + pure: ::sp_core::crypto::AccountId32, + who: ::sp_core::crypto::AccountId32, + proxy_type: runtime_types::rococo_runtime::ProxyType, + disambiguation_index: ::core::primitive::u16, + }, + #[codec(index = 2)] + Announced { + real: ::sp_core::crypto::AccountId32, + proxy: ::sp_core::crypto::AccountId32, + call_hash: runtime_types::primitive_types::H256, + }, + #[codec(index = 3)] + ProxyAdded { + delegator: ::sp_core::crypto::AccountId32, + delegatee: ::sp_core::crypto::AccountId32, + proxy_type: runtime_types::rococo_runtime::ProxyType, + delay: ::core::primitive::u32, + }, + #[codec(index = 4)] + ProxyRemoved { + delegator: ::sp_core::crypto::AccountId32, + delegatee: ::sp_core::crypto::AccountId32, + proxy_type: runtime_types::rococo_runtime::ProxyType, + delay: ::core::primitive::u32, + }, + } + } + } + pub mod pallet_multisig { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewMultisig { + approving: ::sp_core::crypto::AccountId32, + multisig: ::sp_core::crypto::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 1)] + MultisigApproval { + approving: ::sp_core::crypto::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::sp_core::crypto::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + MultisigExecuted { + approving: ::sp_core::crypto::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::sp_core::crypto::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 3)] + MultisigCancelled { + cancelling: ::sp_core::crypto::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::sp_core::crypto::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Timepoint<_0> { + pub height: _0, + pub index: ::core::primitive::u32, + } + } + pub mod pallet_preimage { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Noted { hash: runtime_types::primitive_types::H256 }, + #[codec(index = 1)] + Requested { hash: runtime_types::primitive_types::H256 }, + #[codec(index = 2)] + Cleared { hash: runtime_types::primitive_types::H256 }, + } + } + } + pub mod pallet_bounties { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + BountyProposed { index: ::core::primitive::u32 }, + #[codec(index = 1)] + BountyRejected { index: ::core::primitive::u32, bond: ::core::primitive::u128 }, + #[codec(index = 2)] + BountyBecameActive { index: ::core::primitive::u32 }, + #[codec(index = 3)] + BountyAwarded { + index: ::core::primitive::u32, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 4)] + BountyClaimed { + index: ::core::primitive::u32, + payout: ::core::primitive::u128, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 5)] + BountyCanceled { index: ::core::primitive::u32 }, + #[codec(index = 6)] + BountyExtended { index: ::core::primitive::u32 }, + } + } + } + pub mod pallet_child_bounties { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Added { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, + #[codec(index = 1)] + Awarded { + index: ::core::primitive::u32, + child_index: ::core::primitive::u32, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 2)] + Claimed { + index: ::core::primitive::u32, + child_index: ::core::primitive::u32, + payout: ::core::primitive::u128, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + Canceled { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, + } + } + } + pub mod pallet_tips { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewTip { tip_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 1)] + TipClosing { tip_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 2)] + TipClosed { + tip_hash: runtime_types::primitive_types::H256, + who: ::sp_core::crypto::AccountId32, + payout: ::core::primitive::u128, + }, + #[codec(index = 3)] + TipRetracted { tip_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 4)] + TipSlashed { + tip_hash: runtime_types::primitive_types::H256, + finder: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_nis { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + BidPlaced { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + duration: ::core::primitive::u32, + }, + #[codec(index = 1)] + BidRetracted { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + duration: ::core::primitive::u32, + }, + #[codec(index = 2)] + BidDropped { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + duration: ::core::primitive::u32, + }, + #[codec(index = 3)] + Issued { + index: ::core::primitive::u32, + expiry: ::core::primitive::u32, + who: ::sp_core::crypto::AccountId32, + proportion: runtime_types::sp_arithmetic::per_things::Perquintill, + amount: ::core::primitive::u128, + }, + #[codec(index = 4)] + Thawed { + index: ::core::primitive::u32, + who: ::sp_core::crypto::AccountId32, + proportion: runtime_types::sp_arithmetic::per_things::Perquintill, + amount: ::core::primitive::u128, + dropped: ::core::primitive::bool, + }, + #[codec(index = 5)] + Funded { deficit: ::core::primitive::u128 }, + #[codec(index = 6)] + Transferred { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + index: ::core::primitive::u32, + }, + } + } + } + pub mod polkadot_core_primitives { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct CandidateHash(pub runtime_types::primitive_types::H256); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct InboundDownwardMessage<_0> { + pub sent_at: _0, + pub msg: ::sp_std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct InboundHrmpMessage<_0> { + pub sent_at: _0, + pub data: ::sp_std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct OutboundHrmpMessage<_0> { + pub recipient: _0, + pub data: ::sp_std::vec::Vec<::core::primitive::u8>, + } + } + pub mod polkadot_primitives { + use super::runtime_types; + pub mod v5 { + use super::runtime_types; + // pub mod assignment_app { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Public(pub runtime_types::sp_core::sr25519::Public); + // } + pub mod collator_app { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub runtime_types::sp_core::sr25519::Public); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); + } + // pub mod executor_params { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum ExecutorParam { + // #[codec(index = 1)] + // MaxMemoryPages(::core::primitive::u32), + // #[codec(index = 2)] + // StackLogicalMax(::core::primitive::u32), + // #[codec(index = 3)] + // StackNativeMax(::core::primitive::u32), + // #[codec(index = 4)] + // PrecheckingMaxMemory(::core::primitive::u64), + // #[codec(index = 5)] + // PvfPrepTimeout( + // runtime_types::polkadot_primitives::v5::PvfPrepTimeoutKind, + // ::core::primitive::u64, + // ), + // #[codec(index = 6)] + // PvfExecTimeout( + // runtime_types::polkadot_primitives::v5::PvfExecTimeoutKind, + // ::core::primitive::u64, + // ), + // #[codec(index = 7)] + // WasmExtBulkMemory, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct ExecutorParams( + // pub ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::executor_params::ExecutorParam, + // >, + // ); + // } + // pub mod signed { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct UncheckedSigned<_0, _1> { + // pub payload: _0, + // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, + // pub signature: + // runtime_types::polkadot_primitives::v5::validator_app::Signature, + // #[codec(skip)] + // pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, + // } + // } + // pub mod slashing { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct DisputeProof { + // pub time_slot: + // runtime_types::polkadot_primitives::v5::slashing::DisputesTimeSlot, + // pub kind: + // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, + // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, + // pub validator_id: + // runtime_types::polkadot_primitives::v5::validator_app::Public, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct DisputesTimeSlot { + // pub session_index: ::core::primitive::u32, + // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct OpaqueKeyOwnershipProof(pub ::sp_std::vec::Vec<::core::primitive::u8>); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct PendingSlashes { + // pub keys: ::subxt::utils::KeyedVec< + // runtime_types::polkadot_primitives::v5::ValidatorIndex, + // runtime_types::polkadot_primitives::v5::validator_app::Public, + // >, + // pub kind: + // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum SlashingOffenceKind { + // #[codec(index = 0)] + // ForInvalid, + // #[codec(index = 1)] + // AgainstValid, + // } + // } + // pub mod validator_app { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Public(pub runtime_types::sp_core::sr25519::Public); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Assignment { + // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct AvailabilityBitfield( + // pub ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // ); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct BackedCandidate<_0> { + // pub candidate: + // runtime_types::polkadot_primitives::v5::CommittedCandidateReceipt<_0>, + // pub validity_votes: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::ValidityAttestation, + // >, + // pub validator_indices: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct CandidateCommitments<_0> { + // pub upward_messages: + // runtime_types::bounded_collections::bounded_vec::BoundedVec< + // ::sp_std::vec::Vec<::core::primitive::u8>, + // >, + // pub horizontal_messages: + // runtime_types::bounded_collections::bounded_vec::BoundedVec< + // runtime_types::polkadot_core_primitives::OutboundHrmpMessage< + // runtime_types::polkadot_parachain_primitives::primitives::Id, + // >, + // >, + // pub new_validation_code: ::core::option::Option< + // runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, + // >, + // pub head_data: + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // pub processed_downward_messages: ::core::primitive::u32, + // pub hrmp_watermark: _0, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct CandidateDescriptor < _0 > { pub para_id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , pub relay_parent : _0 , pub collator : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Public , pub persisted_validation_data_hash : runtime_types::primitive_types::H256 , pub pov_hash : runtime_types::primitive_types::H256 , pub erasure_root : runtime_types::primitive_types::H256 , pub signature : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Signature , pub para_head : runtime_types::primitive_types::H256 , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum CandidateEvent<_0> { + // #[codec(index = 0)] + // CandidateBacked( + // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // runtime_types::polkadot_primitives::v5::CoreIndex, + // runtime_types::polkadot_primitives::v5::GroupIndex, + // ), + // #[codec(index = 1)] + // CandidateIncluded( + // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // runtime_types::polkadot_primitives::v5::CoreIndex, + // runtime_types::polkadot_primitives::v5::GroupIndex, + // ), + // #[codec(index = 2)] + // CandidateTimedOut( + // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // runtime_types::polkadot_primitives::v5::CoreIndex, + // ), + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct CandidateReceipt<_0> { + pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + pub commitments_hash: runtime_types::primitive_types::H256, + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct CommittedCandidateReceipt<_0> { + // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + // pub commitments: runtime_types::polkadot_primitives::v5::CandidateCommitments< + // ::core::primitive::u32, + // >, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct CoreIndex(pub ::core::primitive::u32); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum CoreOccupied<_0> { + // #[codec(index = 0)] + // Free, + // #[codec(index = 1)] + // Paras(runtime_types::polkadot_primitives::v5::ParasEntry<_0>), + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum CoreState<_0, _1> { + // #[codec(index = 0)] + // Occupied(runtime_types::polkadot_primitives::v5::OccupiedCore<_0, _1>), + // #[codec(index = 1)] + // Scheduled(runtime_types::polkadot_primitives::v5::ScheduledCore), + // #[codec(index = 2)] + // Free, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct DisputeState<_0> { + // pub validators_for: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub validators_against: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub start: _0, + // pub concluded_at: ::core::option::Option<_0>, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum DisputeStatement { + // #[codec(index = 0)] + // Valid(runtime_types::polkadot_primitives::v5::ValidDisputeStatementKind), + // #[codec(index = 1)] + // Invalid(runtime_types::polkadot_primitives::v5::InvalidDisputeStatementKind), + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct DisputeStatementSet { + // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + // pub session: ::core::primitive::u32, + // pub statements: ::sp_std::vec::Vec<( + // runtime_types::polkadot_primitives::v5::DisputeStatement, + // runtime_types::polkadot_primitives::v5::ValidatorIndex, + // runtime_types::polkadot_primitives::v5::validator_app::Signature, + // )>, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct GroupIndex(pub ::core::primitive::u32); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct GroupRotationInfo<_0> { + // pub session_start_block: _0, + // pub group_rotation_frequency: _0, + // pub now: _0, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct IndexedVec<_0, _1>( + // pub ::sp_std::vec::Vec<_1>, + // #[codec(skip)] pub ::core::marker::PhantomData<_0>, + // ); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct InherentData<_0> { + // pub bitfields: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::signed::UncheckedSigned< + // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, + // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, + // >, + // >, + // pub backed_candidates: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::BackedCandidate< + // ::subxt::utils::H256, + // >, + // >, + // pub disputes: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::DisputeStatementSet, + // >, + // pub parent_header: _0, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum InvalidDisputeStatementKind { + // #[codec(index = 0)] + // Explicit, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct OccupiedCore<_0, _1> { + // pub next_up_on_available: ::core::option::Option< + // runtime_types::polkadot_primitives::v5::ScheduledCore, + // >, + // pub occupied_since: _1, + // pub time_out_at: _1, + // pub next_up_on_time_out: ::core::option::Option< + // runtime_types::polkadot_primitives::v5::ScheduledCore, + // >, + // pub availability: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub group_responsible: runtime_types::polkadot_primitives::v5::GroupIndex, + // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + // pub candidate_descriptor: + // runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum OccupiedCoreAssumption { + // #[codec(index = 0)] + // Included, + // #[codec(index = 1)] + // TimedOut, + // #[codec(index = 2)] + // Free, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct ParasEntry<_0> { + // pub assignment: runtime_types::polkadot_primitives::v5::Assignment, + // pub availability_timeouts: ::core::primitive::u32, + // pub ttl: _0, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct PersistedValidationData<_0, _1> { + // pub parent_head: + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // pub relay_parent_number: _1, + // pub relay_parent_storage_root: _0, + // pub max_pov_size: ::core::primitive::u32, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct PvfCheckStatement { pub accept : :: core :: primitive :: bool , pub subject : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub session_index : :: core :: primitive :: u32 , pub validator_index : runtime_types :: polkadot_primitives :: v5 :: ValidatorIndex , } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum PvfExecTimeoutKind { + // #[codec(index = 0)] + // Backing, + // #[codec(index = 1)] + // Approval, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum PvfPrepTimeoutKind { + // #[codec(index = 0)] + // Precheck, + // #[codec(index = 1)] + // Lenient, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct ScheduledCore { + // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + // pub collator: ::core::option::Option< + // runtime_types::polkadot_primitives::v5::collator_app::Public, + // >, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct ScrapedOnChainVotes<_0> { + // pub session: ::core::primitive::u32, + // pub backing_validators_per_candidate: ::sp_std::vec::Vec<( + // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, + // ::sp_std::vec::Vec<( + // runtime_types::polkadot_primitives::v5::ValidatorIndex, + // runtime_types::polkadot_primitives::v5::ValidityAttestation, + // )>, + // )>, + // pub disputes: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::DisputeStatementSet, + // >, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct SessionInfo { + // pub active_validator_indices: + // ::sp_std::vec::Vec, + // pub random_seed: [::core::primitive::u8; 32usize], + // pub dispute_period: ::core::primitive::u32, + // pub validators: runtime_types::polkadot_primitives::v5::IndexedVec< + // runtime_types::polkadot_primitives::v5::ValidatorIndex, + // runtime_types::polkadot_primitives::v5::validator_app::Public, + // >, + // pub discovery_keys: + // ::sp_std::vec::Vec, + // pub assignment_keys: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::assignment_app::Public, + // >, + // pub validator_groups: runtime_types::polkadot_primitives::v5::IndexedVec< + // runtime_types::polkadot_primitives::v5::GroupIndex, + // ::sp_std::vec::Vec, + // >, + // pub n_cores: ::core::primitive::u32, + // pub zeroth_delay_tranche_width: ::core::primitive::u32, + // pub relay_vrf_modulo_samples: ::core::primitive::u32, + // pub n_delay_tranches: ::core::primitive::u32, + // pub no_show_slots: ::core::primitive::u32, + // pub needed_approvals: ::core::primitive::u32, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum UpgradeGoAhead { + // #[codec(index = 0)] + // Abort, + // #[codec(index = 1)] + // GoAhead, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum UpgradeRestriction { + // #[codec(index = 0)] + // Present, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum ValidDisputeStatementKind { + // #[codec(index = 0)] + // Explicit, + // #[codec(index = 1)] + // BackingSeconded(::subxt::utils::H256), + // #[codec(index = 2)] + // BackingValid(::subxt::utils::H256), + // #[codec(index = 3)] + // ApprovalChecking, + // } + // #[derive( + // :: codec :: Decode, + // :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + // Clone, + // Debug, + // PartialEq, + // )] + // pub struct ValidatorIndex(pub ::core::primitive::u32); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum ValidityAttestation { + // #[codec(index = 1)] + // Implicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), + // #[codec(index = 2)] + // Explicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), + // } + // } + // pub mod vstaging { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct AsyncBackingParams { + // pub max_candidate_depth: ::core::primitive::u32, + // pub allowed_ancestry_len: ::core::primitive::u32, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct BackingState<_0, _1> { + // pub constraints: runtime_types::polkadot_primitives::vstaging::Constraints<_1>, + // pub pending_availability: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::vstaging::CandidatePendingAvailability< + // _0, + // _1, + // >, + // >, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct CandidatePendingAvailability<_0, _1> { + // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + // pub commitments: + // runtime_types::polkadot_primitives::v5::CandidateCommitments<_1>, + // pub relay_parent_number: _1, + // pub max_pov_size: ::core::primitive::u32, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Constraints < _0 > { pub min_relay_parent_number : _0 , pub max_pov_size : :: core :: primitive :: u32 , pub max_code_size : :: core :: primitive :: u32 , pub ump_remaining : :: core :: primitive :: u32 , pub ump_remaining_bytes : :: core :: primitive :: u32 , pub max_ump_num_per_candidate : :: core :: primitive :: u32 , pub dmp_remaining_messages : :: std :: vec :: Vec < _0 > , pub hrmp_inbound : runtime_types :: polkadot_primitives :: vstaging :: InboundHrmpLimitations < _0 > , pub hrmp_channels_out : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: vstaging :: OutboundHrmpChannelLimitations ,) > , pub max_hrmp_num_per_candidate : :: core :: primitive :: u32 , pub required_parent : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub upgrade_restriction : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v5 :: UpgradeRestriction > , pub future_validation_code : :: core :: option :: Option < (_0 , runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash ,) > , } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct InboundHrmpLimitations<_0> { + // pub valid_watermarks: ::sp_std::vec::Vec<_0>, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct OutboundHrmpChannelLimitations { + // pub bytes_remaining: ::core::primitive::u32, + // pub messages_remaining: ::core::primitive::u32, + // } + } + } + pub mod sp_core { + use super::runtime_types; + pub mod crypto { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); + } + pub mod ecdsa { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub [::core::primitive::u8; 33usize]); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub [::core::primitive::u8; 65usize]); + } + pub mod ed25519 { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub [::core::primitive::u8; 32usize]); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub [::core::primitive::u8; 64usize]); + } + pub mod sr25519 { + use super::runtime_types; + pub mod vrf { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct VrfSignature { + pub output: [::core::primitive::u8; 32usize], + pub proof: [::core::primitive::u8; 64usize], + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub [::core::primitive::u8; 32usize]); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub [::core::primitive::u8; 64usize]); + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct OpaqueMetadata(pub ::sp_std::vec::Vec<::core::primitive::u8>); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Void {} + } + pub mod pallet_message_queue { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + # [codec (index = 0)] ProcessingFailed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , error : runtime_types :: frame_support :: traits :: messages :: ProcessMessageError , } , # [codec (index = 1)] Processed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , weight_used : :: sp_weights :: Weight , success : :: core :: primitive :: bool , } , # [codec (index = 2)] OverweightEnqueued { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , page_index : :: core :: primitive :: u32 , message_index : :: core :: primitive :: u32 , } , # [codec (index = 3)] PageReaped { origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , index : :: core :: primitive :: u32 , } , } + } + } + pub mod pallet_xcm { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Attempted { outcome: runtime_types::staging_xcm::v3::traits::Outcome }, + #[codec(index = 1)] + Sent { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + message: runtime_types::staging_xcm::v3::Xcm, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + UnexpectedResponse { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 3)] + ResponseReady { + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v3::Response, + }, + #[codec(index = 4)] + Notified { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 5)] + NotifyOverweight { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + actual_weight: ::sp_weights::Weight, + max_budgeted_weight: ::sp_weights::Weight, + }, + #[codec(index = 6)] + NotifyDispatchError { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 7)] + NotifyDecodeFailed { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 8)] + InvalidResponder { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + expected_location: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + #[codec(index = 9)] + InvalidResponderVersion { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 10)] + ResponseTaken { query_id: ::core::primitive::u64 }, + #[codec(index = 11)] + AssetsTrapped { + hash: runtime_types::primitive_types::H256, + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + assets: runtime_types::staging_xcm::VersionedMultiAssets, + }, + #[codec(index = 12)] + VersionChangeNotified { + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + result: ::core::primitive::u32, + cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 13)] + SupportedVersionChanged { + location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + version: ::core::primitive::u32, + }, + #[codec(index = 14)] + NotifyTargetSendFail { + location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + error: runtime_types::staging_xcm::v3::traits::Error, + }, + #[codec(index = 15)] + NotifyTargetMigrationFail { + location: runtime_types::staging_xcm::VersionedMultiLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 16)] + InvalidQuerierVersion { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 17)] + InvalidQuerier { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + expected_querier: + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + maybe_actual_querier: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + #[codec(index = 18)] + VersionNotifyStarted { + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 19)] + VersionNotifyRequested { + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 20)] + VersionNotifyUnrequested { + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 21)] + FeesPaid { + paying: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + fees: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + }, + #[codec(index = 22)] + AssetsClaimed { + hash: runtime_types::primitive_types::H256, + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + assets: runtime_types::staging_xcm::VersionedMultiAssets, + }, + } + } + } + pub mod staging_xcm { + use super::runtime_types; + pub mod double_encoded { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct DoubleEncoded { + pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct DoubleEncoded2 { + pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, + } + } + pub mod v2 { + use super::runtime_types; + pub mod junction { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Junction { + #[codec(index = 0)] + Parachain(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 1)] + AccountId32 { + network: runtime_types::staging_xcm::v2::NetworkId, + id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + AccountIndex64 { + network: runtime_types::staging_xcm::v2::NetworkId, + #[codec(compact)] + index: ::core::primitive::u64, + }, + #[codec(index = 3)] + AccountKey20 { + network: runtime_types::staging_xcm::v2::NetworkId, + key: [::core::primitive::u8; 20usize], + }, + #[codec(index = 4)] + PalletInstance(::core::primitive::u8), + #[codec(index = 5)] + GeneralIndex(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 6)] + GeneralKey( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 7)] + OnlyChild, + #[codec(index = 8)] + Plurality { + id: runtime_types::staging_xcm::v2::BodyId, + part: runtime_types::staging_xcm::v2::BodyPart, + }, + } + } + pub mod multiasset { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AssetId { + #[codec(index = 0)] + Concrete(runtime_types::staging_xcm::v2::multilocation::MultiLocation), + #[codec(index = 1)] + Abstract(::sp_std::vec::Vec<::core::primitive::u8>), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AssetInstance { + #[codec(index = 0)] + Undefined, + #[codec(index = 1)] + Index(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 2)] + Array4([::core::primitive::u8; 4usize]), + #[codec(index = 3)] + Array8([::core::primitive::u8; 8usize]), + #[codec(index = 4)] + Array16([::core::primitive::u8; 16usize]), + #[codec(index = 5)] + Array32([::core::primitive::u8; 32usize]), + #[codec(index = 6)] + Blob(::sp_std::vec::Vec<::core::primitive::u8>), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Fungibility { + #[codec(index = 0)] + Fungible(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 1)] + NonFungible(runtime_types::staging_xcm::v2::multiasset::AssetInstance), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiAsset { + pub id: runtime_types::staging_xcm::v2::multiasset::AssetId, + pub fun: runtime_types::staging_xcm::v2::multiasset::Fungibility, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MultiAssetFilter { + #[codec(index = 0)] + Definite(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + Wild(runtime_types::staging_xcm::v2::multiasset::WildMultiAsset), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiAssets( + pub ::sp_std::vec::Vec< + runtime_types::staging_xcm::v2::multiasset::MultiAsset, + >, + ); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WildFungibility { + #[codec(index = 0)] + Fungible, + #[codec(index = 1)] + NonFungible, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WildMultiAsset { + #[codec(index = 0)] + All, + #[codec(index = 1)] + AllOf { + id: runtime_types::staging_xcm::v2::multiasset::AssetId, + fun: runtime_types::staging_xcm::v2::multiasset::WildFungibility, + }, + } + } + pub mod multilocation { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Junctions { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + X1(runtime_types::staging_xcm::v2::junction::Junction), + #[codec(index = 2)] + X2( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 3)] + X3( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 4)] + X4( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 5)] + X5( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 6)] + X6( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 7)] + X7( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 8)] + X8( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiLocation { + pub parents: ::core::primitive::u8, + pub interior: runtime_types::staging_xcm::v2::multilocation::Junctions, + } + } + pub mod traits { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Error { + #[codec(index = 0)] + Overflow, + #[codec(index = 1)] + Unimplemented, + #[codec(index = 2)] + UntrustedReserveLocation, + #[codec(index = 3)] + UntrustedTeleportLocation, + #[codec(index = 4)] + MultiLocationFull, + #[codec(index = 5)] + MultiLocationNotInvertible, + #[codec(index = 6)] + BadOrigin, + #[codec(index = 7)] + InvalidLocation, + #[codec(index = 8)] + AssetNotFound, + #[codec(index = 9)] + FailedToTransactAsset, + #[codec(index = 10)] + NotWithdrawable, + #[codec(index = 11)] + LocationCannotHold, + #[codec(index = 12)] + ExceedsMaxMessageSize, + #[codec(index = 13)] + DestinationUnsupported, + #[codec(index = 14)] + Transport, + #[codec(index = 15)] + Unroutable, + #[codec(index = 16)] + UnknownClaim, + #[codec(index = 17)] + FailedToDecode, + #[codec(index = 18)] + MaxWeightInvalid, + #[codec(index = 19)] + NotHoldingFees, + #[codec(index = 20)] + TooExpensive, + #[codec(index = 21)] + Trap(::core::primitive::u64), + #[codec(index = 22)] + UnhandledXcmVersion, + #[codec(index = 23)] + WeightLimitReached(::core::primitive::u64), + #[codec(index = 24)] + Barrier, + #[codec(index = 25)] + WeightNotComputable, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BodyId { + #[codec(index = 0)] + Unit, + #[codec(index = 1)] + Named( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Index(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + Executive, + #[codec(index = 4)] + Technical, + #[codec(index = 5)] + Legislative, + #[codec(index = 6)] + Judicial, + #[codec(index = 7)] + Defense, + #[codec(index = 8)] + Administration, + #[codec(index = 9)] + Treasury, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BodyPart { + #[codec(index = 0)] + Voice, + #[codec(index = 1)] + Members { + #[codec(compact)] + count: ::core::primitive::u32, + }, + #[codec(index = 2)] + Fraction { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 3)] + AtLeastProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 4)] + MoreThanProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Instruction { + #[codec(index = 0)] + WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v2::Response, + #[codec(compact)] + max_weight: ::core::primitive::u64, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_type: runtime_types::staging_xcm::v2::OriginKind, + #[codec(compact)] + require_weight_at_most: ::core::primitive::u64, + call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), + #[codec(index = 12)] + ReportError { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 18)] + QueryHolding { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, + weight_limit: runtime_types::staging_xcm::v2::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::staging_xcm::v2::Xcm), + #[codec(index = 22)] + SetAppendix(runtime_types::staging_xcm::v2::Xcm), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 27)] + UnsubscribeVersion, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Instruction2 { + #[codec(index = 0)] + WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v2::Response, + #[codec(compact)] + max_weight: ::core::primitive::u64, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_type: runtime_types::staging_xcm::v2::OriginKind, + #[codec(compact)] + require_weight_at_most: ::core::primitive::u64, + call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), + #[codec(index = 12)] + ReportError { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 18)] + QueryHolding { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, + weight_limit: runtime_types::staging_xcm::v2::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::staging_xcm::v2::Xcm2), + #[codec(index = 22)] + SetAppendix(runtime_types::staging_xcm::v2::Xcm2), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 27)] + UnsubscribeVersion, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum NetworkId { + #[codec(index = 0)] + Any, + #[codec(index = 1)] + Named( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Polkadot, + #[codec(index = 3)] + Kusama, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum OriginKind { + #[codec(index = 0)] + Native, + #[codec(index = 1)] + SovereignAccount, + #[codec(index = 2)] + Superuser, + #[codec(index = 3)] + Xcm, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Response { + #[codec(index = 0)] + Null, + #[codec(index = 1)] + Assets(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ExecutionResult( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::staging_xcm::v2::traits::Error, + )>, + ), + #[codec(index = 3)] + Version(::core::primitive::u32), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WeightLimit { + #[codec(index = 0)] + Unlimited, + #[codec(index = 1)] + Limited(#[codec(compact)] ::core::primitive::u64), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Xcm(pub ::sp_std::vec::Vec); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Xcm2( + pub ::sp_std::vec::Vec, + ); + } + pub mod v3 { + use super::runtime_types; + pub mod junction { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BodyId { + #[codec(index = 0)] + Unit, + #[codec(index = 1)] + Moniker([::core::primitive::u8; 4usize]), + #[codec(index = 2)] + Index(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + Executive, + #[codec(index = 4)] + Technical, + #[codec(index = 5)] + Legislative, + #[codec(index = 6)] + Judicial, + #[codec(index = 7)] + Defense, + #[codec(index = 8)] + Administration, + #[codec(index = 9)] + Treasury, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BodyPart { + #[codec(index = 0)] + Voice, + #[codec(index = 1)] + Members { + #[codec(compact)] + count: ::core::primitive::u32, + }, + #[codec(index = 2)] + Fraction { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 3)] + AtLeastProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 4)] + MoreThanProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Junction { + #[codec(index = 0)] + Parachain(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 1)] + AccountId32 { + network: ::core::option::Option< + runtime_types::staging_xcm::v3::junction::NetworkId, + >, + id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + AccountIndex64 { + network: ::core::option::Option< + runtime_types::staging_xcm::v3::junction::NetworkId, + >, + #[codec(compact)] + index: ::core::primitive::u64, + }, + #[codec(index = 3)] + AccountKey20 { + network: ::core::option::Option< + runtime_types::staging_xcm::v3::junction::NetworkId, + >, + key: [::core::primitive::u8; 20usize], + }, + #[codec(index = 4)] + PalletInstance(::core::primitive::u8), + #[codec(index = 5)] + GeneralIndex(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 6)] + GeneralKey { + length: ::core::primitive::u8, + data: [::core::primitive::u8; 32usize], + }, + #[codec(index = 7)] + OnlyChild, + #[codec(index = 8)] + Plurality { + id: runtime_types::staging_xcm::v3::junction::BodyId, + part: runtime_types::staging_xcm::v3::junction::BodyPart, + }, + #[codec(index = 9)] + GlobalConsensus(runtime_types::staging_xcm::v3::junction::NetworkId), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum NetworkId { + #[codec(index = 0)] + ByGenesis([::core::primitive::u8; 32usize]), + #[codec(index = 1)] + ByFork { + block_number: ::core::primitive::u64, + block_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + Polkadot, + #[codec(index = 3)] + Kusama, + #[codec(index = 4)] + Westend, + #[codec(index = 5)] + Rococo, + #[codec(index = 6)] + Wococo, + #[codec(index = 7)] + Ethereum { + #[codec(compact)] + chain_id: ::core::primitive::u64, + }, + #[codec(index = 8)] + BitcoinCore, + #[codec(index = 9)] + BitcoinCash, + } + } + pub mod junctions { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Junctions { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + X1(runtime_types::staging_xcm::v3::junction::Junction), + #[codec(index = 2)] + X2( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 3)] + X3( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 4)] + X4( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 5)] + X5( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 6)] + X6( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 7)] + X7( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 8)] + X8( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + } + } + pub mod multiasset { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AssetId { + #[codec(index = 0)] + Concrete(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + #[codec(index = 1)] + Abstract([::core::primitive::u8; 32usize]), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AssetInstance { + #[codec(index = 0)] + Undefined, + #[codec(index = 1)] + Index(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 2)] + Array4([::core::primitive::u8; 4usize]), + #[codec(index = 3)] + Array8([::core::primitive::u8; 8usize]), + #[codec(index = 4)] + Array16([::core::primitive::u8; 16usize]), + #[codec(index = 5)] + Array32([::core::primitive::u8; 32usize]), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Fungibility { + #[codec(index = 0)] + Fungible(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 1)] + NonFungible(runtime_types::staging_xcm::v3::multiasset::AssetInstance), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiAsset { + pub id: runtime_types::staging_xcm::v3::multiasset::AssetId, + pub fun: runtime_types::staging_xcm::v3::multiasset::Fungibility, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MultiAssetFilter { + #[codec(index = 0)] + Definite(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 1)] + Wild(runtime_types::staging_xcm::v3::multiasset::WildMultiAsset), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiAssets( + pub ::sp_std::vec::Vec< + runtime_types::staging_xcm::v3::multiasset::MultiAsset, + >, + ); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WildFungibility { + #[codec(index = 0)] + Fungible, + #[codec(index = 1)] + NonFungible, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WildMultiAsset { + #[codec(index = 0)] + All, + #[codec(index = 1)] + AllOf { + id: runtime_types::staging_xcm::v3::multiasset::AssetId, + fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, + }, + #[codec(index = 2)] + AllCounted(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + AllOfCounted { + id: runtime_types::staging_xcm::v3::multiasset::AssetId, + fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, + #[codec(compact)] + count: ::core::primitive::u32, + }, + } + } + pub mod multilocation { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiLocation { + pub parents: ::core::primitive::u8, + pub interior: runtime_types::staging_xcm::v3::junctions::Junctions, + } + } + + pub mod traits { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Error { + #[codec(index = 0)] + Overflow, + #[codec(index = 1)] + Unimplemented, + #[codec(index = 2)] + UntrustedReserveLocation, + #[codec(index = 3)] + UntrustedTeleportLocation, + #[codec(index = 4)] + LocationFull, + #[codec(index = 5)] + LocationNotInvertible, + #[codec(index = 6)] + BadOrigin, + #[codec(index = 7)] + InvalidLocation, + #[codec(index = 8)] + AssetNotFound, + #[codec(index = 9)] + FailedToTransactAsset, + #[codec(index = 10)] + NotWithdrawable, + #[codec(index = 11)] + LocationCannotHold, + #[codec(index = 12)] + ExceedsMaxMessageSize, + #[codec(index = 13)] + DestinationUnsupported, + #[codec(index = 14)] + Transport, + #[codec(index = 15)] + Unroutable, + #[codec(index = 16)] + UnknownClaim, + #[codec(index = 17)] + FailedToDecode, + #[codec(index = 18)] + MaxWeightInvalid, + #[codec(index = 19)] + NotHoldingFees, + #[codec(index = 20)] + TooExpensive, + #[codec(index = 21)] + Trap(::core::primitive::u64), + #[codec(index = 22)] + ExpectationFalse, + #[codec(index = 23)] + PalletNotFound, + #[codec(index = 24)] + NameMismatch, + #[codec(index = 25)] + VersionIncompatible, + #[codec(index = 26)] + HoldingWouldOverflow, + #[codec(index = 27)] + ExportError, + #[codec(index = 28)] + ReanchorFailed, + #[codec(index = 29)] + NoDeal, + #[codec(index = 30)] + FeesNotMet, + #[codec(index = 31)] + LockError, + #[codec(index = 32)] + NoPermission, + #[codec(index = 33)] + Unanchored, + #[codec(index = 34)] + NotDepositable, + #[codec(index = 35)] + UnhandledXcmVersion, + #[codec(index = 36)] + WeightLimitReached(::sp_weights::Weight), + #[codec(index = 37)] + Barrier, + #[codec(index = 38)] + WeightNotComputable, + #[codec(index = 39)] + ExceedsStackLimit, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Outcome { + #[codec(index = 0)] + Complete(::sp_weights::Weight), + #[codec(index = 1)] + Incomplete( + ::sp_weights::Weight, + runtime_types::staging_xcm::v3::traits::Error, + ), + #[codec(index = 2)] + Error(runtime_types::staging_xcm::v3::traits::Error), + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Instruction { + #[codec(index = 0)] + WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v3::Response, + max_weight: ::sp_weights::Weight, + querier: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_kind: runtime_types::staging_xcm::v2::OriginKind, + require_weight_at_most: ::sp_weights::Weight, + call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), + #[codec(index = 12)] + ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + maximal: ::core::primitive::bool, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 18)] + ReportHolding { + response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + weight_limit: runtime_types::staging_xcm::v3::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::staging_xcm::v3::Xcm), + #[codec(index = 22)] + SetAppendix(runtime_types::staging_xcm::v3::Xcm), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + max_response_weight: ::sp_weights::Weight, + }, + #[codec(index = 27)] + UnsubscribeVersion, + #[codec(index = 28)] + BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 29)] + ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 30)] + ExpectOrigin( + ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + ), + #[codec(index = 31)] + ExpectError( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::staging_xcm::v3::traits::Error, + )>, + ), + #[codec(index = 32)] + ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), + #[codec(index = 33)] + QueryPallet { + module_name: ::sp_std::vec::Vec<::core::primitive::u8>, + response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, + }, + #[codec(index = 34)] + ExpectPallet { + #[codec(compact)] + index: ::core::primitive::u32, + name: ::sp_std::vec::Vec<::core::primitive::u8>, + module_name: ::sp_std::vec::Vec<::core::primitive::u8>, + #[codec(compact)] + crate_major: ::core::primitive::u32, + #[codec(compact)] + min_crate_minor: ::core::primitive::u32, + }, + #[codec(index = 35)] + ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), + #[codec(index = 36)] + ClearTransactStatus, + #[codec(index = 37)] + UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), + #[codec(index = 38)] + ExportMessage { + network: runtime_types::staging_xcm::v3::junction::NetworkId, + destination: runtime_types::staging_xcm::v3::junctions::Junctions, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 39)] + LockAsset { + asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 40)] + UnlockAsset { + asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 41)] + NoteUnlockable { + asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 42)] + RequestUnlock { + asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 43)] + SetFeesMode { jit_withdraw: ::core::primitive::bool }, + #[codec(index = 44)] + SetTopic([::core::primitive::u8; 32usize]), + #[codec(index = 45)] + ClearTopic, + #[codec(index = 46)] + AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + #[codec(index = 47)] + UnpaidExecution { + weight_limit: runtime_types::staging_xcm::v3::WeightLimit, + check_origin: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum Instruction2 { + // #[codec(index = 0)] + // WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 1)] + // ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 2)] + // ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 3)] + // QueryResponse { + // #[codec(compact)] + // query_id: ::core::primitive::u64, + // response: runtime_types::staging_xcm::v3::Response, + // max_weight: ::sp_weights::Weight, + // querier: ::core::option::Option< + // runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // >, + // }, + // #[codec(index = 4)] + // TransferAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 5)] + // TransferReserveAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 6)] + // Transact { + // origin_kind: runtime_types::staging_xcm::v2::OriginKind, + // require_weight_at_most: ::sp_weights::Weight, + // call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, + // }, + // #[codec(index = 7)] + // HrmpNewChannelOpenRequest { + // #[codec(compact)] + // sender: ::core::primitive::u32, + // #[codec(compact)] + // max_message_size: ::core::primitive::u32, + // #[codec(compact)] + // max_capacity: ::core::primitive::u32, + // }, + // #[codec(index = 8)] + // HrmpChannelAccepted { + // #[codec(compact)] + // recipient: ::core::primitive::u32, + // }, + // #[codec(index = 9)] + // HrmpChannelClosing { + // #[codec(compact)] + // initiator: ::core::primitive::u32, + // #[codec(compact)] + // sender: ::core::primitive::u32, + // #[codec(compact)] + // recipient: ::core::primitive::u32, + // }, + // #[codec(index = 10)] + // ClearOrigin, + // #[codec(index = 11)] + // DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), + // #[codec(index = 12)] + // ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), + // #[codec(index = 13)] + // DepositAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 14)] + // DepositReserveAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 15)] + // ExchangeAsset { + // give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + // maximal: ::core::primitive::bool, + // }, + // #[codec(index = 16)] + // InitiateReserveWithdraw { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 17)] + // InitiateTeleport { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 18)] + // ReportHolding { + // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // }, + // #[codec(index = 19)] + // BuyExecution { + // fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, + // }, + // #[codec(index = 20)] + // RefundSurplus, + // #[codec(index = 21)] + // SetErrorHandler(runtime_types::staging_xcm::v3::Xcm2), + // #[codec(index = 22)] + // SetAppendix(runtime_types::staging_xcm::v3::Xcm2), + // #[codec(index = 23)] + // ClearError, + // #[codec(index = 24)] + // ClaimAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + // ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 25)] + // Trap(#[codec(compact)] ::core::primitive::u64), + // #[codec(index = 26)] + // SubscribeVersion { + // #[codec(compact)] + // query_id: ::core::primitive::u64, + // max_response_weight: ::sp_weights::Weight, + // }, + // #[codec(index = 27)] + // UnsubscribeVersion, + // #[codec(index = 28)] + // BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 29)] + // ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 30)] + // ExpectOrigin( + // ::core::option::Option< + // runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // >, + // ), + // #[codec(index = 31)] + // ExpectError( + // ::core::option::Option<( + // ::core::primitive::u32, + // runtime_types::staging_xcm::v3::traits::Error, + // )>, + // ), + // #[codec(index = 32)] + // ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), + // #[codec(index = 33)] + // QueryPallet { + // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, + // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, + // }, + // #[codec(index = 34)] + // ExpectPallet { + // #[codec(compact)] + // index: ::core::primitive::u32, + // name: ::sp_std::vec::Vec<::core::primitive::u8>, + // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, + // #[codec(compact)] + // crate_major: ::core::primitive::u32, + // #[codec(compact)] + // min_crate_minor: ::core::primitive::u32, + // }, + // #[codec(index = 35)] + // ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), + // #[codec(index = 36)] + // ClearTransactStatus, + // #[codec(index = 37)] + // UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), + // #[codec(index = 38)] + // ExportMessage { + // network: runtime_types::staging_xcm::v3::junction::NetworkId, + // destination: runtime_types::staging_xcm::v3::junctions::Junctions, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 39)] + // LockAsset { + // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 40)] + // UnlockAsset { + // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 41)] + // NoteUnlockable { + // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 42)] + // RequestUnlock { + // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 43)] + // SetFeesMode { jit_withdraw: ::core::primitive::bool }, + // #[codec(index = 44)] + // SetTopic([::core::primitive::u8; 32usize]), + // #[codec(index = 45)] + // ClearTopic, + // #[codec(index = 46)] + // AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + // #[codec(index = 47)] + // UnpaidExecution { + // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, + // check_origin: ::core::option::Option< + // runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // >, + // }, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MaybeErrorCode { + #[codec(index = 0)] + Success, + #[codec(index = 1)] + Error( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + TruncatedError( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct PalletInfo { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + #[codec(compact)] + pub major: ::core::primitive::u32, + #[codec(compact)] + pub minor: ::core::primitive::u32, + #[codec(compact)] + pub patch: ::core::primitive::u32, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct QueryResponseInfo { + pub destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + #[codec(compact)] + pub query_id: ::core::primitive::u64, + pub max_weight: ::sp_weights::Weight, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Response { + #[codec(index = 0)] + Null, + #[codec(index = 1)] + Assets(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 2)] + ExecutionResult( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::staging_xcm::v3::traits::Error, + )>, + ), + #[codec(index = 3)] + Version(::core::primitive::u32), + #[codec(index = 4)] + PalletsInfo( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::staging_xcm::v3::PalletInfo, + >, + ), + #[codec(index = 5)] + DispatchResult(runtime_types::staging_xcm::v3::MaybeErrorCode), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WeightLimit { + #[codec(index = 0)] + Unlimited, + #[codec(index = 1)] + Limited(::sp_weights::Weight), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Xcm(pub ::sp_std::vec::Vec); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Xcm2(pub ::sp_std::vec::Vec); + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum VersionedAssetId { + // #[codec(index = 3)] + // V3(runtime_types::staging_xcm::v3::multiasset::AssetId), + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum VersionedMultiAssets { + #[codec(index = 1)] + V2(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + V3(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum VersionedMultiLocation { + #[codec(index = 1)] + V2(runtime_types::staging_xcm::v2::multilocation::MultiLocation), + #[codec(index = 3)] + V3(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum VersionedResponse { + // #[codec(index = 2)] + // V2(runtime_types::staging_xcm::v2::Response), + // #[codec(index = 3)] + // V3(runtime_types::staging_xcm::v3::Response), + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum VersionedXcm { + // #[codec(index = 2)] + // V2(runtime_types::staging_xcm::v2::Xcm), + // #[codec(index = 3)] + // V3(runtime_types::staging_xcm::v3::Xcm), + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum VersionedXcm2 { + // #[codec(index = 2)] + // V2(runtime_types::staging_xcm::v2::Xcm2), + // #[codec(index = 3)] + // V3(runtime_types::staging_xcm::v3::Xcm2), + // } + } + + pub mod polkadot_runtime_common { + use super::runtime_types; + pub mod assigned_slots { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + PermanentSlotAssigned( + runtime_types::polkadot_parachain_primitives::primitives::Id, + ), + #[codec(index = 1)] + TemporarySlotAssigned( + runtime_types::polkadot_parachain_primitives::primitives::Id, + ), + #[codec(index = 2)] + MaxPermanentSlotsChanged { slots: ::core::primitive::u32 }, + #[codec(index = 3)] + MaxTemporarySlotsChanged { slots: ::core::primitive::u32 }, + } + } + } + pub mod auctions { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + AuctionStarted { + auction_index: ::core::primitive::u32, + lease_period: ::core::primitive::u32, + ending: ::core::primitive::u32, + }, + #[codec(index = 1)] + AuctionClosed { auction_index: ::core::primitive::u32 }, + #[codec(index = 2)] + Reserved { + bidder: ::sp_core::crypto::AccountId32, + extra_reserved: ::core::primitive::u128, + total_amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + Unreserved { + bidder: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 4)] + ReserveConfiscated { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + leaser: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 5)] + BidAccepted { + bidder: ::sp_core::crypto::AccountId32, + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + amount: ::core::primitive::u128, + first_slot: ::core::primitive::u32, + last_slot: ::core::primitive::u32, + }, + #[codec(index = 6)] + WinningOffset { + auction_index: ::core::primitive::u32, + block_number: ::core::primitive::u32, + }, + } + } + } + pub mod claims { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Claimed { + who: ::sp_core::crypto::AccountId32, + ethereum_address: + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + amount: ::core::primitive::u128, + }, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct EthereumAddress(pub [::core::primitive::u8; 20usize]); + } + pub mod crowdloan { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Created { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 1)] + Contributed { + who: ::sp_core::crypto::AccountId32, + fund_index: + runtime_types::polkadot_parachain_primitives::primitives::Id, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + Withdrew { + who: ::sp_core::crypto::AccountId32, + fund_index: + runtime_types::polkadot_parachain_primitives::primitives::Id, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + PartiallyRefunded { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 4)] + AllRefunded { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 5)] + Dissolved { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 6)] + HandleBidResult { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + result: ::core::result::Result< + (), + runtime_types::sp_runtime::DispatchError, + >, + }, + #[codec(index = 7)] + Edited { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 8)] + MemoUpdated { + who: ::sp_core::crypto::AccountId32, + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + memo: ::sp_std::vec::Vec<::core::primitive::u8>, + }, + #[codec(index = 9)] + AddedToNewRaise { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + } + } + } + pub mod paras_registrar { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Registered { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + manager: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 1)] + Deregistered { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 2)] + Reserved { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + who: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + Swapped { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + other_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + } + } + } + pub mod slots { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewLeasePeriod { lease_period: ::core::primitive::u32 }, + #[codec(index = 1)] + Leased { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + leaser: ::sp_core::crypto::AccountId32, + period_begin: ::core::primitive::u32, + period_count: ::core::primitive::u32, + extra_reserved: ::core::primitive::u128, + total_amount: ::core::primitive::u128, + }, + } + } + } + } + + pub mod pallet_state_trie_migration { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Error { + #[codec(index = 0)] + MaxSignedLimits, + #[codec(index = 1)] + KeyTooLong, + #[codec(index = 2)] + NotEnoughFunds, + #[codec(index = 3)] + BadWitness, + #[codec(index = 4)] + SignedMigrationNotAllowed, + #[codec(index = 5)] + BadChildRoot, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Migrated { + top: ::core::primitive::u32, + child: ::core::primitive::u32, + compute: + runtime_types::pallet_state_trie_migration::pallet::MigrationCompute, + }, + #[codec(index = 1)] + Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 2)] + AutoMigrationFinished, + #[codec(index = 3)] + Halted { error: runtime_types::pallet_state_trie_migration::pallet::Error }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MigrationCompute { + #[codec(index = 0)] + Signed, + #[codec(index = 1)] + Auto, + } + } + } + pub mod bounded_collections { + use super::runtime_types; + pub mod bounded_vec { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct BoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); + } + pub mod weak_bounded_vec { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct WeakBoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); + } + } + pub mod primitive_types { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct H256(pub [::core::primitive::u8; 32usize]); + } + pub mod frame_system { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + ExtrinsicSuccess { + dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + }, + #[codec(index = 1)] + ExtrinsicFailed { + dispatch_error: runtime_types::sp_runtime::DispatchError, + dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + }, + #[codec(index = 2)] + CodeUpdated, + #[codec(index = 3)] + NewAccount { account: ::sp_core::crypto::AccountId32 }, + #[codec(index = 4)] + KilledAccount { account: ::sp_core::crypto::AccountId32 }, + #[codec(index = 5)] + Remarked { + sender: ::sp_core::crypto::AccountId32, + hash: runtime_types::primitive_types::H256, + }, + } + } + } + pub mod frame_support { + use super::runtime_types; + pub mod dispatch { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum DispatchClass { + #[codec(index = 0)] + Normal, + #[codec(index = 1)] + Operational, + #[codec(index = 2)] + Mandatory, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct DispatchInfo { + pub weight: ::sp_weights::Weight, + pub class: runtime_types::frame_support::dispatch::DispatchClass, + pub pays_fee: runtime_types::frame_support::dispatch::Pays, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Pays { + #[codec(index = 0)] + Yes, + #[codec(index = 1)] + No, + } + } + pub mod traits { + use super::runtime_types; + pub mod messages { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum ProcessMessageError { + #[codec(index = 0)] + BadFormat, + #[codec(index = 1)] + Corrupt, + #[codec(index = 2)] + Unsupported, + #[codec(index = 3)] + Overweight(::sp_weights::Weight), + #[codec(index = 4)] + Yield, + } + } + pub mod tokens { + use super::runtime_types; + pub mod misc { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BalanceStatus { + #[codec(index = 0)] + Free, + #[codec(index = 1)] + Reserved, + } + } + } + } + } + pub mod pallet_balances { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Endowed { + account: ::sp_core::crypto::AccountId32, + free_balance: ::core::primitive::u128, + }, + #[codec(index = 1)] + DustLost { + account: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + Transfer { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + BalanceSet { + who: ::sp_core::crypto::AccountId32, + free: ::core::primitive::u128, + }, + #[codec(index = 4)] + Reserved { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 5)] + Unreserved { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + ReserveRepatriated { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + destination_status: + runtime_types::frame_support::traits::tokens::misc::BalanceStatus, + }, + #[codec(index = 7)] + Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 8)] + Withdraw { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 9)] + Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 10)] + Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 11)] + Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 12)] + Suspended { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 13)] + Restored { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 14)] + Upgraded { who: ::sp_core::crypto::AccountId32 }, + #[codec(index = 15)] + Issued { amount: ::core::primitive::u128 }, + #[codec(index = 16)] + Rescinded { amount: ::core::primitive::u128 }, + #[codec(index = 17)] + Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 18)] + Unlocked { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 19)] + Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 20)] + Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event2 { + #[codec(index = 0)] + Endowed { + account: ::sp_core::crypto::AccountId32, + free_balance: ::core::primitive::u128, + }, + #[codec(index = 1)] + DustLost { + account: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + Transfer { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + BalanceSet { + who: ::sp_core::crypto::AccountId32, + free: ::core::primitive::u128, + }, + #[codec(index = 4)] + Reserved { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 5)] + Unreserved { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + ReserveRepatriated { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + destination_status: + runtime_types::frame_support::traits::tokens::misc::BalanceStatus, + }, + #[codec(index = 7)] + Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 8)] + Withdraw { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 9)] + Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 10)] + Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 11)] + Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 12)] + Suspended { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 13)] + Restored { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 14)] + Upgraded { who: ::sp_core::crypto::AccountId32 }, + #[codec(index = 15)] + Issued { amount: ::core::primitive::u128 }, + #[codec(index = 16)] + Rescinded { amount: ::core::primitive::u128 }, + #[codec(index = 17)] + Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 18)] + Unlocked { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 19)] + Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 20)] + Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + } + } + } + pub mod polkadot_runtime_parachains { + use super::runtime_types; + pub mod assigner_on_demand { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + OnDemandOrderPlaced { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + spot_price: ::core::primitive::u128, + }, + #[codec(index = 1)] + SpotTrafficSet { + traffic: runtime_types::sp_arithmetic::fixed_point::FixedU128, + }, + } + } + } + pub mod inclusion { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + CandidateBacked( + runtime_types::polkadot_primitives::v5::CandidateReceipt< + runtime_types::primitive_types::H256, + >, + runtime_types::polkadot_parachain_primitives::primitives::HeadData, + runtime_types::polkadot_primitives::v5::CoreIndex, + runtime_types::polkadot_primitives::v5::GroupIndex, + ), + #[codec(index = 1)] + CandidateIncluded( + runtime_types::polkadot_primitives::v5::CandidateReceipt< + runtime_types::primitive_types::H256, + >, + runtime_types::polkadot_parachain_primitives::primitives::HeadData, + runtime_types::polkadot_primitives::v5::CoreIndex, + runtime_types::polkadot_primitives::v5::GroupIndex, + ), + #[codec(index = 2)] + CandidateTimedOut( + runtime_types::polkadot_primitives::v5::CandidateReceipt< + runtime_types::primitive_types::H256, + >, + runtime_types::polkadot_parachain_primitives::primitives::HeadData, + runtime_types::polkadot_primitives::v5::CoreIndex, + ), + #[codec(index = 3)] + UpwardMessagesReceived { + from: runtime_types::polkadot_parachain_primitives::primitives::Id, + count: ::core::primitive::u32, + }, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AggregateMessageOrigin { + #[codec(index = 0)] + Ump(runtime_types::polkadot_runtime_parachains::inclusion::UmpQueueId), + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct AvailabilityBitfieldRecord<_0> { + // pub bitfield: runtime_types::polkadot_primitives::v5::AvailabilityBitfield, + // pub submitted_at: _0, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct CandidatePendingAvailability<_0, _1> { + // pub core: runtime_types::polkadot_primitives::v5::CoreIndex, + // pub hash: runtime_types::polkadot_core_primitives::CandidateHash, + // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + // pub availability_votes: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub backers: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub relay_parent_number: _1, + // pub backed_in_number: _1, + // pub backing_group: runtime_types::polkadot_primitives::v5::GroupIndex, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum UmpQueueId { + #[codec(index = 0)] + Para(runtime_types::polkadot_parachain_primitives::primitives::Id), + } + } + pub mod paras { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + # [codec (index = 0)] CurrentCodeUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 1)] CurrentHeadUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 2)] CodeUpgradeScheduled (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 3)] NewHeadNoted (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 4)] ActionQueued (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , :: core :: primitive :: u32 ,) , # [codec (index = 5)] PvfCheckStarted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 6)] PvfCheckAccepted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 7)] PvfCheckRejected (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , } + } + } + pub mod hrmp { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + OpenChannelRequested( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::Id, + ::core::primitive::u32, + ::core::primitive::u32, + ), + #[codec(index = 1)] + OpenChannelCanceled( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, + ), + #[codec(index = 2)] + OpenChannelAccepted( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::Id, + ), + #[codec(index = 3)] + ChannelClosed( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, + ), + #[codec(index = 4)] + HrmpChannelForceOpened( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::Id, + ::core::primitive::u32, + ::core::primitive::u32, + ), + } + } + } + pub mod disputes { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + DisputeInitiated( + runtime_types::polkadot_core_primitives::CandidateHash, + runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, + ), + #[codec(index = 1)] + DisputeConcluded( + runtime_types::polkadot_core_primitives::CandidateHash, + runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, + ), + #[codec(index = 2)] + Revert(::core::primitive::u32), + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum DisputeLocation { + #[codec(index = 0)] + Local, + #[codec(index = 1)] + Remote, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum DisputeResult { + #[codec(index = 0)] + Valid, + #[codec(index = 1)] + Invalid, + } + } + } + pub mod polkadot_parachain_primitives { + use super::runtime_types; + pub mod primitives { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct HeadData(pub ::sp_std::vec::Vec<::core::primitive::u8>); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct HrmpChannelId { + pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, + pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Id(pub ::core::primitive::u32); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct ValidationCode(pub ::sp_std::vec::Vec<::core::primitive::u8>); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct ValidationCodeHash(pub runtime_types::primitive_types::H256); + } + } + pub mod pallet_sudo { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Sudid { + sudo_result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 1)] + KeyChanged { + old_sudoer: ::core::option::Option<::sp_core::crypto::AccountId32>, + }, + #[codec(index = 2)] + SudoAsDone { + sudo_result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + } + } + } + pub mod sp_arithmetic { + use super::runtime_types; + pub mod fixed_point { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct FixedU128(pub ::core::primitive::u128); + } + pub mod per_things { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Perbill(pub ::core::primitive::u32); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Percent(pub ::core::primitive::u8); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Permill(pub ::core::primitive::u32); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Perquintill(pub ::core::primitive::u64); + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum ArithmeticError { + #[codec(index = 0)] + Underflow, + #[codec(index = 1)] + Overflow, + #[codec(index = 2)] + DivisionByZero, + } + } + pub mod sp_runtime { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum DispatchError { + #[codec(index = 0)] + Other, + #[codec(index = 1)] + CannotLookup, + #[codec(index = 2)] + BadOrigin, + #[codec(index = 3)] + Module(runtime_types::sp_runtime::ModuleError), + #[codec(index = 4)] + ConsumerRemaining, + #[codec(index = 5)] + NoProviders, + #[codec(index = 6)] + TooManyConsumers, + #[codec(index = 7)] + Token(runtime_types::sp_runtime::TokenError), + #[codec(index = 8)] + Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), + #[codec(index = 9)] + Transactional(runtime_types::sp_runtime::TransactionalError), + #[codec(index = 10)] + Exhausted, + #[codec(index = 11)] + Corruption, + #[codec(index = 12)] + Unavailable, + #[codec(index = 13)] + RootNotAllowed, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct ModuleError { + pub index: ::core::primitive::u8, + pub error: [::core::primitive::u8; 4usize], + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum TokenError { + #[codec(index = 0)] + FundsUnavailable, + #[codec(index = 1)] + OnlyProvider, + #[codec(index = 2)] + BelowMinimum, + #[codec(index = 3)] + CannotCreate, + #[codec(index = 4)] + UnknownAsset, + #[codec(index = 5)] + Frozen, + #[codec(index = 6)] + Unsupported, + #[codec(index = 7)] + CannotCreateHold, + #[codec(index = 8)] + NotExpendable, + #[codec(index = 9)] + Blocked, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum TransactionalError { + #[codec(index = 0)] + LimitReached, + #[codec(index = 1)] + NoLayer, + } + } + } +} diff --git a/primitives/coretime/on-demand/src/well_known_keys.rs b/primitives/coretime/on-demand/src/well_known_keys.rs new file mode 100644 index 0000000..07cc8be --- /dev/null +++ b/primitives/coretime/on-demand/src/well_known_keys.rs @@ -0,0 +1,54 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! Keys of well known. +#![cfg_attr(not(feature = "std"), no_std)] + +use cumulus_primitives_core::relay_chain::CoreIndex; +use { + cumulus_primitives_core::ParaId, + sp_core::Encode, + sp_io::hashing::{twox_256, twox_64}, + sp_std::vec::Vec, +}; + +pub const SYSTEM_ACCOUNT: &[u8] = + &hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da9"]; + +pub const SYSTEM_EVENTS: &[u8] = + &hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7"]; + +//OnDemandAssignmentProvider OnDemandQueue +pub const ON_DEMAND_QUEUE: &[u8] = + &hex_literal::hex!["8f32430b49607f8d60bfd3a003ddf4b53f35b69d817556cf6b886e5b4f01fbdc"]; + +//OnDemandAssignmentProvider SpotTraffic +pub const SPOT_TRAFFIC: &[u8] = + &hex_literal::hex!["8f32430b49607f8d60bfd3a003ddf4b5c9308a8e0e640735727536bd9069b11e"]; + +//Configuration ActiveConfig +pub const ACTIVE_CONFIG: &[u8] = + &hex_literal::hex!["06de3d8a54d27e44a9d5ce189618f22db4b49d95320d9021994c850f25b8e385"]; + +pub const CORE_DESCRIPTORS: &[u8] = + &hex_literal::hex!["638595eebaa445ce03a13547bece90e704e6ac775a3245623103ffec2cb2c92f"]; + +/// assigner coretime storage CoreDescriptors +pub fn paras_core_descriptors(core_index: CoreIndex) -> Vec { + core_index.using_encoded(|core_index: &[u8]| { + CORE_DESCRIPTORS.iter().chain(twox_256(core_index).iter()).cloned().collect() + }) +} From 3f2aff024cce8d3fa573fcd1fa655a8227ff5bc5 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Wed, 3 Jul 2024 17:03:32 +0800 Subject: [PATCH 22/44] add on demand client code, recover runtime code of on demand order --- Cargo.lock | 60 ++ client/coretime/on-demand/Cargo.toml | 69 ++ client/coretime/on-demand/src/lib.rs | 662 ++++++++++++++++++ .../coretime/on-demand}/src/metadata.rs | 0 client/coretime/on-demand/src/submit_order.rs | 143 ++++ node/Cargo.toml | 5 +- node/src/main.rs | 3 - node/src/service.rs | 50 +- pallets/on-demand/src/lib.rs | 462 ++++++------ runtime/Cargo.toml | 5 +- runtime/src/lib.rs | 156 ++--- 11 files changed, 1275 insertions(+), 340 deletions(-) create mode 100644 client/coretime/on-demand/Cargo.toml create mode 100644 client/coretime/on-demand/src/lib.rs rename {node => client/coretime/on-demand}/src/metadata.rs (100%) create mode 100644 client/coretime/on-demand/src/submit_order.rs diff --git a/Cargo.lock b/Cargo.lock index ac5f349..77d5923 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -6534,6 +6534,62 @@ dependencies = [ "tracing", ] +[[package]] +name = "mc-coretime-on-demand" +version = "0.1.0" +dependencies = [ + "async-trait", + "cumulus-client-collator", + "cumulus-client-consensus-aura", + "cumulus-client-consensus-common", + "cumulus-client-consensus-proposer", + "cumulus-client-parachain-inherent", + "cumulus-primitives-aura", + "cumulus-primitives-core", + "cumulus-primitives-parachain-inherent", + "cumulus-relay-chain-interface", + "futures", + "log", + "mc-coretime-common", + "mp-coretime-common", + "mp-coretime-on-demand", + "mp-system", + "pallet-broker", + "pallet-transaction-payment-rpc-runtime-api", + "parity-scale-codec", + "polkadot-node-primitives", + "polkadot-node-subsystem", + "polkadot-overseer", + "polkadot-primitives", + "polkadot-runtime-parachains", + "sc-client-api", + "sc-consensus", + "sc-consensus-aura", + "sc-consensus-babe", + "sc-consensus-slots", + "sc-service", + "sc-telemetry", + "sc-transaction-pool", + "sc-transaction-pool-api", + "schnellru", + "sp-api", + "sp-application-crypto 30.0.0", + "sp-block-builder", + "sp-blockchain", + "sp-consensus", + "sp-consensus-aura", + "sp-core 28.0.0", + "sp-inherents", + "sp-keystore 0.34.0", + "sp-runtime 31.0.1", + "sp-state-machine 0.35.0", + "sp-storage 19.0.0 (git+https://github.com/paritytech/polkadot-sdk?branch=release-polkadot-v1.7.0)", + "sp-timestamp", + "substrate-prometheus-endpoint", + "subxt", + "tracing", +] + [[package]] name = "memchr" version = "2.7.2" @@ -9609,7 +9665,9 @@ dependencies = [ "jsonrpsee", "log", "mc-coretime-bulk", + "mc-coretime-on-demand", "mp-coretime-bulk", + "mp-coretime-on-demand", "mp-system", "pallet-balances", "pallet-move-rpc", @@ -9700,6 +9758,7 @@ dependencies = [ "hex-literal", "log", "mp-coretime-bulk", + "mp-coretime-on-demand", "mp-system", "pallet-assets", "pallet-assets-bridge", @@ -9726,6 +9785,7 @@ dependencies = [ "pallet-liquidation", "pallet-message-queue", "pallet-move", + "pallet-on-demand", "pallet-pot", "pallet-pot-runtime-api", "pallet-precompile-substrate-utils", diff --git a/client/coretime/on-demand/Cargo.toml b/client/coretime/on-demand/Cargo.toml new file mode 100644 index 0000000..2e57e5e --- /dev/null +++ b/client/coretime/on-demand/Cargo.toml @@ -0,0 +1,69 @@ +[package] +name = "mc-coretime-on-demand" +authors = ["Magnet"] +description = "client of magnet coretime on demand mode" +license = "Apache License 2.0" +homepage = "https://magnet.magport.io/" +repository.workspace = true +edition.workspace = true +version = "0.1.0" + +[dependencies] +async-trait = { workspace = true } +codec = { package = "parity-scale-codec", workspace = true, features = [ "derive" ] } +futures = { workspace = true } +tracing = { workspace = true } +schnellru = { workspace = true } +log = { workspace = true } +subxt = { workspace = true, features = ["substrate-compat"]} + +# Local +mp-coretime-on-demand = { path = "../../../primitives/coretime/on-demand"} +mp-coretime-common = { path = "../../../primitives/coretime/common"} +mp-system = { path = "../../../primitives/system"} +mc-coretime-common = { path = "../common"} + +# Substrate +sc-client-api = { workspace = true } +sc-consensus = { workspace = true } +sc-consensus-aura = { workspace = true } +sc-consensus-babe = { workspace = true } +sc-consensus-slots = { workspace = true } +sc-telemetry = { workspace = true } +sc-transaction-pool = { workspace = true } +sc-transaction-pool-api = { workspace = true } +sp-api = { workspace = true } +sp-application-crypto = { workspace = true } +sp-block-builder = { workspace = true } +sp-blockchain = { workspace = true } +sp-consensus = { workspace = true } +sp-consensus-aura = { workspace = true } +sp-core = { workspace = true } +sp-inherents = { workspace = true } +sp-keystore = { workspace = true } +sp-runtime = { workspace = true } +sp-timestamp = { workspace = true } +sp-state-machine = { workspace = true } +substrate-prometheus-endpoint = { workspace = true } +sc-service = { workspace = true } +pallet-broker = { workspace = true} +sp-storage = { workspace = true } +pallet-transaction-payment-rpc-runtime-api = { workspace = true} + +# Cumulus +cumulus-client-consensus-common = { workspace = true } +cumulus-client-parachain-inherent = { workspace = true } +cumulus-relay-chain-interface = { workspace = true } +cumulus-client-consensus-proposer = { workspace = true } +cumulus-primitives-aura = { workspace = true } +cumulus-primitives-core = { workspace = true } +cumulus-primitives-parachain-inherent = { workspace = true } +cumulus-client-collator = { workspace = true } +cumulus-client-consensus-aura= { workspace = true } + +# Polkadot +polkadot-primitives = { workspace = true } +polkadot-node-primitives = { workspace = true } +polkadot-node-subsystem = { workspace = true } +polkadot-overseer = { workspace = true } +runtime-parachains = { workspace = true } diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs new file mode 100644 index 0000000..2a72baf --- /dev/null +++ b/client/coretime/on-demand/src/lib.rs @@ -0,0 +1,662 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! Ondemand order Spawner +//! +//! The logic of placing an order to purchase core is as follows. +//! Every time a relay chain block is received, check whether the parachain is in parallel thread mode. +//! If so, read the events of the relay chain to see if there is an order to purchase core. , if there is a purchase, +//! record the purchase information. If not, then determine whether it is necessary to purchase core, such as whether +//! the transactions in the mempool reach a certain threshold. +//! +mod metadata; +mod submit_order; + +use codec::{Codec, Decode}; +use cumulus_primitives_core::{ + relay_chain::BlockNumber as RelayBlockNumber, ParaId, PersistedValidationData, +}; +use cumulus_relay_chain_interface::{RelayChainInterface, RelayChainResult}; +use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; +use metadata::api::runtime_types::pallet_broker::coretime_interface::CoreAssignment; +use metadata::api::runtime_types::polkadot_runtime_parachains::assigner_coretime::CoreDescriptor; +use mp_coretime_common::well_known_keys::paras_para_lifecycles; +use mp_coretime_on_demand::{ + self, + well_known_keys::paras_core_descriptors, + well_known_keys::{ACTIVE_CONFIG, ON_DEMAND_QUEUE, SPOT_TRAFFIC, SYSTEM_EVENTS}, + OrderRecord, OrderRuntimeApi, OrderStatus, +}; +use mp_system::OnRelayChainApi; +pub use pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi; +use polkadot_primitives::OccupiedCoreAssumption; +use runtime_parachains::{configuration::HostConfiguration, paras::ParaLifecycle}; +use sc_client_api::UsageProvider; +use sc_service::TaskManager; +use sc_transaction_pool_api::{InPoolTransaction, MaintainedTransactionPool}; +use sp_api::ProvideRuntimeApi; +use sp_application_crypto::AppPublic; +use sp_consensus_aura::AuraApi; +use sp_core::ByteArray; +use sp_core::{crypto::Pair, H256}; +use sp_keystore::KeystorePtr; +use sp_runtime::{ + codec::Encode, + traits::{ + AtLeast32BitUnsigned, Block as BlockT, Header as HeaderT, MaybeDisplay, Member, + SaturatedConversion, + }, + FixedPointNumber, FixedU128, +}; +use std::cmp::Ordering; +use std::{convert::TryFrom, error::Error, fmt::Debug, sync::Arc}; +use submit_order::{build_rpc_for_submit_order, SubmitOrderError}; + +#[derive(Encode, Decode, Debug, PartialEq, Clone)] +struct EnqueuedOrder { + /// Parachain ID + pub para_id: ParaId, +} + +/// Order type +#[derive(Clone, PartialEq)] +pub enum OrderType { + /// The mem pool gas reaches the threshold. + Normal, + /// Reaching the forced block threshold. + Force, + /// Receive xcm transaction from relay chain. + XCMEvent, +} + +/// Get the spot price of the relay chain. +async fn get_spot_price( + relay_chain: impl RelayChainInterface + Clone, + hash: H256, +) -> Option +where + Balance: Codec + MaybeDisplay + 'static + Debug + From, +{ + let spot_traffic_storage = relay_chain.get_storage_by_key(hash, SPOT_TRAFFIC).await.ok()?; + let p_spot_traffic = spot_traffic_storage + .map(|raw| ::decode(&mut &raw[..])) + .transpose() + .ok()?; + let active_config_storage = relay_chain.get_storage_by_key(hash, ACTIVE_CONFIG).await.ok()?; + let p_active_config = active_config_storage + .map(|raw| >::decode(&mut &raw[..])) + .transpose() + .ok()?; + if p_spot_traffic.is_some() && p_active_config.is_some() { + let spot_traffic = p_spot_traffic.unwrap(); + let active_config = p_active_config.unwrap(); + let spot_price = spot_traffic + .saturating_mul_int(active_config.on_demand_base_fee.saturated_into::()); + Some(Balance::from(spot_price)) + } else { + None + } +} + +/// Whether the relay chain has ondemand function enabled. +async fn start_on_demand( + relay_chain: impl RelayChainInterface + Clone, + hash: H256, + para_id: ParaId, +) -> Option { + let active_config_storage = relay_chain.get_storage_by_key(hash, ACTIVE_CONFIG).await.ok()?; + let p_active_config = active_config_storage + .map(|raw| >::decode(&mut &raw[..])) + .transpose() + .ok()?; + if p_active_config.is_some() { + let mut result = false; + let cores = p_active_config.unwrap().coretime_cores; + for core in 0..cores { + let key = paras_core_descriptors(polkadot_primitives::CoreIndex(core)); + let core_descriptors_storage = + relay_chain.get_storage_by_key(hash, key.as_slice()).await.ok()?; + let p_core_descriptors = core_descriptors_storage + .map(|raw| >::decode(&mut &raw[..])) + .transpose() + .ok()?; + if p_core_descriptors.is_some() { + let p_current_work = p_core_descriptors?.current_work; + if p_current_work.is_some() { + let current_work = p_current_work?; + for (assign, _) in current_work.assignments { + if assign == CoreAssignment::Task(para_id.into()) { + return Some(false); + } else if assign == CoreAssignment::Pool { + result = true + } + } + } + } + } + Some(result) + } else { + None + } +} + +/// Create an order to purchase core. +async fn try_place_order( + hash: H256, + keystore: KeystorePtr, + para_id: ParaId, + url: String, + max_amount: Balance, + slot_block: u32, + height: RelayBlockNumber, + relay_chain: impl RelayChainInterface + Clone, + number: u32, +) -> Result<(), SubmitOrderError> +where + Balance: Codec + MaybeDisplay + 'static + Debug + Into, + ParaId: From, +{ + let max_amount_128 = max_amount.into(); + build_rpc_for_submit_order( + &url, + para_id, + max_amount_128, + hash, + keystore, + slot_block, + height, + relay_chain, + number, + ) + .await +} + +/// Whether the mem pool reaches the threshold for purchasing cores. +async fn reach_txpool_threshold( + parachain: &P, + transaction_pool: Arc, + height: RelayBlockNumber, + snap_txs: Vec, +) -> Option<(bool, OrderType)> +where + Block: BlockT, + P: ProvideRuntimeApi + UsageProvider, + Balance: Codec + MaybeDisplay + 'static + Debug + AtLeast32BitUnsigned + Copy, + P::Api: TransactionPaymentApi + + OrderRuntimeApi + + OnRelayChainApi, + ExPool: MaintainedTransactionPool::Hash> + 'static, + PB: Pair, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, +{ + let mut pending_iterator = transaction_pool.ready(); + let mut is_place_order = false; + let mut all_gas_value = Balance::from(0u32); + let block_hash = parachain.usage_info().chain.best_hash; + let mut back_txs: Vec = vec![]; + loop { + let pending_tx = + if let Some(pending_tx) = pending_iterator.next() { pending_tx } else { break }; + let pending_tx_data = pending_tx.data().clone(); + let utx_length = pending_tx_data.encode().len() as u32; + let query_fee = parachain + .runtime_api() + .query_fee_details(block_hash, pending_tx_data, utx_length) + .ok()?; + all_gas_value = query_fee.final_fee().add(all_gas_value); + if transaction_pool.status().ready != 0 { + is_place_order = + parachain.runtime_api().reach_txpool_threshold(block_hash, all_gas_value).ok()?; + } + log::info!( + "tx_fee:{:?},all_fee:{:?},can_order:{:?},status:{:?}", + query_fee.final_fee(), + all_gas_value, + is_place_order, + transaction_pool.status() + ); + back_txs.push(H256::from_slice(pending_tx.hash().as_ref())); + } + let mut order_type = OrderType::Normal; + if !is_place_order { + //check is need force bid coretime + let force_bid = parachain.runtime_api().on_relaychain(block_hash, height).ok()?; + if all_gas_value.cmp(&Balance::from(0u32)) == Ordering::Greater && force_bid == 1 { + is_place_order = true; + order_type = OrderType::Force; + } + } + if is_place_order { + if back_txs == snap_txs { + is_place_order = false; + } + } + log::info!("back_txs:{:?}", back_txs); + log::info!("snap_txs:{:?}", snap_txs); + Some((is_place_order, order_type)) +} + +/// Whether the xcm transaction event of the relay chain is received. +async fn relay_chain_xcm_event( + relay_chain_interface: impl RelayChainInterface + Clone, + para_id: ParaId, + relay_parent: H256, +) -> Option<(bool, OrderType)> { + let downward_messages = + relay_chain_interface.retrieve_dmq_contents(para_id, relay_parent).await.ok()?; + let horizontal_messages = relay_chain_interface + .retrieve_all_inbound_hrmp_channel_contents(para_id, relay_parent) + .await + .ok()?; + let can_order = downward_messages.len() > 0 || horizontal_messages.len() > 0; + return Some((can_order, OrderType::XCMEvent)); +} + +/// Get the transactions in the ready queue in the mem pool +async fn get_txs(transaction_pool: Arc) -> Vec +where + Block: BlockT, + ExPool: MaintainedTransactionPool::Hash> + 'static, +{ + let mut pending_iterator = transaction_pool.ready(); + let mut back_txs: Vec = vec![]; + loop { + let pending_tx = + if let Some(pending_tx) = pending_iterator.next() { pending_tx } else { break }; + back_txs.push(H256::from_slice(pending_tx.hash().as_ref())); + } + return back_txs; +} + +/// The main processing logic of purchasing core. +async fn handle_new_best_parachain_head( + validation_data: PersistedValidationData, + height: RelayBlockNumber, + parachain: &P, + keystore: KeystorePtr, + relay_chain: impl RelayChainInterface + Clone, + p_hash: H256, + para_id: ParaId, + order_record: Arc>>, + transaction_pool: Arc, + url: String, +) -> Result<(), Box> +where + Block: BlockT, + P: ProvideRuntimeApi + UsageProvider, + Balance: Codec + + MaybeDisplay + + 'static + + Debug + + Into + + AtLeast32BitUnsigned + + Copy + + From, + P::Api: AuraApi + + OrderRuntimeApi + + TransactionPaymentApi + + OnRelayChainApi, + PB: Pair, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, + ExPool: MaintainedTransactionPool::Hash> + 'static, +{ + let para_lifecycles_storage = relay_chain + .get_storage_by_key(p_hash, paras_para_lifecycles(para_id).as_slice()) + .await?; + let para_lifecycles = para_lifecycles_storage + .map(|raw| ::decode(&mut &raw[..])) + .transpose()?; + let is_parathread = match para_lifecycles { + Some(lifecycles) => matches!( + lifecycles, + ParaLifecycle::Parathread + | ParaLifecycle::UpgradingParathread + | ParaLifecycle::OffboardingParathread + ), + None => false, + }; + if !is_parathread { + //parachain mode + let mut order_record_local = order_record.lock().await; + order_record_local.validation_data = None; + order_record_local.author_pub = None; + order_record_local.relay_parent = None; + return Ok(()); + } else { + //parathread + let p_on_demand = start_on_demand(relay_chain.clone(), p_hash, para_id).await; + if p_on_demand.is_some() { + let on_demand = p_on_demand.unwrap(); + if !on_demand { + return Ok(()); + } + } + let order_record_local = order_record.lock().await; + if order_record_local.relay_height == height { + return Ok(()); + } + } + let head = validation_data.clone().parent_head.0; + let parachain_head = match <::Header>::decode(&mut &head[..]) { + Ok(header) => header, + Err(err) => return Err(format!("get parachain head error:{:?}", err).into()), + }; + + let hash = parachain_head.hash(); + let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; + let slot_width = parachain.runtime_api().slot_width(hash)?; + let auth_len = authorities.len() as u32; + let idx = (height >> slot_width) % auth_len; + let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; + let base = 2 as u32; + let slot_block = base.pow(slot_width); + if height % slot_block == 0 { + let mut order_record_local = order_record.lock().await; + order_record_local.relay_base = p_hash; + order_record_local.relay_base_height = height; + order_record_local.order_status = OrderStatus::Init; + } + let mut relevant_keys = Vec::new(); + //System Events + relevant_keys.push(SYSTEM_EVENTS.to_vec()); + let storage_proof = relay_chain.prove_read(p_hash, &relevant_keys).await?; + let order_placed = parachain.runtime_api().order_placed( + hash, + storage_proof, + validation_data.clone(), + para_id, + )?; + match order_placed { + Some(author) => { + let mut order_record_local = order_record.lock().await; + order_record_local.relay_parent = Some(p_hash); + order_record_local.relay_height = height; + order_record_local.validation_data = Some(validation_data); + order_record_local.author_pub = Some(author); + order_record_local.para_id = para_id; + let sequence_number = parachain.runtime_api().sequence_number(hash)?; + order_record_local.sequence_number = sequence_number; + order_record_local.txs = get_txs(transaction_pool.clone()).await; + }, + None => { + let sequence_number = parachain.runtime_api().sequence_number(hash)?; + let order_executed = parachain.runtime_api().order_executed(hash, sequence_number)?; + if order_executed { + return Ok(()); + } + let mut order_record_local = order_record.lock().await; + if collator_public.is_some() { + //your turn + let reached = reach_txpool_threshold::<_, _, _, _, PB>( + parachain, + transaction_pool, + height, + order_record_local.txs.clone(), + ) + .await; + let mut can_order = false; + let mut order_type = OrderType::Normal; + if let Some((reach, o_t)) = reached { + if reach { + order_type = o_t; + let mut exist_order = false; + // key = OnDemandAssignmentProvider OnDemandQueue + let on_demand_queue_storage = + relay_chain.get_storage_by_key(p_hash, ON_DEMAND_QUEUE).await?; + let on_demand_queue = on_demand_queue_storage + .map(|raw| >::decode(&mut &raw[..])) + .transpose()?; + if let Some(vvs) = on_demand_queue.clone() { + for vv in vvs.into_iter() { + if vv.para_id == para_id { + exist_order = true; + break; + } + } + } + if !exist_order { + can_order = true; + } + } else { + let trig_xcm_event = + relay_chain_xcm_event(relay_chain.clone(), para_id, p_hash).await; + if let Some((trig_flag, o_t)) = trig_xcm_event { + can_order = trig_flag; + order_type = o_t; + } + } + } + if can_order { + if height - order_record_local.relay_height > slot_block { + if order_record_local.order_status == OrderStatus::Init { + let max_amount = parachain.runtime_api().order_max_amount(hash)?; + let p_spot_price = + get_spot_price::(relay_chain.clone(), p_hash).await; + let spot_price; + if p_spot_price.is_some() { + spot_price = p_spot_price.unwrap(); + } else { + spot_price = max_amount; + } + match order_type { + OrderType::Normal => { + log::info!( + "============normal place order======================" + ); + }, + OrderType::Force => { + log::info!( + "============force place order======================" + ); + }, + OrderType::XCMEvent => { + log::info!("============xcm place order======================"); + }, + } + let order_result = try_place_order::( + order_record_local.relay_base, + keystore, + para_id, + url, + spot_price, + slot_block, + height, + relay_chain.clone(), + order_record_local.relay_base_height, + ) + .await; + log::info!("===========place order completed==============",); + order_record_local.order_status = OrderStatus::Order; + if order_result.is_err() { + log::info!( + "===========place_order error:=============={:?}", + order_result + ); + } + } + } + } + } + }, + } + Ok(()) +} + +async fn new_best_heads( + relay_chain: impl RelayChainInterface + Clone, + para_id: ParaId, +) -> RelayChainResult> { + let new_best_notification_stream = + relay_chain.new_best_notification_stream().await?.filter_map(move |n| { + let relay_chain = relay_chain.clone(); + async move { + let relay_head: PersistedValidationData = relay_chain + .persisted_validation_data(n.hash(), para_id, OccupiedCoreAssumption::TimedOut) + .await + .map(|s| s.map(|s| s)) + .ok() + .flatten()?; + Some((n.number, relay_head, n.hash())) + } + }); + + Ok(new_best_notification_stream) +} +async fn relay_chain_notification( + para_id: ParaId, + parachain: Arc

, + relay_chain: R, + keystore: KeystorePtr, + order_record: Arc>>, + transaction_pool: Arc, + url: String, +) where + R: RelayChainInterface + Clone, + Block: BlockT, + Balance: Codec + + MaybeDisplay + + 'static + + Debug + + Into + + AtLeast32BitUnsigned + + Copy + + From, + P: ProvideRuntimeApi + UsageProvider, + P::Api: AuraApi + + OrderRuntimeApi + + TransactionPaymentApi + + OnRelayChainApi, + PB: Pair, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, + ExPool: MaintainedTransactionPool::Hash> + 'static, +{ + let new_best_heads = match new_best_heads(relay_chain.clone(), para_id).await { + Ok(best_heads_stream) => best_heads_stream.fuse(), + Err(_err) => { + return; + }, + }; + pin_mut!(new_best_heads); + loop { + select! { + h = new_best_heads.next() => { + match h { + Some((height, head, hash)) => { + let _ = handle_new_best_parachain_head::<_,_,PB,_,_>(head,height, &*parachain,keystore.clone(), relay_chain.clone(), hash, para_id, order_record.clone(),transaction_pool.clone(), url.clone()).await; + }, + None => { + return; + } + } + }, + } + } +} + +pub async fn run_on_demand_task( + para_id: ParaId, + parachain: Arc

, + relay_chain: R, + keystore: KeystorePtr, + order_record: Arc>>, + transaction_pool: Arc, + url: String, +) where + R: RelayChainInterface + Clone, + Block: BlockT, + P: ProvideRuntimeApi + UsageProvider, + Balance: Codec + + MaybeDisplay + + 'static + + Debug + + Into + + AtLeast32BitUnsigned + + Copy + + From, + P::Api: AuraApi + + OrderRuntimeApi + + TransactionPaymentApi + + OnRelayChainApi, + PB: Pair, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, + ExPool: MaintainedTransactionPool::Hash> + 'static, +{ + let relay_chain_notification = relay_chain_notification::<_, _, _, PB, _, _>( + para_id, + parachain.clone(), + relay_chain, + keystore, + order_record, + transaction_pool, + url, + ); + select! { + _ = relay_chain_notification.fuse() => {}, + } +} + +pub fn spawn_on_demand_order( + parachain: Arc, + para_id: ParaId, + relay_chain: R, + transaction_pool: Arc, + task_manager: &TaskManager, + keystore: KeystorePtr, + order_record: Arc>>, + url: String, +) -> sc_service::error::Result<()> +where + Block: BlockT, + R: RelayChainInterface + Clone + 'static, + Balance: Codec + + MaybeDisplay + + 'static + + Debug + + Send + + Into + + AtLeast32BitUnsigned + + Copy + + From, + T: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, + ExPool: MaintainedTransactionPool::Hash> + 'static, + T::Api: AuraApi + + OrderRuntimeApi + + TransactionPaymentApi + + OnRelayChainApi, + PB: Pair + 'static, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, +{ + let on_demand_order_task = run_on_demand_task::<_, _, _, PB, _, _>( + para_id, + parachain.clone(), + relay_chain.clone(), + keystore, + order_record, + transaction_pool.clone(), + url, + ); + task_manager.spawn_essential_handle().spawn_blocking( + "on_demand_order_task", + None, + on_demand_order_task, + ); + Ok(()) +} diff --git a/node/src/metadata.rs b/client/coretime/on-demand/src/metadata.rs similarity index 100% rename from node/src/metadata.rs rename to client/coretime/on-demand/src/metadata.rs diff --git a/client/coretime/on-demand/src/submit_order.rs b/client/coretime/on-demand/src/submit_order.rs new file mode 100644 index 0000000..eb639e4 --- /dev/null +++ b/client/coretime/on-demand/src/submit_order.rs @@ -0,0 +1,143 @@ +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! The code here is implemented, constructing a transaction from the parachain and sending it to the relay chain to purchase core. +//! +//! Subxt is used here to construct and submit the transaction. +//! +use crate::metadata; +use cumulus_primitives_core::{ + relay_chain::BlockId, relay_chain::BlockNumber as RelayBlockNumber, ParaId, +}; +use cumulus_relay_chain_interface::{RelayChainInterface, RelayChainResult}; +use sp_application_crypto::AppCrypto; +use sp_core::ByteArray; +use sp_core::H256; +use sp_keystore::KeystorePtr; +use sp_runtime::{ + traits::{IdentifyAccount, Verify}, + MultiSignature as SpMultiSignature, +}; +use subxt::client::OfflineClientT; +use subxt::{ + config::polkadot::PolkadotExtrinsicParamsBuilder as Params, tx::Signer, utils::MultiSignature, + Config, OnlineClient, PolkadotConfig, +}; + +#[derive(Debug)] +pub enum SubmitOrderError { + RPCUrlError, + RPCConnectError, + RPCCallException, + NonceGetError, + StorageGetError, + GetBlockError, + GetHeadError, +} + +#[derive(Clone, Copy, PartialEq, Eq)] +pub struct Signature(pub [u8; 64]); + +impl From for MultiSignature { + fn from(value: Signature) -> Self { + MultiSignature::Sr25519(value.0) + } +} +pub struct SignerKeystore { + /// Account ID + account_id: T::AccountId, + /// Keystore of node + keystore: KeystorePtr, +} +impl SignerKeystore +where + T: Config, + T::AccountId: From<[u8; 32]>, +{ + pub fn new(keystore: KeystorePtr) -> Self { + let pub_key = + keystore.sr25519_public_keys(sp_consensus_aura::sr25519::AuthorityPair::ID)[0]; + + let binding = ::Signer::from(pub_key).into_account().clone(); + + let account_id = binding.as_slice(); + let mut r = [0u8; 32]; + r.copy_from_slice(account_id); + let acc = T::AccountId::try_from(r).ok().unwrap(); + Self { account_id: acc.clone(), keystore } + } +} +impl Signer for SignerKeystore +where + T: Config, + T::AccountId: From<[u8; 32]>, + T::Signature: From, +{ + fn account_id(&self) -> T::AccountId { + self.account_id.clone() + } + + fn address(&self) -> T::Address { + self.account_id.clone().into() + } + + /// Use aura's key to sign + /// TODO:Modify to other keys, or load the key in some way. + fn sign(&self, signer_payload: &[u8]) -> T::Signature { + let pub_key = + self.keystore.sr25519_public_keys(sp_consensus_aura::sr25519::AuthorityPair::ID)[0]; + + let signature = self + .keystore + .sr25519_sign(sp_consensus_aura::sr25519::AuthorityPair::ID, &pub_key, signer_payload) + .unwrap() + .unwrap(); + + Signature(signature.0).into() + } +} + +/// Construct the transaction and sign it, and then submit the transaction through the rpc interface. +pub async fn build_rpc_for_submit_order( + url: &str, + para_id: ParaId, + max_amount: u128, + hash: H256, + keystore: KeystorePtr, + slot_block: u32, + height: RelayBlockNumber, + relay_chain: impl RelayChainInterface + Clone, + number: u32, +) -> Result<(), SubmitOrderError> { + let client = OnlineClient::::from_url(url) + .await + .map_err(|_e| SubmitOrderError::RPCConnectError)?; + + let place_order = metadata::api::tx().on_demand_assignment_provider().place_order_allow_death( + max_amount, + metadata::api::runtime_types::polkadot_parachain_primitives::primitives::Id(para_id.into()), + ); + + let signer_keystore = SignerKeystore::::new(keystore.clone()); + + // let tx_params = Params::new().mortal_unchecked(number.into(), hash , slot_block.into()).build(); + + let submit_result = client.tx().sign_and_submit_default(&place_order, &signer_keystore).await; + log::info!("submit_result:{:?},{:?},{:?}", submit_result, height, hash); + submit_result.map_err(|_e| SubmitOrderError::RPCCallException)?; + + Ok(()) +} diff --git a/node/Cargo.toml b/node/Cargo.toml index 02135af..ede4d98 100644 --- a/node/Cargo.toml +++ b/node/Cargo.toml @@ -29,12 +29,13 @@ subxt-signer = { workspace = true } # Local parachain-magnet-runtime = { path = "../runtime" } -#magnet-primitives-order = { path = "../primitives/order"} -#magnet-client-consensus-aura = {path ="../client/consensus/aura"} pallet-pot-rpc = { path = "../pallets/pot/rpc" } mp-system = { path = "../primitives/system"} mc-coretime-bulk = {path ="../client/coretime/bulk"} mp-coretime-bulk = { path = "../primitives/coretime/bulk"} +mc-coretime-on-demand = {path ="../client/coretime/on-demand"} +mp-coretime-on-demand = { path = "../primitives/coretime/on-demand"} + # Substrate frame-benchmarking = { workspace = true } diff --git a/node/src/main.rs b/node/src/main.rs index 8fdc1de..e20e4af 100644 --- a/node/src/main.rs +++ b/node/src/main.rs @@ -9,10 +9,7 @@ mod cli; mod client; mod command; mod eth; -mod metadata; -// mod on_demand_order; mod rpc; -// mod submit_order; fn main() -> sc_cli::Result<()> { command::run() diff --git a/node/src/service.rs b/node/src/service.rs index 6ece3fa..e7e83c4 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -49,12 +49,12 @@ use crate::eth::{ FrontierBlockImport as TFrontierBlockImport, FrontierPartialComponents, }; -// use crate::on_demand_order::spawn_on_demand_order; use futures::lock::Mutex; -// use magnet_primitives_order::{OrderRecord, OrderStatus}; use mc_coretime_bulk::spawn_bulk_task; +use mc_coretime_on_demand::spawn_on_demand_order; use mp_coretime_bulk::BulkMemRecord; use mp_coretime_bulk::BulkStatus; +use mp_coretime_on_demand::{OrderRecord, OrderStatus}; use sp_core::ByteArray; use sp_runtime::AccountId32; use sp_trie::StorageProof; @@ -464,29 +464,29 @@ async fn start_node_impl( sync_service: sync_service.clone(), })?; if validator { - // let order_record = - // Arc::new(Mutex::new(OrderRecord:: { - // relay_parent: None, - // relay_height: 0, - // relay_base: Default::default(), - // relay_base_height: 0, - // order_status: OrderStatus::Init, - // validation_data: None, - // para_id, - // sequence_number: 0, - // author_pub: None, - // txs: vec![], - // })); - // spawn_on_demand_order::<_, _, _, _, sp_consensus_aura::sr25519::AuthorityPair, _>( - // client.clone(), - // para_id, - // relay_chain_interface.clone(), - // transaction_pool.clone(), - // &task_manager, - // params.keystore_container.keystore(), - // order_record.clone(), - // rpc_address, - // )?; + let order_record = + Arc::new(Mutex::new(OrderRecord:: { + relay_parent: None, + relay_height: 0, + relay_base: Default::default(), + relay_base_height: 0, + order_status: OrderStatus::Init, + validation_data: None, + para_id, + sequence_number: 0, + author_pub: None, + txs: vec![], + })); + spawn_on_demand_order::<_, _, _, _, sp_consensus_aura::sr25519::AuthorityPair, _>( + client.clone(), + para_id, + relay_chain_interface.clone(), + transaction_pool.clone(), + &task_manager, + params.keystore_container.keystore(), + order_record.clone(), + rpc_address, + )?; let bulk_mem_record = Arc::new(Mutex::new(BulkMemRecord { coretime_para_height: 0, items: Vec::new() })); spawn_bulk_task::<_, _, _, sp_consensus_aura::sr25519::AuthorityPair>( diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs index df98fab..dc8722d 100644 --- a/pallets/on-demand/src/lib.rs +++ b/pallets/on-demand/src/lib.rs @@ -36,10 +36,10 @@ use frame_support::{ }; use frame_system::pallet_prelude::*; use frame_system::{self, EventRecord}; -// use magnet_primitives_order::{ -// metadata::api::{runtime_types, runtime_types::rococo_runtime as polakdot_runtime}, -// well_known_keys::SYSTEM_EVENTS, -// }; +use mp_coretime_on_demand::{ + metadata::api::{runtime_types, runtime_types::rococo_runtime as polakdot_runtime}, + well_known_keys::SYSTEM_EVENTS, +}; pub use pallet::*; use primitives::Balance; use primitives::{Id as ParaId, PersistedValidationData}; @@ -241,241 +241,241 @@ pub mod pallet { #[pallet::call] impl Pallet { - // /// Create an order, which is called by the pallet. - // /// Users cannot actively call this function. - // /// Obtain order information by parsing inherited data. - // /// - // /// Parameters: - // /// - `data`: The inherent data. - // #[pallet::call_index(0)] - // #[pallet::weight((0, DispatchClass::Mandatory))] - // pub fn create_order( - // origin: OriginFor, - // data: magnet_primitives_order::OrderInherentData, - // ) -> DispatchResultWithPostInfo { - // ensure_none(origin)?; - - // let magnet_primitives_order::OrderInherentData { - // relay_storage_proof, - // validation_data, - // sequence_number, - // para_id, - // author_pub, - // } = data; - // let total_weight = match validation_data { - // Some(validation_data) => { - // let (_, price) = Self::check_order_proof( - // relay_storage_proof, - // validation_data.clone(), - // author_pub.clone(), - // para_id, - // ) - // .ok_or(Error::::CreateOrderFail)?; - // let old_sequence_number = SequenceNumber::::get(); - // let order = OrderMap::::get(old_sequence_number); - // if sequence_number != old_sequence_number { - // // In the worst-case scenario, if there are multiple orders at the same - // // time, it may be due to system issues or it may be due to human - // // intervention. Currently, we only support running one order at the same - // // time Err(Error::::WrongSequenceNumber)?; - // // Continuing to produce blocks, recording errors - // log::info!("========WrongSequenceNumber:{:?}========", sequence_number); - // } - // if order.is_none() { - // OrderMap::::insert( - // old_sequence_number, - // Order:: { - // sequence_number: old_sequence_number, - // orderer: author_pub.unwrap(), - // price, - // executed: false, - // }, - // ); - // CurrentRelayHeight::::set(validation_data.relay_parent_number); - // } else { - // Err(Error::::OrderExist)?; - // } - // T::DbWeight::get().reads_writes(2, 1) - // }, - // None => T::DbWeight::get().reads_writes(0, 0), - // }; - // Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) - // } - - // /// Order pallet parameter settings. - // /// It can only be called by accounts with sudo privileges or authorized organization members. - // /// - // /// Parameters: - // /// - `slot_width`: The order interval is 2^slotwidth.. - // /// - `order_max_amount`: The maximum price the user is willing to pay when placing an order. - // /// - `tx_pool_threshold`: Gas threshold that triggers order placement. - // #[pallet::call_index(1)] - // #[pallet::weight(T::WeightInfo::set_parameter(*slot_width))] - // pub fn set_parameter( - // origin: OriginFor, - // slot_width: Option, - // order_max_amount: Option>, - // tx_pool_threshold: Option>, - // ) -> DispatchResultWithPostInfo { - // T::UpdateOrigin::ensure_origin(origin)?; - - // if let Some(t_slot_width) = slot_width { - // >::put(t_slot_width); - // } - // if let Some(t_order_max_amount) = order_max_amount { - // >::put(t_order_max_amount); - // } - // if let Some(t_tx_pool_threshold) = tx_pool_threshold { - // >::put(t_tx_pool_threshold); - // } - // Ok(().into()) - // } + /// Create an order, which is called by the pallet. + /// Users cannot actively call this function. + /// Obtain order information by parsing inherited data. + /// + /// Parameters: + /// - `data`: The inherent data. + #[pallet::call_index(0)] + #[pallet::weight((0, DispatchClass::Mandatory))] + pub fn create_order( + origin: OriginFor, + data: mp_coretime_on_demand::OrderInherentData, + ) -> DispatchResultWithPostInfo { + ensure_none(origin)?; + + let mp_coretime_on_demand::OrderInherentData { + relay_storage_proof, + validation_data, + sequence_number, + para_id, + author_pub, + } = data; + let total_weight = match validation_data { + Some(validation_data) => { + let (_, price) = Self::check_order_proof( + relay_storage_proof, + validation_data.clone(), + author_pub.clone(), + para_id, + ) + .ok_or(Error::::CreateOrderFail)?; + let old_sequence_number = SequenceNumber::::get(); + let order = OrderMap::::get(old_sequence_number); + if sequence_number != old_sequence_number { + // In the worst-case scenario, if there are multiple orders at the same + // time, it may be due to system issues or it may be due to human + // intervention. Currently, we only support running one order at the same + // time Err(Error::::WrongSequenceNumber)?; + // Continuing to produce blocks, recording errors + log::info!("========WrongSequenceNumber:{:?}========", sequence_number); + } + if order.is_none() { + OrderMap::::insert( + old_sequence_number, + Order:: { + sequence_number: old_sequence_number, + orderer: author_pub.unwrap(), + price, + executed: false, + }, + ); + CurrentRelayHeight::::set(validation_data.relay_parent_number); + } else { + Err(Error::::OrderExist)?; + } + T::DbWeight::get().reads_writes(2, 1) + }, + None => T::DbWeight::get().reads_writes(0, 0), + }; + Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) + } + + /// Order pallet parameter settings. + /// It can only be called by accounts with sudo privileges or authorized organization members. + /// + /// Parameters: + /// - `slot_width`: The order interval is 2^slotwidth.. + /// - `order_max_amount`: The maximum price the user is willing to pay when placing an order. + /// - `tx_pool_threshold`: Gas threshold that triggers order placement. + #[pallet::call_index(1)] + #[pallet::weight(T::WeightInfo::set_parameter(*slot_width))] + pub fn set_parameter( + origin: OriginFor, + slot_width: Option, + order_max_amount: Option>, + tx_pool_threshold: Option>, + ) -> DispatchResultWithPostInfo { + T::UpdateOrigin::ensure_origin(origin)?; + + if let Some(t_slot_width) = slot_width { + >::put(t_slot_width); + } + if let Some(t_order_max_amount) = order_max_amount { + >::put(t_order_max_amount); + } + if let Some(t_tx_pool_threshold) = tx_pool_threshold { + >::put(t_tx_pool_threshold); + } + Ok(().into()) + } } } impl Pallet { - // /// Obtain the order account and price from the relaychain's validation. - // /// - // /// Parameters: - // /// - `relay_storage_proof`: The proof of relay chain storage. - // ///- `validation_data`: The validation data. - // /// - `para_id`: ID of parachain. - // fn get_author_from_proof( - // relay_storage_proof: sp_trie::StorageProof, - // validation_data: PersistedValidationData, - // para_id: ParaId, - // ) -> Option<(T::AuthorityId, Balance)> { - // let relay_storage_root = validation_data.relay_parent_storage_root; - // let relay_storage_rooted_proof = - // RelayChainStateProof::new(para_id, relay_storage_root, relay_storage_proof) - // .expect("Invalid relay chain state proof"); - // let head_data = relay_storage_rooted_proof - // .read_entry::>>>( - // SYSTEM_EVENTS, - // None, - // ) - // .ok()?; - // let v_price: Vec = head_data - // .iter() - // .filter_map(|item| { - // if let polakdot_runtime::RuntimeEvent::OnDemandAssignmentProvider( - // runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event::OnDemandOrderPlaced{ - // para_id: pid, - // spot_price: sprice, - // }) = &item.event - // { - // if pid.encode() == para_id.encode() { - // Some(*sprice) - // } else { - // None - // } - // } else { - // None - // } - // }) - // .collect(); - // let orderer: Vec<(T::AuthorityId, u128)> = v_price - // .iter() - // .filter_map(|item| { - // let mut orderer = None; - // let _: Vec<_> = head_data - // .iter() - // .filter_map(|event| { - // if let polakdot_runtime::RuntimeEvent::Balances( - // runtime_types::pallet_balances::pallet::Event::Withdraw { - // who: ref order, - // amount: eprice, - // }, - // ) = event.event - // { - // if eprice == *item { - // orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { - // Ok(order) => Some((order, eprice)), - // Err(_) => None, - // }; - // Some(()) - // } else { - // None - // } - // } else { - // None - // } - // }) - // .collect(); - // orderer - // }) - // .collect(); - // if orderer.len() > 0 { - // Some(orderer[0].clone()) - // } else { - // None - // } - // } + /// Obtain the order account and price from the relaychain's validation. + /// + /// Parameters: + /// - `relay_storage_proof`: The proof of relay chain storage. + ///- `validation_data`: The validation data. + /// - `para_id`: ID of parachain. + fn get_author_from_proof( + relay_storage_proof: sp_trie::StorageProof, + validation_data: PersistedValidationData, + para_id: ParaId, + ) -> Option<(T::AuthorityId, Balance)> { + let relay_storage_root = validation_data.relay_parent_storage_root; + let relay_storage_rooted_proof = + RelayChainStateProof::new(para_id, relay_storage_root, relay_storage_proof) + .expect("Invalid relay chain state proof"); + let head_data = relay_storage_rooted_proof + .read_entry::>>>( + SYSTEM_EVENTS, + None, + ) + .ok()?; + let v_price: Vec = head_data + .iter() + .filter_map(|item| { + if let polakdot_runtime::RuntimeEvent::OnDemandAssignmentProvider( + runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event::OnDemandOrderPlaced{ + para_id: pid, + spot_price: sprice, + }) = &item.event + { + if pid.encode() == para_id.encode() { + Some(*sprice) + } else { + None + } + } else { + None + } + }) + .collect(); + let orderer: Vec<(T::AuthorityId, u128)> = v_price + .iter() + .filter_map(|item| { + let mut orderer = None; + let _: Vec<_> = head_data + .iter() + .filter_map(|event| { + if let polakdot_runtime::RuntimeEvent::Balances( + runtime_types::pallet_balances::pallet::Event::Withdraw { + who: ref order, + amount: eprice, + }, + ) = event.event + { + if eprice == *item { + orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { + Ok(order) => Some((order, eprice)), + Err(_) => None, + }; + Some(()) + } else { + None + } + } else { + None + } + }) + .collect(); + orderer + }) + .collect(); + if orderer.len() > 0 { + Some(orderer[0].clone()) + } else { + None + } + } - // /// Check whether the account is in the validation of relaychain. - // /// - // /// Parameters: - // /// - `relay_storage_proof`: The proof of relay chain storage. - // /// - `validation_data`: The validation data. - // /// - `author_pub`: Account. - // /// - `para_id`: ID of parachain. - // fn check_order_proof( - // relay_storage_proof: sp_trie::StorageProof, - // validation_data: PersistedValidationData, - // author_pub: Option, - // para_id: ParaId, - // ) -> Option<(T::AuthorityId, Balance)> { - // let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); - // match op_author { - // Some((author, spot_price)) => { - // if author_pub == Some(author.clone()) { - // Some((author, spot_price)) - // } else { - // None - // } - // }, - // None => None, - // } - // } + /// Check whether the account is in the validation of relaychain. + /// + /// Parameters: + /// - `relay_storage_proof`: The proof of relay chain storage. + /// - `validation_data`: The validation data. + /// - `author_pub`: Account. + /// - `para_id`: ID of parachain. + fn check_order_proof( + relay_storage_proof: sp_trie::StorageProof, + validation_data: PersistedValidationData, + author_pub: Option, + para_id: ParaId, + ) -> Option<(T::AuthorityId, Balance)> { + let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); + match op_author { + Some((author, spot_price)) => { + if author_pub == Some(author.clone()) { + Some((author, spot_price)) + } else { + None + } + }, + None => None, + } + } - // /// Check whether there is an order event in the validation of relaychain. - // /// - // /// Parameters: - // /// - `relay_storage_proof`: The proof of relay chain storage. - // /// - `validation_data`: The validation data. - // /// - `para_id`: ID of parachain. - // pub fn order_placed( - // relay_storage_proof: sp_trie::StorageProof, - // validation_data: PersistedValidationData, - // para_id: ParaId, - // ) -> Option { - // let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); - // match op_author { - // Some((author, _)) => Some(author), - // None => None, - // } - // } + /// Check whether there is an order event in the validation of relaychain. + /// + /// Parameters: + /// - `relay_storage_proof`: The proof of relay chain storage. + /// - `validation_data`: The validation data. + /// - `para_id`: ID of parachain. + pub fn order_placed( + relay_storage_proof: sp_trie::StorageProof, + validation_data: PersistedValidationData, + para_id: ParaId, + ) -> Option { + let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); + match op_author { + Some((author, _)) => Some(author), + None => None, + } + } - // /// Whether the gas threshold for placing an order has been reached. - // /// - // /// Parameters: - // /// - `gas_balance`: The total gas. - // pub fn reach_txpool_threshold(gas_balance: BalanceOf) -> bool { - // let txpool_threshold = TxPoolThreshold::::get(); - // gas_balance > txpool_threshold - // } + /// Whether the gas threshold for placing an order has been reached. + /// + /// Parameters: + /// - `gas_balance`: The total gas. + pub fn reach_txpool_threshold(gas_balance: BalanceOf) -> bool { + let txpool_threshold = TxPoolThreshold::::get(); + gas_balance > txpool_threshold + } - // /// Whether the order with the specified sequence number is executed. - // /// - // /// Parameters: - // /// - `sequence_number`: The sequence number. - // pub fn order_executed(sequence_number: u64) -> bool { - // let order_map = OrderMap::::get(sequence_number); - // match order_map { - // Some(order) => order.executed, - // None => false, - // } - // } + /// Whether the order with the specified sequence number is executed. + /// + /// Parameters: + /// - `sequence_number`: The sequence number. + pub fn order_executed(sequence_number: u64) -> bool { + let order_map = OrderMap::::get(sequence_number); + match order_map { + Some(order) => order.executed, + None => false, + } + } } pub trait OrderGasCost { diff --git a/runtime/Cargo.toml b/runtime/Cargo.toml index 4df2a13..06b0205 100644 --- a/runtime/Cargo.toml +++ b/runtime/Cargo.toml @@ -32,8 +32,9 @@ pallet-pot-runtime-api = { path = "../pallets/pot/runtime-api", default-features pallet-assurance = { path = "../pallets/assurance", default-features = false } pallet-liquidation = {path = "../pallets/liquidation", default-features = false} pallet-bulk = { path = "../pallets/bulk", default-features = false } +pallet-on-demand = { path = "../pallets/on-demand", default-features = false } mp-coretime-bulk = { path = "../primitives/coretime/bulk", default-features = false } - +mp-coretime-on-demand = { path = "../primitives/coretime/on-demand", default-features = false } # Substrate frame-benchmarking = { workspace = true, default-features = false, optional = true} @@ -214,6 +215,8 @@ std = [ "pallet-move/std", "pallet-bulk/std", "mp-coretime-bulk/std", + "pallet-on-demand/std", + "mp-coretime-on-demand/std", ] runtime-benchmarks = [ diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index e8859a0..a6d867b 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -91,7 +91,7 @@ use weights::{BlockExecutionWeight, ExtrinsicBaseWeight}; // XCM Imports use cumulus_primitives_core::{AggregateMessageOrigin, ParaId, PersistedValidationData}; pub use pallet_bulk::{self, BulkGasCost}; -// pub use pallet_order::{self, OrderGasCost}; +pub use pallet_on_demand::{self, OrderGasCost}; use xcm::latest::prelude::{ Asset as MultiAsset, BodyId, InteriorLocation as InteriorMultiLocation, Junction::PalletInstance, Location as MultiLocation, @@ -700,56 +700,56 @@ impl pallet_collator_selection::Config for Runtime { type WeightInfo = (); } -// pub struct OrderGasCostHandler(); - -// impl OrderGasCost for OrderGasCostHandler -// where -// T: pallet_order::Config, -// T::AccountId: From<[u8; 32]>, -// { -// fn gas_cost( -// block_number: BlockNumberFor, -// ) -> Result, sp_runtime::DispatchError> { -// let sequece_number = >::block_2_sequence(block_number); -// if sequece_number.is_none() { -// return Ok(None); -// } -// let order = >::order_map( -// sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, -// ) -// .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; -// let mut r = [0u8; 32]; -// r.copy_from_slice(order.orderer.encode().as_slice()); -// let account = T::AccountId::try_from(r) -// .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; -// Ok(Some((account, order.price))) -// } -// } - -// parameter_types! { -// pub const SlotWidth: u32 = 2; -// pub const OrderMaxAmount:Balance = 200000000; -// pub const TxPoolThreshold:Balance = 3000000000; -// } +pub struct OrderGasCostHandler(); + +impl OrderGasCost for OrderGasCostHandler +where + T: pallet_on_demand::Config, + T::AccountId: From<[u8; 32]>, +{ + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError> { + let sequece_number = >::block_2_sequence(block_number); + if sequece_number.is_none() { + return Ok(None); + } + let order = >::order_map( + sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, + ) + .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; + let mut r = [0u8; 32]; + r.copy_from_slice(order.orderer.encode().as_slice()); + let account = T::AccountId::try_from(r) + .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; + Ok(Some((account, order.price))) + } +} + +parameter_types! { + pub const SlotWidth: u32 = 2; + pub const OrderMaxAmount:Balance = 200000000; + pub const TxPoolThreshold:Balance = 3000000000; +} type EnsureRootOrHalf = EitherOfDiverse< EnsureRoot, pallet_collective::EnsureProportionMoreThan, >; -// impl pallet_order::Config for Runtime { -// type RuntimeEvent = RuntimeEvent; -// type AuthorityId = AuraId; -// type Currency = Balances; -// type UpdateOrigin = EnsureRootOrHalf; -// type OrderMaxAmount = OrderMaxAmount; -// type SlotWidth = SlotWidth; -// type TxPoolThreshold = TxPoolThreshold; -// type WeightInfo = pallet_order::weights::SubstrateWeight; -// } -pub struct OrderGasCostHandler(); +impl pallet_on_demand::Config for Runtime { + type RuntimeEvent = RuntimeEvent; + type AuthorityId = AuraId; + type Currency = Balances; + type UpdateOrigin = EnsureRootOrHalf; + type OrderMaxAmount = OrderMaxAmount; + type SlotWidth = SlotWidth; + type TxPoolThreshold = TxPoolThreshold; + type WeightInfo = pallet_on_demand::weights::SubstrateWeight; +} +pub struct BulkGasCostHandler(); -impl BulkGasCost for OrderGasCostHandler +impl BulkGasCost for BulkGasCostHandler where T: pallet_bulk::Config, T::AccountId: From<[u8; 32]>, @@ -1232,7 +1232,7 @@ construct_runtime!( HotfixSufficients: pallet_hotfix_sufficients = 45, //Magnet - // OrderPallet: pallet_order = 51, + OrderPallet: pallet_on_demand = 51, EVMUtils: pallet_evm_utils = 60, Pot: pallet_pot = 61, Assurance: pallet_assurance = 62, @@ -1616,39 +1616,39 @@ impl_runtime_apis! { ConsensusHook::can_build_upon(included_hash, slot) } } - // impl magnet_primitives_order::OrderRuntimeApi for Runtime { - - // fn slot_width()-> u32{ - // OrderPallet::slot_width() - // } - // fn order_max_amount() -> Balance { - // OrderPallet::order_max_amount() - // } - // fn sequence_number()-> u64 { - // OrderPallet::sequence_number() - // } - - // fn current_relay_height()-> u32 { - // OrderPallet::current_relay_height() - // } - - // fn order_placed( - // relay_storage_proof: sp_trie::StorageProof, - // validation_data: PersistedValidationData, - // para_id:ParaId, - // )-> Option { - // OrderPallet::order_placed(relay_storage_proof, validation_data, para_id) - // } - - // fn reach_txpool_threshold(gas_balance:Balance) -> bool { - // OrderPallet::reach_txpool_threshold(gas_balance) - // } - - - // fn order_executed(sequence_number:u64) -> bool { - // OrderPallet::order_executed(sequence_number) - // } - // } + impl mp_coretime_on_demand::OrderRuntimeApi for Runtime { + + fn slot_width()-> u32{ + OrderPallet::slot_width() + } + fn order_max_amount() -> Balance { + OrderPallet::order_max_amount() + } + fn sequence_number()-> u64 { + OrderPallet::sequence_number() + } + + fn current_relay_height()-> u32 { + OrderPallet::current_relay_height() + } + + fn order_placed( + relay_storage_proof: sp_trie::StorageProof, + validation_data: PersistedValidationData, + para_id:ParaId, + )-> Option { + OrderPallet::order_placed(relay_storage_proof, validation_data, para_id) + } + + fn reach_txpool_threshold(gas_balance:Balance) -> bool { + OrderPallet::reach_txpool_threshold(gas_balance) + } + + + fn order_executed(sequence_number:u64) -> bool { + OrderPallet::order_executed(sequence_number) + } + } impl mp_coretime_bulk::BulkRuntimeApi for Runtime { fn rpc_url()-> Vec{ From 701e869fa879554a6aec61d19b57fe39769f828b Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Thu, 4 Jul 2024 11:24:12 +0800 Subject: [PATCH 23/44] remove on demand client useless metadata of relaychain --- client/coretime/on-demand/src/lib.rs | 4 +- client/coretime/on-demand/src/metadata.rs | 52742 +--------------- client/coretime/on-demand/src/submit_order.rs | 6 +- 3 files changed, 203 insertions(+), 52549 deletions(-) diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index 2a72baf..63dccc7 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -31,8 +31,7 @@ use cumulus_primitives_core::{ }; use cumulus_relay_chain_interface::{RelayChainInterface, RelayChainResult}; use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; -use metadata::api::runtime_types::pallet_broker::coretime_interface::CoreAssignment; -use metadata::api::runtime_types::polkadot_runtime_parachains::assigner_coretime::CoreDescriptor; +use metadata::{CoreAssignment, CoreDescriptor}; use mp_coretime_common::well_known_keys::paras_para_lifecycles; use mp_coretime_on_demand::{ self, @@ -50,7 +49,6 @@ use sc_transaction_pool_api::{InPoolTransaction, MaintainedTransactionPool}; use sp_api::ProvideRuntimeApi; use sp_application_crypto::AppPublic; use sp_consensus_aura::AuraApi; -use sp_core::ByteArray; use sp_core::{crypto::Pair, H256}; use sp_keystore::KeystorePtr; use sp_runtime::{ diff --git a/client/coretime/on-demand/src/metadata.rs b/client/coretime/on-demand/src/metadata.rs index a6a2f35..78e6d44 100644 --- a/client/coretime/on-demand/src/metadata.rs +++ b/client/coretime/on-demand/src/metadata.rs @@ -1,52544 +1,202 @@ -#[allow(dead_code, unused_imports, non_camel_case_types)] -#[allow(clippy::all)] -#[allow(rustdoc::broken_intra_doc_links)] -pub mod api { - #[allow(unused_imports)] - mod root_mod { - pub use super::*; - } - pub static PALLETS: [&str; 67usize] = [ - "System", - "Babe", - "Timestamp", - "Indices", - "Balances", - "TransactionPayment", - "Authorship", - "Offences", - "Historical", - "Session", - "Grandpa", - "AuthorityDiscovery", - "Treasury", - "ConvictionVoting", - "Referenda", - "FellowshipCollective", - "FellowshipReferenda", - "Origins", - "Whitelist", - "Claims", - "Utility", - "Identity", - "Society", - "Recovery", - "Vesting", - "Scheduler", - "Proxy", - "Multisig", - "Preimage", - "AssetRate", - "Bounties", - "ChildBounties", - "Nis", - "NisCounterpartBalances", - "ParachainsOrigin", - "Configuration", - "ParasShared", - "ParaInclusion", - "ParaInherent", - "ParaScheduler", - "Paras", - "Initializer", - "Dmp", - "Hrmp", - "ParaSessionInfo", - "ParasDisputes", - "ParasSlashing", - "MessageQueue", +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! Relaychain runtime metadata. +//! +//! The data type here is generated by the subxt tool and represents the related data type of the relaychain. +//! + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, + Eq, + PartialEq, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub enum CoreAssignment { + #[codec(index = 0)] + Idle, + #[codec(index = 1)] + Pool, + #[codec(index = 2)] + Task(u32), +} + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct QueueDescriptor<_0> { + pub first: _0, + pub last: _0, +} +#[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct PartsOf57600(pub u16); +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct AssignmentState { + pub ratio: PartsOf57600, + pub remaining: PartsOf57600, +} + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct WorkState<_0> { + pub assignments: Vec<(CoreAssignment, AssignmentState)>, + pub end_hint: Option<_0>, + pub pos: u16, + pub step: PartsOf57600, +} +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct CoreDescriptor<_0> { + pub queue: Option>, + pub current_work: Option>, +} + +#[derive( + :: subxt :: ext :: codec :: CompactAs, + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct Id(pub u32); + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct PlaceOrderAllowDeath { + pub max_amount: u128, + pub para_id: Id, +} + + +impl ::subxt::blocks::StaticExtrinsic for PlaceOrderAllowDeath { + const PALLET: &'static str = "OnDemandAssignmentProvider"; + const CALL: &'static str = "place_order_allow_death"; +} + +pub fn place_order_allow_death( + max_amount: u128, + para_id: Id, +) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( + "OnDemandAssignmentProvider", + "place_order_allow_death", + PlaceOrderAllowDeath { max_amount, para_id }, + [ + 42u8, 115u8, 192u8, 118u8, 20u8, 174u8, 114u8, 94u8, 177u8, 195u8, 175u8, 214u8, 175u8, + 25u8, 167u8, 135u8, 194u8, 251u8, 186u8, 185u8, 218u8, 153u8, 182u8, 166u8, 28u8, + 238u8, 72u8, 64u8, 115u8, 67u8, 58u8, 165u8, + ], + ) +} + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct PlaceOrderKeepAlive { + pub max_amount: u128, + pub para_id: Id, +} + + +impl ::subxt::blocks::StaticExtrinsic for PlaceOrderKeepAlive { + const PALLET: &'static str = "OnDemandAssignmentProvider"; + const CALL: &'static str = "place_order_keep_alive"; +} + + +#[warn(dead_code)] +pub fn place_order_keep_alive( + max_amount: u128, + para_id: Id, +) -> ::subxt::tx::Payload { + ::subxt::tx::Payload::new_static( "OnDemandAssignmentProvider", - "ParachainsAssignmentProvider", - "CoretimeAssignmentProvider", - "Registrar", - "Slots", - "Auctions", - "Crowdloan", - "Coretime", - "XcmPallet", - "Beefy", - "Mmr", - "MmrLeaf", - "IdentityMigrator", - "ParasSudoWrapper", - "AssignedSlots", - "ValidatorManager", - "StateTrieMigration", - "RootTesting", - "Sudo", - ]; - pub static RUNTIME_APIS: [&str; 16usize] = [ - "Core", - "Metadata", - "BlockBuilder", - "TaggedTransactionQueue", - "OffchainWorkerApi", - "ParachainHost", - "BeefyApi", - "MmrApi", - "GrandpaApi", - "BabeApi", - "AuthorityDiscoveryApi", - "SessionKeys", - "AccountNonceApi", - "TransactionPaymentApi", - "BeefyMmrApi", - "GenesisBuilder", - ]; - #[doc = r" The error type returned when there is a runtime issue."] - pub type DispatchError = runtime_types::sp_runtime::DispatchError; - #[doc = r" The outer event enum."] - pub type Event = runtime_types::rococo_runtime::RuntimeEvent; - #[doc = r" The outer extrinsic enum."] - pub type Call = runtime_types::rococo_runtime::RuntimeCall; - #[doc = r" The outer error enum representing the DispatchError's Module variant."] - pub type Error = runtime_types::rococo_runtime::RuntimeError; - pub fn constants() -> ConstantsApi { - ConstantsApi - } - pub fn storage() -> StorageApi { - StorageApi - } - pub fn tx() -> TransactionApi { - TransactionApi - } - pub fn apis() -> runtime_apis::RuntimeApi { - runtime_apis::RuntimeApi - } - pub mod runtime_apis { - use super::root_mod; - use super::runtime_types; - use subxt::ext::codec::Encode; - pub struct RuntimeApi; - impl RuntimeApi { - pub fn core(&self) -> core::Core { - core::Core - } - pub fn metadata(&self) -> metadata::Metadata { - metadata::Metadata - } - pub fn block_builder(&self) -> block_builder::BlockBuilder { - block_builder::BlockBuilder - } - pub fn tagged_transaction_queue( - &self, - ) -> tagged_transaction_queue::TaggedTransactionQueue { - tagged_transaction_queue::TaggedTransactionQueue - } - pub fn offchain_worker_api(&self) -> offchain_worker_api::OffchainWorkerApi { - offchain_worker_api::OffchainWorkerApi - } - pub fn parachain_host(&self) -> parachain_host::ParachainHost { - parachain_host::ParachainHost - } - pub fn beefy_api(&self) -> beefy_api::BeefyApi { - beefy_api::BeefyApi - } - pub fn mmr_api(&self) -> mmr_api::MmrApi { - mmr_api::MmrApi - } - pub fn grandpa_api(&self) -> grandpa_api::GrandpaApi { - grandpa_api::GrandpaApi - } - pub fn babe_api(&self) -> babe_api::BabeApi { - babe_api::BabeApi - } - pub fn authority_discovery_api( - &self, - ) -> authority_discovery_api::AuthorityDiscoveryApi { - authority_discovery_api::AuthorityDiscoveryApi - } - pub fn session_keys(&self) -> session_keys::SessionKeys { - session_keys::SessionKeys - } - pub fn account_nonce_api(&self) -> account_nonce_api::AccountNonceApi { - account_nonce_api::AccountNonceApi - } - pub fn transaction_payment_api( - &self, - ) -> transaction_payment_api::TransactionPaymentApi { - transaction_payment_api::TransactionPaymentApi - } - pub fn beefy_mmr_api(&self) -> beefy_mmr_api::BeefyMmrApi { - beefy_mmr_api::BeefyMmrApi - } - pub fn genesis_builder(&self) -> genesis_builder::GenesisBuilder { - genesis_builder::GenesisBuilder - } - } - pub mod core { - use super::root_mod; - use super::runtime_types; - #[doc = " The `Core` runtime api that every Substrate runtime needs to implement."] - pub struct Core; - impl Core { - #[doc = " Returns the version of the runtime."] - pub fn version( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Version, - runtime_types::sp_version::RuntimeVersion, - > { - ::subxt::runtime_api::Payload::new_static( - "Core", - "version", - types::Version {}, - [ - 76u8, 202u8, 17u8, 117u8, 189u8, 237u8, 239u8, 237u8, 151u8, 17u8, - 125u8, 159u8, 218u8, 92u8, 57u8, 238u8, 64u8, 147u8, 40u8, 72u8, 157u8, - 116u8, 37u8, 195u8, 156u8, 27u8, 123u8, 173u8, 178u8, 102u8, 136u8, - 6u8, - ], - ) - } - #[doc = " Execute the given block."] - pub fn execute_block( - &self, - block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > >, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "Core", - "execute_block", - types::ExecuteBlock { block }, - [ - 133u8, 135u8, 228u8, 65u8, 106u8, 27u8, 85u8, 158u8, 112u8, 254u8, - 93u8, 26u8, 102u8, 201u8, 118u8, 216u8, 249u8, 247u8, 91u8, 74u8, 56u8, - 208u8, 231u8, 115u8, 131u8, 29u8, 209u8, 6u8, 65u8, 57u8, 214u8, 125u8, - ], - ) - } - #[doc = " Initialize a block with the given header."] - pub fn initialize_block( - &self, - header: runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "Core", - "initialize_block", - types::InitializeBlock { header }, - [ - 146u8, 138u8, 72u8, 240u8, 63u8, 96u8, 110u8, 189u8, 77u8, 92u8, 96u8, - 232u8, 41u8, 217u8, 105u8, 148u8, 83u8, 190u8, 152u8, 219u8, 19u8, - 87u8, 163u8, 1u8, 232u8, 25u8, 221u8, 74u8, 224u8, 67u8, 223u8, 34u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Version {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExecuteBlock { pub block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InitializeBlock { - pub header: - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - } - } - } - pub mod metadata { - use super::root_mod; - use super::runtime_types; - #[doc = " The `Metadata` api trait that returns metadata for the runtime."] - pub struct Metadata; - impl Metadata { - #[doc = " Returns the metadata of a runtime."] - pub fn metadata( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Metadata, - runtime_types::sp_core::OpaqueMetadata, - > { - ::subxt::runtime_api::Payload::new_static( - "Metadata", - "metadata", - types::Metadata {}, - [ - 231u8, 24u8, 67u8, 152u8, 23u8, 26u8, 188u8, 82u8, 229u8, 6u8, 185u8, - 27u8, 175u8, 68u8, 83u8, 122u8, 69u8, 89u8, 185u8, 74u8, 248u8, 87u8, - 217u8, 124u8, 193u8, 252u8, 199u8, 186u8, 196u8, 179u8, 179u8, 96u8, - ], - ) - } - #[doc = " Returns the metadata at a given version."] - #[doc = ""] - #[doc = " If the given `version` isn't supported, this will return `None`."] - #[doc = " Use [`Self::metadata_versions`] to find out about supported metadata version of the runtime."] - pub fn metadata_at_version( - &self, - version: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::MetadataAtVersion, - ::core::option::Option, - > { - ::subxt::runtime_api::Payload::new_static( - "Metadata", - "metadata_at_version", - types::MetadataAtVersion { version }, - [ - 131u8, 53u8, 212u8, 234u8, 16u8, 25u8, 120u8, 252u8, 153u8, 153u8, - 216u8, 28u8, 54u8, 113u8, 52u8, 236u8, 146u8, 68u8, 142u8, 8u8, 10u8, - 169u8, 131u8, 142u8, 204u8, 38u8, 48u8, 108u8, 134u8, 86u8, 226u8, - 61u8, - ], - ) - } - #[doc = " Returns the supported metadata versions."] - #[doc = ""] - #[doc = " This can be used to call `metadata_at_version`."] - pub fn metadata_versions( - &self, - ) -> ::subxt::runtime_api::Payload< - types::MetadataVersions, - ::std::vec::Vec<::core::primitive::u32>, - > { - ::subxt::runtime_api::Payload::new_static( - "Metadata", - "metadata_versions", - types::MetadataVersions {}, - [ - 23u8, 144u8, 137u8, 91u8, 188u8, 39u8, 231u8, 208u8, 252u8, 218u8, - 224u8, 176u8, 77u8, 32u8, 130u8, 212u8, 223u8, 76u8, 100u8, 190u8, - 82u8, 94u8, 190u8, 8u8, 82u8, 244u8, 225u8, 179u8, 85u8, 176u8, 56u8, - 16u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Metadata {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MetadataAtVersion { - pub version: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MetadataVersions {} - } - } - pub mod block_builder { - use super::root_mod; - use super::runtime_types; - #[doc = " The `BlockBuilder` api trait that provides the required functionality for building a block."] - pub struct BlockBuilder; - impl BlockBuilder { - #[doc = " Apply the given extrinsic."] - #[doc = ""] - #[doc = " Returns an inclusion outcome which specifies if this extrinsic is included in"] - #[doc = " this block or not."] - pub fn apply_extrinsic( - &self, - extrinsic : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, - ) -> ::subxt::runtime_api::Payload< - types::ApplyExtrinsic, - ::core::result::Result< - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - runtime_types::sp_runtime::transaction_validity::TransactionValidityError, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "BlockBuilder", - "apply_extrinsic", - types::ApplyExtrinsic { extrinsic }, - [ - 72u8, 54u8, 139u8, 3u8, 118u8, 136u8, 65u8, 47u8, 6u8, 105u8, 125u8, - 223u8, 160u8, 29u8, 103u8, 74u8, 79u8, 149u8, 48u8, 90u8, 237u8, 2u8, - 97u8, 201u8, 123u8, 34u8, 167u8, 37u8, 187u8, 35u8, 176u8, 97u8, - ], - ) - } - #[doc = " Finish the current block."] - pub fn finalize_block( - &self, - ) -> ::subxt::runtime_api::Payload< - types::FinalizeBlock, - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - > { - ::subxt::runtime_api::Payload::new_static( - "BlockBuilder", - "finalize_block", - types::FinalizeBlock {}, - [ - 244u8, 207u8, 24u8, 33u8, 13u8, 69u8, 9u8, 249u8, 145u8, 143u8, 122u8, - 96u8, 197u8, 55u8, 64u8, 111u8, 238u8, 224u8, 34u8, 201u8, 27u8, 146u8, - 232u8, 99u8, 191u8, 30u8, 114u8, 16u8, 32u8, 220u8, 58u8, 62u8, - ], - ) - } - #[doc = " Generate inherent extrinsics. The inherent data will vary from chain to chain."] pub fn inherent_extrinsics (& self , inherent : runtime_types :: sp_inherents :: InherentData ,) -> :: subxt :: runtime_api :: Payload < types :: InherentExtrinsics , :: std :: vec :: Vec < :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > >{ - ::subxt::runtime_api::Payload::new_static( - "BlockBuilder", - "inherent_extrinsics", - types::InherentExtrinsics { inherent }, - [ - 254u8, 110u8, 245u8, 201u8, 250u8, 192u8, 27u8, 228u8, 151u8, 213u8, - 166u8, 89u8, 94u8, 81u8, 189u8, 234u8, 64u8, 18u8, 245u8, 80u8, 29u8, - 18u8, 140u8, 129u8, 113u8, 236u8, 135u8, 55u8, 79u8, 159u8, 175u8, - 183u8, - ], - ) - } - #[doc = " Check that the inherents are valid. The inherent data will vary from chain to chain."] - pub fn check_inherents( - &self, - block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > >, - data: runtime_types::sp_inherents::InherentData, - ) -> ::subxt::runtime_api::Payload< - types::CheckInherents, - runtime_types::sp_inherents::CheckInherentsResult, - > { - ::subxt::runtime_api::Payload::new_static( - "BlockBuilder", - "check_inherents", - types::CheckInherents { block, data }, - [ - 153u8, 134u8, 1u8, 215u8, 139u8, 11u8, 53u8, 51u8, 210u8, 175u8, 197u8, - 28u8, 38u8, 209u8, 175u8, 247u8, 142u8, 157u8, 50u8, 151u8, 164u8, - 191u8, 181u8, 118u8, 80u8, 97u8, 160u8, 248u8, 110u8, 217u8, 181u8, - 234u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApplyExtrinsic { pub extrinsic : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FinalizeBlock {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InherentExtrinsics { - pub inherent: runtime_types::sp_inherents::InherentData, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckInherents { pub block : runtime_types :: sp_runtime :: generic :: block :: Block < runtime_types :: sp_runtime :: generic :: header :: Header < :: core :: primitive :: u32 > , :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > > , pub data : runtime_types :: sp_inherents :: InherentData , } - } - } - pub mod tagged_transaction_queue { - use super::root_mod; - use super::runtime_types; - #[doc = " The `TaggedTransactionQueue` api trait for interfering with the transaction queue."] - pub struct TaggedTransactionQueue; - impl TaggedTransactionQueue { - #[doc = " Validate the transaction."] - #[doc = ""] - #[doc = " This method is invoked by the transaction pool to learn details about given transaction."] - #[doc = " The implementation should make sure to verify the correctness of the transaction"] - #[doc = " against current state. The given `block_hash` corresponds to the hash of the block"] - #[doc = " that is used as current state."] - #[doc = ""] - #[doc = " Note that this call may be performed by the pool multiple times and transactions"] - #[doc = " might be verified in any possible order."] - pub fn validate_transaction( - &self, - source: runtime_types::sp_runtime::transaction_validity::TransactionSource, - tx : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, - block_hash: ::subxt::utils::H256, - ) -> ::subxt::runtime_api::Payload< - types::ValidateTransaction, - ::core::result::Result< - runtime_types::sp_runtime::transaction_validity::ValidTransaction, - runtime_types::sp_runtime::transaction_validity::TransactionValidityError, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "TaggedTransactionQueue", - "validate_transaction", - types::ValidateTransaction { source, tx, block_hash }, - [ - 196u8, 50u8, 90u8, 49u8, 109u8, 251u8, 200u8, 35u8, 23u8, 150u8, 140u8, - 143u8, 232u8, 164u8, 133u8, 89u8, 32u8, 240u8, 115u8, 39u8, 95u8, 70u8, - 162u8, 76u8, 122u8, 73u8, 151u8, 144u8, 234u8, 120u8, 100u8, 29u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidateTransaction { pub source : runtime_types :: sp_runtime :: transaction_validity :: TransactionSource , pub tx : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub block_hash : :: subxt :: utils :: H256 , } - } - } - pub mod offchain_worker_api { - use super::root_mod; - use super::runtime_types; - #[doc = " The offchain worker api."] - pub struct OffchainWorkerApi; - impl OffchainWorkerApi { - #[doc = " Starts the off-chain task for given block header."] - pub fn offchain_worker( - &self, - header: runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "OffchainWorkerApi", - "offchain_worker", - types::OffchainWorker { header }, - [ - 10u8, 135u8, 19u8, 153u8, 33u8, 216u8, 18u8, 242u8, 33u8, 140u8, 4u8, - 223u8, 200u8, 130u8, 103u8, 118u8, 137u8, 24u8, 19u8, 127u8, 161u8, - 29u8, 184u8, 111u8, 222u8, 111u8, 253u8, 73u8, 45u8, 31u8, 79u8, 60u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OffchainWorker { - pub header: - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - } - } - } - pub mod parachain_host { - use super::root_mod; - use super::runtime_types; - #[doc = " The API for querying the state of parachains on-chain."] - pub struct ParachainHost; - impl ParachainHost { - #[doc = " Get the current validators."] - pub fn validators( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Validators, - ::std::vec::Vec, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "validators", - types::Validators {}, - [ - 56u8, 64u8, 189u8, 234u8, 85u8, 75u8, 2u8, 212u8, 192u8, 95u8, 230u8, - 201u8, 98u8, 220u8, 78u8, 20u8, 101u8, 16u8, 153u8, 192u8, 133u8, - 179u8, 217u8, 98u8, 247u8, 143u8, 104u8, 147u8, 47u8, 255u8, 111u8, - 72u8, - ], - ) - } - #[doc = " Returns the validator groups and rotation info localized based on the hypothetical child"] - #[doc = " of a block whose state this is invoked on. Note that `now` in the `GroupRotationInfo`"] - #[doc = " should be the successor of the number of the block."] - pub fn validator_groups( - &self, - ) -> ::subxt::runtime_api::Payload< - types::ValidatorGroups, - ( - ::std::vec::Vec< - ::std::vec::Vec, - >, - runtime_types::polkadot_primitives::v6::GroupRotationInfo< - ::core::primitive::u32, - >, - ), - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "validator_groups", - types::ValidatorGroups {}, - [ - 89u8, 221u8, 163u8, 73u8, 194u8, 196u8, 136u8, 242u8, 249u8, 182u8, - 239u8, 251u8, 157u8, 211u8, 41u8, 58u8, 242u8, 242u8, 177u8, 145u8, - 107u8, 167u8, 193u8, 204u8, 226u8, 228u8, 82u8, 249u8, 187u8, 211u8, - 37u8, 124u8, - ], - ) - } - #[doc = " Yields information on all availability cores as relevant to the child block."] - #[doc = " Cores are either free or occupied. Free cores can have paras assigned to them."] - pub fn availability_cores( - &self, - ) -> ::subxt::runtime_api::Payload< - types::AvailabilityCores, - ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::CoreState< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "availability_cores", - types::AvailabilityCores {}, - [ - 238u8, 20u8, 188u8, 206u8, 26u8, 17u8, 72u8, 123u8, 33u8, 54u8, 66u8, - 13u8, 244u8, 246u8, 228u8, 177u8, 176u8, 251u8, 82u8, 12u8, 170u8, - 29u8, 39u8, 158u8, 16u8, 23u8, 253u8, 169u8, 117u8, 12u8, 0u8, 65u8, - ], - ) - } - #[doc = " Yields the persisted validation data for the given `ParaId` along with an assumption that"] - #[doc = " should be used if the para currently occupies a core."] - #[doc = ""] - #[doc = " Returns `None` if either the para is not registered or the assumption is `Freed`"] - #[doc = " and the para already occupies a core."] - pub fn persisted_validation_data( - &self, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - assumption: runtime_types::polkadot_primitives::v6::OccupiedCoreAssumption, - ) -> ::subxt::runtime_api::Payload< - types::PersistedValidationData, - ::core::option::Option< - runtime_types::polkadot_primitives::v6::PersistedValidationData< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "persisted_validation_data", - types::PersistedValidationData { para_id, assumption }, - [ - 119u8, 217u8, 57u8, 241u8, 70u8, 56u8, 102u8, 20u8, 98u8, 60u8, 47u8, - 78u8, 124u8, 81u8, 158u8, 254u8, 30u8, 14u8, 223u8, 195u8, 95u8, 179u8, - 228u8, 53u8, 149u8, 224u8, 62u8, 8u8, 27u8, 3u8, 100u8, 37u8, - ], - ) - } - #[doc = " Returns the persisted validation data for the given `ParaId` along with the corresponding"] - #[doc = " validation code hash. Instead of accepting assumption about the para, matches the validation"] - #[doc = " data hash against an expected one and yields `None` if they're not equal."] pub fn assumed_validation_data (& self , para_id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , expected_persisted_validation_data_hash : :: subxt :: utils :: H256 ,) -> :: subxt :: runtime_api :: Payload < types :: AssumedValidationData , :: core :: option :: Option < (runtime_types :: polkadot_primitives :: v6 :: PersistedValidationData < :: subxt :: utils :: H256 , :: core :: primitive :: u32 > , runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash ,) > >{ - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "assumed_validation_data", - types::AssumedValidationData { - para_id, - expected_persisted_validation_data_hash, - }, - [ - 37u8, 162u8, 100u8, 72u8, 19u8, 135u8, 13u8, 211u8, 51u8, 153u8, 201u8, - 97u8, 61u8, 193u8, 167u8, 118u8, 60u8, 242u8, 228u8, 81u8, 165u8, 62u8, - 191u8, 206u8, 157u8, 232u8, 62u8, 55u8, 240u8, 236u8, 76u8, 204u8, - ], - ) - } - #[doc = " Checks if the given validation outputs pass the acceptance criteria."] - pub fn check_validation_outputs( - &self, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - outputs: runtime_types::polkadot_primitives::v6::CandidateCommitments< - ::core::primitive::u32, - >, - ) -> ::subxt::runtime_api::Payload< - types::CheckValidationOutputs, - ::core::primitive::bool, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "check_validation_outputs", - types::CheckValidationOutputs { para_id, outputs }, - [ - 128u8, 33u8, 213u8, 120u8, 39u8, 18u8, 135u8, 248u8, 196u8, 43u8, 0u8, - 143u8, 198u8, 64u8, 93u8, 133u8, 248u8, 206u8, 103u8, 137u8, 168u8, - 255u8, 144u8, 29u8, 121u8, 246u8, 179u8, 187u8, 83u8, 53u8, 142u8, - 82u8, - ], - ) - } - #[doc = " Returns the session index expected at a child of the block."] - #[doc = ""] - #[doc = " This can be used to instantiate a `SigningContext`."] - pub fn session_index_for_child( - &self, - ) -> ::subxt::runtime_api::Payload< - types::SessionIndexForChild, - ::core::primitive::u32, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "session_index_for_child", - types::SessionIndexForChild {}, - [ - 135u8, 9u8, 1u8, 244u8, 174u8, 151u8, 247u8, 75u8, 226u8, 216u8, 53u8, - 78u8, 26u8, 109u8, 44u8, 77u8, 208u8, 151u8, 94u8, 212u8, 115u8, 43u8, - 118u8, 22u8, 140u8, 117u8, 15u8, 224u8, 163u8, 252u8, 90u8, 255u8, - ], - ) - } - #[doc = " Fetch the validation code used by a para, making the given `OccupiedCoreAssumption`."] - #[doc = ""] - #[doc = " Returns `None` if either the para is not registered or the assumption is `Freed`"] - #[doc = " and the para already occupies a core."] - pub fn validation_code( - &self, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - assumption: runtime_types::polkadot_primitives::v6::OccupiedCoreAssumption, - ) -> ::subxt::runtime_api::Payload< - types::ValidationCode, - ::core::option::Option< - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "validation_code", - types::ValidationCode { para_id, assumption }, - [ - 231u8, 15u8, 35u8, 159u8, 96u8, 23u8, 246u8, 125u8, 78u8, 79u8, 158u8, - 116u8, 36u8, 199u8, 53u8, 61u8, 242u8, 136u8, 227u8, 174u8, 136u8, - 71u8, 143u8, 47u8, 216u8, 21u8, 225u8, 117u8, 50u8, 104u8, 161u8, - 232u8, - ], - ) - } - #[doc = " Get the receipt of a candidate pending availability. This returns `Some` for any paras"] - #[doc = " assigned to occupied cores in `availability_cores` and `None` otherwise."] - pub fn candidate_pending_availability( - &self, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::runtime_api::Payload< - types::CandidatePendingAvailability, - ::core::option::Option< - runtime_types::polkadot_primitives::v6::CommittedCandidateReceipt< - ::subxt::utils::H256, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "candidate_pending_availability", - types::CandidatePendingAvailability { para_id }, - [ - 139u8, 185u8, 205u8, 255u8, 131u8, 180u8, 248u8, 168u8, 25u8, 124u8, - 105u8, 141u8, 59u8, 118u8, 109u8, 136u8, 103u8, 200u8, 5u8, 218u8, - 72u8, 55u8, 114u8, 89u8, 207u8, 140u8, 51u8, 86u8, 167u8, 41u8, 221u8, - 86u8, - ], - ) - } - #[doc = " Get a vector of events concerning candidates that occurred within a block."] - pub fn candidate_events( - &self, - ) -> ::subxt::runtime_api::Payload< - types::CandidateEvents, - ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::CandidateEvent< - ::subxt::utils::H256, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "candidate_events", - types::CandidateEvents {}, - [ - 101u8, 145u8, 200u8, 182u8, 213u8, 111u8, 180u8, 73u8, 14u8, 107u8, - 110u8, 145u8, 122u8, 35u8, 223u8, 219u8, 66u8, 101u8, 130u8, 255u8, - 44u8, 46u8, 50u8, 61u8, 104u8, 237u8, 34u8, 16u8, 179u8, 214u8, 115u8, - 7u8, - ], - ) - } - #[doc = " Get all the pending inbound messages in the downward message queue for a para."] - pub fn dmq_contents( - &self, - recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::runtime_api::Payload< - types::DmqContents, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundDownwardMessage< - ::core::primitive::u32, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "dmq_contents", - types::DmqContents { recipient }, - [ - 189u8, 11u8, 38u8, 223u8, 11u8, 108u8, 201u8, 122u8, 207u8, 7u8, 74u8, - 14u8, 247u8, 226u8, 108u8, 21u8, 213u8, 55u8, 8u8, 137u8, 211u8, 98u8, - 19u8, 11u8, 212u8, 218u8, 209u8, 63u8, 51u8, 252u8, 86u8, 53u8, - ], - ) - } - #[doc = " Get the contents of all channels addressed to the given recipient. Channels that have no"] - #[doc = " messages in them are also included."] - pub fn inbound_hrmp_channels_contents( - &self, - recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::runtime_api::Payload< - types::InboundHrmpChannelsContents, - ::subxt::utils::KeyedVec< - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundHrmpMessage< - ::core::primitive::u32, - >, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "inbound_hrmp_channels_contents", - types::InboundHrmpChannelsContents { recipient }, - [ - 132u8, 29u8, 42u8, 39u8, 72u8, 243u8, 110u8, 43u8, 110u8, 9u8, 21u8, - 18u8, 91u8, 40u8, 231u8, 223u8, 239u8, 16u8, 110u8, 54u8, 108u8, 234u8, - 140u8, 205u8, 80u8, 221u8, 115u8, 48u8, 197u8, 248u8, 6u8, 25u8, - ], - ) - } - #[doc = " Get the validation code from its hash."] - pub fn validation_code_by_hash( - &self, - hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash, - ) -> ::subxt::runtime_api::Payload< - types::ValidationCodeByHash, - ::core::option::Option< - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "validation_code_by_hash", - types::ValidationCodeByHash { hash }, - [ - 219u8, 250u8, 130u8, 89u8, 178u8, 234u8, 255u8, 33u8, 90u8, 78u8, 58u8, - 124u8, 141u8, 145u8, 156u8, 81u8, 184u8, 52u8, 65u8, 112u8, 35u8, - 153u8, 222u8, 23u8, 226u8, 53u8, 164u8, 22u8, 236u8, 103u8, 197u8, - 236u8, - ], - ) - } - #[doc = " Scrape dispute relevant from on-chain, backing votes and resolved disputes."] - pub fn on_chain_votes( - &self, - ) -> ::subxt::runtime_api::Payload< - types::OnChainVotes, - ::core::option::Option< - runtime_types::polkadot_primitives::v6::ScrapedOnChainVotes< - ::subxt::utils::H256, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "on_chain_votes", - types::OnChainVotes {}, - [ - 158u8, 98u8, 68u8, 85u8, 65u8, 186u8, 211u8, 5u8, 16u8, 63u8, 34u8, - 85u8, 16u8, 114u8, 115u8, 174u8, 154u8, 127u8, 176u8, 205u8, 12u8, - 231u8, 3u8, 170u8, 102u8, 223u8, 25u8, 130u8, 225u8, 214u8, 98u8, - 255u8, - ], - ) - } - #[doc = " Get the session info for the given session, if stored."] - #[doc = ""] - #[doc = " NOTE: This function is only available since parachain host version 2."] - pub fn session_info( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::SessionInfo, - ::core::option::Option, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "session_info", - types::SessionInfo { index }, - [ - 77u8, 115u8, 39u8, 190u8, 116u8, 250u8, 66u8, 128u8, 168u8, 24u8, - 120u8, 153u8, 111u8, 125u8, 249u8, 115u8, 112u8, 169u8, 208u8, 31u8, - 95u8, 234u8, 14u8, 242u8, 14u8, 190u8, 120u8, 171u8, 202u8, 67u8, 81u8, - 237u8, - ], - ) - } - #[doc = " Submits a PVF pre-checking statement into the transaction pool."] - #[doc = ""] - #[doc = " NOTE: This function is only available since parachain host version 2."] - pub fn submit_pvf_check_statement( - &self, - stmt: runtime_types::polkadot_primitives::v6::PvfCheckStatement, - signature: runtime_types::polkadot_primitives::v6::validator_app::Signature, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "submit_pvf_check_statement", - types::SubmitPvfCheckStatement { stmt, signature }, - [ - 91u8, 138u8, 75u8, 79u8, 171u8, 224u8, 206u8, 152u8, 202u8, 131u8, - 251u8, 200u8, 75u8, 99u8, 49u8, 192u8, 175u8, 212u8, 139u8, 236u8, - 188u8, 243u8, 82u8, 62u8, 190u8, 79u8, 113u8, 23u8, 222u8, 29u8, 255u8, - 196u8, - ], - ) - } - #[doc = " Returns code hashes of PVFs that require pre-checking by validators in the active set."] - #[doc = ""] - #[doc = " NOTE: This function is only available since parachain host version 2."] pub fn pvfs_require_precheck (& self ,) -> :: subxt :: runtime_api :: Payload < types :: PvfsRequirePrecheck , :: std :: vec :: Vec < runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash > >{ - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "pvfs_require_precheck", - types::PvfsRequirePrecheck {}, - [ - 251u8, 162u8, 214u8, 223u8, 70u8, 67u8, 170u8, 19u8, 191u8, 37u8, - 233u8, 249u8, 89u8, 28u8, 76u8, 213u8, 194u8, 28u8, 15u8, 199u8, 167u8, - 23u8, 139u8, 220u8, 218u8, 223u8, 115u8, 4u8, 95u8, 24u8, 32u8, 29u8, - ], - ) - } - #[doc = " Fetch the hash of the validation code used by a para, making the given `OccupiedCoreAssumption`."] - #[doc = ""] - #[doc = " NOTE: This function is only available since parachain host version 2."] pub fn validation_code_hash (& self , para_id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , assumption : runtime_types :: polkadot_primitives :: v6 :: OccupiedCoreAssumption ,) -> :: subxt :: runtime_api :: Payload < types :: ValidationCodeHash , :: core :: option :: Option < runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash > >{ - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "validation_code_hash", - types::ValidationCodeHash { para_id, assumption }, - [ - 226u8, 142u8, 121u8, 182u8, 206u8, 180u8, 8u8, 19u8, 237u8, 84u8, - 121u8, 1u8, 126u8, 211u8, 241u8, 133u8, 195u8, 182u8, 116u8, 128u8, - 58u8, 81u8, 12u8, 68u8, 79u8, 212u8, 108u8, 178u8, 237u8, 25u8, 203u8, - 135u8, - ], - ) - } - #[doc = " Returns all onchain disputes."] - pub fn disputes( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Disputes, - ::std::vec::Vec<( - ::core::primitive::u32, - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_primitives::v6::DisputeState< - ::core::primitive::u32, - >, - )>, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "disputes", - types::Disputes {}, - [ - 183u8, 88u8, 143u8, 44u8, 138u8, 79u8, 65u8, 198u8, 42u8, 109u8, 235u8, - 152u8, 3u8, 13u8, 106u8, 189u8, 197u8, 126u8, 44u8, 161u8, 67u8, 49u8, - 163u8, 193u8, 248u8, 207u8, 1u8, 108u8, 188u8, 152u8, 87u8, 125u8, - ], - ) - } - #[doc = " Returns execution parameters for the session."] - pub fn session_executor_params( - &self, - session_index: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::SessionExecutorParams, - ::core::option::Option< - runtime_types::polkadot_primitives::v6::executor_params::ExecutorParams, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "session_executor_params", - types::SessionExecutorParams { session_index }, - [ - 94u8, 35u8, 29u8, 188u8, 247u8, 116u8, 165u8, 43u8, 248u8, 76u8, 21u8, - 237u8, 26u8, 25u8, 105u8, 27u8, 24u8, 245u8, 97u8, 25u8, 47u8, 118u8, - 98u8, 231u8, 27u8, 76u8, 172u8, 207u8, 90u8, 103u8, 52u8, 168u8, - ], - ) - } - #[doc = " Returns a list of validators that lost a past session dispute and need to be slashed."] - #[doc = " NOTE: This function is only available since parachain host version 5."] - pub fn unapplied_slashes( - &self, - ) -> ::subxt::runtime_api::Payload< - types::UnappliedSlashes, - ::std::vec::Vec<( - ::core::primitive::u32, - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_primitives::v6::slashing::PendingSlashes, - )>, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "unapplied_slashes", - types::UnappliedSlashes {}, - [ - 205u8, 16u8, 246u8, 48u8, 72u8, 160u8, 7u8, 136u8, 225u8, 2u8, 209u8, - 254u8, 255u8, 115u8, 49u8, 214u8, 131u8, 22u8, 210u8, 9u8, 111u8, - 170u8, 109u8, 247u8, 110u8, 42u8, 55u8, 68u8, 85u8, 37u8, 250u8, 4u8, - ], - ) - } - #[doc = " Returns a merkle proof of a validator session key."] - #[doc = " NOTE: This function is only available since parachain host version 5."] - pub fn key_ownership_proof( - &self, - validator_id: runtime_types::polkadot_primitives::v6::validator_app::Public, - ) -> ::subxt::runtime_api::Payload< - types::KeyOwnershipProof, - ::core::option::Option< - runtime_types::polkadot_primitives::v6::slashing::OpaqueKeyOwnershipProof, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "key_ownership_proof", - types::KeyOwnershipProof { validator_id }, - [ - 194u8, 237u8, 59u8, 4u8, 194u8, 235u8, 38u8, 58u8, 58u8, 221u8, 189u8, - 69u8, 254u8, 2u8, 242u8, 200u8, 86u8, 4u8, 138u8, 184u8, 198u8, 58u8, - 200u8, 34u8, 243u8, 91u8, 122u8, 35u8, 18u8, 83u8, 152u8, 191u8, - ], - ) - } - #[doc = " Submit an unsigned extrinsic to slash validators who lost a dispute about"] - #[doc = " a candidate of a past session."] - #[doc = " NOTE: This function is only available since parachain host version 5."] - pub fn submit_report_dispute_lost( - &self, - dispute_proof: runtime_types::polkadot_primitives::v6::slashing::DisputeProof, - key_ownership_proof : runtime_types :: polkadot_primitives :: v6 :: slashing :: OpaqueKeyOwnershipProof, - ) -> ::subxt::runtime_api::Payload< - types::SubmitReportDisputeLost, - ::core::option::Option<()>, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "submit_report_dispute_lost", - types::SubmitReportDisputeLost { dispute_proof, key_ownership_proof }, - [ - 98u8, 63u8, 249u8, 13u8, 163u8, 161u8, 43u8, 96u8, 75u8, 65u8, 3u8, - 116u8, 8u8, 149u8, 122u8, 190u8, 179u8, 108u8, 17u8, 22u8, 59u8, 134u8, - 43u8, 31u8, 13u8, 254u8, 21u8, 112u8, 129u8, 16u8, 5u8, 180u8, - ], - ) - } - #[doc = " Get the minimum number of backing votes for a parachain candidate."] - #[doc = " This is a staging method! Do not use on production runtimes!"] - pub fn minimum_backing_votes( - &self, - ) -> ::subxt::runtime_api::Payload - { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "minimum_backing_votes", - types::MinimumBackingVotes {}, - [ - 222u8, 75u8, 167u8, 245u8, 183u8, 148u8, 14u8, 92u8, 54u8, 164u8, - 239u8, 183u8, 215u8, 170u8, 133u8, 71u8, 19u8, 131u8, 104u8, 28u8, - 219u8, 237u8, 178u8, 34u8, 190u8, 151u8, 48u8, 146u8, 78u8, 17u8, 66u8, - 146u8, - ], - ) - } - #[doc = " Returns the state of parachain backing for a given para."] - pub fn para_backing_state( - &self, - _0: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::runtime_api::Payload< - types::ParaBackingState, - ::core::option::Option< - runtime_types::polkadot_primitives::v6::async_backing::BackingState< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "para_backing_state", - types::ParaBackingState { _0 }, - [ - 26u8, 210u8, 45u8, 233u8, 133u8, 180u8, 12u8, 156u8, 59u8, 249u8, 10u8, - 38u8, 32u8, 28u8, 25u8, 30u8, 83u8, 33u8, 142u8, 21u8, 12u8, 151u8, - 182u8, 128u8, 131u8, 192u8, 240u8, 73u8, 119u8, 64u8, 254u8, 139u8, - ], - ) - } - #[doc = " Returns candidate's acceptance limitations for asynchronous backing for a relay parent."] - pub fn async_backing_params( - &self, - ) -> ::subxt::runtime_api::Payload< - types::AsyncBackingParams, - runtime_types::polkadot_primitives::v6::async_backing::AsyncBackingParams, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "async_backing_params", - types::AsyncBackingParams {}, - [ - 150u8, 157u8, 193u8, 44u8, 160u8, 18u8, 122u8, 188u8, 157u8, 84u8, - 202u8, 253u8, 55u8, 113u8, 188u8, 169u8, 216u8, 250u8, 145u8, 81u8, - 73u8, 194u8, 234u8, 237u8, 101u8, 250u8, 35u8, 52u8, 205u8, 38u8, 22u8, - 238u8, - ], - ) - } - #[doc = " Returns a list of all disabled validators at the given block."] - pub fn disabled_validators( - &self, - ) -> ::subxt::runtime_api::Payload< - types::DisabledValidators, - ::std::vec::Vec, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "disabled_validators", - types::DisabledValidators {}, - [ - 121u8, 124u8, 228u8, 59u8, 10u8, 148u8, 131u8, 130u8, 221u8, 33u8, - 226u8, 13u8, 223u8, 67u8, 145u8, 39u8, 205u8, 237u8, 178u8, 249u8, - 126u8, 152u8, 65u8, 131u8, 111u8, 113u8, 194u8, 111u8, 37u8, 124u8, - 164u8, 212u8, - ], - ) - } - #[doc = " Get node features."] - #[doc = " This is a staging method! Do not use on production runtimes!"] - pub fn node_features( - &self, - ) -> ::subxt::runtime_api::Payload< - types::NodeFeatures, - ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "node_features", - types::NodeFeatures {}, - [ - 94u8, 110u8, 38u8, 62u8, 66u8, 234u8, 216u8, 228u8, 36u8, 17u8, 33u8, - 56u8, 184u8, 122u8, 34u8, 254u8, 46u8, 62u8, 107u8, 227u8, 3u8, 126u8, - 220u8, 142u8, 92u8, 226u8, 123u8, 236u8, 34u8, 234u8, 82u8, 80u8, - ], - ) - } - #[doc = " Approval voting configuration parameters"] - pub fn approval_voting_params( - &self, - ) -> ::subxt::runtime_api::Payload< - types::ApprovalVotingParams, - runtime_types::polkadot_primitives::vstaging::ApprovalVotingParams, - > { - ::subxt::runtime_api::Payload::new_static( - "ParachainHost", - "approval_voting_params", - types::ApprovalVotingParams {}, - [ - 89u8, 130u8, 95u8, 58u8, 124u8, 176u8, 43u8, 109u8, 222u8, 178u8, - 241u8, 177u8, 242u8, 32u8, 84u8, 22u8, 252u8, 178u8, 168u8, 17u8, 38u8, - 249u8, 25u8, 229u8, 75u8, 119u8, 150u8, 112u8, 144u8, 118u8, 189u8, - 253u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Validators {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidatorGroups {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AvailabilityCores {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PersistedValidationData { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub assumption: runtime_types::polkadot_primitives::v6::OccupiedCoreAssumption, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssumedValidationData { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub expected_persisted_validation_data_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckValidationOutputs { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub outputs: runtime_types::polkadot_primitives::v6::CandidateCommitments< - ::core::primitive::u32, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SessionIndexForChild {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidationCode { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub assumption: runtime_types::polkadot_primitives::v6::OccupiedCoreAssumption, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidatePendingAvailability { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidateEvents {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DmqContents { - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InboundHrmpChannelsContents { - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidationCodeByHash { pub hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OnChainVotes {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SessionInfo { - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitPvfCheckStatement { - pub stmt: runtime_types::polkadot_primitives::v6::PvfCheckStatement, - pub signature: runtime_types::polkadot_primitives::v6::validator_app::Signature, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PvfsRequirePrecheck {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidationCodeHash { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub assumption: runtime_types::polkadot_primitives::v6::OccupiedCoreAssumption, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Disputes {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SessionExecutorParams { - pub session_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnappliedSlashes {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KeyOwnershipProof { - pub validator_id: runtime_types::polkadot_primitives::v6::validator_app::Public, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitReportDisputeLost { - pub dispute_proof: - runtime_types::polkadot_primitives::v6::slashing::DisputeProof, - pub key_ownership_proof: - runtime_types::polkadot_primitives::v6::slashing::OpaqueKeyOwnershipProof, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MinimumBackingVotes {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ParaBackingState { - pub _0: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsyncBackingParams {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DisabledValidators {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NodeFeatures {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApprovalVotingParams {} - } - } - pub mod beefy_api { - use super::root_mod; - use super::runtime_types; - #[doc = " API necessary for BEEFY voters."] - pub struct BeefyApi; - impl BeefyApi { - #[doc = " Return the block number where BEEFY consensus is enabled/started"] - pub fn beefy_genesis( - &self, - ) -> ::subxt::runtime_api::Payload< - types::BeefyGenesis, - ::core::option::Option<::core::primitive::u32>, - > { - ::subxt::runtime_api::Payload::new_static( - "BeefyApi", - "beefy_genesis", - types::BeefyGenesis {}, - [ - 246u8, 129u8, 31u8, 77u8, 24u8, 47u8, 5u8, 156u8, 64u8, 222u8, 180u8, - 78u8, 110u8, 77u8, 218u8, 149u8, 210u8, 151u8, 164u8, 220u8, 165u8, - 119u8, 116u8, 220u8, 20u8, 122u8, 37u8, 176u8, 75u8, 218u8, 194u8, - 244u8, - ], - ) - } - #[doc = " Return the current active BEEFY validator set"] - pub fn validator_set( - &self, - ) -> ::subxt::runtime_api::Payload< - types::ValidatorSet, - ::core::option::Option< - runtime_types::sp_consensus_beefy::ValidatorSet< - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - >, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "BeefyApi", - "validator_set", - types::ValidatorSet {}, - [ - 26u8, 174u8, 151u8, 215u8, 199u8, 11u8, 123u8, 18u8, 209u8, 187u8, - 70u8, 245u8, 59u8, 23u8, 11u8, 26u8, 167u8, 202u8, 83u8, 213u8, 99u8, - 74u8, 143u8, 140u8, 34u8, 9u8, 225u8, 217u8, 244u8, 169u8, 30u8, 217u8, - ], - ) - } - #[doc = " Submits an unsigned extrinsic to report an equivocation. The caller"] - #[doc = " must provide the equivocation proof and a key ownership proof"] - #[doc = " (should be obtained using `generate_key_ownership_proof`). The"] - #[doc = " extrinsic will be unsigned and should only be accepted for local"] - #[doc = " authorship (not to be broadcast to the network). This method returns"] - #[doc = " `None` when creation of the extrinsic fails, e.g. if equivocation"] - #[doc = " reporting is disabled for the given runtime (i.e. this method is"] - #[doc = " hardcoded to return `None`). Only useful in an offchain context."] - pub fn submit_report_equivocation_unsigned_extrinsic( - &self, - equivocation_proof: runtime_types::sp_consensus_beefy::EquivocationProof< - ::core::primitive::u32, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Signature, - >, - key_owner_proof: runtime_types::sp_consensus_beefy::OpaqueKeyOwnershipProof, - ) -> ::subxt::runtime_api::Payload< - types::SubmitReportEquivocationUnsignedExtrinsic, - ::core::option::Option<()>, - > { - ::subxt::runtime_api::Payload::new_static( - "BeefyApi", - "submit_report_equivocation_unsigned_extrinsic", - types::SubmitReportEquivocationUnsignedExtrinsic { - equivocation_proof, - key_owner_proof, - }, - [ - 20u8, 162u8, 43u8, 173u8, 248u8, 140u8, 57u8, 151u8, 189u8, 96u8, 68u8, - 130u8, 14u8, 162u8, 230u8, 61u8, 169u8, 189u8, 239u8, 71u8, 121u8, - 137u8, 141u8, 206u8, 91u8, 164u8, 175u8, 93u8, 33u8, 161u8, 166u8, - 192u8, - ], - ) - } - #[doc = " Generates a proof of key ownership for the given authority in the"] - #[doc = " given set. An example usage of this module is coupled with the"] - #[doc = " session historical module to prove that a given authority key is"] - #[doc = " tied to a given staking identity during a specific session. Proofs"] - #[doc = " of key ownership are necessary for submitting equivocation reports."] - #[doc = " NOTE: even though the API takes a `set_id` as parameter the current"] - #[doc = " implementations ignores this parameter and instead relies on this"] - #[doc = " method being called at the correct block height, i.e. any point at"] - #[doc = " which the given set id is live on-chain. Future implementations will"] - #[doc = " instead use indexed data through an offchain worker, not requiring"] - #[doc = " older states to be available."] - pub fn generate_key_ownership_proof( - &self, - set_id: ::core::primitive::u64, - authority_id: runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - ) -> ::subxt::runtime_api::Payload< - types::GenerateKeyOwnershipProof, - ::core::option::Option< - runtime_types::sp_consensus_beefy::OpaqueKeyOwnershipProof, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "BeefyApi", - "generate_key_ownership_proof", - types::GenerateKeyOwnershipProof { set_id, authority_id }, - [ - 244u8, 175u8, 3u8, 235u8, 173u8, 34u8, 210u8, 81u8, 41u8, 5u8, 85u8, - 179u8, 53u8, 153u8, 16u8, 62u8, 103u8, 71u8, 180u8, 11u8, 165u8, 90u8, - 186u8, 156u8, 118u8, 114u8, 22u8, 108u8, 149u8, 9u8, 232u8, 174u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BeefyGenesis {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidatorSet {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitReportEquivocationUnsignedExtrinsic { - pub equivocation_proof: runtime_types::sp_consensus_beefy::EquivocationProof< - ::core::primitive::u32, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Signature, - >, - pub key_owner_proof: runtime_types::sp_consensus_beefy::OpaqueKeyOwnershipProof, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GenerateKeyOwnershipProof { - pub set_id: ::core::primitive::u64, - pub authority_id: runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - } - } - } - pub mod mmr_api { - use super::root_mod; - use super::runtime_types; - #[doc = " API to interact with MMR pallet."] - pub struct MmrApi; - impl MmrApi { - #[doc = " Return the on-chain MMR root hash."] - pub fn mmr_root( - &self, - ) -> ::subxt::runtime_api::Payload< - types::MmrRoot, - ::core::result::Result< - ::subxt::utils::H256, - runtime_types::sp_mmr_primitives::Error, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "MmrApi", - "mmr_root", - types::MmrRoot {}, - [ - 148u8, 252u8, 77u8, 233u8, 236u8, 8u8, 119u8, 105u8, 207u8, 161u8, - 109u8, 158u8, 211u8, 64u8, 67u8, 216u8, 242u8, 52u8, 122u8, 4u8, 83u8, - 113u8, 54u8, 77u8, 165u8, 89u8, 61u8, 159u8, 98u8, 51u8, 45u8, 90u8, - ], - ) - } - #[doc = " Return the number of MMR blocks in the chain."] - pub fn mmr_leaf_count( - &self, - ) -> ::subxt::runtime_api::Payload< - types::MmrLeafCount, - ::core::result::Result< - ::core::primitive::u64, - runtime_types::sp_mmr_primitives::Error, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "MmrApi", - "mmr_leaf_count", - types::MmrLeafCount {}, - [ - 165u8, 141u8, 127u8, 184u8, 27u8, 185u8, 251u8, 25u8, 44u8, 93u8, - 239u8, 158u8, 104u8, 91u8, 22u8, 87u8, 101u8, 166u8, 90u8, 90u8, 45u8, - 105u8, 254u8, 136u8, 233u8, 121u8, 9u8, 216u8, 179u8, 55u8, 126u8, - 158u8, - ], - ) - } - #[doc = " Generate MMR proof for a series of block numbers. If `best_known_block_number = Some(n)`,"] - #[doc = " use historical MMR state at given block height `n`. Else, use current MMR state."] - pub fn generate_proof( - &self, - block_numbers: ::std::vec::Vec<::core::primitive::u32>, - best_known_block_number: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::runtime_api::Payload< - types::GenerateProof, - ::core::result::Result< - ( - ::std::vec::Vec, - runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, - ), - runtime_types::sp_mmr_primitives::Error, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "MmrApi", - "generate_proof", - types::GenerateProof { block_numbers, best_known_block_number }, - [ - 187u8, 175u8, 153u8, 82u8, 245u8, 180u8, 126u8, 156u8, 67u8, 89u8, - 253u8, 29u8, 54u8, 168u8, 196u8, 144u8, 24u8, 123u8, 154u8, 69u8, - 245u8, 90u8, 110u8, 239u8, 15u8, 125u8, 204u8, 148u8, 71u8, 209u8, - 58u8, 32u8, - ], - ) - } - #[doc = " Verify MMR proof against on-chain MMR for a batch of leaves."] - #[doc = ""] - #[doc = " Note this function will use on-chain MMR root hash and check if the proof matches the hash."] - #[doc = " Note, the leaves should be sorted such that corresponding leaves and leaf indices have the"] - #[doc = " same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]"] - pub fn verify_proof( - &self, - leaves: ::std::vec::Vec, - proof: runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, - ) -> ::subxt::runtime_api::Payload< - types::VerifyProof, - ::core::result::Result<(), runtime_types::sp_mmr_primitives::Error>, - > { - ::subxt::runtime_api::Payload::new_static( - "MmrApi", - "verify_proof", - types::VerifyProof { leaves, proof }, - [ - 236u8, 54u8, 135u8, 196u8, 161u8, 247u8, 183u8, 78u8, 153u8, 69u8, - 59u8, 78u8, 62u8, 20u8, 187u8, 47u8, 77u8, 209u8, 209u8, 224u8, 127u8, - 85u8, 122u8, 33u8, 123u8, 128u8, 92u8, 251u8, 110u8, 233u8, 50u8, - 160u8, - ], - ) - } - #[doc = " Verify MMR proof against given root hash for a batch of leaves."] - #[doc = ""] - #[doc = " Note this function does not require any on-chain storage - the"] - #[doc = " proof is verified against given MMR root hash."] - #[doc = ""] - #[doc = " Note, the leaves should be sorted such that corresponding leaves and leaf indices have the"] - #[doc = " same position in both the `leaves` vector and the `leaf_indices` vector contained in the [Proof]"] - pub fn verify_proof_stateless( - &self, - root: ::subxt::utils::H256, - leaves: ::std::vec::Vec, - proof: runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, - ) -> ::subxt::runtime_api::Payload< - types::VerifyProofStateless, - ::core::result::Result<(), runtime_types::sp_mmr_primitives::Error>, - > { - ::subxt::runtime_api::Payload::new_static( - "MmrApi", - "verify_proof_stateless", - types::VerifyProofStateless { root, leaves, proof }, - [ - 163u8, 232u8, 190u8, 65u8, 135u8, 136u8, 50u8, 60u8, 137u8, 37u8, - 192u8, 24u8, 137u8, 144u8, 165u8, 131u8, 49u8, 88u8, 15u8, 139u8, 83u8, - 152u8, 162u8, 148u8, 22u8, 74u8, 82u8, 25u8, 183u8, 83u8, 212u8, 56u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MmrRoot {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MmrLeafCount {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GenerateProof { - pub block_numbers: ::std::vec::Vec<::core::primitive::u32>, - pub best_known_block_number: ::core::option::Option<::core::primitive::u32>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VerifyProof { - pub leaves: - ::std::vec::Vec, - pub proof: runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VerifyProofStateless { - pub root: ::subxt::utils::H256, - pub leaves: - ::std::vec::Vec, - pub proof: runtime_types::sp_mmr_primitives::Proof<::subxt::utils::H256>, - } - } - } - pub mod grandpa_api { - use super::root_mod; - use super::runtime_types; - #[doc = " APIs for integrating the GRANDPA finality gadget into runtimes."] - #[doc = " This should be implemented on the runtime side."] - #[doc = ""] - #[doc = " This is primarily used for negotiating authority-set changes for the"] - #[doc = " gadget. GRANDPA uses a signaling model of changing authority sets:"] - #[doc = " changes should be signaled with a delay of N blocks, and then automatically"] - #[doc = " applied in the runtime after those N blocks have passed."] - #[doc = ""] - #[doc = " The consensus protocol will coordinate the handoff externally."] - pub struct GrandpaApi; - impl GrandpaApi { - #[doc = " Get the current GRANDPA authorities and weights. This should not change except"] - #[doc = " for when changes are scheduled and the corresponding delay has passed."] - #[doc = ""] - #[doc = " When called at block B, it will return the set of authorities that should be"] - #[doc = " used to finalize descendants of this block (B+1, B+2, ...). The block B itself"] - #[doc = " is finalized by the authorities from block B-1."] - pub fn grandpa_authorities( - &self, - ) -> ::subxt::runtime_api::Payload< - types::GrandpaAuthorities, - ::std::vec::Vec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - > { - ::subxt::runtime_api::Payload::new_static( - "GrandpaApi", - "grandpa_authorities", - types::GrandpaAuthorities {}, - [ - 166u8, 76u8, 160u8, 101u8, 242u8, 145u8, 213u8, 10u8, 16u8, 130u8, - 230u8, 196u8, 125u8, 152u8, 92u8, 143u8, 119u8, 223u8, 140u8, 189u8, - 203u8, 95u8, 52u8, 105u8, 147u8, 107u8, 135u8, 228u8, 62u8, 178u8, - 128u8, 33u8, - ], - ) - } - #[doc = " Submits an unsigned extrinsic to report an equivocation. The caller"] - #[doc = " must provide the equivocation proof and a key ownership proof"] - #[doc = " (should be obtained using `generate_key_ownership_proof`). The"] - #[doc = " extrinsic will be unsigned and should only be accepted for local"] - #[doc = " authorship (not to be broadcast to the network). This method returns"] - #[doc = " `None` when creation of the extrinsic fails, e.g. if equivocation"] - #[doc = " reporting is disabled for the given runtime (i.e. this method is"] - #[doc = " hardcoded to return `None`). Only useful in an offchain context."] - pub fn submit_report_equivocation_unsigned_extrinsic( - &self, - equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - key_owner_proof: runtime_types::sp_consensus_grandpa::OpaqueKeyOwnershipProof, - ) -> ::subxt::runtime_api::Payload< - types::SubmitReportEquivocationUnsignedExtrinsic, - ::core::option::Option<()>, - > { - ::subxt::runtime_api::Payload::new_static( - "GrandpaApi", - "submit_report_equivocation_unsigned_extrinsic", - types::SubmitReportEquivocationUnsignedExtrinsic { - equivocation_proof, - key_owner_proof, - }, - [ - 112u8, 94u8, 150u8, 250u8, 132u8, 127u8, 185u8, 24u8, 113u8, 62u8, - 28u8, 171u8, 83u8, 9u8, 41u8, 228u8, 92u8, 137u8, 29u8, 190u8, 214u8, - 232u8, 100u8, 66u8, 100u8, 168u8, 149u8, 122u8, 93u8, 17u8, 236u8, - 104u8, - ], - ) - } - #[doc = " Generates a proof of key ownership for the given authority in the"] - #[doc = " given set. An example usage of this module is coupled with the"] - #[doc = " session historical module to prove that a given authority key is"] - #[doc = " tied to a given staking identity during a specific session. Proofs"] - #[doc = " of key ownership are necessary for submitting equivocation reports."] - #[doc = " NOTE: even though the API takes a `set_id` as parameter the current"] - #[doc = " implementations ignore this parameter and instead rely on this"] - #[doc = " method being called at the correct block height, i.e. any point at"] - #[doc = " which the given set id is live on-chain. Future implementations will"] - #[doc = " instead use indexed data through an offchain worker, not requiring"] - #[doc = " older states to be available."] - pub fn generate_key_ownership_proof( - &self, - set_id: ::core::primitive::u64, - authority_id: runtime_types::sp_consensus_grandpa::app::Public, - ) -> ::subxt::runtime_api::Payload< - types::GenerateKeyOwnershipProof, - ::core::option::Option< - runtime_types::sp_consensus_grandpa::OpaqueKeyOwnershipProof, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "GrandpaApi", - "generate_key_ownership_proof", - types::GenerateKeyOwnershipProof { set_id, authority_id }, - [ - 40u8, 126u8, 113u8, 27u8, 245u8, 45u8, 123u8, 138u8, 12u8, 3u8, 125u8, - 186u8, 151u8, 53u8, 186u8, 93u8, 13u8, 150u8, 163u8, 176u8, 206u8, - 89u8, 244u8, 127u8, 182u8, 85u8, 203u8, 41u8, 101u8, 183u8, 209u8, - 179u8, - ], - ) - } - #[doc = " Get current GRANDPA authority set id."] - pub fn current_set_id( - &self, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "GrandpaApi", - "current_set_id", - types::CurrentSetId {}, - [ - 42u8, 230u8, 120u8, 211u8, 156u8, 245u8, 109u8, 86u8, 100u8, 146u8, - 234u8, 205u8, 41u8, 183u8, 109u8, 42u8, 17u8, 33u8, 156u8, 25u8, 139u8, - 84u8, 101u8, 75u8, 232u8, 198u8, 87u8, 136u8, 218u8, 233u8, 103u8, - 156u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GrandpaAuthorities {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitReportEquivocationUnsignedExtrinsic { - pub equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - pub key_owner_proof: - runtime_types::sp_consensus_grandpa::OpaqueKeyOwnershipProof, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GenerateKeyOwnershipProof { - pub set_id: ::core::primitive::u64, - pub authority_id: runtime_types::sp_consensus_grandpa::app::Public, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CurrentSetId {} - } - } - pub mod babe_api { - use super::root_mod; - use super::runtime_types; - #[doc = " API necessary for block authorship with BABE."] - pub struct BabeApi; - impl BabeApi { - #[doc = " Return the configuration for BABE."] - pub fn configuration( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Configuration, - runtime_types::sp_consensus_babe::BabeConfiguration, - > { - ::subxt::runtime_api::Payload::new_static( - "BabeApi", - "configuration", - types::Configuration {}, - [ - 8u8, 81u8, 234u8, 29u8, 30u8, 198u8, 76u8, 19u8, 188u8, 198u8, 127u8, - 33u8, 141u8, 95u8, 132u8, 106u8, 31u8, 41u8, 215u8, 54u8, 240u8, 65u8, - 59u8, 160u8, 188u8, 237u8, 10u8, 143u8, 250u8, 79u8, 45u8, 161u8, - ], - ) - } - #[doc = " Returns the slot that started the current epoch."] - pub fn current_epoch_start( - &self, - ) -> ::subxt::runtime_api::Payload< - types::CurrentEpochStart, - runtime_types::sp_consensus_slots::Slot, - > { - ::subxt::runtime_api::Payload::new_static( - "BabeApi", - "current_epoch_start", - types::CurrentEpochStart {}, - [ - 122u8, 125u8, 246u8, 170u8, 27u8, 50u8, 128u8, 137u8, 228u8, 62u8, - 145u8, 64u8, 65u8, 119u8, 166u8, 237u8, 115u8, 92u8, 125u8, 124u8, - 11u8, 33u8, 96u8, 88u8, 88u8, 122u8, 141u8, 137u8, 58u8, 182u8, 148u8, - 170u8, - ], - ) - } - #[doc = " Returns information regarding the current epoch."] - pub fn current_epoch( - &self, - ) -> ::subxt::runtime_api::Payload< - types::CurrentEpoch, - runtime_types::sp_consensus_babe::Epoch, - > { - ::subxt::runtime_api::Payload::new_static( - "BabeApi", - "current_epoch", - types::CurrentEpoch {}, - [ - 73u8, 171u8, 149u8, 138u8, 230u8, 95u8, 241u8, 189u8, 207u8, 145u8, - 103u8, 76u8, 79u8, 44u8, 250u8, 68u8, 238u8, 4u8, 149u8, 234u8, 165u8, - 91u8, 89u8, 228u8, 132u8, 201u8, 203u8, 98u8, 209u8, 137u8, 8u8, 63u8, - ], - ) - } - #[doc = " Returns information regarding the next epoch (which was already"] - #[doc = " previously announced)."] - pub fn next_epoch( - &self, - ) -> ::subxt::runtime_api::Payload< - types::NextEpoch, - runtime_types::sp_consensus_babe::Epoch, - > { - ::subxt::runtime_api::Payload::new_static( - "BabeApi", - "next_epoch", - types::NextEpoch {}, - [ - 191u8, 124u8, 183u8, 209u8, 73u8, 171u8, 164u8, 244u8, 68u8, 239u8, - 196u8, 54u8, 188u8, 85u8, 229u8, 175u8, 29u8, 89u8, 148u8, 108u8, - 208u8, 156u8, 62u8, 193u8, 167u8, 184u8, 251u8, 245u8, 123u8, 87u8, - 19u8, 225u8, - ], - ) - } - #[doc = " Generates a proof of key ownership for the given authority in the"] - #[doc = " current epoch. An example usage of this module is coupled with the"] - #[doc = " session historical module to prove that a given authority key is"] - #[doc = " tied to a given staking identity during a specific session. Proofs"] - #[doc = " of key ownership are necessary for submitting equivocation reports."] - #[doc = " NOTE: even though the API takes a `slot` as parameter the current"] - #[doc = " implementations ignores this parameter and instead relies on this"] - #[doc = " method being called at the correct block height, i.e. any point at"] - #[doc = " which the epoch for the given slot is live on-chain. Future"] - #[doc = " implementations will instead use indexed data through an offchain"] - #[doc = " worker, not requiring older states to be available."] - pub fn generate_key_ownership_proof( - &self, - slot: runtime_types::sp_consensus_slots::Slot, - authority_id: runtime_types::sp_consensus_babe::app::Public, - ) -> ::subxt::runtime_api::Payload< - types::GenerateKeyOwnershipProof, - ::core::option::Option< - runtime_types::sp_consensus_babe::OpaqueKeyOwnershipProof, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "BabeApi", - "generate_key_ownership_proof", - types::GenerateKeyOwnershipProof { slot, authority_id }, - [ - 235u8, 220u8, 75u8, 20u8, 175u8, 246u8, 127u8, 176u8, 225u8, 25u8, - 240u8, 252u8, 58u8, 254u8, 153u8, 133u8, 197u8, 168u8, 19u8, 231u8, - 234u8, 173u8, 58u8, 152u8, 212u8, 123u8, 13u8, 131u8, 84u8, 221u8, - 98u8, 46u8, - ], - ) - } - #[doc = " Submits an unsigned extrinsic to report an equivocation. The caller"] - #[doc = " must provide the equivocation proof and a key ownership proof"] - #[doc = " (should be obtained using `generate_key_ownership_proof`). The"] - #[doc = " extrinsic will be unsigned and should only be accepted for local"] - #[doc = " authorship (not to be broadcast to the network). This method returns"] - #[doc = " `None` when creation of the extrinsic fails, e.g. if equivocation"] - #[doc = " reporting is disabled for the given runtime (i.e. this method is"] - #[doc = " hardcoded to return `None`). Only useful in an offchain context."] - pub fn submit_report_equivocation_unsigned_extrinsic( - &self, - equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - runtime_types::sp_consensus_babe::app::Public, - >, - key_owner_proof: runtime_types::sp_consensus_babe::OpaqueKeyOwnershipProof, - ) -> ::subxt::runtime_api::Payload< - types::SubmitReportEquivocationUnsignedExtrinsic, - ::core::option::Option<()>, - > { - ::subxt::runtime_api::Payload::new_static( - "BabeApi", - "submit_report_equivocation_unsigned_extrinsic", - types::SubmitReportEquivocationUnsignedExtrinsic { - equivocation_proof, - key_owner_proof, - }, - [ - 9u8, 163u8, 149u8, 31u8, 89u8, 32u8, 224u8, 116u8, 102u8, 46u8, 10u8, - 189u8, 35u8, 166u8, 111u8, 156u8, 204u8, 80u8, 35u8, 64u8, 223u8, 3u8, - 4u8, 0u8, 97u8, 118u8, 124u8, 142u8, 224u8, 160u8, 2u8, 50u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Configuration {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CurrentEpochStart {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CurrentEpoch {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NextEpoch {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GenerateKeyOwnershipProof { - pub slot: runtime_types::sp_consensus_slots::Slot, - pub authority_id: runtime_types::sp_consensus_babe::app::Public, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SubmitReportEquivocationUnsignedExtrinsic { - pub equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - runtime_types::sp_consensus_babe::app::Public, - >, - pub key_owner_proof: runtime_types::sp_consensus_babe::OpaqueKeyOwnershipProof, - } - } - } - pub mod authority_discovery_api { - use super::root_mod; - use super::runtime_types; - #[doc = " The authority discovery api."] - #[doc = ""] - #[doc = " This api is used by the `client/authority-discovery` module to retrieve identifiers"] - #[doc = " of the current and next authority set."] - pub struct AuthorityDiscoveryApi; - impl AuthorityDiscoveryApi { - #[doc = " Retrieve authority identifiers of the current and next authority set."] - pub fn authorities( - &self, - ) -> ::subxt::runtime_api::Payload< - types::Authorities, - ::std::vec::Vec, - > { - ::subxt::runtime_api::Payload::new_static( - "AuthorityDiscoveryApi", - "authorities", - types::Authorities {}, - [ - 231u8, 109u8, 175u8, 33u8, 103u8, 6u8, 157u8, 241u8, 62u8, 92u8, 246u8, - 9u8, 109u8, 137u8, 233u8, 96u8, 103u8, 59u8, 201u8, 132u8, 102u8, 32u8, - 19u8, 183u8, 106u8, 146u8, 41u8, 172u8, 147u8, 55u8, 156u8, 77u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Authorities {} - } - } - pub mod session_keys { - use super::root_mod; - use super::runtime_types; - #[doc = " Session keys runtime api."] - pub struct SessionKeys; - impl SessionKeys { - #[doc = " Generate a set of session keys with optionally using the given seed."] - #[doc = " The keys should be stored within the keystore exposed via runtime"] - #[doc = " externalities."] - #[doc = ""] - #[doc = " The seed needs to be a valid `utf8` string."] - #[doc = ""] - #[doc = " Returns the concatenated SCALE encoded public keys."] - pub fn generate_session_keys( - &self, - seed: ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, - ) -> ::subxt::runtime_api::Payload< - types::GenerateSessionKeys, - ::std::vec::Vec<::core::primitive::u8>, - > { - ::subxt::runtime_api::Payload::new_static( - "SessionKeys", - "generate_session_keys", - types::GenerateSessionKeys { seed }, - [ - 96u8, 171u8, 164u8, 166u8, 175u8, 102u8, 101u8, 47u8, 133u8, 95u8, - 102u8, 202u8, 83u8, 26u8, 238u8, 47u8, 126u8, 132u8, 22u8, 11u8, 33u8, - 190u8, 175u8, 94u8, 58u8, 245u8, 46u8, 80u8, 195u8, 184u8, 107u8, 65u8, - ], - ) - } - #[doc = " Decode the given public session keys."] - #[doc = ""] - #[doc = " Returns the list of public raw public keys + key type."] - pub fn decode_session_keys( - &self, - encoded: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::runtime_api::Payload< - types::DecodeSessionKeys, - ::core::option::Option< - ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - runtime_types::sp_core::crypto::KeyTypeId, - )>, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "SessionKeys", - "decode_session_keys", - types::DecodeSessionKeys { encoded }, - [ - 57u8, 242u8, 18u8, 51u8, 132u8, 110u8, 238u8, 255u8, 39u8, 194u8, 8u8, - 54u8, 198u8, 178u8, 75u8, 151u8, 148u8, 176u8, 144u8, 197u8, 87u8, - 29u8, 179u8, 235u8, 176u8, 78u8, 252u8, 103u8, 72u8, 203u8, 151u8, - 248u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GenerateSessionKeys { - pub seed: ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DecodeSessionKeys { - pub encoded: ::std::vec::Vec<::core::primitive::u8>, - } - } - } - pub mod account_nonce_api { - use super::root_mod; - use super::runtime_types; - #[doc = " The API to query account nonce."] - pub struct AccountNonceApi; - impl AccountNonceApi { - #[doc = " Get current account nonce of given `AccountId`."] - pub fn account_nonce( - &self, - account: ::subxt::utils::AccountId32, - ) -> ::subxt::runtime_api::Payload { - ::subxt::runtime_api::Payload::new_static( - "AccountNonceApi", - "account_nonce", - types::AccountNonce { account }, - [ - 231u8, 82u8, 7u8, 227u8, 131u8, 2u8, 215u8, 252u8, 173u8, 82u8, 11u8, - 103u8, 200u8, 25u8, 114u8, 116u8, 79u8, 229u8, 152u8, 150u8, 236u8, - 37u8, 101u8, 26u8, 220u8, 146u8, 182u8, 101u8, 73u8, 55u8, 191u8, - 171u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AccountNonce { - pub account: ::subxt::utils::AccountId32, - } - } - } - pub mod transaction_payment_api { - use super::root_mod; - use super::runtime_types; - pub struct TransactionPaymentApi; - impl TransactionPaymentApi { - pub fn query_info( - &self, - uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, - len: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::QueryInfo, - runtime_types::pallet_transaction_payment::types::RuntimeDispatchInfo< - ::core::primitive::u128, - runtime_types::sp_weights::weight_v2::Weight, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentApi", - "query_info", - types::QueryInfo { uxt, len }, - [ - 56u8, 30u8, 174u8, 34u8, 202u8, 24u8, 177u8, 189u8, 145u8, 36u8, 1u8, - 156u8, 98u8, 209u8, 178u8, 49u8, 198u8, 23u8, 150u8, 173u8, 35u8, - 205u8, 147u8, 129u8, 42u8, 22u8, 69u8, 3u8, 129u8, 8u8, 196u8, 139u8, - ], - ) - } - pub fn query_fee_details( - &self, - uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) >, - len: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload< - types::QueryFeeDetails, - runtime_types::pallet_transaction_payment::types::FeeDetails< - ::core::primitive::u128, - >, - > { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentApi", - "query_fee_details", - types::QueryFeeDetails { uxt, len }, - [ - 117u8, 60u8, 137u8, 159u8, 237u8, 252u8, 216u8, 238u8, 232u8, 1u8, - 100u8, 152u8, 26u8, 185u8, 145u8, 125u8, 68u8, 189u8, 4u8, 30u8, 125u8, - 7u8, 196u8, 153u8, 235u8, 51u8, 219u8, 108u8, 185u8, 254u8, 100u8, - 201u8, - ], - ) - } - pub fn query_weight_to_fee( - &self, - weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::runtime_api::Payload - { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentApi", - "query_weight_to_fee", - types::QueryWeightToFee { weight }, - [ - 206u8, 243u8, 189u8, 83u8, 231u8, 244u8, 247u8, 52u8, 126u8, 208u8, - 224u8, 5u8, 163u8, 108u8, 254u8, 114u8, 214u8, 156u8, 227u8, 217u8, - 211u8, 198u8, 121u8, 164u8, 110u8, 54u8, 181u8, 146u8, 50u8, 146u8, - 146u8, 23u8, - ], - ) - } - pub fn query_length_to_fee( - &self, - length: ::core::primitive::u32, - ) -> ::subxt::runtime_api::Payload - { - ::subxt::runtime_api::Payload::new_static( - "TransactionPaymentApi", - "query_length_to_fee", - types::QueryLengthToFee { length }, - [ - 92u8, 132u8, 29u8, 119u8, 66u8, 11u8, 196u8, 224u8, 129u8, 23u8, 249u8, - 12u8, 32u8, 28u8, 92u8, 50u8, 188u8, 101u8, 203u8, 229u8, 248u8, 216u8, - 130u8, 150u8, 212u8, 161u8, 81u8, 254u8, 116u8, 89u8, 162u8, 48u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryInfo { pub uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub len : :: core :: primitive :: u32 , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryFeeDetails { pub uxt : :: subxt :: utils :: UncheckedExtrinsic < :: subxt :: utils :: MultiAddress < :: subxt :: utils :: AccountId32 , () > , runtime_types :: rococo_runtime :: RuntimeCall , runtime_types :: sp_runtime :: MultiSignature , (runtime_types :: frame_system :: extensions :: check_non_zero_sender :: CheckNonZeroSender , runtime_types :: frame_system :: extensions :: check_spec_version :: CheckSpecVersion , runtime_types :: frame_system :: extensions :: check_tx_version :: CheckTxVersion , runtime_types :: frame_system :: extensions :: check_genesis :: CheckGenesis , runtime_types :: frame_system :: extensions :: check_mortality :: CheckMortality , runtime_types :: frame_system :: extensions :: check_nonce :: CheckNonce , runtime_types :: frame_system :: extensions :: check_weight :: CheckWeight , runtime_types :: pallet_transaction_payment :: ChargeTransactionPayment ,) > , pub len : :: core :: primitive :: u32 , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryWeightToFee { - pub weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryLengthToFee { - pub length: ::core::primitive::u32, - } - } - } - pub mod beefy_mmr_api { - use super::root_mod; - use super::runtime_types; - #[doc = " API useful for BEEFY light clients."] - pub struct BeefyMmrApi; - impl BeefyMmrApi { - #[doc = " Return the currently active BEEFY authority set proof."] - pub fn authority_set_proof( - &self, - ) -> ::subxt::runtime_api::Payload< - types::AuthoritySetProof, - runtime_types::sp_consensus_beefy::mmr::BeefyAuthoritySet<::subxt::utils::H256>, - > { - ::subxt::runtime_api::Payload::new_static( - "BeefyMmrApi", - "authority_set_proof", - types::AuthoritySetProof {}, - [ - 199u8, 220u8, 251u8, 219u8, 216u8, 5u8, 181u8, 172u8, 191u8, 209u8, - 123u8, 25u8, 151u8, 129u8, 166u8, 21u8, 107u8, 22u8, 74u8, 144u8, - 202u8, 6u8, 254u8, 197u8, 148u8, 227u8, 131u8, 244u8, 254u8, 193u8, - 212u8, 97u8, - ], - ) - } - #[doc = " Return the next/queued BEEFY authority set proof."] - pub fn next_authority_set_proof( - &self, - ) -> ::subxt::runtime_api::Payload< - types::NextAuthoritySetProof, - runtime_types::sp_consensus_beefy::mmr::BeefyAuthoritySet<::subxt::utils::H256>, - > { - ::subxt::runtime_api::Payload::new_static( - "BeefyMmrApi", - "next_authority_set_proof", - types::NextAuthoritySetProof {}, - [ - 66u8, 217u8, 48u8, 108u8, 211u8, 187u8, 61u8, 85u8, 210u8, 59u8, 128u8, - 159u8, 34u8, 151u8, 154u8, 140u8, 13u8, 244u8, 31u8, 216u8, 67u8, 67u8, - 171u8, 112u8, 51u8, 145u8, 4u8, 22u8, 252u8, 242u8, 192u8, 130u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AuthoritySetProof {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NextAuthoritySetProof {} - } - } - pub mod genesis_builder { - use super::root_mod; - use super::runtime_types; - #[doc = " API to interact with GenesisConfig for the runtime"] - pub struct GenesisBuilder; - impl GenesisBuilder { - #[doc = " Creates the default `GenesisConfig` and returns it as a JSON blob."] - #[doc = ""] - #[doc = " This function instantiates the default `GenesisConfig` struct for the runtime and serializes it into a JSON"] - #[doc = " blob. It returns a `Vec` containing the JSON representation of the default `GenesisConfig`."] - pub fn create_default_config( - &self, - ) -> ::subxt::runtime_api::Payload< - types::CreateDefaultConfig, - ::std::vec::Vec<::core::primitive::u8>, - > { - ::subxt::runtime_api::Payload::new_static( - "GenesisBuilder", - "create_default_config", - types::CreateDefaultConfig {}, - [ - 238u8, 5u8, 139u8, 81u8, 184u8, 155u8, 221u8, 118u8, 190u8, 76u8, - 229u8, 67u8, 132u8, 89u8, 83u8, 80u8, 56u8, 171u8, 169u8, 64u8, 123u8, - 20u8, 129u8, 159u8, 28u8, 135u8, 84u8, 52u8, 192u8, 98u8, 104u8, 214u8, - ], - ) - } - #[doc = " Build `GenesisConfig` from a JSON blob not using any defaults and store it in the storage."] - #[doc = ""] - #[doc = " This function deserializes the full `GenesisConfig` from the given JSON blob and puts it into the storage."] - #[doc = " If the provided JSON blob is incorrect or incomplete or the deserialization fails, an error is returned."] - #[doc = " It is recommended to log any errors encountered during the process."] - #[doc = ""] - #[doc = " Please note that provided json blob must contain all `GenesisConfig` fields, no defaults will be used."] - pub fn build_config( - &self, - json: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::runtime_api::Payload< - types::BuildConfig, - ::core::result::Result<(), ::std::string::String>, - > { - ::subxt::runtime_api::Payload::new_static( - "GenesisBuilder", - "build_config", - types::BuildConfig { json }, - [ - 6u8, 98u8, 68u8, 125u8, 157u8, 26u8, 107u8, 86u8, 213u8, 227u8, 26u8, - 229u8, 122u8, 161u8, 229u8, 114u8, 123u8, 192u8, 66u8, 231u8, 148u8, - 175u8, 5u8, 185u8, 248u8, 88u8, 40u8, 122u8, 230u8, 209u8, 170u8, - 254u8, - ], - ) - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreateDefaultConfig {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BuildConfig { - pub json: ::std::vec::Vec<::core::primitive::u8>, - } - } - } - } - pub fn custom() -> CustomValuesApi { - CustomValuesApi - } - pub struct CustomValuesApi; - impl CustomValuesApi {} - pub struct ConstantsApi; - impl ConstantsApi { - pub fn system(&self) -> system::constants::ConstantsApi { - system::constants::ConstantsApi - } - pub fn babe(&self) -> babe::constants::ConstantsApi { - babe::constants::ConstantsApi - } - pub fn timestamp(&self) -> timestamp::constants::ConstantsApi { - timestamp::constants::ConstantsApi - } - pub fn indices(&self) -> indices::constants::ConstantsApi { - indices::constants::ConstantsApi - } - pub fn balances(&self) -> balances::constants::ConstantsApi { - balances::constants::ConstantsApi - } - pub fn transaction_payment(&self) -> transaction_payment::constants::ConstantsApi { - transaction_payment::constants::ConstantsApi - } - pub fn grandpa(&self) -> grandpa::constants::ConstantsApi { - grandpa::constants::ConstantsApi - } - pub fn treasury(&self) -> treasury::constants::ConstantsApi { - treasury::constants::ConstantsApi - } - pub fn conviction_voting(&self) -> conviction_voting::constants::ConstantsApi { - conviction_voting::constants::ConstantsApi - } - pub fn referenda(&self) -> referenda::constants::ConstantsApi { - referenda::constants::ConstantsApi - } - pub fn fellowship_referenda(&self) -> fellowship_referenda::constants::ConstantsApi { - fellowship_referenda::constants::ConstantsApi - } - pub fn claims(&self) -> claims::constants::ConstantsApi { - claims::constants::ConstantsApi - } - pub fn utility(&self) -> utility::constants::ConstantsApi { - utility::constants::ConstantsApi - } - pub fn identity(&self) -> identity::constants::ConstantsApi { - identity::constants::ConstantsApi - } - pub fn society(&self) -> society::constants::ConstantsApi { - society::constants::ConstantsApi - } - pub fn recovery(&self) -> recovery::constants::ConstantsApi { - recovery::constants::ConstantsApi - } - pub fn vesting(&self) -> vesting::constants::ConstantsApi { - vesting::constants::ConstantsApi - } - pub fn scheduler(&self) -> scheduler::constants::ConstantsApi { - scheduler::constants::ConstantsApi - } - pub fn proxy(&self) -> proxy::constants::ConstantsApi { - proxy::constants::ConstantsApi - } - pub fn multisig(&self) -> multisig::constants::ConstantsApi { - multisig::constants::ConstantsApi - } - pub fn bounties(&self) -> bounties::constants::ConstantsApi { - bounties::constants::ConstantsApi - } - pub fn child_bounties(&self) -> child_bounties::constants::ConstantsApi { - child_bounties::constants::ConstantsApi - } - pub fn nis(&self) -> nis::constants::ConstantsApi { - nis::constants::ConstantsApi - } - pub fn nis_counterpart_balances( - &self, - ) -> nis_counterpart_balances::constants::ConstantsApi { - nis_counterpart_balances::constants::ConstantsApi - } - pub fn paras(&self) -> paras::constants::ConstantsApi { - paras::constants::ConstantsApi - } - pub fn message_queue(&self) -> message_queue::constants::ConstantsApi { - message_queue::constants::ConstantsApi - } - pub fn on_demand_assignment_provider( - &self, - ) -> on_demand_assignment_provider::constants::ConstantsApi { - on_demand_assignment_provider::constants::ConstantsApi - } - pub fn registrar(&self) -> registrar::constants::ConstantsApi { - registrar::constants::ConstantsApi - } - pub fn slots(&self) -> slots::constants::ConstantsApi { - slots::constants::ConstantsApi - } - pub fn auctions(&self) -> auctions::constants::ConstantsApi { - auctions::constants::ConstantsApi - } - pub fn crowdloan(&self) -> crowdloan::constants::ConstantsApi { - crowdloan::constants::ConstantsApi - } - pub fn coretime(&self) -> coretime::constants::ConstantsApi { - coretime::constants::ConstantsApi - } - pub fn beefy(&self) -> beefy::constants::ConstantsApi { - beefy::constants::ConstantsApi - } - pub fn assigned_slots(&self) -> assigned_slots::constants::ConstantsApi { - assigned_slots::constants::ConstantsApi - } - pub fn state_trie_migration(&self) -> state_trie_migration::constants::ConstantsApi { - state_trie_migration::constants::ConstantsApi - } - } - pub struct StorageApi; - impl StorageApi { - pub fn system(&self) -> system::storage::StorageApi { - system::storage::StorageApi - } - pub fn babe(&self) -> babe::storage::StorageApi { - babe::storage::StorageApi - } - pub fn timestamp(&self) -> timestamp::storage::StorageApi { - timestamp::storage::StorageApi - } - pub fn indices(&self) -> indices::storage::StorageApi { - indices::storage::StorageApi - } - pub fn balances(&self) -> balances::storage::StorageApi { - balances::storage::StorageApi - } - pub fn transaction_payment(&self) -> transaction_payment::storage::StorageApi { - transaction_payment::storage::StorageApi - } - pub fn authorship(&self) -> authorship::storage::StorageApi { - authorship::storage::StorageApi - } - pub fn offences(&self) -> offences::storage::StorageApi { - offences::storage::StorageApi - } - pub fn historical(&self) -> historical::storage::StorageApi { - historical::storage::StorageApi - } - pub fn session(&self) -> session::storage::StorageApi { - session::storage::StorageApi - } - pub fn grandpa(&self) -> grandpa::storage::StorageApi { - grandpa::storage::StorageApi - } - pub fn authority_discovery(&self) -> authority_discovery::storage::StorageApi { - authority_discovery::storage::StorageApi - } - pub fn treasury(&self) -> treasury::storage::StorageApi { - treasury::storage::StorageApi - } - pub fn conviction_voting(&self) -> conviction_voting::storage::StorageApi { - conviction_voting::storage::StorageApi - } - pub fn referenda(&self) -> referenda::storage::StorageApi { - referenda::storage::StorageApi - } - pub fn fellowship_collective(&self) -> fellowship_collective::storage::StorageApi { - fellowship_collective::storage::StorageApi - } - pub fn fellowship_referenda(&self) -> fellowship_referenda::storage::StorageApi { - fellowship_referenda::storage::StorageApi - } - pub fn whitelist(&self) -> whitelist::storage::StorageApi { - whitelist::storage::StorageApi - } - pub fn claims(&self) -> claims::storage::StorageApi { - claims::storage::StorageApi - } - pub fn identity(&self) -> identity::storage::StorageApi { - identity::storage::StorageApi - } - pub fn society(&self) -> society::storage::StorageApi { - society::storage::StorageApi - } - pub fn recovery(&self) -> recovery::storage::StorageApi { - recovery::storage::StorageApi - } - pub fn vesting(&self) -> vesting::storage::StorageApi { - vesting::storage::StorageApi - } - pub fn scheduler(&self) -> scheduler::storage::StorageApi { - scheduler::storage::StorageApi - } - pub fn proxy(&self) -> proxy::storage::StorageApi { - proxy::storage::StorageApi - } - pub fn multisig(&self) -> multisig::storage::StorageApi { - multisig::storage::StorageApi - } - pub fn preimage(&self) -> preimage::storage::StorageApi { - preimage::storage::StorageApi - } - pub fn asset_rate(&self) -> asset_rate::storage::StorageApi { - asset_rate::storage::StorageApi - } - pub fn bounties(&self) -> bounties::storage::StorageApi { - bounties::storage::StorageApi - } - pub fn child_bounties(&self) -> child_bounties::storage::StorageApi { - child_bounties::storage::StorageApi - } - pub fn nis(&self) -> nis::storage::StorageApi { - nis::storage::StorageApi - } - pub fn nis_counterpart_balances(&self) -> nis_counterpart_balances::storage::StorageApi { - nis_counterpart_balances::storage::StorageApi - } - pub fn configuration(&self) -> configuration::storage::StorageApi { - configuration::storage::StorageApi - } - pub fn paras_shared(&self) -> paras_shared::storage::StorageApi { - paras_shared::storage::StorageApi - } - pub fn para_inclusion(&self) -> para_inclusion::storage::StorageApi { - para_inclusion::storage::StorageApi - } - pub fn para_inherent(&self) -> para_inherent::storage::StorageApi { - para_inherent::storage::StorageApi - } - pub fn para_scheduler(&self) -> para_scheduler::storage::StorageApi { - para_scheduler::storage::StorageApi - } - pub fn paras(&self) -> paras::storage::StorageApi { - paras::storage::StorageApi - } - pub fn initializer(&self) -> initializer::storage::StorageApi { - initializer::storage::StorageApi - } - pub fn dmp(&self) -> dmp::storage::StorageApi { - dmp::storage::StorageApi - } - pub fn hrmp(&self) -> hrmp::storage::StorageApi { - hrmp::storage::StorageApi - } - pub fn para_session_info(&self) -> para_session_info::storage::StorageApi { - para_session_info::storage::StorageApi - } - pub fn paras_disputes(&self) -> paras_disputes::storage::StorageApi { - paras_disputes::storage::StorageApi - } - pub fn paras_slashing(&self) -> paras_slashing::storage::StorageApi { - paras_slashing::storage::StorageApi - } - pub fn message_queue(&self) -> message_queue::storage::StorageApi { - message_queue::storage::StorageApi - } - pub fn on_demand_assignment_provider( - &self, - ) -> on_demand_assignment_provider::storage::StorageApi { - on_demand_assignment_provider::storage::StorageApi - } - pub fn coretime_assignment_provider( - &self, - ) -> coretime_assignment_provider::storage::StorageApi { - coretime_assignment_provider::storage::StorageApi - } - pub fn registrar(&self) -> registrar::storage::StorageApi { - registrar::storage::StorageApi - } - pub fn slots(&self) -> slots::storage::StorageApi { - slots::storage::StorageApi - } - pub fn auctions(&self) -> auctions::storage::StorageApi { - auctions::storage::StorageApi - } - pub fn crowdloan(&self) -> crowdloan::storage::StorageApi { - crowdloan::storage::StorageApi - } - pub fn xcm_pallet(&self) -> xcm_pallet::storage::StorageApi { - xcm_pallet::storage::StorageApi - } - pub fn beefy(&self) -> beefy::storage::StorageApi { - beefy::storage::StorageApi - } - pub fn mmr(&self) -> mmr::storage::StorageApi { - mmr::storage::StorageApi - } - pub fn mmr_leaf(&self) -> mmr_leaf::storage::StorageApi { - mmr_leaf::storage::StorageApi - } - pub fn assigned_slots(&self) -> assigned_slots::storage::StorageApi { - assigned_slots::storage::StorageApi - } - pub fn validator_manager(&self) -> validator_manager::storage::StorageApi { - validator_manager::storage::StorageApi - } - pub fn state_trie_migration(&self) -> state_trie_migration::storage::StorageApi { - state_trie_migration::storage::StorageApi - } - pub fn sudo(&self) -> sudo::storage::StorageApi { - sudo::storage::StorageApi - } - } - pub struct TransactionApi; - impl TransactionApi { - pub fn system(&self) -> system::calls::TransactionApi { - system::calls::TransactionApi - } - pub fn babe(&self) -> babe::calls::TransactionApi { - babe::calls::TransactionApi - } - pub fn timestamp(&self) -> timestamp::calls::TransactionApi { - timestamp::calls::TransactionApi - } - pub fn indices(&self) -> indices::calls::TransactionApi { - indices::calls::TransactionApi - } - pub fn balances(&self) -> balances::calls::TransactionApi { - balances::calls::TransactionApi - } - pub fn session(&self) -> session::calls::TransactionApi { - session::calls::TransactionApi - } - pub fn grandpa(&self) -> grandpa::calls::TransactionApi { - grandpa::calls::TransactionApi - } - pub fn treasury(&self) -> treasury::calls::TransactionApi { - treasury::calls::TransactionApi - } - pub fn conviction_voting(&self) -> conviction_voting::calls::TransactionApi { - conviction_voting::calls::TransactionApi - } - pub fn referenda(&self) -> referenda::calls::TransactionApi { - referenda::calls::TransactionApi - } - pub fn fellowship_collective(&self) -> fellowship_collective::calls::TransactionApi { - fellowship_collective::calls::TransactionApi - } - pub fn fellowship_referenda(&self) -> fellowship_referenda::calls::TransactionApi { - fellowship_referenda::calls::TransactionApi - } - pub fn whitelist(&self) -> whitelist::calls::TransactionApi { - whitelist::calls::TransactionApi - } - pub fn claims(&self) -> claims::calls::TransactionApi { - claims::calls::TransactionApi - } - pub fn utility(&self) -> utility::calls::TransactionApi { - utility::calls::TransactionApi - } - pub fn identity(&self) -> identity::calls::TransactionApi { - identity::calls::TransactionApi - } - pub fn society(&self) -> society::calls::TransactionApi { - society::calls::TransactionApi - } - pub fn recovery(&self) -> recovery::calls::TransactionApi { - recovery::calls::TransactionApi - } - pub fn vesting(&self) -> vesting::calls::TransactionApi { - vesting::calls::TransactionApi - } - pub fn scheduler(&self) -> scheduler::calls::TransactionApi { - scheduler::calls::TransactionApi - } - pub fn proxy(&self) -> proxy::calls::TransactionApi { - proxy::calls::TransactionApi - } - pub fn multisig(&self) -> multisig::calls::TransactionApi { - multisig::calls::TransactionApi - } - pub fn preimage(&self) -> preimage::calls::TransactionApi { - preimage::calls::TransactionApi - } - pub fn asset_rate(&self) -> asset_rate::calls::TransactionApi { - asset_rate::calls::TransactionApi - } - pub fn bounties(&self) -> bounties::calls::TransactionApi { - bounties::calls::TransactionApi - } - pub fn child_bounties(&self) -> child_bounties::calls::TransactionApi { - child_bounties::calls::TransactionApi - } - pub fn nis(&self) -> nis::calls::TransactionApi { - nis::calls::TransactionApi - } - pub fn nis_counterpart_balances(&self) -> nis_counterpart_balances::calls::TransactionApi { - nis_counterpart_balances::calls::TransactionApi - } - pub fn configuration(&self) -> configuration::calls::TransactionApi { - configuration::calls::TransactionApi - } - pub fn paras_shared(&self) -> paras_shared::calls::TransactionApi { - paras_shared::calls::TransactionApi - } - pub fn para_inclusion(&self) -> para_inclusion::calls::TransactionApi { - para_inclusion::calls::TransactionApi - } - pub fn para_inherent(&self) -> para_inherent::calls::TransactionApi { - para_inherent::calls::TransactionApi - } - pub fn paras(&self) -> paras::calls::TransactionApi { - paras::calls::TransactionApi - } - pub fn initializer(&self) -> initializer::calls::TransactionApi { - initializer::calls::TransactionApi - } - pub fn hrmp(&self) -> hrmp::calls::TransactionApi { - hrmp::calls::TransactionApi - } - pub fn paras_disputes(&self) -> paras_disputes::calls::TransactionApi { - paras_disputes::calls::TransactionApi - } - pub fn paras_slashing(&self) -> paras_slashing::calls::TransactionApi { - paras_slashing::calls::TransactionApi - } - pub fn message_queue(&self) -> message_queue::calls::TransactionApi { - message_queue::calls::TransactionApi - } - pub fn on_demand_assignment_provider( - &self, - ) -> on_demand_assignment_provider::calls::TransactionApi { - on_demand_assignment_provider::calls::TransactionApi - } - pub fn registrar(&self) -> registrar::calls::TransactionApi { - registrar::calls::TransactionApi - } - pub fn slots(&self) -> slots::calls::TransactionApi { - slots::calls::TransactionApi - } - pub fn auctions(&self) -> auctions::calls::TransactionApi { - auctions::calls::TransactionApi - } - pub fn crowdloan(&self) -> crowdloan::calls::TransactionApi { - crowdloan::calls::TransactionApi - } - pub fn coretime(&self) -> coretime::calls::TransactionApi { - coretime::calls::TransactionApi - } - pub fn xcm_pallet(&self) -> xcm_pallet::calls::TransactionApi { - xcm_pallet::calls::TransactionApi - } - pub fn beefy(&self) -> beefy::calls::TransactionApi { - beefy::calls::TransactionApi - } - pub fn identity_migrator(&self) -> identity_migrator::calls::TransactionApi { - identity_migrator::calls::TransactionApi - } - pub fn paras_sudo_wrapper(&self) -> paras_sudo_wrapper::calls::TransactionApi { - paras_sudo_wrapper::calls::TransactionApi - } - pub fn assigned_slots(&self) -> assigned_slots::calls::TransactionApi { - assigned_slots::calls::TransactionApi - } - pub fn validator_manager(&self) -> validator_manager::calls::TransactionApi { - validator_manager::calls::TransactionApi - } - pub fn state_trie_migration(&self) -> state_trie_migration::calls::TransactionApi { - state_trie_migration::calls::TransactionApi - } - pub fn root_testing(&self) -> root_testing::calls::TransactionApi { - root_testing::calls::TransactionApi - } - pub fn sudo(&self) -> sudo::calls::TransactionApi { - sudo::calls::TransactionApi - } - } - #[doc = r" check whether the metadata provided is aligned with this statically generated code."] - pub fn is_codegen_valid_for(metadata: &::subxt::Metadata) -> bool { - let runtime_metadata_hash = metadata - .hasher() - .only_these_pallets(&PALLETS) - .only_these_runtime_apis(&RUNTIME_APIS) - .hash(); - runtime_metadata_hash - == [ - 218u8, 127u8, 7u8, 149u8, 113u8, 102u8, 152u8, 249u8, 20u8, 130u8, 78u8, 180u8, - 101u8, 67u8, 250u8, 34u8, 39u8, 230u8, 178u8, 24u8, 119u8, 139u8, 233u8, 246u8, - 20u8, 18u8, 29u8, 255u8, 135u8, 167u8, 48u8, 67u8, - ] - } - pub mod system { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the System pallet"] - pub type Error = runtime_types::frame_system::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::frame_system::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Remark { - pub remark: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for Remark { - const PALLET: &'static str = "System"; - const CALL: &'static str = "remark"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHeapPages { - pub pages: ::core::primitive::u64, - } - impl ::subxt::blocks::StaticExtrinsic for SetHeapPages { - const PALLET: &'static str = "System"; - const CALL: &'static str = "set_heap_pages"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCode { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for SetCode { - const PALLET: &'static str = "System"; - const CALL: &'static str = "set_code"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCodeWithoutChecks { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for SetCodeWithoutChecks { - const PALLET: &'static str = "System"; - const CALL: &'static str = "set_code_without_checks"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetStorage { - pub items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - } - impl ::subxt::blocks::StaticExtrinsic for SetStorage { - const PALLET: &'static str = "System"; - const CALL: &'static str = "set_storage"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillStorage { - pub keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - } - impl ::subxt::blocks::StaticExtrinsic for KillStorage { - const PALLET: &'static str = "System"; - const CALL: &'static str = "kill_storage"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillPrefix { - pub prefix: ::std::vec::Vec<::core::primitive::u8>, - pub subkeys: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for KillPrefix { - const PALLET: &'static str = "System"; - const CALL: &'static str = "kill_prefix"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemarkWithEvent { - pub remark: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for RemarkWithEvent { - const PALLET: &'static str = "System"; - const CALL: &'static str = "remark_with_event"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AuthorizeUpgrade { - pub code_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for AuthorizeUpgrade { - const PALLET: &'static str = "System"; - const CALL: &'static str = "authorize_upgrade"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AuthorizeUpgradeWithoutChecks { - pub code_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for AuthorizeUpgradeWithoutChecks { - const PALLET: &'static str = "System"; - const CALL: &'static str = "authorize_upgrade_without_checks"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApplyAuthorizedUpgrade { - pub code: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for ApplyAuthorizedUpgrade { - const PALLET: &'static str = "System"; - const CALL: &'static str = "apply_authorized_upgrade"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::remark`]."] - pub fn remark( - &self, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "remark", - types::Remark { remark }, - [ - 43u8, 126u8, 180u8, 174u8, 141u8, 48u8, 52u8, 125u8, 166u8, 212u8, - 216u8, 98u8, 100u8, 24u8, 132u8, 71u8, 101u8, 64u8, 246u8, 169u8, 33u8, - 250u8, 147u8, 208u8, 2u8, 40u8, 129u8, 209u8, 232u8, 207u8, 207u8, - 13u8, - ], - ) - } - #[doc = "See [`Pallet::set_heap_pages`]."] - pub fn set_heap_pages( - &self, - pages: ::core::primitive::u64, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_heap_pages", - types::SetHeapPages { pages }, - [ - 188u8, 191u8, 99u8, 216u8, 219u8, 109u8, 141u8, 50u8, 78u8, 235u8, - 215u8, 242u8, 195u8, 24u8, 111u8, 76u8, 229u8, 64u8, 99u8, 225u8, - 134u8, 121u8, 81u8, 209u8, 127u8, 223u8, 98u8, 215u8, 150u8, 70u8, - 57u8, 147u8, - ], - ) - } - #[doc = "See [`Pallet::set_code`]."] - pub fn set_code( - &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_code", - types::SetCode { code }, - [ - 233u8, 248u8, 88u8, 245u8, 28u8, 65u8, 25u8, 169u8, 35u8, 237u8, 19u8, - 203u8, 136u8, 160u8, 18u8, 3u8, 20u8, 197u8, 81u8, 169u8, 244u8, 188u8, - 27u8, 147u8, 147u8, 236u8, 65u8, 25u8, 3u8, 143u8, 182u8, 22u8, - ], - ) - } - #[doc = "See [`Pallet::set_code_without_checks`]."] - pub fn set_code_without_checks( - &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_code_without_checks", - types::SetCodeWithoutChecks { code }, - [ - 82u8, 212u8, 157u8, 44u8, 70u8, 0u8, 143u8, 15u8, 109u8, 109u8, 107u8, - 157u8, 141u8, 42u8, 169u8, 11u8, 15u8, 186u8, 252u8, 138u8, 10u8, - 147u8, 15u8, 178u8, 247u8, 229u8, 213u8, 98u8, 207u8, 231u8, 119u8, - 115u8, - ], - ) - } - #[doc = "See [`Pallet::set_storage`]."] - pub fn set_storage( - &self, - items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "set_storage", - types::SetStorage { items }, - [ - 141u8, 216u8, 52u8, 222u8, 223u8, 136u8, 123u8, 181u8, 19u8, 75u8, - 163u8, 102u8, 229u8, 189u8, 158u8, 142u8, 95u8, 235u8, 240u8, 49u8, - 150u8, 76u8, 78u8, 137u8, 126u8, 88u8, 183u8, 88u8, 231u8, 146u8, - 234u8, 43u8, - ], - ) - } - #[doc = "See [`Pallet::kill_storage`]."] - pub fn kill_storage( - &self, - keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "kill_storage", - types::KillStorage { keys }, - [ - 73u8, 63u8, 196u8, 36u8, 144u8, 114u8, 34u8, 213u8, 108u8, 93u8, 209u8, - 234u8, 153u8, 185u8, 33u8, 91u8, 187u8, 195u8, 223u8, 130u8, 58u8, - 156u8, 63u8, 47u8, 228u8, 249u8, 216u8, 139u8, 143u8, 177u8, 41u8, - 35u8, - ], - ) - } - #[doc = "See [`Pallet::kill_prefix`]."] - pub fn kill_prefix( - &self, - prefix: ::std::vec::Vec<::core::primitive::u8>, - subkeys: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "kill_prefix", - types::KillPrefix { prefix, subkeys }, - [ - 184u8, 57u8, 139u8, 24u8, 208u8, 87u8, 108u8, 215u8, 198u8, 189u8, - 175u8, 242u8, 167u8, 215u8, 97u8, 63u8, 110u8, 166u8, 238u8, 98u8, - 67u8, 236u8, 111u8, 110u8, 234u8, 81u8, 102u8, 5u8, 182u8, 5u8, 214u8, - 85u8, - ], - ) - } - #[doc = "See [`Pallet::remark_with_event`]."] - pub fn remark_with_event( - &self, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "remark_with_event", - types::RemarkWithEvent { remark }, - [ - 120u8, 120u8, 153u8, 92u8, 184u8, 85u8, 34u8, 2u8, 174u8, 206u8, 105u8, - 228u8, 233u8, 130u8, 80u8, 246u8, 228u8, 59u8, 234u8, 240u8, 4u8, 49u8, - 147u8, 170u8, 115u8, 91u8, 149u8, 200u8, 228u8, 181u8, 8u8, 154u8, - ], - ) - } - #[doc = "See [`Pallet::authorize_upgrade`]."] - pub fn authorize_upgrade( - &self, - code_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "authorize_upgrade", - types::AuthorizeUpgrade { code_hash }, - [ - 4u8, 14u8, 76u8, 107u8, 209u8, 129u8, 9u8, 39u8, 193u8, 17u8, 84u8, - 254u8, 170u8, 214u8, 24u8, 155u8, 29u8, 184u8, 249u8, 241u8, 109u8, - 58u8, 145u8, 131u8, 109u8, 63u8, 38u8, 165u8, 107u8, 215u8, 217u8, - 172u8, - ], - ) - } - #[doc = "See [`Pallet::authorize_upgrade_without_checks`]."] - pub fn authorize_upgrade_without_checks( - &self, - code_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "authorize_upgrade_without_checks", - types::AuthorizeUpgradeWithoutChecks { code_hash }, - [ - 126u8, 126u8, 55u8, 26u8, 47u8, 55u8, 66u8, 8u8, 167u8, 18u8, 29u8, - 136u8, 146u8, 14u8, 189u8, 117u8, 16u8, 227u8, 162u8, 61u8, 149u8, - 197u8, 104u8, 184u8, 185u8, 161u8, 99u8, 154u8, 80u8, 125u8, 181u8, - 233u8, - ], - ) - } - #[doc = "See [`Pallet::apply_authorized_upgrade`]."] - pub fn apply_authorized_upgrade( - &self, - code: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "System", - "apply_authorized_upgrade", - types::ApplyAuthorizedUpgrade { code }, - [ - 232u8, 107u8, 127u8, 38u8, 230u8, 29u8, 97u8, 4u8, 160u8, 191u8, 222u8, - 156u8, 245u8, 102u8, 196u8, 141u8, 44u8, 163u8, 98u8, 68u8, 125u8, - 32u8, 124u8, 101u8, 108u8, 93u8, 211u8, 52u8, 0u8, 231u8, 33u8, 227u8, - ], - ) - } - } - } - #[doc = "Event for the System pallet."] - pub type Event = runtime_types::frame_system::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An extrinsic completed successfully."] - pub struct ExtrinsicSuccess { - pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - } - impl ::subxt::events::StaticEvent for ExtrinsicSuccess { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "ExtrinsicSuccess"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An extrinsic failed."] - pub struct ExtrinsicFailed { - pub dispatch_error: runtime_types::sp_runtime::DispatchError, - pub dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - } - impl ::subxt::events::StaticEvent for ExtrinsicFailed { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "ExtrinsicFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "`:code` was updated."] - pub struct CodeUpdated; - impl ::subxt::events::StaticEvent for CodeUpdated { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "CodeUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new account was created."] - pub struct NewAccount { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for NewAccount { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "NewAccount"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was reaped."] - pub struct KilledAccount { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for KilledAccount { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "KilledAccount"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "On on-chain remark happened."] - pub struct Remarked { - pub sender: ::subxt::utils::AccountId32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Remarked { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "Remarked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An upgrade was authorized."] - pub struct UpgradeAuthorized { - pub code_hash: ::subxt::utils::H256, - pub check_version: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for UpgradeAuthorized { - const PALLET: &'static str = "System"; - const EVENT: &'static str = "UpgradeAuthorized"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The full account information for a particular account ID."] - pub fn account_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::AccountInfo< - ::core::primitive::u32, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "Account", - vec![], - [ - 14u8, 233u8, 115u8, 214u8, 0u8, 109u8, 222u8, 121u8, 162u8, 65u8, 60u8, - 175u8, 209u8, 79u8, 222u8, 124u8, 22u8, 235u8, 138u8, 176u8, 133u8, - 124u8, 90u8, 158u8, 85u8, 45u8, 37u8, 174u8, 47u8, 79u8, 47u8, 166u8, - ], - ) - } - #[doc = " The full account information for a particular account ID."] - pub fn account( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::AccountInfo< - ::core::primitive::u32, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Account", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 14u8, 233u8, 115u8, 214u8, 0u8, 109u8, 222u8, 121u8, 162u8, 65u8, 60u8, - 175u8, 209u8, 79u8, 222u8, 124u8, 22u8, 235u8, 138u8, 176u8, 133u8, - 124u8, 90u8, 158u8, 85u8, 45u8, 37u8, 174u8, 47u8, 79u8, 47u8, 166u8, - ], - ) - } - #[doc = " Total extrinsics count for the current block."] - pub fn extrinsic_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicCount", - vec![], - [ - 102u8, 76u8, 236u8, 42u8, 40u8, 231u8, 33u8, 222u8, 123u8, 147u8, - 153u8, 148u8, 234u8, 203u8, 181u8, 119u8, 6u8, 187u8, 177u8, 199u8, - 120u8, 47u8, 137u8, 254u8, 96u8, 100u8, 165u8, 182u8, 249u8, 230u8, - 159u8, 79u8, - ], - ) - } - #[doc = " The current weight for the block."] - pub fn block_weight( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_support::dispatch::PerDispatchClass< - runtime_types::sp_weights::weight_v2::Weight, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockWeight", - vec![], - [ - 158u8, 46u8, 228u8, 89u8, 210u8, 214u8, 84u8, 154u8, 50u8, 68u8, 63u8, - 62u8, 43u8, 42u8, 99u8, 27u8, 54u8, 42u8, 146u8, 44u8, 241u8, 216u8, - 229u8, 30u8, 216u8, 255u8, 165u8, 238u8, 181u8, 130u8, 36u8, 102u8, - ], - ) - } - #[doc = " Total length (in bytes) for all extrinsics put together, for the current block."] - pub fn all_extrinsics_len( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "AllExtrinsicsLen", - vec![], - [ - 117u8, 86u8, 61u8, 243u8, 41u8, 51u8, 102u8, 214u8, 137u8, 100u8, - 243u8, 185u8, 122u8, 174u8, 187u8, 117u8, 86u8, 189u8, 63u8, 135u8, - 101u8, 218u8, 203u8, 201u8, 237u8, 254u8, 128u8, 183u8, 169u8, 221u8, - 242u8, 65u8, - ], - ) - } - #[doc = " Map of block numbers to block hashes."] - pub fn block_hash_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockHash", - vec![], - [ - 217u8, 32u8, 215u8, 253u8, 24u8, 182u8, 207u8, 178u8, 157u8, 24u8, - 103u8, 100u8, 195u8, 165u8, 69u8, 152u8, 112u8, 181u8, 56u8, 192u8, - 164u8, 16u8, 20u8, 222u8, 28u8, 214u8, 144u8, 142u8, 146u8, 69u8, - 202u8, 118u8, - ], - ) - } - #[doc = " Map of block numbers to block hashes."] - pub fn block_hash( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "BlockHash", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 217u8, 32u8, 215u8, 253u8, 24u8, 182u8, 207u8, 178u8, 157u8, 24u8, - 103u8, 100u8, 195u8, 165u8, 69u8, 152u8, 112u8, 181u8, 56u8, 192u8, - 164u8, 16u8, 20u8, 222u8, 28u8, 214u8, 144u8, 142u8, 146u8, 69u8, - 202u8, 118u8, - ], - ) - } - #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] - pub fn extrinsic_data_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicData", - vec![], - [ - 160u8, 180u8, 122u8, 18u8, 196u8, 26u8, 2u8, 37u8, 115u8, 232u8, 133u8, - 220u8, 106u8, 245u8, 4u8, 129u8, 42u8, 84u8, 241u8, 45u8, 199u8, 179u8, - 128u8, 61u8, 170u8, 137u8, 231u8, 156u8, 247u8, 57u8, 47u8, 38u8, - ], - ) - } - #[doc = " Extrinsics data for the current block (maps an extrinsic's index to its data)."] - pub fn extrinsic_data( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u8>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "ExtrinsicData", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 160u8, 180u8, 122u8, 18u8, 196u8, 26u8, 2u8, 37u8, 115u8, 232u8, 133u8, - 220u8, 106u8, 245u8, 4u8, 129u8, 42u8, 84u8, 241u8, 45u8, 199u8, 179u8, - 128u8, 61u8, 170u8, 137u8, 231u8, 156u8, 247u8, 57u8, 47u8, 38u8, - ], - ) - } - #[doc = " The current block number being processed. Set by `execute_block`."] - pub fn number( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Number", - vec![], - [ - 30u8, 194u8, 177u8, 90u8, 194u8, 232u8, 46u8, 180u8, 85u8, 129u8, 14u8, - 9u8, 8u8, 8u8, 23u8, 95u8, 230u8, 5u8, 13u8, 105u8, 125u8, 2u8, 22u8, - 200u8, 78u8, 93u8, 115u8, 28u8, 150u8, 113u8, 48u8, 53u8, - ], - ) - } - #[doc = " Hash of the previous block."] - pub fn parent_hash( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "ParentHash", - vec![], - [ - 26u8, 130u8, 11u8, 216u8, 155u8, 71u8, 128u8, 170u8, 30u8, 153u8, 21u8, - 192u8, 62u8, 93u8, 137u8, 80u8, 120u8, 81u8, 202u8, 94u8, 248u8, 125u8, - 71u8, 82u8, 141u8, 229u8, 32u8, 56u8, 73u8, 50u8, 101u8, 78u8, - ], - ) - } - #[doc = " Digest of the current block, also part of the block header."] - pub fn digest( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_runtime::generic::digest::Digest, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Digest", - vec![], - [ - 61u8, 64u8, 237u8, 91u8, 145u8, 232u8, 17u8, 254u8, 181u8, 16u8, 234u8, - 91u8, 51u8, 140u8, 254u8, 131u8, 98u8, 135u8, 21u8, 37u8, 251u8, 20u8, - 58u8, 92u8, 123u8, 141u8, 14u8, 227u8, 146u8, 46u8, 222u8, 117u8, - ], - ) - } - #[doc = " Events deposited for the current block."] - #[doc = ""] - #[doc = " NOTE: The item is unbound and should therefore never be read on chain."] - #[doc = " It could otherwise inflate the PoV size of a block."] - #[doc = ""] - #[doc = " Events have a large in-memory size. Box the events to not go out-of-memory"] - #[doc = " just in case someone still reads them from within the runtime."] - pub fn events( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::frame_system::EventRecord< - runtime_types::rococo_runtime::RuntimeEvent, - ::subxt::utils::H256, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "Events", - vec![], - [ - 138u8, 52u8, 102u8, 47u8, 93u8, 113u8, 243u8, 175u8, 151u8, 246u8, - 194u8, 245u8, 184u8, 28u8, 30u8, 14u8, 192u8, 152u8, 139u8, 177u8, - 19u8, 32u8, 226u8, 99u8, 55u8, 152u8, 241u8, 166u8, 23u8, 209u8, 145u8, - 54u8, - ], - ) - } - #[doc = " The number of events in the `Events` list."] - pub fn event_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "EventCount", - vec![], - [ - 175u8, 24u8, 252u8, 184u8, 210u8, 167u8, 146u8, 143u8, 164u8, 80u8, - 151u8, 205u8, 189u8, 189u8, 55u8, 220u8, 47u8, 101u8, 181u8, 33u8, - 254u8, 131u8, 13u8, 143u8, 3u8, 244u8, 245u8, 45u8, 2u8, 210u8, 79u8, - 133u8, - ], - ) - } - #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] - #[doc = " of events in the `>` list."] - #[doc = ""] - #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] - #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] - #[doc = " in case of changes fetch the list of events of interest."] - #[doc = ""] - #[doc = " The value has the type `(BlockNumberFor, EventIndex)` because if we used only just"] - #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] - #[doc = " no notification will be triggered thus the event might be lost."] - pub fn event_topics_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "System", - "EventTopics", - vec![], - [ - 40u8, 225u8, 14u8, 75u8, 44u8, 176u8, 76u8, 34u8, 143u8, 107u8, 69u8, - 133u8, 114u8, 13u8, 172u8, 250u8, 141u8, 73u8, 12u8, 65u8, 217u8, 63u8, - 120u8, 241u8, 48u8, 106u8, 143u8, 161u8, 128u8, 100u8, 166u8, 59u8, - ], - ) - } - #[doc = " Mapping between a topic (represented by T::Hash) and a vector of indexes"] - #[doc = " of events in the `>` list."] - #[doc = ""] - #[doc = " All topic vectors have deterministic storage locations depending on the topic. This"] - #[doc = " allows light-clients to leverage the changes trie storage tracking mechanism and"] - #[doc = " in case of changes fetch the list of events of interest."] - #[doc = ""] - #[doc = " The value has the type `(BlockNumberFor, EventIndex)` because if we used only just"] - #[doc = " the `EventIndex` then in case if the topic has the same contents on the next block"] - #[doc = " no notification will be triggered thus the event might be lost."] - pub fn event_topics( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<(::core::primitive::u32, ::core::primitive::u32)>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "EventTopics", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 40u8, 225u8, 14u8, 75u8, 44u8, 176u8, 76u8, 34u8, 143u8, 107u8, 69u8, - 133u8, 114u8, 13u8, 172u8, 250u8, 141u8, 73u8, 12u8, 65u8, 217u8, 63u8, - 120u8, 241u8, 48u8, 106u8, 143u8, 161u8, 128u8, 100u8, 166u8, 59u8, - ], - ) - } - #[doc = " Stores the `spec_version` and `spec_name` of when the last runtime upgrade happened."] - pub fn last_runtime_upgrade( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::LastRuntimeUpgradeInfo, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "LastRuntimeUpgrade", - vec![], - [ - 137u8, 29u8, 175u8, 75u8, 197u8, 208u8, 91u8, 207u8, 156u8, 87u8, - 148u8, 68u8, 91u8, 140u8, 22u8, 233u8, 1u8, 229u8, 56u8, 34u8, 40u8, - 194u8, 253u8, 30u8, 163u8, 39u8, 54u8, 209u8, 13u8, 27u8, 139u8, 184u8, - ], - ) - } - #[doc = " True if we have upgraded so that `type RefCount` is `u32`. False (default) if not."] - pub fn upgraded_to_u32_ref_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "UpgradedToU32RefCount", - vec![], - [ - 229u8, 73u8, 9u8, 132u8, 186u8, 116u8, 151u8, 171u8, 145u8, 29u8, 34u8, - 130u8, 52u8, 146u8, 124u8, 175u8, 79u8, 189u8, 147u8, 230u8, 234u8, - 107u8, 124u8, 31u8, 2u8, 22u8, 86u8, 190u8, 4u8, 147u8, 50u8, 245u8, - ], - ) - } - #[doc = " True if we have upgraded so that AccountInfo contains three types of `RefCount`. False"] - #[doc = " (default) if not."] - pub fn upgraded_to_triple_ref_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "UpgradedToTripleRefCount", - vec![], - [ - 97u8, 66u8, 124u8, 243u8, 27u8, 167u8, 147u8, 81u8, 254u8, 201u8, - 101u8, 24u8, 40u8, 231u8, 14u8, 179u8, 154u8, 163u8, 71u8, 81u8, 185u8, - 167u8, 82u8, 254u8, 189u8, 3u8, 101u8, 207u8, 206u8, 194u8, 155u8, - 151u8, - ], - ) - } - #[doc = " The execution phase of the block."] - pub fn execution_phase( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::Phase, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "ExecutionPhase", - vec![], - [ - 191u8, 129u8, 100u8, 134u8, 126u8, 116u8, 154u8, 203u8, 220u8, 200u8, - 0u8, 26u8, 161u8, 250u8, 133u8, 205u8, 146u8, 24u8, 5u8, 156u8, 158u8, - 35u8, 36u8, 253u8, 52u8, 235u8, 86u8, 167u8, 35u8, 100u8, 119u8, 27u8, - ], - ) - } - #[doc = " `Some` if a code upgrade has been authorized."] - pub fn authorized_upgrade( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::frame_system::CodeUpgradeAuthorization, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "System", - "AuthorizedUpgrade", - vec![], - [ - 165u8, 97u8, 27u8, 138u8, 2u8, 28u8, 55u8, 92u8, 96u8, 96u8, 168u8, - 169u8, 55u8, 178u8, 44u8, 127u8, 58u8, 140u8, 206u8, 178u8, 1u8, 37u8, - 214u8, 213u8, 251u8, 123u8, 5u8, 111u8, 90u8, 148u8, 217u8, 135u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Block & extrinsics weights: base values and limits."] - pub fn block_weights( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "System", - "BlockWeights", - [ - 176u8, 124u8, 225u8, 136u8, 25u8, 73u8, 247u8, 33u8, 82u8, 206u8, 85u8, - 190u8, 127u8, 102u8, 71u8, 11u8, 185u8, 8u8, 58u8, 0u8, 94u8, 55u8, - 163u8, 177u8, 104u8, 59u8, 60u8, 136u8, 246u8, 116u8, 0u8, 239u8, - ], - ) - } - #[doc = " The maximum length of a block (in bytes)."] - pub fn block_length( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "System", - "BlockLength", - [ - 23u8, 242u8, 225u8, 39u8, 225u8, 67u8, 152u8, 41u8, 155u8, 104u8, 68u8, - 229u8, 185u8, 133u8, 10u8, 143u8, 184u8, 152u8, 234u8, 44u8, 140u8, - 96u8, 166u8, 235u8, 162u8, 160u8, 72u8, 7u8, 35u8, 194u8, 3u8, 37u8, - ], - ) - } - #[doc = " Maximum number of block number to block hash mappings to keep (oldest pruned first)."] - pub fn block_hash_count( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "System", - "BlockHashCount", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The weight of runtime database operations the runtime can invoke."] - pub fn db_weight( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "System", - "DbWeight", - [ - 42u8, 43u8, 178u8, 142u8, 243u8, 203u8, 60u8, 173u8, 118u8, 111u8, - 200u8, 170u8, 102u8, 70u8, 237u8, 187u8, 198u8, 120u8, 153u8, 232u8, - 183u8, 76u8, 74u8, 10u8, 70u8, 243u8, 14u8, 218u8, 213u8, 126u8, 29u8, - 177u8, - ], - ) - } - #[doc = " Get the chain's current version."] - pub fn version( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "System", - "Version", - [ - 219u8, 45u8, 162u8, 245u8, 177u8, 246u8, 48u8, 126u8, 191u8, 157u8, - 228u8, 83u8, 111u8, 133u8, 183u8, 13u8, 148u8, 108u8, 92u8, 102u8, - 72u8, 205u8, 74u8, 242u8, 233u8, 79u8, 20u8, 170u8, 72u8, 202u8, 158u8, - 165u8, - ], - ) - } - #[doc = " The designated SS58 prefix of this chain."] - #[doc = ""] - #[doc = " This replaces the \"ss58Format\" property declared in the chain spec. Reason is"] - #[doc = " that the runtime should know about the prefix in order to make use of it as"] - #[doc = " an identifier of the chain."] - pub fn ss58_prefix(&self) -> ::subxt::constants::Address<::core::primitive::u16> { - ::subxt::constants::Address::new_static( - "System", - "SS58Prefix", - [ - 116u8, 33u8, 2u8, 170u8, 181u8, 147u8, 171u8, 169u8, 167u8, 227u8, - 41u8, 144u8, 11u8, 236u8, 82u8, 100u8, 74u8, 60u8, 184u8, 72u8, 169u8, - 90u8, 208u8, 135u8, 15u8, 117u8, 10u8, 123u8, 128u8, 193u8, 29u8, 70u8, - ], - ) - } - } - } - } - pub mod babe { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_babe::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_babe::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocation { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - impl ::subxt::blocks::StaticExtrinsic for ReportEquivocation { - const PALLET: &'static str = "Babe"; - const CALL: &'static str = "report_equivocation"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocationUnsigned { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - impl ::subxt::blocks::StaticExtrinsic for ReportEquivocationUnsigned { - const PALLET: &'static str = "Babe"; - const CALL: &'static str = "report_equivocation_unsigned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlanConfigChange { - pub config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - } - impl ::subxt::blocks::StaticExtrinsic for PlanConfigChange { - const PALLET: &'static str = "Babe"; - const CALL: &'static str = "plan_config_change"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::report_equivocation`]."] - pub fn report_equivocation( - &self, - equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - runtime_types::sp_consensus_babe::app::Public, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Babe", - "report_equivocation", - types::ReportEquivocation { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 37u8, 70u8, 151u8, 149u8, 231u8, 197u8, 226u8, 88u8, 38u8, 138u8, - 147u8, 164u8, 250u8, 117u8, 156u8, 178u8, 44u8, 20u8, 123u8, 33u8, - 11u8, 106u8, 56u8, 122u8, 90u8, 11u8, 15u8, 219u8, 245u8, 18u8, 171u8, - 90u8, - ], - ) - } - #[doc = "See [`Pallet::report_equivocation_unsigned`]."] - pub fn report_equivocation_unsigned( - &self, - equivocation_proof: runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - runtime_types::sp_consensus_babe::app::Public, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Babe", - "report_equivocation_unsigned", - types::ReportEquivocationUnsigned { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 179u8, 248u8, 80u8, 171u8, 220u8, 8u8, 75u8, 215u8, 121u8, 151u8, - 255u8, 4u8, 6u8, 54u8, 141u8, 244u8, 111u8, 156u8, 183u8, 19u8, 192u8, - 195u8, 79u8, 53u8, 0u8, 170u8, 120u8, 227u8, 186u8, 45u8, 48u8, 57u8, - ], - ) - } - #[doc = "See [`Pallet::plan_config_change`]."] - pub fn plan_config_change( - &self, - config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Babe", - "plan_config_change", - types::PlanConfigChange { config }, - [ - 227u8, 155u8, 182u8, 231u8, 240u8, 107u8, 30u8, 22u8, 15u8, 52u8, - 172u8, 203u8, 115u8, 47u8, 6u8, 66u8, 170u8, 231u8, 186u8, 77u8, 19u8, - 235u8, 91u8, 136u8, 95u8, 149u8, 188u8, 163u8, 161u8, 109u8, 164u8, - 179u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Current epoch index."] - pub fn epoch_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "EpochIndex", - vec![], - [ - 32u8, 82u8, 130u8, 31u8, 190u8, 162u8, 237u8, 189u8, 104u8, 244u8, - 30u8, 199u8, 179u8, 0u8, 161u8, 107u8, 72u8, 240u8, 201u8, 222u8, - 177u8, 222u8, 35u8, 156u8, 81u8, 132u8, 162u8, 118u8, 238u8, 84u8, - 112u8, 89u8, - ], - ) - } - #[doc = " Current epoch authorities."] - pub fn authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( - runtime_types::sp_consensus_babe::app::Public, - ::core::primitive::u64, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "Authorities", - vec![], - [ - 67u8, 196u8, 244u8, 13u8, 246u8, 245u8, 198u8, 98u8, 81u8, 55u8, 182u8, - 187u8, 214u8, 5u8, 181u8, 76u8, 251u8, 213u8, 144u8, 166u8, 36u8, - 153u8, 234u8, 181u8, 252u8, 55u8, 198u8, 175u8, 55u8, 211u8, 105u8, - 85u8, - ], - ) - } - #[doc = " The slot at which the first epoch actually started. This is 0"] - #[doc = " until the first block of the chain."] - pub fn genesis_slot( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_slots::Slot, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "GenesisSlot", - vec![], - [ - 218u8, 174u8, 152u8, 76u8, 188u8, 214u8, 7u8, 88u8, 253u8, 187u8, - 139u8, 234u8, 51u8, 28u8, 220u8, 57u8, 73u8, 1u8, 18u8, 205u8, 80u8, - 160u8, 120u8, 216u8, 139u8, 191u8, 100u8, 108u8, 162u8, 106u8, 175u8, - 107u8, - ], - ) - } - #[doc = " Current slot number."] - pub fn current_slot( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_slots::Slot, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "CurrentSlot", - vec![], - [ - 112u8, 199u8, 115u8, 248u8, 217u8, 242u8, 45u8, 231u8, 178u8, 53u8, - 236u8, 167u8, 219u8, 238u8, 81u8, 243u8, 39u8, 140u8, 68u8, 19u8, - 201u8, 169u8, 211u8, 133u8, 135u8, 213u8, 150u8, 105u8, 60u8, 252u8, - 43u8, 57u8, - ], - ) - } - #[doc = " The epoch randomness for the *current* epoch."] - #[doc = ""] - #[doc = " # Security"] - #[doc = ""] - #[doc = " This MUST NOT be used for gambling, as it can be influenced by a"] - #[doc = " malicious validator in the short term. It MAY be used in many"] - #[doc = " cryptographic protocols, however, so long as one remembers that this"] - #[doc = " (like everything else on-chain) it is public. For example, it can be"] - #[doc = " used where a number is needed that cannot have been chosen by an"] - #[doc = " adversary, for purposes such as public-coin zero-knowledge proofs."] - pub fn randomness( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - [::core::primitive::u8; 32usize], - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "Randomness", - vec![], - [ - 36u8, 15u8, 52u8, 73u8, 195u8, 177u8, 186u8, 125u8, 134u8, 11u8, 103u8, - 248u8, 170u8, 237u8, 105u8, 239u8, 168u8, 204u8, 147u8, 52u8, 15u8, - 226u8, 126u8, 176u8, 133u8, 186u8, 169u8, 241u8, 156u8, 118u8, 67u8, - 58u8, - ], - ) - } - #[doc = " Pending epoch configuration change that will be applied when the next epoch is enacted."] - pub fn pending_epoch_config_change( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "PendingEpochConfigChange", - vec![], - [ - 79u8, 216u8, 84u8, 210u8, 83u8, 149u8, 122u8, 160u8, 159u8, 164u8, - 16u8, 134u8, 154u8, 104u8, 77u8, 254u8, 139u8, 18u8, 163u8, 59u8, 92u8, - 9u8, 135u8, 141u8, 147u8, 86u8, 44u8, 95u8, 183u8, 101u8, 11u8, 58u8, - ], - ) - } - #[doc = " Next epoch randomness."] - pub fn next_randomness( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - [::core::primitive::u8; 32usize], - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "NextRandomness", - vec![], - [ - 96u8, 191u8, 139u8, 171u8, 144u8, 92u8, 33u8, 58u8, 23u8, 219u8, 164u8, - 121u8, 59u8, 209u8, 112u8, 244u8, 50u8, 8u8, 14u8, 244u8, 103u8, 125u8, - 120u8, 210u8, 16u8, 250u8, 54u8, 192u8, 72u8, 8u8, 219u8, 152u8, - ], - ) - } - #[doc = " Next epoch authorities."] - pub fn next_authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( - runtime_types::sp_consensus_babe::app::Public, - ::core::primitive::u64, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "NextAuthorities", - vec![], - [ - 116u8, 95u8, 126u8, 199u8, 237u8, 90u8, 202u8, 227u8, 247u8, 56u8, - 201u8, 113u8, 239u8, 191u8, 151u8, 56u8, 156u8, 133u8, 61u8, 64u8, - 141u8, 26u8, 8u8, 95u8, 177u8, 255u8, 54u8, 223u8, 132u8, 74u8, 210u8, - 128u8, - ], - ) - } - #[doc = " Randomness under construction."] - #[doc = ""] - #[doc = " We make a trade-off between storage accesses and list length."] - #[doc = " We store the under-construction randomness in segments of up to"] - #[doc = " `UNDER_CONSTRUCTION_SEGMENT_LENGTH`."] - #[doc = ""] - #[doc = " Once a segment reaches this length, we begin the next one."] - #[doc = " We reset all segments and return to `0` at the beginning of every"] - #[doc = " epoch."] - pub fn segment_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "SegmentIndex", - vec![], - [ - 145u8, 91u8, 142u8, 240u8, 184u8, 94u8, 68u8, 52u8, 130u8, 3u8, 75u8, - 175u8, 155u8, 130u8, 66u8, 9u8, 150u8, 242u8, 123u8, 111u8, 124u8, - 241u8, 100u8, 128u8, 220u8, 133u8, 96u8, 227u8, 164u8, 241u8, 170u8, - 34u8, - ], - ) - } - #[doc = " TWOX-NOTE: `SegmentIndex` is an increasing integer, so this is okay."] - pub fn under_construction_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - [::core::primitive::u8; 32usize], - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "UnderConstruction", - vec![], - [ - 120u8, 120u8, 59u8, 247u8, 50u8, 6u8, 220u8, 14u8, 2u8, 76u8, 203u8, - 244u8, 232u8, 144u8, 253u8, 191u8, 101u8, 35u8, 99u8, 85u8, 111u8, - 168u8, 31u8, 110u8, 187u8, 124u8, 72u8, 32u8, 43u8, 66u8, 8u8, 215u8, - ], - ) - } - #[doc = " TWOX-NOTE: `SegmentIndex` is an increasing integer, so this is okay."] - pub fn under_construction( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - [::core::primitive::u8; 32usize], - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "UnderConstruction", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 120u8, 120u8, 59u8, 247u8, 50u8, 6u8, 220u8, 14u8, 2u8, 76u8, 203u8, - 244u8, 232u8, 144u8, 253u8, 191u8, 101u8, 35u8, 99u8, 85u8, 111u8, - 168u8, 31u8, 110u8, 187u8, 124u8, 72u8, 32u8, 43u8, 66u8, 8u8, 215u8, - ], - ) - } - #[doc = " Temporary value (cleared at block finalization) which is `Some`"] - #[doc = " if per-block initialization has already been called for current block."] - pub fn initialized( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "Initialized", - vec![], - [ - 169u8, 217u8, 237u8, 78u8, 186u8, 202u8, 206u8, 213u8, 54u8, 85u8, - 206u8, 166u8, 22u8, 138u8, 236u8, 60u8, 211u8, 169u8, 12u8, 183u8, - 23u8, 69u8, 194u8, 236u8, 112u8, 21u8, 62u8, 219u8, 92u8, 131u8, 134u8, - 145u8, - ], - ) - } - #[doc = " This field should always be populated during block processing unless"] - #[doc = " secondary plain slots are enabled (which don't contain a VRF output)."] - #[doc = ""] - #[doc = " It is set in `on_finalize`, before it will contain the value from the last block."] - pub fn author_vrf_randomness( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option<[::core::primitive::u8; 32usize]>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "AuthorVrfRandomness", - vec![], - [ - 160u8, 157u8, 62u8, 48u8, 196u8, 136u8, 63u8, 132u8, 155u8, 183u8, - 91u8, 201u8, 146u8, 29u8, 192u8, 142u8, 168u8, 152u8, 197u8, 233u8, - 5u8, 25u8, 0u8, 154u8, 234u8, 180u8, 146u8, 132u8, 106u8, 164u8, 149u8, - 63u8, - ], - ) - } - #[doc = " The block numbers when the last and current epoch have started, respectively `N-1` and"] - #[doc = " `N`."] - #[doc = " NOTE: We track this is in order to annotate the block number when a given pool of"] - #[doc = " entropy was fixed (i.e. it was known to chain observers). Since epochs are defined in"] - #[doc = " slots, which may be skipped, the block numbers may not line up with the slot numbers."] - pub fn epoch_start( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "EpochStart", - vec![], - [ - 144u8, 133u8, 140u8, 56u8, 241u8, 203u8, 199u8, 123u8, 244u8, 126u8, - 196u8, 151u8, 214u8, 204u8, 243u8, 244u8, 210u8, 198u8, 174u8, 126u8, - 200u8, 236u8, 248u8, 190u8, 181u8, 152u8, 113u8, 224u8, 95u8, 234u8, - 169u8, 14u8, - ], - ) - } - #[doc = " How late the current block is compared to its parent."] - #[doc = ""] - #[doc = " This entry is populated as part of block execution and is cleaned up"] - #[doc = " on block finalization. Querying this storage entry outside of block"] - #[doc = " execution context should always yield zero."] - pub fn lateness( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "Lateness", - vec![], - [ - 229u8, 214u8, 133u8, 149u8, 32u8, 159u8, 26u8, 22u8, 252u8, 131u8, - 200u8, 191u8, 231u8, 176u8, 178u8, 127u8, 33u8, 212u8, 139u8, 220u8, - 157u8, 38u8, 4u8, 226u8, 204u8, 32u8, 55u8, 20u8, 205u8, 141u8, 29u8, - 87u8, - ], - ) - } - #[doc = " The configuration for the current epoch. Should never be `None` as it is initialized in"] - #[doc = " genesis."] - pub fn epoch_config( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_babe::BabeEpochConfiguration, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "EpochConfig", - vec![], - [ - 151u8, 58u8, 93u8, 2u8, 19u8, 98u8, 41u8, 144u8, 241u8, 70u8, 195u8, - 37u8, 126u8, 241u8, 111u8, 65u8, 16u8, 228u8, 111u8, 220u8, 241u8, - 215u8, 179u8, 235u8, 122u8, 88u8, 92u8, 95u8, 131u8, 252u8, 236u8, - 46u8, - ], - ) - } - #[doc = " The configuration for the next epoch, `None` if the config will not change"] - #[doc = " (you can fallback to `EpochConfig` instead in that case)."] - pub fn next_epoch_config( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_babe::BabeEpochConfiguration, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "NextEpochConfig", - vec![], - [ - 65u8, 54u8, 74u8, 141u8, 193u8, 124u8, 130u8, 238u8, 106u8, 27u8, - 221u8, 189u8, 103u8, 53u8, 39u8, 243u8, 212u8, 216u8, 75u8, 185u8, - 104u8, 220u8, 70u8, 108u8, 87u8, 172u8, 201u8, 185u8, 39u8, 55u8, - 145u8, 6u8, - ], - ) - } - #[doc = " A list of the last 100 skipped epochs and the corresponding session index"] - #[doc = " when the epoch was skipped."] - #[doc = ""] - #[doc = " This is only used for validating equivocation proofs. An equivocation proof"] - #[doc = " must contains a key-ownership proof for a given session, therefore we need a"] - #[doc = " way to tie together sessions and epoch indices, i.e. we need to validate that"] - #[doc = " a validator was the owner of a given key on a given session, and what the"] - #[doc = " active epoch index was during that session."] - pub fn skipped_epochs( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u64, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Babe", - "SkippedEpochs", - vec![], - [ - 120u8, 167u8, 144u8, 97u8, 41u8, 216u8, 103u8, 90u8, 3u8, 86u8, 196u8, - 35u8, 160u8, 150u8, 144u8, 233u8, 128u8, 35u8, 119u8, 66u8, 6u8, 63u8, - 114u8, 140u8, 182u8, 228u8, 192u8, 30u8, 50u8, 145u8, 217u8, 108u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The amount of time, in slots, that each epoch should last."] - #[doc = " NOTE: Currently it is not possible to change the epoch duration after"] - #[doc = " the chain has started. Attempting to do so will brick block production."] - pub fn epoch_duration( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Babe", - "EpochDuration", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - #[doc = " The expected average block time at which BABE should be creating"] - #[doc = " blocks. Since BABE is probabilistic it is not trivial to figure out"] - #[doc = " what the expected average block time should be based on the slot"] - #[doc = " duration and the security parameter `c` (where `1 - c` represents"] - #[doc = " the probability of a slot being empty)."] - pub fn expected_block_time( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Babe", - "ExpectedBlockTime", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - #[doc = " Max number of authorities allowed"] - pub fn max_authorities( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Babe", - "MaxAuthorities", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of nominators for each validator."] - pub fn max_nominators( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Babe", - "MaxNominators", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod timestamp { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_timestamp::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Set { - #[codec(compact)] - pub now: ::core::primitive::u64, - } - impl ::subxt::blocks::StaticExtrinsic for Set { - const PALLET: &'static str = "Timestamp"; - const CALL: &'static str = "set"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::set`]."] - pub fn set(&self, now: ::core::primitive::u64) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Timestamp", - "set", - types::Set { now }, - [ - 37u8, 95u8, 49u8, 218u8, 24u8, 22u8, 0u8, 95u8, 72u8, 35u8, 155u8, - 199u8, 213u8, 54u8, 207u8, 22u8, 185u8, 193u8, 221u8, 70u8, 18u8, - 200u8, 4u8, 231u8, 195u8, 173u8, 6u8, 122u8, 11u8, 203u8, 231u8, 227u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current time for the current block."] - pub fn now( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Timestamp", - "Now", - vec![], - [ - 44u8, 50u8, 80u8, 30u8, 195u8, 146u8, 123u8, 238u8, 8u8, 163u8, 187u8, - 92u8, 61u8, 39u8, 51u8, 29u8, 173u8, 169u8, 217u8, 158u8, 85u8, 187u8, - 141u8, 26u8, 12u8, 115u8, 51u8, 11u8, 200u8, 244u8, 138u8, 152u8, - ], - ) - } - #[doc = " Whether the timestamp has been updated in this block."] - #[doc = ""] - #[doc = " This value is updated to `true` upon successful submission of a timestamp by a node."] - #[doc = " It is then checked at the end of each block execution in the `on_finalize` hook."] - pub fn did_update( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Timestamp", - "DidUpdate", - vec![], - [ - 229u8, 175u8, 246u8, 102u8, 237u8, 158u8, 212u8, 229u8, 238u8, 214u8, - 205u8, 160u8, 164u8, 252u8, 195u8, 75u8, 139u8, 110u8, 22u8, 34u8, - 248u8, 204u8, 107u8, 46u8, 20u8, 200u8, 238u8, 167u8, 71u8, 41u8, - 214u8, 140u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum period between blocks."] - #[doc = ""] - #[doc = " Be aware that this is different to the *expected* period that the block production"] - #[doc = " apparatus provides. Your chosen consensus system will generally work with this to"] - #[doc = " determine a sensible block time. For example, in the Aura pallet it will be double this"] - #[doc = " period on default settings."] - pub fn minimum_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Timestamp", - "MinimumPeriod", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - } - } - } - pub mod indices { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_indices::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_indices::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Claim { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Claim { - const PALLET: &'static str = "Indices"; - const CALL: &'static str = "claim"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Transfer { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Transfer { - const PALLET: &'static str = "Indices"; - const CALL: &'static str = "transfer"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Free { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Free { - const PALLET: &'static str = "Indices"; - const CALL: &'static str = "free"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceTransfer { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub index: ::core::primitive::u32, - pub freeze: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for ForceTransfer { - const PALLET: &'static str = "Indices"; - const CALL: &'static str = "force_transfer"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Freeze { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Freeze { - const PALLET: &'static str = "Indices"; - const CALL: &'static str = "freeze"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::claim`]."] - pub fn claim( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Indices", - "claim", - types::Claim { index }, - [ - 146u8, 58u8, 246u8, 135u8, 59u8, 90u8, 3u8, 5u8, 140u8, 169u8, 232u8, - 195u8, 11u8, 107u8, 36u8, 141u8, 118u8, 174u8, 160u8, 160u8, 19u8, - 205u8, 177u8, 193u8, 18u8, 102u8, 115u8, 31u8, 72u8, 29u8, 91u8, 235u8, - ], - ) - } - #[doc = "See [`Pallet::transfer`]."] - pub fn transfer( - &self, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Indices", - "transfer", - types::Transfer { new, index }, - [ - 121u8, 156u8, 174u8, 248u8, 72u8, 126u8, 99u8, 188u8, 71u8, 134u8, - 107u8, 147u8, 139u8, 139u8, 57u8, 198u8, 17u8, 241u8, 142u8, 64u8, - 16u8, 121u8, 249u8, 146u8, 24u8, 86u8, 78u8, 187u8, 38u8, 146u8, 96u8, - 218u8, - ], - ) - } - #[doc = "See [`Pallet::free`]."] - pub fn free( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Indices", - "free", - types::Free { index }, - [ - 241u8, 211u8, 234u8, 102u8, 189u8, 22u8, 209u8, 27u8, 8u8, 229u8, 80u8, - 227u8, 138u8, 252u8, 222u8, 111u8, 77u8, 201u8, 235u8, 51u8, 163u8, - 247u8, 13u8, 126u8, 216u8, 136u8, 57u8, 222u8, 56u8, 66u8, 215u8, - 244u8, - ], - ) - } - #[doc = "See [`Pallet::force_transfer`]."] - pub fn force_transfer( - &self, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - index: ::core::primitive::u32, - freeze: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Indices", - "force_transfer", - types::ForceTransfer { new, index, freeze }, - [ - 137u8, 128u8, 43u8, 135u8, 129u8, 169u8, 162u8, 136u8, 175u8, 31u8, - 161u8, 120u8, 15u8, 176u8, 203u8, 23u8, 107u8, 31u8, 135u8, 200u8, - 221u8, 186u8, 162u8, 229u8, 238u8, 82u8, 192u8, 122u8, 136u8, 6u8, - 176u8, 42u8, - ], - ) - } - #[doc = "See [`Pallet::freeze`]."] - pub fn freeze( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Indices", - "freeze", - types::Freeze { index }, - [ - 238u8, 215u8, 108u8, 156u8, 84u8, 240u8, 130u8, 229u8, 27u8, 132u8, - 93u8, 78u8, 2u8, 251u8, 43u8, 203u8, 2u8, 142u8, 147u8, 48u8, 92u8, - 101u8, 207u8, 24u8, 51u8, 16u8, 36u8, 229u8, 188u8, 129u8, 160u8, - 117u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_indices::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A account index was assigned."] - pub struct IndexAssigned { - pub who: ::subxt::utils::AccountId32, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for IndexAssigned { - const PALLET: &'static str = "Indices"; - const EVENT: &'static str = "IndexAssigned"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A account index has been freed up (unassigned)."] - pub struct IndexFreed { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for IndexFreed { - const PALLET: &'static str = "Indices"; - const EVENT: &'static str = "IndexFreed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A account index has been frozen to its current account ID."] - pub struct IndexFrozen { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for IndexFrozen { - const PALLET: &'static str = "Indices"; - const EVENT: &'static str = "IndexFrozen"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The lookup from index to account."] - pub fn accounts_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::subxt::utils::AccountId32, ::core::primitive::u128, ::core::primitive::bool), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Indices", - "Accounts", - vec![], - [ - 48u8, 189u8, 43u8, 119u8, 32u8, 168u8, 28u8, 12u8, 245u8, 81u8, 119u8, - 182u8, 23u8, 201u8, 33u8, 147u8, 128u8, 171u8, 155u8, 134u8, 71u8, - 87u8, 100u8, 248u8, 107u8, 129u8, 36u8, 197u8, 220u8, 90u8, 11u8, - 238u8, - ], - ) - } - #[doc = " The lookup from index to account."] - pub fn accounts( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::subxt::utils::AccountId32, ::core::primitive::u128, ::core::primitive::bool), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Indices", - "Accounts", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 48u8, 189u8, 43u8, 119u8, 32u8, 168u8, 28u8, 12u8, 245u8, 81u8, 119u8, - 182u8, 23u8, 201u8, 33u8, 147u8, 128u8, 171u8, 155u8, 134u8, 71u8, - 87u8, 100u8, 248u8, 107u8, 129u8, 36u8, 197u8, 220u8, 90u8, 11u8, - 238u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The deposit needed for reserving an index."] - pub fn deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Indices", - "Deposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - } - } - } - pub mod balances { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_balances::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_balances::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAllowDeath { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for TransferAllowDeath { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "transfer_allow_death"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceTransfer { - pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceTransfer { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "force_transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferKeepAlive { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for TransferKeepAlive { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "transfer_keep_alive"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAll { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub keep_alive: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for TransferAll { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "transfer_all"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnreserve { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub amount: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceUnreserve { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "force_unreserve"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpgradeAccounts { - pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - impl ::subxt::blocks::StaticExtrinsic for UpgradeAccounts { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "upgrade_accounts"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetBalance { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub new_free: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSetBalance { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "force_set_balance"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceAdjustTotalIssuance { - pub direction: runtime_types::pallet_balances::types::AdjustmentDirection, - #[codec(compact)] - pub delta: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceAdjustTotalIssuance { - const PALLET: &'static str = "Balances"; - const CALL: &'static str = "force_adjust_total_issuance"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::transfer_allow_death`]."] - pub fn transfer_allow_death( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_allow_death", - types::TransferAllowDeath { dest, value }, - [ - 51u8, 166u8, 195u8, 10u8, 139u8, 218u8, 55u8, 130u8, 6u8, 194u8, 35u8, - 140u8, 27u8, 205u8, 214u8, 222u8, 102u8, 43u8, 143u8, 145u8, 86u8, - 219u8, 210u8, 147u8, 13u8, 39u8, 51u8, 21u8, 237u8, 179u8, 132u8, - 130u8, - ], - ) - } - #[doc = "See [`Pallet::force_transfer`]."] - pub fn force_transfer( - &self, - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_transfer", - types::ForceTransfer { source, dest, value }, - [ - 154u8, 93u8, 222u8, 27u8, 12u8, 248u8, 63u8, 213u8, 224u8, 86u8, 250u8, - 153u8, 249u8, 102u8, 83u8, 160u8, 79u8, 125u8, 105u8, 222u8, 77u8, - 180u8, 90u8, 105u8, 81u8, 217u8, 60u8, 25u8, 213u8, 51u8, 185u8, 96u8, - ], - ) - } - #[doc = "See [`Pallet::transfer_keep_alive`]."] - pub fn transfer_keep_alive( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_keep_alive", - types::TransferKeepAlive { dest, value }, - [ - 245u8, 14u8, 190u8, 193u8, 32u8, 210u8, 74u8, 92u8, 25u8, 182u8, 76u8, - 55u8, 247u8, 83u8, 114u8, 75u8, 143u8, 236u8, 117u8, 25u8, 54u8, 157u8, - 208u8, 207u8, 233u8, 89u8, 70u8, 161u8, 235u8, 242u8, 222u8, 59u8, - ], - ) - } - #[doc = "See [`Pallet::transfer_all`]."] - pub fn transfer_all( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "transfer_all", - types::TransferAll { dest, keep_alive }, - [ - 105u8, 132u8, 49u8, 144u8, 195u8, 250u8, 34u8, 46u8, 213u8, 248u8, - 112u8, 188u8, 81u8, 228u8, 136u8, 18u8, 67u8, 172u8, 37u8, 38u8, 238u8, - 9u8, 34u8, 15u8, 67u8, 34u8, 148u8, 195u8, 223u8, 29u8, 154u8, 6u8, - ], - ) - } - #[doc = "See [`Pallet::force_unreserve`]."] - pub fn force_unreserve( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_unreserve", - types::ForceUnreserve { who, amount }, - [ - 142u8, 151u8, 64u8, 205u8, 46u8, 64u8, 62u8, 122u8, 108u8, 49u8, 223u8, - 140u8, 120u8, 153u8, 35u8, 165u8, 187u8, 38u8, 157u8, 200u8, 123u8, - 199u8, 198u8, 168u8, 208u8, 159u8, 39u8, 134u8, 92u8, 103u8, 84u8, - 171u8, - ], - ) - } - #[doc = "See [`Pallet::upgrade_accounts`]."] - pub fn upgrade_accounts( - &self, - who: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "upgrade_accounts", - types::UpgradeAccounts { who }, - [ - 66u8, 200u8, 179u8, 104u8, 65u8, 2u8, 101u8, 56u8, 130u8, 161u8, 224u8, - 233u8, 255u8, 124u8, 70u8, 122u8, 8u8, 49u8, 103u8, 178u8, 68u8, 47u8, - 214u8, 166u8, 217u8, 116u8, 178u8, 50u8, 212u8, 164u8, 98u8, 226u8, - ], - ) - } - #[doc = "See [`Pallet::force_set_balance`]."] - pub fn force_set_balance( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - new_free: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_set_balance", - types::ForceSetBalance { who, new_free }, - [ - 114u8, 229u8, 59u8, 204u8, 180u8, 83u8, 17u8, 4u8, 59u8, 4u8, 55u8, - 39u8, 151u8, 196u8, 124u8, 60u8, 209u8, 65u8, 193u8, 11u8, 44u8, 164u8, - 116u8, 93u8, 169u8, 30u8, 199u8, 165u8, 55u8, 231u8, 223u8, 43u8, - ], - ) - } - #[doc = "See [`Pallet::force_adjust_total_issuance`]."] - pub fn force_adjust_total_issuance( - &self, - direction: runtime_types::pallet_balances::types::AdjustmentDirection, - delta: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Balances", - "force_adjust_total_issuance", - types::ForceAdjustTotalIssuance { direction, delta }, - [ - 208u8, 134u8, 56u8, 133u8, 232u8, 164u8, 10u8, 213u8, 53u8, 193u8, - 190u8, 63u8, 236u8, 186u8, 96u8, 122u8, 104u8, 87u8, 173u8, 38u8, 58u8, - 176u8, 21u8, 78u8, 42u8, 106u8, 46u8, 248u8, 251u8, 190u8, 150u8, - 202u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_balances::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was created with some free balance."] - pub struct Endowed { - pub account: ::subxt::utils::AccountId32, - pub free_balance: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Endowed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Endowed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] - #[doc = "resulting in an outright loss."] - pub struct DustLost { - pub account: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DustLost { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "DustLost"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Transfer succeeded."] - pub struct Transfer { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Transfer { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A balance was set by root."] - pub struct BalanceSet { - pub who: ::subxt::utils::AccountId32, - pub free: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for BalanceSet { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "BalanceSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was reserved (moved from free to reserved)."] - pub struct Reserved { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Reserved { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Reserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was unreserved (moved from reserved to free)."] - pub struct Unreserved { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unreserved { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Unreserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was moved from the reserve of the first account to the second account."] - #[doc = "Final argument indicates the destination balance type."] - pub struct ReserveRepatriated { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - } - impl ::subxt::events::StaticEvent for ReserveRepatriated { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "ReserveRepatriated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was deposited (e.g. for transaction fees)."] - pub struct Deposit { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Deposit { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Deposit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] - pub struct Withdraw { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdraw { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Withdraw"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] - pub struct Slashed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Slashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was minted into an account."] - pub struct Minted { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Minted { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Minted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was burned from an account."] - pub struct Burned { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Burned { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Burned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was suspended from an account (it can be restored later)."] - pub struct Suspended { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Suspended { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Suspended"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was restored into an account."] - pub struct Restored { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Restored { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Restored"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was upgraded."] - pub struct Upgraded { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Upgraded { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Upgraded"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] - pub struct Issued { - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Issued { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Issued"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] - pub struct Rescinded { - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Rescinded { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Rescinded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was locked."] - pub struct Locked { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Locked { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Locked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was unlocked."] - pub struct Unlocked { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unlocked { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Unlocked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was frozen."] - pub struct Frozen { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Frozen { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Frozen"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was thawed."] - pub struct Thawed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Thawed { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "Thawed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `TotalIssuance` was forcefully changed."] - pub struct TotalIssuanceForced { - pub old: ::core::primitive::u128, - pub new: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for TotalIssuanceForced { - const PALLET: &'static str = "Balances"; - const EVENT: &'static str = "TotalIssuanceForced"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The total units issued in the system."] - pub fn total_issuance( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "TotalIssuance", - vec![], - [ - 116u8, 70u8, 119u8, 194u8, 69u8, 37u8, 116u8, 206u8, 171u8, 70u8, - 171u8, 210u8, 226u8, 111u8, 184u8, 204u8, 206u8, 11u8, 68u8, 72u8, - 255u8, 19u8, 194u8, 11u8, 27u8, 194u8, 81u8, 204u8, 59u8, 224u8, 202u8, - 185u8, - ], - ) - } - #[doc = " The total units of outstanding deactivated balance in the system."] - pub fn inactive_issuance( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "InactiveIssuance", - vec![], - [ - 212u8, 185u8, 19u8, 50u8, 250u8, 72u8, 173u8, 50u8, 4u8, 104u8, 161u8, - 249u8, 77u8, 247u8, 204u8, 248u8, 11u8, 18u8, 57u8, 4u8, 82u8, 110u8, - 30u8, 216u8, 16u8, 37u8, 87u8, 67u8, 189u8, 235u8, 214u8, 155u8, - ], - ) - } - #[doc = " The Balances pallet example of storing the balance of an account."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " You can also store the balance of an account in the `System` pallet."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = System"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] - #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] - #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] - #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] - pub fn account_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Account", - vec![], - [ - 213u8, 38u8, 200u8, 69u8, 218u8, 0u8, 112u8, 181u8, 160u8, 23u8, 96u8, - 90u8, 3u8, 88u8, 126u8, 22u8, 103u8, 74u8, 64u8, 69u8, 29u8, 247u8, - 18u8, 17u8, 234u8, 143u8, 189u8, 22u8, 247u8, 194u8, 154u8, 249u8, - ], - ) - } - #[doc = " The Balances pallet example of storing the balance of an account."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " You can also store the balance of an account in the `System` pallet."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = System"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] - #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] - #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] - #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] - pub fn account( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Account", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 213u8, 38u8, 200u8, 69u8, 218u8, 0u8, 112u8, 181u8, 160u8, 23u8, 96u8, - 90u8, 3u8, 88u8, 126u8, 22u8, 103u8, 74u8, 64u8, 69u8, 29u8, 247u8, - 18u8, 17u8, 234u8, 143u8, 189u8, 22u8, 247u8, 194u8, 154u8, 249u8, - ], - ) - } - #[doc = " Any liquidity locks on some account balances."] - #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] - pub fn locks_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Locks", - vec![], - [ - 10u8, 223u8, 55u8, 0u8, 249u8, 69u8, 168u8, 41u8, 75u8, 35u8, 120u8, - 167u8, 18u8, 132u8, 9u8, 20u8, 91u8, 51u8, 27u8, 69u8, 136u8, 187u8, - 13u8, 220u8, 163u8, 122u8, 26u8, 141u8, 174u8, 249u8, 85u8, 37u8, - ], - ) - } - #[doc = " Any liquidity locks on some account balances."] - #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] - pub fn locks( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Locks", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 10u8, 223u8, 55u8, 0u8, 249u8, 69u8, 168u8, 41u8, 75u8, 35u8, 120u8, - 167u8, 18u8, 132u8, 9u8, 20u8, 91u8, 51u8, 27u8, 69u8, 136u8, 187u8, - 13u8, 220u8, 163u8, 122u8, 26u8, 141u8, 174u8, 249u8, 85u8, 37u8, - ], - ) - } - #[doc = " Named reserves on some account balances."] - pub fn reserves_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::ReserveData< - [::core::primitive::u8; 8usize], - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Reserves", - vec![], - [ - 112u8, 10u8, 241u8, 77u8, 64u8, 187u8, 106u8, 159u8, 13u8, 153u8, - 140u8, 178u8, 182u8, 50u8, 1u8, 55u8, 149u8, 92u8, 196u8, 229u8, 170u8, - 106u8, 193u8, 88u8, 255u8, 244u8, 2u8, 193u8, 62u8, 235u8, 204u8, 91u8, - ], - ) - } - #[doc = " Named reserves on some account balances."] - pub fn reserves( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::ReserveData< - [::core::primitive::u8; 8usize], - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Reserves", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 112u8, 10u8, 241u8, 77u8, 64u8, 187u8, 106u8, 159u8, 13u8, 153u8, - 140u8, 178u8, 182u8, 50u8, 1u8, 55u8, 149u8, 92u8, 196u8, 229u8, 170u8, - 106u8, 193u8, 88u8, 255u8, 244u8, 2u8, 193u8, 62u8, 235u8, 204u8, 91u8, - ], - ) - } - #[doc = " Holds on account balances."] - pub fn holds_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - runtime_types::rococo_runtime::RuntimeHoldReason, - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Holds", - vec![], - [ - 181u8, 39u8, 29u8, 45u8, 45u8, 198u8, 129u8, 210u8, 189u8, 183u8, - 121u8, 125u8, 57u8, 90u8, 95u8, 107u8, 51u8, 13u8, 22u8, 105u8, 191u8, - 61u8, 54u8, 182u8, 50u8, 200u8, 137u8, 247u8, 180u8, 158u8, 16u8, - 193u8, - ], - ) - } - #[doc = " Holds on account balances."] - pub fn holds( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - runtime_types::rococo_runtime::RuntimeHoldReason, - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Holds", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 181u8, 39u8, 29u8, 45u8, 45u8, 198u8, 129u8, 210u8, 189u8, 183u8, - 121u8, 125u8, 57u8, 90u8, 95u8, 107u8, 51u8, 13u8, 22u8, 105u8, 191u8, - 61u8, 54u8, 182u8, 50u8, 200u8, 137u8, 247u8, 180u8, 158u8, 16u8, - 193u8, - ], - ) - } - #[doc = " Freeze locks on account balances."] - pub fn freezes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Freezes", - vec![], - [ - 69u8, 49u8, 165u8, 76u8, 135u8, 142u8, 179u8, 118u8, 50u8, 109u8, 53u8, - 112u8, 110u8, 94u8, 30u8, 93u8, 173u8, 38u8, 27u8, 142u8, 19u8, 5u8, - 163u8, 4u8, 68u8, 218u8, 179u8, 224u8, 118u8, 218u8, 115u8, 64u8, - ], - ) - } - #[doc = " Freeze locks on account balances."] - pub fn freezes( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Balances", - "Freezes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 69u8, 49u8, 165u8, 76u8, 135u8, 142u8, 179u8, 118u8, 50u8, 109u8, 53u8, - 112u8, 110u8, 94u8, 30u8, 93u8, 173u8, 38u8, 27u8, 142u8, 19u8, 5u8, - 163u8, 4u8, 68u8, 218u8, 179u8, 224u8, 118u8, 218u8, 115u8, 64u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount required to keep an account open. MUST BE GREATER THAN ZERO!"] - #[doc = ""] - #[doc = " If you *really* need it to be zero, you can enable the feature `insecure_zero_ed` for"] - #[doc = " this pallet. However, you do so at your own risk: this will open up a major DoS vector."] - #[doc = " In case you have multiple sources of provider references, you may also get unexpected"] - #[doc = " behaviour if you set this to zero."] - #[doc = ""] - #[doc = " Bottom line: Do yourself a favour and make it at least one!"] - pub fn existential_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Balances", - "ExistentialDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum number of locks that should exist on an account."] - #[doc = " Not strictly enforced, but used for weight estimation."] - pub fn max_locks(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxLocks", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of named reserves that can exist on an account."] - pub fn max_reserves(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxReserves", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of individual freeze locks that can exist on an account at any time."] - pub fn max_freezes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Balances", - "MaxFreezes", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod transaction_payment { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_transaction_payment::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] - #[doc = "has been paid by `who`."] - pub struct TransactionFeePaid { - pub who: ::subxt::utils::AccountId32, - pub actual_fee: ::core::primitive::u128, - pub tip: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for TransactionFeePaid { - const PALLET: &'static str = "TransactionPayment"; - const EVENT: &'static str = "TransactionFeePaid"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - pub fn next_fee_multiplier( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "TransactionPayment", - "NextFeeMultiplier", - vec![], - [ - 247u8, 39u8, 81u8, 170u8, 225u8, 226u8, 82u8, 147u8, 34u8, 113u8, - 147u8, 213u8, 59u8, 80u8, 139u8, 35u8, 36u8, 196u8, 152u8, 19u8, 9u8, - 159u8, 176u8, 79u8, 249u8, 201u8, 170u8, 1u8, 129u8, 79u8, 146u8, - 197u8, - ], - ) - } - pub fn storage_version( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_transaction_payment::Releases, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "TransactionPayment", - "StorageVersion", - vec![], - [ - 105u8, 243u8, 158u8, 241u8, 159u8, 231u8, 253u8, 6u8, 4u8, 32u8, 85u8, - 178u8, 126u8, 31u8, 203u8, 134u8, 154u8, 38u8, 122u8, 155u8, 150u8, - 251u8, 174u8, 15u8, 74u8, 134u8, 216u8, 244u8, 168u8, 175u8, 158u8, - 144u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " A fee multiplier for `Operational` extrinsics to compute \"virtual tip\" to boost their"] - #[doc = " `priority`"] - #[doc = ""] - #[doc = " This value is multiplied by the `final_fee` to obtain a \"virtual tip\" that is later"] - #[doc = " added to a tip component in regular `priority` calculations."] - #[doc = " It means that a `Normal` transaction can front-run a similarly-sized `Operational`"] - #[doc = " extrinsic (with no tip), by including a tip value greater than the virtual tip."] - #[doc = ""] - #[doc = " ```rust,ignore"] - #[doc = " // For `Normal`"] - #[doc = " let priority = priority_calc(tip);"] - #[doc = ""] - #[doc = " // For `Operational`"] - #[doc = " let virtual_tip = (inclusion_fee + tip) * OperationalFeeMultiplier;"] - #[doc = " let priority = priority_calc(tip + virtual_tip);"] - #[doc = " ```"] - #[doc = ""] - #[doc = " Note that since we use `final_fee` the multiplier applies also to the regular `tip`"] - #[doc = " sent with the transaction. So, not only does the transaction get a priority bump based"] - #[doc = " on the `inclusion_fee`, but we also amplify the impact of tips applied to `Operational`"] - #[doc = " transactions."] - pub fn operational_fee_multiplier( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u8> { - ::subxt::constants::Address::new_static( - "TransactionPayment", - "OperationalFeeMultiplier", - [ - 141u8, 130u8, 11u8, 35u8, 226u8, 114u8, 92u8, 179u8, 168u8, 110u8, - 28u8, 91u8, 221u8, 64u8, 4u8, 148u8, 201u8, 193u8, 185u8, 66u8, 226u8, - 114u8, 97u8, 79u8, 62u8, 212u8, 202u8, 114u8, 237u8, 228u8, 183u8, - 165u8, - ], - ) - } - } - } - } - pub mod authorship { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Author of current block."] - pub fn author( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Authorship", - "Author", - vec![], - [ - 247u8, 192u8, 118u8, 227u8, 47u8, 20u8, 203u8, 199u8, 216u8, 87u8, - 220u8, 50u8, 166u8, 61u8, 168u8, 213u8, 253u8, 62u8, 202u8, 199u8, - 61u8, 192u8, 237u8, 53u8, 22u8, 148u8, 164u8, 245u8, 99u8, 24u8, 146u8, - 18u8, - ], - ) - } - } - } - } - pub mod offences { - use super::root_mod; - use super::runtime_types; - #[doc = "Events type."] - pub type Event = runtime_types::pallet_offences::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "There is an offence reported of the given `kind` happened at the `session_index` and"] - #[doc = "(kind-specific) time slot. This event is not deposited for duplicate slashes."] - #[doc = "\\[kind, timeslot\\]."] - pub struct Offence { - pub kind: [::core::primitive::u8; 16usize], - pub timeslot: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::events::StaticEvent for Offence { - const PALLET: &'static str = "Offences"; - const EVENT: &'static str = "Offence"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The primary structure that holds all offence records keyed by report identifiers."] - pub fn reports_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_staking::offence::OffenceDetails< - ::subxt::utils::AccountId32, - (::subxt::utils::AccountId32, ()), - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "Reports", - vec![], - [ - 255u8, 234u8, 162u8, 48u8, 243u8, 210u8, 198u8, 231u8, 218u8, 142u8, - 167u8, 10u8, 232u8, 223u8, 239u8, 55u8, 74u8, 23u8, 14u8, 236u8, 88u8, - 231u8, 152u8, 55u8, 91u8, 120u8, 11u8, 96u8, 100u8, 113u8, 131u8, - 173u8, - ], - ) - } - #[doc = " The primary structure that holds all offence records keyed by report identifiers."] - pub fn reports( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_staking::offence::OffenceDetails< - ::subxt::utils::AccountId32, - (::subxt::utils::AccountId32, ()), - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "Reports", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 255u8, 234u8, 162u8, 48u8, 243u8, 210u8, 198u8, 231u8, 218u8, 142u8, - 167u8, 10u8, 232u8, 223u8, 239u8, 55u8, 74u8, 23u8, 14u8, 236u8, 88u8, - 231u8, 152u8, 55u8, 91u8, 120u8, 11u8, 96u8, 100u8, 113u8, 131u8, - 173u8, - ], - ) - } - #[doc = " A vector of reports of the same kind that happened at the same time slot."] - pub fn concurrent_reports_index_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::H256>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "ConcurrentReportsIndex", - vec![], - [ - 170u8, 186u8, 72u8, 29u8, 251u8, 38u8, 193u8, 195u8, 109u8, 86u8, 0u8, - 241u8, 20u8, 235u8, 108u8, 126u8, 215u8, 82u8, 73u8, 113u8, 199u8, - 138u8, 24u8, 58u8, 216u8, 72u8, 221u8, 232u8, 252u8, 244u8, 96u8, - 247u8, - ], - ) - } - #[doc = " A vector of reports of the same kind that happened at the same time slot."] - pub fn concurrent_reports_index_iter1( - &self, - _0: impl ::std::borrow::Borrow<[::core::primitive::u8; 16usize]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::H256>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "ConcurrentReportsIndex", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 170u8, 186u8, 72u8, 29u8, 251u8, 38u8, 193u8, 195u8, 109u8, 86u8, 0u8, - 241u8, 20u8, 235u8, 108u8, 126u8, 215u8, 82u8, 73u8, 113u8, 199u8, - 138u8, 24u8, 58u8, 216u8, 72u8, 221u8, 232u8, 252u8, 244u8, 96u8, - 247u8, - ], - ) - } - #[doc = " A vector of reports of the same kind that happened at the same time slot."] - pub fn concurrent_reports_index( - &self, - _0: impl ::std::borrow::Borrow<[::core::primitive::u8; 16usize]>, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::H256>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Offences", - "ConcurrentReportsIndex", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 170u8, 186u8, 72u8, 29u8, 251u8, 38u8, 193u8, 195u8, 109u8, 86u8, 0u8, - 241u8, 20u8, 235u8, 108u8, 126u8, 215u8, 82u8, 73u8, 113u8, 199u8, - 138u8, 24u8, 58u8, 216u8, 72u8, 221u8, 232u8, 252u8, 244u8, 96u8, - 247u8, - ], - ) - } - } - } - } - pub mod historical { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Mapping from historical session indices to session-data root hash and validator count."] - pub fn historical_sessions_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::subxt::utils::H256, ::core::primitive::u32), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Historical", - "HistoricalSessions", - vec![], - [ - 9u8, 138u8, 247u8, 141u8, 178u8, 146u8, 124u8, 81u8, 162u8, 211u8, - 205u8, 149u8, 222u8, 254u8, 253u8, 188u8, 170u8, 242u8, 218u8, 41u8, - 124u8, 178u8, 109u8, 209u8, 163u8, 125u8, 225u8, 206u8, 249u8, 175u8, - 117u8, 75u8, - ], - ) - } - #[doc = " Mapping from historical session indices to session-data root hash and validator count."] - pub fn historical_sessions( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::subxt::utils::H256, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Historical", - "HistoricalSessions", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 9u8, 138u8, 247u8, 141u8, 178u8, 146u8, 124u8, 81u8, 162u8, 211u8, - 205u8, 149u8, 222u8, 254u8, 253u8, 188u8, 170u8, 242u8, 218u8, 41u8, - 124u8, 178u8, 109u8, 209u8, 163u8, 125u8, 225u8, 206u8, 249u8, 175u8, - 117u8, 75u8, - ], - ) - } - #[doc = " The range of historical sessions we store. [first, last)"] - pub fn stored_range( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Historical", - "StoredRange", - vec![], - [ - 134u8, 32u8, 250u8, 13u8, 201u8, 25u8, 54u8, 243u8, 231u8, 81u8, 252u8, - 231u8, 68u8, 217u8, 235u8, 43u8, 22u8, 223u8, 220u8, 133u8, 198u8, - 218u8, 95u8, 152u8, 189u8, 87u8, 6u8, 228u8, 242u8, 59u8, 232u8, 59u8, - ], - ) - } - } - } - } - pub mod session { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the session pallet."] - pub type Error = runtime_types::pallet_session::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_session::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetKeys { - pub keys: runtime_types::rococo_runtime::SessionKeys, - pub proof: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for SetKeys { - const PALLET: &'static str = "Session"; - const CALL: &'static str = "set_keys"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PurgeKeys; - impl ::subxt::blocks::StaticExtrinsic for PurgeKeys { - const PALLET: &'static str = "Session"; - const CALL: &'static str = "purge_keys"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::set_keys`]."] - pub fn set_keys( - &self, - keys: runtime_types::rococo_runtime::SessionKeys, - proof: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Session", - "set_keys", - types::SetKeys { keys, proof }, - [ - 160u8, 137u8, 167u8, 56u8, 165u8, 202u8, 149u8, 39u8, 16u8, 52u8, - 173u8, 215u8, 250u8, 158u8, 78u8, 126u8, 236u8, 153u8, 173u8, 68u8, - 237u8, 8u8, 47u8, 77u8, 119u8, 226u8, 248u8, 220u8, 139u8, 68u8, 145u8, - 207u8, - ], - ) - } - #[doc = "See [`Pallet::purge_keys`]."] - pub fn purge_keys(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Session", - "purge_keys", - types::PurgeKeys {}, - [ - 215u8, 204u8, 146u8, 236u8, 32u8, 78u8, 198u8, 79u8, 85u8, 214u8, 15u8, - 151u8, 158u8, 31u8, 146u8, 119u8, 119u8, 204u8, 151u8, 169u8, 226u8, - 67u8, 217u8, 39u8, 241u8, 245u8, 203u8, 240u8, 203u8, 172u8, 16u8, - 209u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_session::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New session has happened. Note that the argument is the session index, not the"] - #[doc = "block number as the type might suggest."] - pub struct NewSession { - pub session_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for NewSession { - const PALLET: &'static str = "Session"; - const EVENT: &'static str = "NewSession"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current set of validators."] - pub fn validators( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "Validators", - vec![], - [ - 50u8, 86u8, 154u8, 222u8, 249u8, 209u8, 156u8, 22u8, 155u8, 25u8, - 133u8, 194u8, 210u8, 50u8, 38u8, 28u8, 139u8, 201u8, 90u8, 139u8, - 115u8, 12u8, 12u8, 141u8, 4u8, 178u8, 201u8, 241u8, 223u8, 234u8, 6u8, - 86u8, - ], - ) - } - #[doc = " Current index of the session."] - pub fn current_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "CurrentIndex", - vec![], - [ - 167u8, 151u8, 125u8, 150u8, 159u8, 21u8, 78u8, 217u8, 237u8, 183u8, - 135u8, 65u8, 187u8, 114u8, 188u8, 206u8, 16u8, 32u8, 69u8, 208u8, - 134u8, 159u8, 232u8, 224u8, 243u8, 27u8, 31u8, 166u8, 145u8, 44u8, - 221u8, 230u8, - ], - ) - } - #[doc = " True if the underlying economic identities or weighting behind the validators"] - #[doc = " has changed in the queued validator set."] - pub fn queued_changed( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "QueuedChanged", - vec![], - [ - 184u8, 137u8, 224u8, 137u8, 31u8, 236u8, 95u8, 164u8, 102u8, 225u8, - 198u8, 227u8, 140u8, 37u8, 113u8, 57u8, 59u8, 4u8, 202u8, 102u8, 117u8, - 36u8, 226u8, 64u8, 113u8, 141u8, 199u8, 111u8, 99u8, 144u8, 198u8, - 153u8, - ], - ) - } - #[doc = " The queued keys for the next session. When the next session begins, these keys"] - #[doc = " will be used to determine the validator's session keys."] - pub fn queued_keys( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::rococo_runtime::SessionKeys, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "QueuedKeys", - vec![], - [ - 123u8, 8u8, 241u8, 219u8, 141u8, 50u8, 254u8, 247u8, 130u8, 71u8, - 105u8, 18u8, 149u8, 204u8, 28u8, 104u8, 184u8, 6u8, 165u8, 31u8, 153u8, - 54u8, 235u8, 78u8, 48u8, 182u8, 83u8, 221u8, 243u8, 110u8, 249u8, - 212u8, - ], - ) - } - #[doc = " Indices of disabled validators."] - #[doc = ""] - #[doc = " The vec is always kept sorted so that we can find whether a given validator is"] - #[doc = " disabled using binary search. It gets cleared when `on_session_ending` returns"] - #[doc = " a new set of identities."] - pub fn disabled_validators( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::core::primitive::u32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "DisabledValidators", - vec![], - [ - 213u8, 19u8, 168u8, 234u8, 187u8, 200u8, 180u8, 97u8, 234u8, 189u8, - 36u8, 233u8, 158u8, 184u8, 45u8, 35u8, 129u8, 213u8, 133u8, 8u8, 104u8, - 183u8, 46u8, 68u8, 154u8, 240u8, 132u8, 22u8, 247u8, 11u8, 54u8, 221u8, - ], - ) - } - #[doc = " The next session keys for a validator."] - pub fn next_keys_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::rococo_runtime::SessionKeys, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "NextKeys", - vec![], - [ - 13u8, 219u8, 184u8, 220u8, 199u8, 150u8, 34u8, 166u8, 125u8, 46u8, - 26u8, 160u8, 113u8, 243u8, 227u8, 6u8, 121u8, 176u8, 222u8, 250u8, - 108u8, 240u8, 0u8, 15u8, 177u8, 220u8, 206u8, 94u8, 179u8, 41u8, 209u8, - 23u8, - ], - ) - } - #[doc = " The next session keys for a validator."] - pub fn next_keys( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::rococo_runtime::SessionKeys, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "NextKeys", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 13u8, 219u8, 184u8, 220u8, 199u8, 150u8, 34u8, 166u8, 125u8, 46u8, - 26u8, 160u8, 113u8, 243u8, 227u8, 6u8, 121u8, 176u8, 222u8, 250u8, - 108u8, 240u8, 0u8, 15u8, 177u8, 220u8, 206u8, 94u8, 179u8, 41u8, 209u8, - 23u8, - ], - ) - } - #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] - pub fn key_owner_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "KeyOwner", - vec![], - [ - 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, - 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, - 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, - 206u8, - ], - ) - } - #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] - pub fn key_owner_iter1( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Session", - "KeyOwner", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, - 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, - 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, - 206u8, - ], - ) - } - #[doc = " The owner of a key. The key is the `KeyTypeId` + the encoded key."] - pub fn key_owner( - &self, - _0: impl ::std::borrow::Borrow, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Session", - "KeyOwner", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 217u8, 204u8, 21u8, 114u8, 247u8, 129u8, 32u8, 242u8, 93u8, 91u8, - 253u8, 253u8, 248u8, 90u8, 12u8, 202u8, 195u8, 25u8, 18u8, 100u8, - 253u8, 109u8, 88u8, 77u8, 217u8, 140u8, 51u8, 40u8, 118u8, 35u8, 107u8, - 206u8, - ], - ) - } - } - } - } - pub mod grandpa { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_grandpa::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_grandpa::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocation { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - impl ::subxt::blocks::StaticExtrinsic for ReportEquivocation { - const PALLET: &'static str = "Grandpa"; - const CALL: &'static str = "report_equivocation"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocationUnsigned { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - impl ::subxt::blocks::StaticExtrinsic for ReportEquivocationUnsigned { - const PALLET: &'static str = "Grandpa"; - const CALL: &'static str = "report_equivocation_unsigned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NoteStalled { - pub delay: ::core::primitive::u32, - pub best_finalized_block_number: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for NoteStalled { - const PALLET: &'static str = "Grandpa"; - const CALL: &'static str = "note_stalled"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::report_equivocation`]."] - pub fn report_equivocation( - &self, - equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Grandpa", - "report_equivocation", - types::ReportEquivocation { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 11u8, 183u8, 81u8, 93u8, 41u8, 7u8, 70u8, 155u8, 8u8, 57u8, 177u8, - 245u8, 131u8, 79u8, 236u8, 118u8, 147u8, 114u8, 40u8, 204u8, 177u8, - 2u8, 43u8, 42u8, 2u8, 201u8, 202u8, 120u8, 150u8, 109u8, 108u8, 156u8, - ], - ) - } - #[doc = "See [`Pallet::report_equivocation_unsigned`]."] - pub fn report_equivocation_unsigned( - &self, - equivocation_proof: runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Grandpa", - "report_equivocation_unsigned", - types::ReportEquivocationUnsigned { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 141u8, 133u8, 227u8, 65u8, 22u8, 181u8, 108u8, 9u8, 157u8, 27u8, 124u8, - 53u8, 177u8, 27u8, 5u8, 16u8, 193u8, 66u8, 59u8, 87u8, 143u8, 238u8, - 251u8, 167u8, 117u8, 138u8, 246u8, 236u8, 65u8, 148u8, 20u8, 131u8, - ], - ) - } - #[doc = "See [`Pallet::note_stalled`]."] - pub fn note_stalled( - &self, - delay: ::core::primitive::u32, - best_finalized_block_number: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Grandpa", - "note_stalled", - types::NoteStalled { delay, best_finalized_block_number }, - [ - 158u8, 25u8, 64u8, 114u8, 131u8, 139u8, 227u8, 132u8, 42u8, 107u8, - 40u8, 249u8, 18u8, 93u8, 254u8, 86u8, 37u8, 67u8, 250u8, 35u8, 241u8, - 194u8, 209u8, 20u8, 39u8, 75u8, 186u8, 21u8, 48u8, 124u8, 151u8, 31u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_grandpa::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New authority set has been applied."] - pub struct NewAuthorities { - pub authority_set: ::std::vec::Vec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - } - impl ::subxt::events::StaticEvent for NewAuthorities { - const PALLET: &'static str = "Grandpa"; - const EVENT: &'static str = "NewAuthorities"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Current authority set has been paused."] - pub struct Paused; - impl ::subxt::events::StaticEvent for Paused { - const PALLET: &'static str = "Grandpa"; - const EVENT: &'static str = "Paused"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Current authority set has been resumed."] - pub struct Resumed; - impl ::subxt::events::StaticEvent for Resumed { - const PALLET: &'static str = "Grandpa"; - const EVENT: &'static str = "Resumed"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " State of the current authority set."] - pub fn state( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_grandpa::StoredState<::core::primitive::u32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Grandpa", - "State", - vec![], - [ - 73u8, 71u8, 112u8, 83u8, 238u8, 75u8, 44u8, 9u8, 180u8, 33u8, 30u8, - 121u8, 98u8, 96u8, 61u8, 133u8, 16u8, 70u8, 30u8, 249u8, 34u8, 148u8, - 15u8, 239u8, 164u8, 157u8, 52u8, 27u8, 144u8, 52u8, 223u8, 109u8, - ], - ) - } - #[doc = " Pending change: (signaled at, scheduled change)."] - pub fn pending_change( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_grandpa::StoredPendingChange<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Grandpa", - "PendingChange", - vec![], - [ - 150u8, 194u8, 185u8, 248u8, 239u8, 43u8, 141u8, 253u8, 61u8, 106u8, - 74u8, 164u8, 209u8, 204u8, 206u8, 200u8, 32u8, 38u8, 11u8, 78u8, 84u8, - 243u8, 181u8, 142u8, 179u8, 151u8, 81u8, 204u8, 244u8, 150u8, 137u8, - 250u8, - ], - ) - } - #[doc = " next block number where we can force a change."] - pub fn next_forced( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Grandpa", - "NextForced", - vec![], - [ - 3u8, 231u8, 56u8, 18u8, 87u8, 112u8, 227u8, 126u8, 180u8, 131u8, 255u8, - 141u8, 82u8, 34u8, 61u8, 47u8, 234u8, 37u8, 95u8, 62u8, 33u8, 235u8, - 231u8, 122u8, 125u8, 8u8, 223u8, 95u8, 255u8, 204u8, 40u8, 97u8, - ], - ) - } - #[doc = " `true` if we are currently stalled."] - pub fn stalled( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Grandpa", - "Stalled", - vec![], - [ - 6u8, 81u8, 205u8, 142u8, 195u8, 48u8, 0u8, 247u8, 108u8, 170u8, 10u8, - 249u8, 72u8, 206u8, 32u8, 103u8, 109u8, 57u8, 51u8, 21u8, 144u8, 204u8, - 79u8, 8u8, 191u8, 185u8, 38u8, 34u8, 118u8, 223u8, 75u8, 241u8, - ], - ) - } - #[doc = " The number of changes (both in terms of keys and underlying economic responsibilities)"] - #[doc = " in the \"set\" of Grandpa validators from genesis."] - pub fn current_set_id( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Grandpa", - "CurrentSetId", - vec![], - [ - 234u8, 215u8, 218u8, 42u8, 30u8, 76u8, 129u8, 40u8, 125u8, 137u8, - 207u8, 47u8, 46u8, 213u8, 159u8, 50u8, 175u8, 81u8, 155u8, 123u8, - 246u8, 175u8, 156u8, 68u8, 22u8, 113u8, 135u8, 137u8, 163u8, 18u8, - 115u8, 73u8, - ], - ) - } - #[doc = " A mapping from grandpa set ID to the index of the *most recent* session for which its"] - #[doc = " members were responsible."] - #[doc = ""] - #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] - #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] - #[doc = " together sessions and GRANDPA set ids, i.e. we need to validate that a validator"] - #[doc = " was the owner of a given key on a given session, and what the active set ID was"] - #[doc = " during that session."] - #[doc = ""] - #[doc = " TWOX-NOTE: `SetId` is not under user control."] - pub fn set_id_session_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Grandpa", - "SetIdSession", - vec![], - [ - 47u8, 0u8, 239u8, 121u8, 187u8, 213u8, 254u8, 50u8, 238u8, 10u8, 162u8, - 65u8, 189u8, 166u8, 37u8, 74u8, 82u8, 81u8, 160u8, 20u8, 180u8, 253u8, - 238u8, 18u8, 209u8, 203u8, 38u8, 148u8, 16u8, 105u8, 72u8, 169u8, - ], - ) - } - #[doc = " A mapping from grandpa set ID to the index of the *most recent* session for which its"] - #[doc = " members were responsible."] - #[doc = ""] - #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] - #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] - #[doc = " together sessions and GRANDPA set ids, i.e. we need to validate that a validator"] - #[doc = " was the owner of a given key on a given session, and what the active set ID was"] - #[doc = " during that session."] - #[doc = ""] - #[doc = " TWOX-NOTE: `SetId` is not under user control."] - pub fn set_id_session( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Grandpa", - "SetIdSession", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 47u8, 0u8, 239u8, 121u8, 187u8, 213u8, 254u8, 50u8, 238u8, 10u8, 162u8, - 65u8, 189u8, 166u8, 37u8, 74u8, 82u8, 81u8, 160u8, 20u8, 180u8, 253u8, - 238u8, 18u8, 209u8, 203u8, 38u8, 148u8, 16u8, 105u8, 72u8, 169u8, - ], - ) - } - #[doc = " The current list of authorities."] - pub fn authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Grandpa", - "Authorities", - vec![], - [ - 67u8, 196u8, 244u8, 13u8, 246u8, 245u8, 198u8, 98u8, 81u8, 55u8, 182u8, - 187u8, 214u8, 5u8, 181u8, 76u8, 251u8, 213u8, 144u8, 166u8, 36u8, - 153u8, 234u8, 181u8, 252u8, 55u8, 198u8, 175u8, 55u8, 211u8, 105u8, - 85u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Max Authorities in use"] - pub fn max_authorities( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Grandpa", - "MaxAuthorities", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of nominators for each validator."] - pub fn max_nominators( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Grandpa", - "MaxNominators", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of entries to keep in the set id to session index mapping."] - #[doc = ""] - #[doc = " Since the `SetIdSession` map is only used for validating equivocations this"] - #[doc = " value should relate to the bonding duration of whatever staking system is"] - #[doc = " being used (if any). If equivocation handling is not enabled then this value"] - #[doc = " can be zero."] - pub fn max_set_id_session_entries( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Grandpa", - "MaxSetIdSessionEntries", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - } - } - } - pub mod authority_discovery { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Keys of the current authority set."] - pub fn keys( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::sp_authority_discovery::app::Public, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "AuthorityDiscovery", - "Keys", - vec![], - [ - 111u8, 104u8, 188u8, 46u8, 152u8, 140u8, 137u8, 244u8, 52u8, 214u8, - 115u8, 156u8, 39u8, 239u8, 15u8, 168u8, 193u8, 125u8, 57u8, 195u8, - 250u8, 156u8, 234u8, 222u8, 222u8, 253u8, 135u8, 232u8, 196u8, 163u8, - 29u8, 218u8, - ], - ) - } - #[doc = " Keys of the next authority set."] - pub fn next_keys( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::sp_authority_discovery::app::Public, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "AuthorityDiscovery", - "NextKeys", - vec![], - [ - 171u8, 107u8, 15u8, 108u8, 125u8, 102u8, 193u8, 240u8, 127u8, 160u8, - 53u8, 1u8, 208u8, 36u8, 134u8, 4u8, 216u8, 26u8, 156u8, 143u8, 154u8, - 194u8, 153u8, 199u8, 46u8, 211u8, 153u8, 222u8, 244u8, 4u8, 165u8, 2u8, - ], - ) - } - } - } - } - pub mod treasury { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the treasury pallet."] - pub type Error = runtime_types::pallet_treasury::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_treasury::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeSpend { - #[codec(compact)] - pub value: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for ProposeSpend { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "propose_spend"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RejectProposal { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RejectProposal { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "reject_proposal"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveProposal { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ApproveProposal { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "approve_proposal"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SpendLocal { - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for SpendLocal { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "spend_local"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveApproval { - #[codec(compact)] - pub proposal_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveApproval { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "remove_approval"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Spend { - pub asset_kind: ::std::boxed::Box< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub beneficiary: ::std::boxed::Box, - pub valid_from: ::core::option::Option<::core::primitive::u32>, - } - impl ::subxt::blocks::StaticExtrinsic for Spend { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "spend"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Payout { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Payout { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "payout"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckStatus { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for CheckStatus { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "check_status"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VoidSpend { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for VoidSpend { - const PALLET: &'static str = "Treasury"; - const CALL: &'static str = "void_spend"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::propose_spend`]."] - pub fn propose_spend( - &self, - value: ::core::primitive::u128, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "propose_spend", - types::ProposeSpend { value, beneficiary }, - [ - 250u8, 230u8, 64u8, 10u8, 93u8, 132u8, 194u8, 69u8, 91u8, 50u8, 98u8, - 212u8, 72u8, 218u8, 29u8, 149u8, 2u8, 190u8, 219u8, 4u8, 25u8, 110u8, - 5u8, 199u8, 196u8, 37u8, 64u8, 57u8, 207u8, 235u8, 164u8, 226u8, - ], - ) - } - #[doc = "See [`Pallet::reject_proposal`]."] - pub fn reject_proposal( - &self, - proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "reject_proposal", - types::RejectProposal { proposal_id }, - [ - 18u8, 166u8, 80u8, 141u8, 222u8, 230u8, 4u8, 36u8, 7u8, 76u8, 12u8, - 40u8, 145u8, 114u8, 12u8, 43u8, 223u8, 78u8, 189u8, 222u8, 120u8, 80u8, - 225u8, 215u8, 119u8, 68u8, 200u8, 15u8, 25u8, 172u8, 192u8, 173u8, - ], - ) - } - #[doc = "See [`Pallet::approve_proposal`]."] - pub fn approve_proposal( - &self, - proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "approve_proposal", - types::ApproveProposal { proposal_id }, - [ - 154u8, 176u8, 152u8, 97u8, 167u8, 177u8, 78u8, 9u8, 235u8, 229u8, - 199u8, 193u8, 214u8, 3u8, 16u8, 30u8, 4u8, 104u8, 27u8, 184u8, 100u8, - 65u8, 179u8, 13u8, 91u8, 62u8, 115u8, 5u8, 219u8, 211u8, 251u8, 153u8, - ], - ) - } - #[doc = "See [`Pallet::spend_local`]."] - pub fn spend_local( - &self, - amount: ::core::primitive::u128, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "spend_local", - types::SpendLocal { amount, beneficiary }, - [ - 137u8, 171u8, 83u8, 247u8, 245u8, 212u8, 152u8, 127u8, 210u8, 71u8, - 254u8, 134u8, 189u8, 26u8, 249u8, 41u8, 214u8, 175u8, 24u8, 64u8, 33u8, - 90u8, 23u8, 134u8, 44u8, 110u8, 63u8, 46u8, 46u8, 146u8, 222u8, 79u8, - ], - ) - } - #[doc = "See [`Pallet::remove_approval`]."] - pub fn remove_approval( - &self, - proposal_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "remove_approval", - types::RemoveApproval { proposal_id }, - [ - 180u8, 20u8, 39u8, 227u8, 29u8, 228u8, 234u8, 36u8, 155u8, 114u8, - 197u8, 135u8, 185u8, 31u8, 56u8, 247u8, 224u8, 168u8, 254u8, 233u8, - 250u8, 134u8, 186u8, 155u8, 108u8, 84u8, 94u8, 226u8, 207u8, 130u8, - 196u8, 100u8, - ], - ) - } - #[doc = "See [`Pallet::spend`]."] - pub fn spend( - &self, - asset_kind : runtime_types :: polkadot_runtime_common :: impls :: VersionedLocatableAsset, - amount: ::core::primitive::u128, - beneficiary: runtime_types::xcm::VersionedLocation, - valid_from: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "spend", - types::Spend { - asset_kind: ::std::boxed::Box::new(asset_kind), - amount, - beneficiary: ::std::boxed::Box::new(beneficiary), - valid_from, - }, - [ - 127u8, 68u8, 115u8, 140u8, 122u8, 90u8, 253u8, 105u8, 230u8, 137u8, - 104u8, 130u8, 221u8, 123u8, 49u8, 126u8, 247u8, 80u8, 12u8, 4u8, 223u8, - 218u8, 187u8, 192u8, 61u8, 221u8, 46u8, 211u8, 71u8, 196u8, 55u8, - 237u8, - ], - ) - } - #[doc = "See [`Pallet::payout`]."] - pub fn payout( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "payout", - types::Payout { index }, - [ - 179u8, 254u8, 82u8, 94u8, 248u8, 26u8, 6u8, 34u8, 93u8, 244u8, 186u8, - 199u8, 163u8, 32u8, 110u8, 220u8, 78u8, 11u8, 168u8, 182u8, 169u8, - 56u8, 53u8, 194u8, 168u8, 218u8, 131u8, 38u8, 46u8, 156u8, 93u8, 234u8, - ], - ) - } - #[doc = "See [`Pallet::check_status`]."] - pub fn check_status( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "check_status", - types::CheckStatus { index }, - [ - 164u8, 111u8, 10u8, 11u8, 104u8, 237u8, 112u8, 240u8, 104u8, 130u8, - 179u8, 221u8, 54u8, 18u8, 8u8, 172u8, 148u8, 245u8, 110u8, 174u8, 75u8, - 38u8, 46u8, 143u8, 101u8, 232u8, 65u8, 252u8, 36u8, 152u8, 29u8, 209u8, - ], - ) - } - #[doc = "See [`Pallet::void_spend`]."] - pub fn void_spend( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Treasury", - "void_spend", - types::VoidSpend { index }, - [ - 9u8, 212u8, 174u8, 92u8, 43u8, 102u8, 224u8, 124u8, 247u8, 239u8, - 196u8, 68u8, 132u8, 171u8, 116u8, 206u8, 52u8, 23u8, 92u8, 31u8, 156u8, - 160u8, 25u8, 16u8, 125u8, 60u8, 9u8, 109u8, 145u8, 139u8, 102u8, 224u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_treasury::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New proposal."] - pub struct Proposed { - pub proposal_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Proposed { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Proposed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "We have ended a spend period and will now allocate funds."] - pub struct Spending { - pub budget_remaining: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Spending { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Spending"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some funds have been allocated."] - pub struct Awarded { - pub proposal_index: ::core::primitive::u32, - pub award: ::core::primitive::u128, - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Awarded { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Awarded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal was rejected; funds were slashed."] - pub struct Rejected { - pub proposal_index: ::core::primitive::u32, - pub slashed: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Rejected { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Rejected"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some of our funds have been burnt."] - pub struct Burnt { - pub burnt_funds: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Burnt { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Burnt"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Spending has finished; this is the amount that rolls over until next spend."] - pub struct Rollover { - pub rollover_balance: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Rollover { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Rollover"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some funds have been deposited."] - pub struct Deposit { - pub value: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Deposit { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Deposit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new spend proposal has been approved."] - pub struct SpendApproved { - pub proposal_index: ::core::primitive::u32, - pub amount: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for SpendApproved { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "SpendApproved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The inactive funds of the pallet have been updated."] - pub struct UpdatedInactive { - pub reactivated: ::core::primitive::u128, - pub deactivated: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for UpdatedInactive { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "UpdatedInactive"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new asset spend proposal has been approved."] - pub struct AssetSpendApproved { - pub index: ::core::primitive::u32, - pub asset_kind: - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - pub amount: ::core::primitive::u128, - pub beneficiary: runtime_types::xcm::VersionedLocation, - pub valid_from: ::core::primitive::u32, - pub expire_at: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for AssetSpendApproved { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "AssetSpendApproved"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An approved spend was voided."] - pub struct AssetSpendVoided { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for AssetSpendVoided { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "AssetSpendVoided"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A payment happened."] - pub struct Paid { - pub index: ::core::primitive::u32, - pub payment_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for Paid { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "Paid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A payment failed and can be retried."] - pub struct PaymentFailed { - pub index: ::core::primitive::u32, - pub payment_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for PaymentFailed { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "PaymentFailed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A spend was processed and removed from the storage. It might have been successfully"] - #[doc = "paid or it may have expired."] - pub struct SpendProcessed { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for SpendProcessed { - const PALLET: &'static str = "Treasury"; - const EVENT: &'static str = "SpendProcessed"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Number of proposals that have been made."] - pub fn proposal_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Treasury", - "ProposalCount", - vec![], - [ - 91u8, 238u8, 246u8, 106u8, 95u8, 66u8, 83u8, 134u8, 1u8, 225u8, 164u8, - 216u8, 113u8, 101u8, 203u8, 200u8, 113u8, 97u8, 246u8, 228u8, 140u8, - 29u8, 29u8, 48u8, 176u8, 137u8, 93u8, 230u8, 56u8, 75u8, 51u8, 149u8, - ], - ) - } - #[doc = " Proposals that have been made."] - pub fn proposals_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_treasury::Proposal< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Treasury", - "Proposals", - vec![], - [ - 207u8, 135u8, 145u8, 146u8, 48u8, 10u8, 252u8, 40u8, 20u8, 115u8, - 205u8, 41u8, 173u8, 83u8, 115u8, 46u8, 106u8, 40u8, 130u8, 157u8, - 213u8, 87u8, 45u8, 23u8, 14u8, 167u8, 99u8, 208u8, 153u8, 163u8, 141u8, - 55u8, - ], - ) - } - #[doc = " Proposals that have been made."] - pub fn proposals( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_treasury::Proposal< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Treasury", - "Proposals", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 207u8, 135u8, 145u8, 146u8, 48u8, 10u8, 252u8, 40u8, 20u8, 115u8, - 205u8, 41u8, 173u8, 83u8, 115u8, 46u8, 106u8, 40u8, 130u8, 157u8, - 213u8, 87u8, 45u8, 23u8, 14u8, 167u8, 99u8, 208u8, 153u8, 163u8, 141u8, - 55u8, - ], - ) - } - #[doc = " The amount which has been reported as inactive to Currency."] - pub fn deactivated( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Treasury", - "Deactivated", - vec![], - [ - 120u8, 221u8, 159u8, 56u8, 161u8, 44u8, 54u8, 233u8, 47u8, 114u8, - 170u8, 150u8, 52u8, 24u8, 137u8, 212u8, 122u8, 247u8, 40u8, 17u8, - 208u8, 130u8, 42u8, 154u8, 33u8, 222u8, 59u8, 116u8, 0u8, 15u8, 79u8, - 123u8, - ], - ) - } - #[doc = " Proposal indices that have been approved but not yet awarded."] - pub fn approvals( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Treasury", - "Approvals", - vec![], - [ - 78u8, 147u8, 186u8, 235u8, 17u8, 40u8, 247u8, 235u8, 67u8, 222u8, 3u8, - 14u8, 248u8, 17u8, 67u8, 180u8, 93u8, 161u8, 64u8, 35u8, 119u8, 194u8, - 187u8, 226u8, 135u8, 162u8, 147u8, 174u8, 139u8, 72u8, 99u8, 212u8, - ], - ) - } - #[doc = " The count of spends that have been made."] - pub fn spend_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Treasury", - "SpendCount", - vec![], - [ - 220u8, 74u8, 248u8, 52u8, 243u8, 209u8, 42u8, 236u8, 27u8, 98u8, 76u8, - 153u8, 129u8, 176u8, 34u8, 177u8, 33u8, 132u8, 21u8, 71u8, 206u8, - 146u8, 222u8, 44u8, 232u8, 246u8, 205u8, 92u8, 240u8, 136u8, 182u8, - 30u8, - ], - ) - } - #[doc = " Spends that have been approved and being processed."] - pub fn spends_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_treasury::SpendStatus< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - ::core::primitive::u128, - runtime_types::xcm::VersionedLocation, - ::core::primitive::u32, - ::core::primitive::u64, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Treasury", - "Spends", - vec![], - [ - 207u8, 104u8, 63u8, 103u8, 177u8, 66u8, 236u8, 100u8, 122u8, 213u8, - 125u8, 153u8, 180u8, 219u8, 124u8, 22u8, 88u8, 161u8, 188u8, 197u8, - 70u8, 46u8, 72u8, 170u8, 146u8, 4u8, 127u8, 160u8, 204u8, 2u8, 89u8, - 95u8, - ], - ) - } - #[doc = " Spends that have been approved and being processed."] - pub fn spends( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_treasury::SpendStatus< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - ::core::primitive::u128, - runtime_types::xcm::VersionedLocation, - ::core::primitive::u32, - ::core::primitive::u64, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Treasury", - "Spends", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 207u8, 104u8, 63u8, 103u8, 177u8, 66u8, 236u8, 100u8, 122u8, 213u8, - 125u8, 153u8, 180u8, 219u8, 124u8, 22u8, 88u8, 161u8, 188u8, 197u8, - 70u8, 46u8, 72u8, 170u8, 146u8, 4u8, 127u8, 160u8, 204u8, 2u8, 89u8, - 95u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Fraction of a proposal's value that should be bonded in order to place the proposal."] - #[doc = " An accepted proposal gets these back. A rejected proposal does not."] - pub fn proposal_bond( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Treasury", - "ProposalBond", - [ - 65u8, 93u8, 120u8, 165u8, 204u8, 81u8, 159u8, 163u8, 93u8, 135u8, - 114u8, 121u8, 147u8, 35u8, 215u8, 213u8, 4u8, 223u8, 83u8, 37u8, 225u8, - 200u8, 189u8, 156u8, 140u8, 36u8, 58u8, 46u8, 42u8, 232u8, 155u8, 0u8, - ], - ) - } - #[doc = " Minimum amount of funds that should be placed in a deposit for making a proposal."] - pub fn proposal_bond_minimum( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Treasury", - "ProposalBondMinimum", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Maximum amount of funds that should be placed in a deposit for making a proposal."] - pub fn proposal_bond_maximum( - &self, - ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> { - ::subxt::constants::Address::new_static( - "Treasury", - "ProposalBondMaximum", - [ - 198u8, 51u8, 89u8, 159u8, 124u8, 251u8, 51u8, 80u8, 167u8, 193u8, 44u8, - 199u8, 80u8, 36u8, 41u8, 130u8, 137u8, 229u8, 178u8, 208u8, 37u8, - 215u8, 169u8, 183u8, 180u8, 191u8, 140u8, 240u8, 250u8, 61u8, 42u8, - 147u8, - ], - ) - } - #[doc = " Period between successive spends."] - pub fn spend_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Treasury", - "SpendPeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Percentage of spare funds (if any) that are burnt per spend period."] - pub fn burn( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Treasury", - "Burn", - [ - 65u8, 93u8, 120u8, 165u8, 204u8, 81u8, 159u8, 163u8, 93u8, 135u8, - 114u8, 121u8, 147u8, 35u8, 215u8, 213u8, 4u8, 223u8, 83u8, 37u8, 225u8, - 200u8, 189u8, 156u8, 140u8, 36u8, 58u8, 46u8, 42u8, 232u8, 155u8, 0u8, - ], - ) - } - #[doc = " The treasury's pallet id, used for deriving its sovereign account ID."] - pub fn pallet_id( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "Treasury", - "PalletId", - [ - 56u8, 243u8, 53u8, 83u8, 154u8, 179u8, 170u8, 80u8, 133u8, 173u8, 61u8, - 161u8, 47u8, 225u8, 146u8, 21u8, 50u8, 229u8, 248u8, 27u8, 104u8, 58u8, - 129u8, 197u8, 102u8, 160u8, 168u8, 205u8, 154u8, 42u8, 217u8, 53u8, - ], - ) - } - #[doc = " The maximum number of approvals that can wait in the spending queue."] - #[doc = ""] - #[doc = " NOTE: This parameter is also used within the Bounties Pallet extension if enabled."] - pub fn max_approvals(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Treasury", - "MaxApprovals", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The period during which an approved treasury spend has to be claimed."] - pub fn payout_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Treasury", - "PayoutPeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod conviction_voting { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_conviction_voting::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_conviction_voting::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - #[codec(compact)] - pub poll_index: ::core::primitive::u32, - pub vote: runtime_types::pallet_conviction_voting::vote::AccountVote< - ::core::primitive::u128, - >, - } - impl ::subxt::blocks::StaticExtrinsic for Vote { - const PALLET: &'static str = "ConvictionVoting"; - const CALL: &'static str = "vote"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Delegate { - pub class: ::core::primitive::u16, - pub to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, - pub balance: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for Delegate { - const PALLET: &'static str = "ConvictionVoting"; - const CALL: &'static str = "delegate"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Undelegate { - pub class: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for Undelegate { - const PALLET: &'static str = "ConvictionVoting"; - const CALL: &'static str = "undelegate"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unlock { - pub class: ::core::primitive::u16, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for Unlock { - const PALLET: &'static str = "ConvictionVoting"; - const CALL: &'static str = "unlock"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveVote { - pub class: ::core::option::Option<::core::primitive::u16>, - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveVote { - const PALLET: &'static str = "ConvictionVoting"; - const CALL: &'static str = "remove_vote"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveOtherVote { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub class: ::core::primitive::u16, - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveOtherVote { - const PALLET: &'static str = "ConvictionVoting"; - const CALL: &'static str = "remove_other_vote"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::vote`]."] - pub fn vote( - &self, - poll_index: ::core::primitive::u32, - vote: runtime_types::pallet_conviction_voting::vote::AccountVote< - ::core::primitive::u128, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "vote", - types::Vote { poll_index, vote }, - [ - 57u8, 170u8, 177u8, 168u8, 158u8, 43u8, 87u8, 242u8, 176u8, 85u8, - 230u8, 64u8, 103u8, 239u8, 190u8, 6u8, 228u8, 165u8, 248u8, 77u8, - 231u8, 221u8, 186u8, 107u8, 249u8, 201u8, 226u8, 52u8, 129u8, 90u8, - 142u8, 159u8, - ], - ) - } - #[doc = "See [`Pallet::delegate`]."] - pub fn delegate( - &self, - class: ::core::primitive::u16, - to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, - balance: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "delegate", - types::Delegate { class, to, conviction, balance }, - [ - 223u8, 143u8, 33u8, 94u8, 32u8, 156u8, 43u8, 40u8, 142u8, 134u8, 209u8, - 134u8, 255u8, 179u8, 97u8, 46u8, 8u8, 140u8, 5u8, 29u8, 76u8, 22u8, - 36u8, 7u8, 108u8, 190u8, 220u8, 151u8, 10u8, 47u8, 89u8, 55u8, - ], - ) - } - #[doc = "See [`Pallet::undelegate`]."] - pub fn undelegate( - &self, - class: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "undelegate", - types::Undelegate { class }, - [ - 140u8, 232u8, 6u8, 53u8, 228u8, 8u8, 131u8, 144u8, 65u8, 66u8, 245u8, - 247u8, 147u8, 135u8, 198u8, 57u8, 82u8, 212u8, 89u8, 46u8, 236u8, - 168u8, 200u8, 220u8, 93u8, 168u8, 101u8, 29u8, 110u8, 76u8, 67u8, - 181u8, - ], - ) - } - #[doc = "See [`Pallet::unlock`]."] - pub fn unlock( - &self, - class: ::core::primitive::u16, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "unlock", - types::Unlock { class, target }, - [ - 79u8, 5u8, 252u8, 237u8, 109u8, 238u8, 157u8, 237u8, 125u8, 171u8, - 65u8, 160u8, 102u8, 192u8, 5u8, 141u8, 179u8, 249u8, 253u8, 213u8, - 105u8, 251u8, 241u8, 145u8, 186u8, 177u8, 244u8, 139u8, 71u8, 140u8, - 173u8, 108u8, - ], - ) - } - #[doc = "See [`Pallet::remove_vote`]."] - pub fn remove_vote( - &self, - class: ::core::option::Option<::core::primitive::u16>, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "remove_vote", - types::RemoveVote { class, index }, - [ - 255u8, 108u8, 211u8, 146u8, 168u8, 231u8, 207u8, 44u8, 76u8, 24u8, - 235u8, 60u8, 23u8, 79u8, 192u8, 192u8, 46u8, 40u8, 134u8, 27u8, 125u8, - 114u8, 125u8, 247u8, 85u8, 102u8, 76u8, 159u8, 34u8, 167u8, 152u8, - 148u8, - ], - ) - } - #[doc = "See [`Pallet::remove_other_vote`]."] - pub fn remove_other_vote( - &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - class: ::core::primitive::u16, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ConvictionVoting", - "remove_other_vote", - types::RemoveOtherVote { target, class, index }, - [ - 165u8, 26u8, 166u8, 37u8, 10u8, 174u8, 243u8, 10u8, 73u8, 93u8, 213u8, - 69u8, 200u8, 16u8, 48u8, 146u8, 160u8, 92u8, 28u8, 26u8, 158u8, 55u8, - 6u8, 251u8, 36u8, 132u8, 46u8, 195u8, 107u8, 34u8, 0u8, 100u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_conviction_voting::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account has delegated their vote to another account. \\[who, target\\]"] - pub struct Delegated(pub ::subxt::utils::AccountId32, pub ::subxt::utils::AccountId32); - impl ::subxt::events::StaticEvent for Delegated { - const PALLET: &'static str = "ConvictionVoting"; - const EVENT: &'static str = "Delegated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An \\[account\\] has cancelled a previous delegation operation."] - pub struct Undelegated(pub ::subxt::utils::AccountId32); - impl ::subxt::events::StaticEvent for Undelegated { - const PALLET: &'static str = "ConvictionVoting"; - const EVENT: &'static str = "Undelegated"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] - #[doc = " number of votes that we have recorded."] - pub fn voting_for_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_conviction_voting::vote::Voting< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - ::core::primitive::u32, - ::core::primitive::u32, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "VotingFor", - vec![], - [ - 76u8, 63u8, 153u8, 193u8, 39u8, 137u8, 186u8, 29u8, 202u8, 56u8, 169u8, - 56u8, 103u8, 138u8, 192u8, 18u8, 179u8, 114u8, 56u8, 121u8, 197u8, - 12u8, 29u8, 239u8, 220u8, 231u8, 24u8, 46u8, 134u8, 99u8, 53u8, 206u8, - ], - ) - } - #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] - #[doc = " number of votes that we have recorded."] - pub fn voting_for_iter1( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_conviction_voting::vote::Voting< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - ::core::primitive::u32, - ::core::primitive::u32, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "VotingFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 76u8, 63u8, 153u8, 193u8, 39u8, 137u8, 186u8, 29u8, 202u8, 56u8, 169u8, - 56u8, 103u8, 138u8, 192u8, 18u8, 179u8, 114u8, 56u8, 121u8, 197u8, - 12u8, 29u8, 239u8, 220u8, 231u8, 24u8, 46u8, 134u8, 99u8, 53u8, 206u8, - ], - ) - } - #[doc = " All voting for a particular voter in a particular voting class. We store the balance for the"] - #[doc = " number of votes that we have recorded."] - pub fn voting_for( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_conviction_voting::vote::Voting< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - ::core::primitive::u32, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "VotingFor", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 76u8, 63u8, 153u8, 193u8, 39u8, 137u8, 186u8, 29u8, 202u8, 56u8, 169u8, - 56u8, 103u8, 138u8, 192u8, 18u8, 179u8, 114u8, 56u8, 121u8, 197u8, - 12u8, 29u8, 239u8, 220u8, 231u8, 24u8, 46u8, 134u8, 99u8, 53u8, 206u8, - ], - ) - } - #[doc = " The voting classes which have a non-zero lock requirement and the lock amounts which they"] - #[doc = " require. The actual amount locked on behalf of this pallet should always be the maximum of"] - #[doc = " this list."] - pub fn class_locks_for_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u16, - ::core::primitive::u128, - )>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "ClassLocksFor", - vec![], - [ - 74u8, 74u8, 8u8, 82u8, 215u8, 61u8, 13u8, 9u8, 44u8, 222u8, 33u8, - 245u8, 195u8, 124u8, 6u8, 174u8, 65u8, 245u8, 71u8, 42u8, 47u8, 46u8, - 164u8, 231u8, 11u8, 245u8, 115u8, 207u8, 209u8, 137u8, 90u8, 6u8, - ], - ) - } - #[doc = " The voting classes which have a non-zero lock requirement and the lock amounts which they"] - #[doc = " require. The actual amount locked on behalf of this pallet should always be the maximum of"] - #[doc = " this list."] - pub fn class_locks_for( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u16, - ::core::primitive::u128, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ConvictionVoting", - "ClassLocksFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 74u8, 74u8, 8u8, 82u8, 215u8, 61u8, 13u8, 9u8, 44u8, 222u8, 33u8, - 245u8, 195u8, 124u8, 6u8, 174u8, 65u8, 245u8, 71u8, 42u8, 47u8, 46u8, - 164u8, 231u8, 11u8, 245u8, 115u8, 207u8, 209u8, 137u8, 90u8, 6u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The maximum number of concurrent votes an account may have."] - #[doc = ""] - #[doc = " Also used to compute weight, an overly large value can lead to extrinsics with large"] - #[doc = " weight estimation: see `delegate` for instance."] - pub fn max_votes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ConvictionVoting", - "MaxVotes", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The minimum period of vote locking."] - #[doc = ""] - #[doc = " It should be no shorter than enactment period to ensure that in the case of an approval,"] - #[doc = " those successful voters are locked into the consequences that their votes entail."] - pub fn vote_locking_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ConvictionVoting", - "VoteLockingPeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod referenda { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_referenda::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_referenda::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Submit { - pub proposal_origin: - ::std::boxed::Box, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - pub enactment_moment: - runtime_types::frame_support::traits::schedule::DispatchTime< - ::core::primitive::u32, - >, - } - impl ::subxt::blocks::StaticExtrinsic for Submit { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "submit"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlaceDecisionDeposit { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for PlaceDecisionDeposit { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "place_decision_deposit"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RefundDecisionDeposit { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RefundDecisionDeposit { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "refund_decision_deposit"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Cancel { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Cancel { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "cancel"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Kill { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Kill { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "kill"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NudgeReferendum { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for NudgeReferendum { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "nudge_referendum"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OneFewerDeciding { - pub track: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for OneFewerDeciding { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "one_fewer_deciding"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RefundSubmissionDeposit { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RefundSubmissionDeposit { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "refund_submission_deposit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMetadata { - pub index: ::core::primitive::u32, - pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, - } - impl ::subxt::blocks::StaticExtrinsic for SetMetadata { - const PALLET: &'static str = "Referenda"; - const CALL: &'static str = "set_metadata"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::submit`]."] - pub fn submit( - &self, - proposal_origin: runtime_types::rococo_runtime::OriginCaller, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - enactment_moment: runtime_types::frame_support::traits::schedule::DispatchTime< - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "submit", - types::Submit { - proposal_origin: ::std::boxed::Box::new(proposal_origin), - proposal, - enactment_moment, - }, - [ - 252u8, 72u8, 60u8, 208u8, 214u8, 81u8, 179u8, 80u8, 7u8, 215u8, 54u8, - 7u8, 214u8, 49u8, 72u8, 70u8, 213u8, 143u8, 217u8, 190u8, 47u8, 3u8, - 191u8, 110u8, 67u8, 139u8, 137u8, 215u8, 14u8, 225u8, 124u8, 117u8, - ], - ) - } - #[doc = "See [`Pallet::place_decision_deposit`]."] - pub fn place_decision_deposit( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "place_decision_deposit", - types::PlaceDecisionDeposit { index }, - [ - 247u8, 158u8, 55u8, 191u8, 188u8, 200u8, 3u8, 47u8, 20u8, 175u8, 86u8, - 203u8, 52u8, 253u8, 91u8, 131u8, 21u8, 213u8, 56u8, 68u8, 40u8, 84u8, - 184u8, 30u8, 9u8, 193u8, 63u8, 182u8, 178u8, 241u8, 247u8, 220u8, - ], - ) - } - #[doc = "See [`Pallet::refund_decision_deposit`]."] - pub fn refund_decision_deposit( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "refund_decision_deposit", - types::RefundDecisionDeposit { index }, - [ - 159u8, 19u8, 35u8, 216u8, 114u8, 105u8, 18u8, 42u8, 148u8, 151u8, - 136u8, 92u8, 117u8, 30u8, 29u8, 41u8, 238u8, 58u8, 195u8, 91u8, 115u8, - 135u8, 96u8, 99u8, 154u8, 233u8, 8u8, 249u8, 145u8, 165u8, 77u8, 164u8, - ], - ) - } - #[doc = "See [`Pallet::cancel`]."] - pub fn cancel( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "cancel", - types::Cancel { index }, - [ - 55u8, 206u8, 119u8, 156u8, 238u8, 165u8, 193u8, 73u8, 242u8, 13u8, - 212u8, 75u8, 136u8, 156u8, 151u8, 14u8, 35u8, 41u8, 156u8, 107u8, 60u8, - 190u8, 39u8, 216u8, 8u8, 74u8, 213u8, 130u8, 160u8, 131u8, 237u8, - 122u8, - ], - ) - } - #[doc = "See [`Pallet::kill`]."] - pub fn kill( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "kill", - types::Kill { index }, - [ - 50u8, 89u8, 57u8, 0u8, 87u8, 129u8, 113u8, 140u8, 179u8, 178u8, 126u8, - 198u8, 92u8, 92u8, 189u8, 64u8, 123u8, 232u8, 57u8, 227u8, 223u8, - 219u8, 73u8, 217u8, 179u8, 44u8, 210u8, 125u8, 180u8, 10u8, 143u8, - 48u8, - ], - ) - } - #[doc = "See [`Pallet::nudge_referendum`]."] - pub fn nudge_referendum( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "nudge_referendum", - types::NudgeReferendum { index }, - [ - 75u8, 99u8, 172u8, 30u8, 170u8, 150u8, 211u8, 229u8, 249u8, 128u8, - 194u8, 246u8, 100u8, 142u8, 193u8, 184u8, 232u8, 81u8, 29u8, 17u8, - 99u8, 91u8, 236u8, 85u8, 230u8, 226u8, 57u8, 115u8, 45u8, 170u8, 54u8, - 213u8, - ], - ) - } - #[doc = "See [`Pallet::one_fewer_deciding`]."] - pub fn one_fewer_deciding( - &self, - track: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "one_fewer_deciding", - types::OneFewerDeciding { track }, - [ - 15u8, 84u8, 79u8, 231u8, 21u8, 239u8, 244u8, 143u8, 183u8, 215u8, - 181u8, 25u8, 225u8, 195u8, 95u8, 171u8, 17u8, 156u8, 182u8, 128u8, - 111u8, 40u8, 151u8, 102u8, 196u8, 55u8, 36u8, 212u8, 89u8, 190u8, - 131u8, 167u8, - ], - ) - } - #[doc = "See [`Pallet::refund_submission_deposit`]."] - pub fn refund_submission_deposit( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "refund_submission_deposit", - types::RefundSubmissionDeposit { index }, - [ - 20u8, 217u8, 115u8, 6u8, 1u8, 60u8, 54u8, 136u8, 35u8, 41u8, 38u8, - 23u8, 85u8, 100u8, 141u8, 126u8, 30u8, 160u8, 61u8, 46u8, 134u8, 98u8, - 82u8, 38u8, 211u8, 124u8, 208u8, 222u8, 210u8, 10u8, 155u8, 122u8, - ], - ) - } - #[doc = "See [`Pallet::set_metadata`]."] - pub fn set_metadata( - &self, - index: ::core::primitive::u32, - maybe_hash: ::core::option::Option<::subxt::utils::H256>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Referenda", - "set_metadata", - types::SetMetadata { index, maybe_hash }, - [ - 207u8, 29u8, 146u8, 233u8, 219u8, 205u8, 88u8, 118u8, 106u8, 61u8, - 124u8, 101u8, 2u8, 41u8, 169u8, 70u8, 114u8, 189u8, 162u8, 118u8, 1u8, - 108u8, 234u8, 98u8, 245u8, 245u8, 183u8, 126u8, 89u8, 13u8, 112u8, - 88u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_referenda::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been submitted."] - pub struct Submitted { - pub index: ::core::primitive::u32, - pub track: ::core::primitive::u16, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - } - impl ::subxt::events::StaticEvent for Submitted { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Submitted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The decision deposit has been placed."] - pub struct DecisionDepositPlaced { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DecisionDepositPlaced { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "DecisionDepositPlaced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The decision deposit has been refunded."] - pub struct DecisionDepositRefunded { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DecisionDepositRefunded { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "DecisionDepositRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A deposit has been slashed."] - pub struct DepositSlashed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DepositSlashed { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "DepositSlashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has moved into the deciding phase."] - pub struct DecisionStarted { - pub index: ::core::primitive::u32, - pub track: ::core::primitive::u16, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for DecisionStarted { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "DecisionStarted"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ConfirmStarted { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ConfirmStarted { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "ConfirmStarted"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ConfirmAborted { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ConfirmAborted { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "ConfirmAborted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has ended its confirmation phase and is ready for approval."] - pub struct Confirmed { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Confirmed { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Confirmed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been approved and its proposal has been scheduled."] - pub struct Approved { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Approved { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Approved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal has been rejected by referendum."] - pub struct Rejected { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Rejected { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Rejected"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been timed out without being decided."] - pub struct TimedOut { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for TimedOut { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "TimedOut"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been cancelled."] - pub struct Cancelled { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Cancelled { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Cancelled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been killed."] - pub struct Killed { - pub index: ::core::primitive::u32, - pub tally: - runtime_types::pallet_conviction_voting::types::Tally<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for Killed { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "Killed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The submission deposit has been refunded."] - pub struct SubmissionDepositRefunded { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for SubmissionDepositRefunded { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "SubmissionDepositRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata for a referendum has been set."] - pub struct MetadataSet { - pub index: ::core::primitive::u32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataSet { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "MetadataSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata for a referendum has been cleared."] - pub struct MetadataCleared { - pub index: ::core::primitive::u32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataCleared { - const PALLET: &'static str = "Referenda"; - const EVENT: &'static str = "MetadataCleared"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The next free referendum index, aka the number of referenda started so far."] - pub fn referendum_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "ReferendumCount", - vec![], - [ - 64u8, 145u8, 232u8, 153u8, 121u8, 87u8, 128u8, 253u8, 170u8, 192u8, - 139u8, 18u8, 0u8, 33u8, 243u8, 11u8, 238u8, 222u8, 244u8, 5u8, 247u8, - 198u8, 149u8, 31u8, 122u8, 208u8, 86u8, 179u8, 166u8, 167u8, 93u8, - 67u8, - ], - ) - } - #[doc = " Information concerning any given referendum."] - pub fn referendum_info_for_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_referenda::types::ReferendumInfo< - ::core::primitive::u16, - runtime_types::rococo_runtime::OriginCaller, - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - ::core::primitive::u128, - runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - ::subxt::utils::AccountId32, - (::core::primitive::u32, ::core::primitive::u32), - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "ReferendumInfoFor", - vec![], - [ - 244u8, 215u8, 156u8, 181u8, 105u8, 12u8, 138u8, 249u8, 173u8, 158u8, - 171u8, 67u8, 107u8, 228u8, 45u8, 180u8, 252u8, 244u8, 186u8, 78u8, - 226u8, 223u8, 168u8, 137u8, 6u8, 232u8, 169u8, 108u8, 104u8, 211u8, - 1u8, 157u8, - ], - ) - } - #[doc = " Information concerning any given referendum."] - pub fn referendum_info_for( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_referenda::types::ReferendumInfo< - ::core::primitive::u16, - runtime_types::rococo_runtime::OriginCaller, - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - ::core::primitive::u128, - runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - ::subxt::utils::AccountId32, - (::core::primitive::u32, ::core::primitive::u32), - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "ReferendumInfoFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 244u8, 215u8, 156u8, 181u8, 105u8, 12u8, 138u8, 249u8, 173u8, 158u8, - 171u8, 67u8, 107u8, 228u8, 45u8, 180u8, 252u8, 244u8, 186u8, 78u8, - 226u8, 223u8, 168u8, 137u8, 6u8, 232u8, 169u8, 108u8, 104u8, 211u8, - 1u8, 157u8, - ], - ) - } - #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] - #[doc = " conviction-weighted approvals."] - #[doc = ""] - #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] - pub fn track_queue_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - ::core::primitive::u128, - )>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "TrackQueue", - vec![], - [ - 125u8, 59u8, 111u8, 68u8, 27u8, 236u8, 82u8, 55u8, 83u8, 159u8, 105u8, - 20u8, 241u8, 118u8, 58u8, 141u8, 103u8, 60u8, 246u8, 49u8, 121u8, - 183u8, 7u8, 203u8, 225u8, 67u8, 132u8, 79u8, 150u8, 107u8, 71u8, 89u8, - ], - ) - } - #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] - #[doc = " conviction-weighted approvals."] - #[doc = ""] - #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] - pub fn track_queue( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - ::core::primitive::u128, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "TrackQueue", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 125u8, 59u8, 111u8, 68u8, 27u8, 236u8, 82u8, 55u8, 83u8, 159u8, 105u8, - 20u8, 241u8, 118u8, 58u8, 141u8, 103u8, 60u8, 246u8, 49u8, 121u8, - 183u8, 7u8, 203u8, 225u8, 67u8, 132u8, 79u8, 150u8, 107u8, 71u8, 89u8, - ], - ) - } - #[doc = " The number of referenda being decided currently."] - pub fn deciding_count_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "DecidingCount", - vec![], - [ - 203u8, 89u8, 158u8, 179u8, 194u8, 82u8, 248u8, 162u8, 93u8, 140u8, - 146u8, 51u8, 110u8, 232u8, 51u8, 1u8, 128u8, 212u8, 199u8, 14u8, 182u8, - 103u8, 47u8, 252u8, 126u8, 108u8, 166u8, 69u8, 252u8, 179u8, 126u8, - 245u8, - ], - ) - } - #[doc = " The number of referenda being decided currently."] - pub fn deciding_count( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "DecidingCount", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 203u8, 89u8, 158u8, 179u8, 194u8, 82u8, 248u8, 162u8, 93u8, 140u8, - 146u8, 51u8, 110u8, 232u8, 51u8, 1u8, 128u8, 212u8, 199u8, 14u8, 182u8, - 103u8, 47u8, 252u8, 126u8, 108u8, 166u8, 69u8, 252u8, 179u8, 126u8, - 245u8, - ], - ) - } - #[doc = " The metadata is a general information concerning the referendum."] - #[doc = " The `Hash` refers to the preimage of the `Preimages` provider which can be a JSON"] - #[doc = " dump or IPFS hash of a JSON file."] - #[doc = ""] - #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] - #[doc = " large preimages."] - pub fn metadata_of_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "MetadataOf", - vec![], - [ - 159u8, 250u8, 56u8, 189u8, 247u8, 165u8, 206u8, 166u8, 91u8, 139u8, - 124u8, 164u8, 25u8, 246u8, 199u8, 36u8, 159u8, 56u8, 227u8, 136u8, 4u8, - 45u8, 193u8, 72u8, 200u8, 164u8, 39u8, 207u8, 224u8, 124u8, 191u8, - 110u8, - ], - ) - } - #[doc = " The metadata is a general information concerning the referendum."] - #[doc = " The `Hash` refers to the preimage of the `Preimages` provider which can be a JSON"] - #[doc = " dump or IPFS hash of a JSON file."] - #[doc = ""] - #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] - #[doc = " large preimages."] - pub fn metadata_of( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Referenda", - "MetadataOf", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 159u8, 250u8, 56u8, 189u8, 247u8, 165u8, 206u8, 166u8, 91u8, 139u8, - 124u8, 164u8, 25u8, 246u8, 199u8, 36u8, 159u8, 56u8, 227u8, 136u8, 4u8, - 45u8, 193u8, 72u8, 200u8, 164u8, 39u8, 207u8, 224u8, 124u8, 191u8, - 110u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount to be used as a deposit for a public referendum proposal."] - pub fn submission_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Referenda", - "SubmissionDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Maximum size of the referendum queue for a single track."] - pub fn max_queued(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Referenda", - "MaxQueued", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of blocks after submission that a referendum must begin being decided by."] - #[doc = " Once this passes, then anyone may cancel the referendum."] - pub fn undeciding_timeout( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Referenda", - "UndecidingTimeout", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Quantization level for the referendum wakeup scheduler. A higher number will result in"] - #[doc = " fewer storage reads/writes needed for smaller voters, but also result in delays to the"] - #[doc = " automatic referendum status changes. Explicit servicing instructions are unaffected."] - pub fn alarm_interval( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Referenda", - "AlarmInterval", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Information concerning the different referendum tracks."] - pub fn tracks( - &self, - ) -> ::subxt::constants::Address< - ::std::vec::Vec<( - ::core::primitive::u16, - runtime_types::pallet_referenda::types::TrackInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - )>, - > { - ::subxt::constants::Address::new_static( - "Referenda", - "Tracks", - [ - 35u8, 226u8, 207u8, 234u8, 184u8, 139u8, 187u8, 184u8, 128u8, 199u8, - 227u8, 15u8, 31u8, 196u8, 5u8, 207u8, 138u8, 174u8, 130u8, 201u8, - 200u8, 113u8, 86u8, 93u8, 221u8, 243u8, 229u8, 24u8, 18u8, 150u8, 56u8, - 159u8, - ], - ) - } - } - } - } - pub mod fellowship_collective { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_ranked_collective::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_ranked_collective::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for AddMember { - const PALLET: &'static str = "FellowshipCollective"; - const CALL: &'static str = "add_member"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PromoteMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for PromoteMember { - const PALLET: &'static str = "FellowshipCollective"; - const CALL: &'static str = "promote_member"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DemoteMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for DemoteMember { - const PALLET: &'static str = "FellowshipCollective"; - const CALL: &'static str = "demote_member"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub min_rank: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveMember { - const PALLET: &'static str = "FellowshipCollective"; - const CALL: &'static str = "remove_member"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - pub poll: ::core::primitive::u32, - pub aye: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for Vote { - const PALLET: &'static str = "FellowshipCollective"; - const CALL: &'static str = "vote"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CleanupPoll { - pub poll_index: ::core::primitive::u32, - pub max: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for CleanupPoll { - const PALLET: &'static str = "FellowshipCollective"; - const CALL: &'static str = "cleanup_poll"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExchangeMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub new_who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for ExchangeMember { - const PALLET: &'static str = "FellowshipCollective"; - const CALL: &'static str = "exchange_member"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::add_member`]."] - pub fn add_member( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipCollective", - "add_member", - types::AddMember { who }, - [ - 2u8, 131u8, 37u8, 217u8, 112u8, 46u8, 86u8, 165u8, 248u8, 244u8, 33u8, - 236u8, 155u8, 28u8, 163u8, 169u8, 213u8, 32u8, 70u8, 217u8, 97u8, - 194u8, 138u8, 77u8, 133u8, 97u8, 188u8, 49u8, 49u8, 31u8, 177u8, 206u8, - ], - ) - } - #[doc = "See [`Pallet::promote_member`]."] - pub fn promote_member( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipCollective", - "promote_member", - types::PromoteMember { who }, - [ - 169u8, 155u8, 9u8, 50u8, 144u8, 133u8, 230u8, 60u8, 216u8, 147u8, 3u8, - 236u8, 94u8, 185u8, 106u8, 139u8, 235u8, 143u8, 189u8, 135u8, 208u8, - 176u8, 126u8, 124u8, 85u8, 140u8, 189u8, 125u8, 87u8, 56u8, 57u8, - 246u8, - ], - ) - } - #[doc = "See [`Pallet::demote_member`]."] - pub fn demote_member( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipCollective", - "demote_member", - types::DemoteMember { who }, - [ - 21u8, 185u8, 71u8, 166u8, 106u8, 88u8, 74u8, 251u8, 78u8, 28u8, 205u8, - 171u8, 199u8, 195u8, 97u8, 149u8, 175u8, 229u8, 25u8, 113u8, 96u8, - 25u8, 240u8, 64u8, 109u8, 246u8, 203u8, 45u8, 110u8, 205u8, 115u8, - 178u8, - ], - ) - } - #[doc = "See [`Pallet::remove_member`]."] - pub fn remove_member( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - min_rank: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipCollective", - "remove_member", - types::RemoveMember { who, min_rank }, - [ - 23u8, 156u8, 32u8, 64u8, 158u8, 50u8, 64u8, 199u8, 108u8, 67u8, 133u8, - 128u8, 138u8, 241u8, 14u8, 238u8, 192u8, 173u8, 250u8, 11u8, 124u8, - 119u8, 177u8, 190u8, 152u8, 116u8, 134u8, 42u8, 216u8, 49u8, 113u8, - 49u8, - ], - ) - } - #[doc = "See [`Pallet::vote`]."] - pub fn vote( - &self, - poll: ::core::primitive::u32, - aye: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipCollective", - "vote", - types::Vote { poll, aye }, - [ - 54u8, 116u8, 81u8, 239u8, 223u8, 35u8, 11u8, 244u8, 245u8, 94u8, 23u8, - 241u8, 125u8, 231u8, 56u8, 150u8, 105u8, 125u8, 100u8, 171u8, 182u8, - 186u8, 134u8, 40u8, 4u8, 121u8, 119u8, 11u8, 93u8, 158u8, 59u8, 209u8, - ], - ) - } - #[doc = "See [`Pallet::cleanup_poll`]."] - pub fn cleanup_poll( - &self, - poll_index: ::core::primitive::u32, - max: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipCollective", - "cleanup_poll", - types::CleanupPoll { poll_index, max }, - [ - 157u8, 109u8, 86u8, 253u8, 62u8, 107u8, 235u8, 255u8, 171u8, 68u8, - 103u8, 92u8, 245u8, 25u8, 252u8, 158u8, 174u8, 137u8, 77u8, 251u8, - 105u8, 113u8, 165u8, 46u8, 39u8, 55u8, 166u8, 79u8, 103u8, 81u8, 121u8, - 37u8, - ], - ) - } - #[doc = "See [`Pallet::exchange_member`]."] - pub fn exchange_member( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - new_who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipCollective", - "exchange_member", - types::ExchangeMember { who, new_who }, - [ - 240u8, 208u8, 76u8, 147u8, 117u8, 23u8, 91u8, 37u8, 22u8, 101u8, 53u8, - 247u8, 161u8, 94u8, 109u8, 233u8, 104u8, 129u8, 67u8, 31u8, 223u8, - 182u8, 50u8, 233u8, 120u8, 129u8, 224u8, 135u8, 52u8, 162u8, 26u8, - 189u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_ranked_collective::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member `who` has been added."] - pub struct MemberAdded { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for MemberAdded { - const PALLET: &'static str = "FellowshipCollective"; - const EVENT: &'static str = "MemberAdded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The member `who`se rank has been changed to the given `rank`."] - pub struct RankChanged { - pub who: ::subxt::utils::AccountId32, - pub rank: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for RankChanged { - const PALLET: &'static str = "FellowshipCollective"; - const EVENT: &'static str = "RankChanged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The member `who` of given `rank` has been removed from the collective."] - pub struct MemberRemoved { - pub who: ::subxt::utils::AccountId32, - pub rank: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for MemberRemoved { - const PALLET: &'static str = "FellowshipCollective"; - const EVENT: &'static str = "MemberRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The member `who` has voted for the `poll` with the given `vote` leading to an updated"] - #[doc = "`tally`."] - pub struct Voted { - pub who: ::subxt::utils::AccountId32, - pub poll: ::core::primitive::u32, - pub vote: runtime_types::pallet_ranked_collective::VoteRecord, - pub tally: runtime_types::pallet_ranked_collective::Tally, - } - impl ::subxt::events::StaticEvent for Voted { - const PALLET: &'static str = "FellowshipCollective"; - const EVENT: &'static str = "Voted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The member `who` had their `AccountId` changed to `new_who`."] - pub struct MemberExchanged { - pub who: ::subxt::utils::AccountId32, - pub new_who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for MemberExchanged { - const PALLET: &'static str = "FellowshipCollective"; - const EVENT: &'static str = "MemberExchanged"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The number of members in the collective who have at least the rank according to the index"] - #[doc = " of the vec."] - pub fn member_count_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "MemberCount", - vec![], - [ - 0u8, 141u8, 66u8, 91u8, 155u8, 74u8, 17u8, 191u8, 143u8, 41u8, 231u8, - 56u8, 123u8, 219u8, 145u8, 27u8, 197u8, 62u8, 118u8, 237u8, 30u8, 7u8, - 107u8, 96u8, 95u8, 17u8, 242u8, 206u8, 246u8, 79u8, 53u8, 214u8, - ], - ) - } - #[doc = " The number of members in the collective who have at least the rank according to the index"] - #[doc = " of the vec."] - pub fn member_count( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "MemberCount", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 0u8, 141u8, 66u8, 91u8, 155u8, 74u8, 17u8, 191u8, 143u8, 41u8, 231u8, - 56u8, 123u8, 219u8, 145u8, 27u8, 197u8, 62u8, 118u8, 237u8, 30u8, 7u8, - 107u8, 96u8, 95u8, 17u8, 242u8, 206u8, 246u8, 79u8, 53u8, 214u8, - ], - ) - } - #[doc = " The current members of the collective."] - pub fn members_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_ranked_collective::MemberRecord, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "Members", - vec![], - [ - 101u8, 183u8, 36u8, 241u8, 67u8, 8u8, 252u8, 116u8, 110u8, 153u8, - 117u8, 210u8, 128u8, 80u8, 130u8, 163u8, 38u8, 76u8, 230u8, 107u8, - 112u8, 90u8, 102u8, 24u8, 217u8, 2u8, 244u8, 197u8, 103u8, 215u8, - 247u8, 133u8, - ], - ) - } - #[doc = " The current members of the collective."] - pub fn members( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_ranked_collective::MemberRecord, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "Members", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 101u8, 183u8, 36u8, 241u8, 67u8, 8u8, 252u8, 116u8, 110u8, 153u8, - 117u8, 210u8, 128u8, 80u8, 130u8, 163u8, 38u8, 76u8, 230u8, 107u8, - 112u8, 90u8, 102u8, 24u8, 217u8, 2u8, 244u8, 197u8, 103u8, 215u8, - 247u8, 133u8, - ], - ) - } - #[doc = " The index of each ranks's member into the group of members who have at least that rank."] - pub fn id_to_index_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "IdToIndex", - vec![], - [ - 121u8, 225u8, 69u8, 131u8, 194u8, 3u8, 82u8, 27u8, 129u8, 152u8, 157u8, - 45u8, 39u8, 47u8, 166u8, 28u8, 42u8, 92u8, 217u8, 189u8, 160u8, 102u8, - 153u8, 196u8, 94u8, 48u8, 248u8, 113u8, 164u8, 111u8, 27u8, 9u8, - ], - ) - } - #[doc = " The index of each ranks's member into the group of members who have at least that rank."] - pub fn id_to_index_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "IdToIndex", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 121u8, 225u8, 69u8, 131u8, 194u8, 3u8, 82u8, 27u8, 129u8, 152u8, 157u8, - 45u8, 39u8, 47u8, 166u8, 28u8, 42u8, 92u8, 217u8, 189u8, 160u8, 102u8, - 153u8, 196u8, 94u8, 48u8, 248u8, 113u8, 164u8, 111u8, 27u8, 9u8, - ], - ) - } - #[doc = " The index of each ranks's member into the group of members who have at least that rank."] - pub fn id_to_index( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "IdToIndex", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 121u8, 225u8, 69u8, 131u8, 194u8, 3u8, 82u8, 27u8, 129u8, 152u8, 157u8, - 45u8, 39u8, 47u8, 166u8, 28u8, 42u8, 92u8, 217u8, 189u8, 160u8, 102u8, - 153u8, 196u8, 94u8, 48u8, 248u8, 113u8, 164u8, 111u8, 27u8, 9u8, - ], - ) - } - #[doc = " The members in the collective by index. All indices in the range `0..MemberCount` will"] - #[doc = " return `Some`, however a member's index is not guaranteed to remain unchanged over time."] - pub fn index_to_id_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "IndexToId", - vec![], - [ - 110u8, 48u8, 214u8, 224u8, 56u8, 195u8, 186u8, 24u8, 111u8, 37u8, 15u8, - 153u8, 245u8, 101u8, 229u8, 149u8, 216u8, 185u8, 7u8, 242u8, 196u8, - 29u8, 205u8, 243u8, 162u8, 92u8, 71u8, 253u8, 102u8, 152u8, 137u8, - 70u8, - ], - ) - } - #[doc = " The members in the collective by index. All indices in the range `0..MemberCount` will"] - #[doc = " return `Some`, however a member's index is not guaranteed to remain unchanged over time."] - pub fn index_to_id_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "IndexToId", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 110u8, 48u8, 214u8, 224u8, 56u8, 195u8, 186u8, 24u8, 111u8, 37u8, 15u8, - 153u8, 245u8, 101u8, 229u8, 149u8, 216u8, 185u8, 7u8, 242u8, 196u8, - 29u8, 205u8, 243u8, 162u8, 92u8, 71u8, 253u8, 102u8, 152u8, 137u8, - 70u8, - ], - ) - } - #[doc = " The members in the collective by index. All indices in the range `0..MemberCount` will"] - #[doc = " return `Some`, however a member's index is not guaranteed to remain unchanged over time."] - pub fn index_to_id( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "IndexToId", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 110u8, 48u8, 214u8, 224u8, 56u8, 195u8, 186u8, 24u8, 111u8, 37u8, 15u8, - 153u8, 245u8, 101u8, 229u8, 149u8, 216u8, 185u8, 7u8, 242u8, 196u8, - 29u8, 205u8, 243u8, 162u8, 92u8, 71u8, 253u8, 102u8, 152u8, 137u8, - 70u8, - ], - ) - } - #[doc = " Votes on a given proposal, if it is ongoing."] - pub fn voting_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_ranked_collective::VoteRecord, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "Voting", - vec![], - [ - 180u8, 146u8, 236u8, 178u8, 30u8, 50u8, 161u8, 50u8, 140u8, 110u8, - 220u8, 1u8, 109u8, 209u8, 17u8, 94u8, 234u8, 223u8, 222u8, 177u8, - 243u8, 194u8, 246u8, 48u8, 178u8, 86u8, 30u8, 185u8, 56u8, 206u8, - 175u8, 18u8, - ], - ) - } - #[doc = " Votes on a given proposal, if it is ongoing."] - pub fn voting_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_ranked_collective::VoteRecord, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "Voting", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 180u8, 146u8, 236u8, 178u8, 30u8, 50u8, 161u8, 50u8, 140u8, 110u8, - 220u8, 1u8, 109u8, 209u8, 17u8, 94u8, 234u8, 223u8, 222u8, 177u8, - 243u8, 194u8, 246u8, 48u8, 178u8, 86u8, 30u8, 185u8, 56u8, 206u8, - 175u8, 18u8, - ], - ) - } - #[doc = " Votes on a given proposal, if it is ongoing."] - pub fn voting( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_ranked_collective::VoteRecord, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "Voting", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 180u8, 146u8, 236u8, 178u8, 30u8, 50u8, 161u8, 50u8, 140u8, 110u8, - 220u8, 1u8, 109u8, 209u8, 17u8, 94u8, 234u8, 223u8, 222u8, 177u8, - 243u8, 194u8, 246u8, 48u8, 178u8, 86u8, 30u8, 185u8, 56u8, 206u8, - 175u8, 18u8, - ], - ) - } - pub fn voting_cleanup_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "VotingCleanup", - vec![], - [ - 223u8, 130u8, 79u8, 104u8, 94u8, 221u8, 222u8, 72u8, 187u8, 95u8, - 231u8, 59u8, 28u8, 119u8, 191u8, 63u8, 40u8, 186u8, 58u8, 254u8, 14u8, - 233u8, 152u8, 36u8, 2u8, 231u8, 120u8, 13u8, 120u8, 211u8, 232u8, 11u8, - ], - ) - } - pub fn voting_cleanup( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipCollective", - "VotingCleanup", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 223u8, 130u8, 79u8, 104u8, 94u8, 221u8, 222u8, 72u8, 187u8, 95u8, - 231u8, 59u8, 28u8, 119u8, 191u8, 63u8, 40u8, 186u8, 58u8, 254u8, 14u8, - 233u8, 152u8, 36u8, 2u8, 231u8, 120u8, 13u8, 120u8, 211u8, 232u8, 11u8, - ], - ) - } - } - } - } - pub mod fellowship_referenda { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_referenda::pallet::Error2; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_referenda::pallet::Call2; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Submit { - pub proposal_origin: - ::std::boxed::Box, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - pub enactment_moment: - runtime_types::frame_support::traits::schedule::DispatchTime< - ::core::primitive::u32, - >, - } - impl ::subxt::blocks::StaticExtrinsic for Submit { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "submit"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlaceDecisionDeposit { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for PlaceDecisionDeposit { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "place_decision_deposit"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RefundDecisionDeposit { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RefundDecisionDeposit { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "refund_decision_deposit"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Cancel { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Cancel { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "cancel"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Kill { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Kill { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "kill"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NudgeReferendum { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for NudgeReferendum { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "nudge_referendum"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OneFewerDeciding { - pub track: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for OneFewerDeciding { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "one_fewer_deciding"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RefundSubmissionDeposit { - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RefundSubmissionDeposit { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "refund_submission_deposit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMetadata { - pub index: ::core::primitive::u32, - pub maybe_hash: ::core::option::Option<::subxt::utils::H256>, - } - impl ::subxt::blocks::StaticExtrinsic for SetMetadata { - const PALLET: &'static str = "FellowshipReferenda"; - const CALL: &'static str = "set_metadata"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::submit`]."] - pub fn submit( - &self, - proposal_origin: runtime_types::rococo_runtime::OriginCaller, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - enactment_moment: runtime_types::frame_support::traits::schedule::DispatchTime< - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "submit", - types::Submit { - proposal_origin: ::std::boxed::Box::new(proposal_origin), - proposal, - enactment_moment, - }, - [ - 252u8, 72u8, 60u8, 208u8, 214u8, 81u8, 179u8, 80u8, 7u8, 215u8, 54u8, - 7u8, 214u8, 49u8, 72u8, 70u8, 213u8, 143u8, 217u8, 190u8, 47u8, 3u8, - 191u8, 110u8, 67u8, 139u8, 137u8, 215u8, 14u8, 225u8, 124u8, 117u8, - ], - ) - } - #[doc = "See [`Pallet::place_decision_deposit`]."] - pub fn place_decision_deposit( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "place_decision_deposit", - types::PlaceDecisionDeposit { index }, - [ - 247u8, 158u8, 55u8, 191u8, 188u8, 200u8, 3u8, 47u8, 20u8, 175u8, 86u8, - 203u8, 52u8, 253u8, 91u8, 131u8, 21u8, 213u8, 56u8, 68u8, 40u8, 84u8, - 184u8, 30u8, 9u8, 193u8, 63u8, 182u8, 178u8, 241u8, 247u8, 220u8, - ], - ) - } - #[doc = "See [`Pallet::refund_decision_deposit`]."] - pub fn refund_decision_deposit( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "refund_decision_deposit", - types::RefundDecisionDeposit { index }, - [ - 159u8, 19u8, 35u8, 216u8, 114u8, 105u8, 18u8, 42u8, 148u8, 151u8, - 136u8, 92u8, 117u8, 30u8, 29u8, 41u8, 238u8, 58u8, 195u8, 91u8, 115u8, - 135u8, 96u8, 99u8, 154u8, 233u8, 8u8, 249u8, 145u8, 165u8, 77u8, 164u8, - ], - ) - } - #[doc = "See [`Pallet::cancel`]."] - pub fn cancel( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "cancel", - types::Cancel { index }, - [ - 55u8, 206u8, 119u8, 156u8, 238u8, 165u8, 193u8, 73u8, 242u8, 13u8, - 212u8, 75u8, 136u8, 156u8, 151u8, 14u8, 35u8, 41u8, 156u8, 107u8, 60u8, - 190u8, 39u8, 216u8, 8u8, 74u8, 213u8, 130u8, 160u8, 131u8, 237u8, - 122u8, - ], - ) - } - #[doc = "See [`Pallet::kill`]."] - pub fn kill( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "kill", - types::Kill { index }, - [ - 50u8, 89u8, 57u8, 0u8, 87u8, 129u8, 113u8, 140u8, 179u8, 178u8, 126u8, - 198u8, 92u8, 92u8, 189u8, 64u8, 123u8, 232u8, 57u8, 227u8, 223u8, - 219u8, 73u8, 217u8, 179u8, 44u8, 210u8, 125u8, 180u8, 10u8, 143u8, - 48u8, - ], - ) - } - #[doc = "See [`Pallet::nudge_referendum`]."] - pub fn nudge_referendum( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "nudge_referendum", - types::NudgeReferendum { index }, - [ - 75u8, 99u8, 172u8, 30u8, 170u8, 150u8, 211u8, 229u8, 249u8, 128u8, - 194u8, 246u8, 100u8, 142u8, 193u8, 184u8, 232u8, 81u8, 29u8, 17u8, - 99u8, 91u8, 236u8, 85u8, 230u8, 226u8, 57u8, 115u8, 45u8, 170u8, 54u8, - 213u8, - ], - ) - } - #[doc = "See [`Pallet::one_fewer_deciding`]."] - pub fn one_fewer_deciding( - &self, - track: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "one_fewer_deciding", - types::OneFewerDeciding { track }, - [ - 15u8, 84u8, 79u8, 231u8, 21u8, 239u8, 244u8, 143u8, 183u8, 215u8, - 181u8, 25u8, 225u8, 195u8, 95u8, 171u8, 17u8, 156u8, 182u8, 128u8, - 111u8, 40u8, 151u8, 102u8, 196u8, 55u8, 36u8, 212u8, 89u8, 190u8, - 131u8, 167u8, - ], - ) - } - #[doc = "See [`Pallet::refund_submission_deposit`]."] - pub fn refund_submission_deposit( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "refund_submission_deposit", - types::RefundSubmissionDeposit { index }, - [ - 20u8, 217u8, 115u8, 6u8, 1u8, 60u8, 54u8, 136u8, 35u8, 41u8, 38u8, - 23u8, 85u8, 100u8, 141u8, 126u8, 30u8, 160u8, 61u8, 46u8, 134u8, 98u8, - 82u8, 38u8, 211u8, 124u8, 208u8, 222u8, 210u8, 10u8, 155u8, 122u8, - ], - ) - } - #[doc = "See [`Pallet::set_metadata`]."] - pub fn set_metadata( - &self, - index: ::core::primitive::u32, - maybe_hash: ::core::option::Option<::subxt::utils::H256>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "FellowshipReferenda", - "set_metadata", - types::SetMetadata { index, maybe_hash }, - [ - 207u8, 29u8, 146u8, 233u8, 219u8, 205u8, 88u8, 118u8, 106u8, 61u8, - 124u8, 101u8, 2u8, 41u8, 169u8, 70u8, 114u8, 189u8, 162u8, 118u8, 1u8, - 108u8, 234u8, 98u8, 245u8, 245u8, 183u8, 126u8, 89u8, 13u8, 112u8, - 88u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_referenda::pallet::Event2; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been submitted."] - pub struct Submitted { - pub index: ::core::primitive::u32, - pub track: ::core::primitive::u16, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - } - impl ::subxt::events::StaticEvent for Submitted { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "Submitted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The decision deposit has been placed."] - pub struct DecisionDepositPlaced { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DecisionDepositPlaced { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "DecisionDepositPlaced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The decision deposit has been refunded."] - pub struct DecisionDepositRefunded { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DecisionDepositRefunded { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "DecisionDepositRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A deposit has been slashed."] - pub struct DepositSlashed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DepositSlashed { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "DepositSlashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has moved into the deciding phase."] - pub struct DecisionStarted { - pub index: ::core::primitive::u32, - pub track: ::core::primitive::u16, - pub proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - pub tally: runtime_types::pallet_ranked_collective::Tally, - } - impl ::subxt::events::StaticEvent for DecisionStarted { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "DecisionStarted"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ConfirmStarted { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ConfirmStarted { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "ConfirmStarted"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ConfirmAborted { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ConfirmAborted { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "ConfirmAborted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has ended its confirmation phase and is ready for approval."] - pub struct Confirmed { - pub index: ::core::primitive::u32, - pub tally: runtime_types::pallet_ranked_collective::Tally, - } - impl ::subxt::events::StaticEvent for Confirmed { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "Confirmed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been approved and its proposal has been scheduled."] - pub struct Approved { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Approved { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "Approved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proposal has been rejected by referendum."] - pub struct Rejected { - pub index: ::core::primitive::u32, - pub tally: runtime_types::pallet_ranked_collective::Tally, - } - impl ::subxt::events::StaticEvent for Rejected { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "Rejected"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been timed out without being decided."] - pub struct TimedOut { - pub index: ::core::primitive::u32, - pub tally: runtime_types::pallet_ranked_collective::Tally, - } - impl ::subxt::events::StaticEvent for TimedOut { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "TimedOut"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been cancelled."] - pub struct Cancelled { - pub index: ::core::primitive::u32, - pub tally: runtime_types::pallet_ranked_collective::Tally, - } - impl ::subxt::events::StaticEvent for Cancelled { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "Cancelled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A referendum has been killed."] - pub struct Killed { - pub index: ::core::primitive::u32, - pub tally: runtime_types::pallet_ranked_collective::Tally, - } - impl ::subxt::events::StaticEvent for Killed { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "Killed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The submission deposit has been refunded."] - pub struct SubmissionDepositRefunded { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for SubmissionDepositRefunded { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "SubmissionDepositRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata for a referendum has been set."] - pub struct MetadataSet { - pub index: ::core::primitive::u32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataSet { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "MetadataSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Metadata for a referendum has been cleared."] - pub struct MetadataCleared { - pub index: ::core::primitive::u32, - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for MetadataCleared { - const PALLET: &'static str = "FellowshipReferenda"; - const EVENT: &'static str = "MetadataCleared"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The next free referendum index, aka the number of referenda started so far."] - pub fn referendum_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "ReferendumCount", - vec![], - [ - 64u8, 145u8, 232u8, 153u8, 121u8, 87u8, 128u8, 253u8, 170u8, 192u8, - 139u8, 18u8, 0u8, 33u8, 243u8, 11u8, 238u8, 222u8, 244u8, 5u8, 247u8, - 198u8, 149u8, 31u8, 122u8, 208u8, 86u8, 179u8, 166u8, 167u8, 93u8, - 67u8, - ], - ) - } - #[doc = " Information concerning any given referendum."] - pub fn referendum_info_for_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_referenda::types::ReferendumInfo< - ::core::primitive::u16, - runtime_types::rococo_runtime::OriginCaller, - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - ::core::primitive::u128, - runtime_types::pallet_ranked_collective::Tally, - ::subxt::utils::AccountId32, - (::core::primitive::u32, ::core::primitive::u32), - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "ReferendumInfoFor", - vec![], - [ - 64u8, 146u8, 31u8, 207u8, 209u8, 86u8, 44u8, 53u8, 78u8, 240u8, 222u8, - 131u8, 225u8, 83u8, 114u8, 205u8, 225u8, 20u8, 128u8, 183u8, 19u8, - 204u8, 67u8, 31u8, 154u8, 115u8, 183u8, 218u8, 34u8, 134u8, 222u8, - 32u8, - ], - ) - } - #[doc = " Information concerning any given referendum."] - pub fn referendum_info_for( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_referenda::types::ReferendumInfo< - ::core::primitive::u16, - runtime_types::rococo_runtime::OriginCaller, - ::core::primitive::u32, - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - ::core::primitive::u128, - runtime_types::pallet_ranked_collective::Tally, - ::subxt::utils::AccountId32, - (::core::primitive::u32, ::core::primitive::u32), - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "ReferendumInfoFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 64u8, 146u8, 31u8, 207u8, 209u8, 86u8, 44u8, 53u8, 78u8, 240u8, 222u8, - 131u8, 225u8, 83u8, 114u8, 205u8, 225u8, 20u8, 128u8, 183u8, 19u8, - 204u8, 67u8, 31u8, 154u8, 115u8, 183u8, 218u8, 34u8, 134u8, 222u8, - 32u8, - ], - ) - } - #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] - #[doc = " conviction-weighted approvals."] - #[doc = ""] - #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] - pub fn track_queue_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "TrackQueue", - vec![], - [ - 187u8, 113u8, 225u8, 99u8, 159u8, 207u8, 182u8, 41u8, 116u8, 136u8, - 119u8, 196u8, 152u8, 50u8, 192u8, 22u8, 171u8, 182u8, 237u8, 228u8, - 80u8, 255u8, 227u8, 141u8, 155u8, 83u8, 71u8, 131u8, 118u8, 109u8, - 186u8, 65u8, - ], - ) - } - #[doc = " The sorted list of referenda ready to be decided but not yet being decided, ordered by"] - #[doc = " conviction-weighted approvals."] - #[doc = ""] - #[doc = " This should be empty if `DecidingCount` is less than `TrackInfo::max_deciding`."] - pub fn track_queue( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "TrackQueue", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 187u8, 113u8, 225u8, 99u8, 159u8, 207u8, 182u8, 41u8, 116u8, 136u8, - 119u8, 196u8, 152u8, 50u8, 192u8, 22u8, 171u8, 182u8, 237u8, 228u8, - 80u8, 255u8, 227u8, 141u8, 155u8, 83u8, 71u8, 131u8, 118u8, 109u8, - 186u8, 65u8, - ], - ) - } - #[doc = " The number of referenda being decided currently."] - pub fn deciding_count_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "DecidingCount", - vec![], - [ - 203u8, 89u8, 158u8, 179u8, 194u8, 82u8, 248u8, 162u8, 93u8, 140u8, - 146u8, 51u8, 110u8, 232u8, 51u8, 1u8, 128u8, 212u8, 199u8, 14u8, 182u8, - 103u8, 47u8, 252u8, 126u8, 108u8, 166u8, 69u8, 252u8, 179u8, 126u8, - 245u8, - ], - ) - } - #[doc = " The number of referenda being decided currently."] - pub fn deciding_count( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u16>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "DecidingCount", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 203u8, 89u8, 158u8, 179u8, 194u8, 82u8, 248u8, 162u8, 93u8, 140u8, - 146u8, 51u8, 110u8, 232u8, 51u8, 1u8, 128u8, 212u8, 199u8, 14u8, 182u8, - 103u8, 47u8, 252u8, 126u8, 108u8, 166u8, 69u8, 252u8, 179u8, 126u8, - 245u8, - ], - ) - } - #[doc = " The metadata is a general information concerning the referendum."] - #[doc = " The `Hash` refers to the preimage of the `Preimages` provider which can be a JSON"] - #[doc = " dump or IPFS hash of a JSON file."] - #[doc = ""] - #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] - #[doc = " large preimages."] - pub fn metadata_of_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "MetadataOf", - vec![], - [ - 159u8, 250u8, 56u8, 189u8, 247u8, 165u8, 206u8, 166u8, 91u8, 139u8, - 124u8, 164u8, 25u8, 246u8, 199u8, 36u8, 159u8, 56u8, 227u8, 136u8, 4u8, - 45u8, 193u8, 72u8, 200u8, 164u8, 39u8, 207u8, 224u8, 124u8, 191u8, - 110u8, - ], - ) - } - #[doc = " The metadata is a general information concerning the referendum."] - #[doc = " The `Hash` refers to the preimage of the `Preimages` provider which can be a JSON"] - #[doc = " dump or IPFS hash of a JSON file."] - #[doc = ""] - #[doc = " Consider a garbage collection for a metadata of finished referendums to `unrequest` (remove)"] - #[doc = " large preimages."] - pub fn metadata_of( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "FellowshipReferenda", - "MetadataOf", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 159u8, 250u8, 56u8, 189u8, 247u8, 165u8, 206u8, 166u8, 91u8, 139u8, - 124u8, 164u8, 25u8, 246u8, 199u8, 36u8, 159u8, 56u8, 227u8, 136u8, 4u8, - 45u8, 193u8, 72u8, 200u8, 164u8, 39u8, 207u8, 224u8, 124u8, 191u8, - 110u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount to be used as a deposit for a public referendum proposal."] - pub fn submission_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "FellowshipReferenda", - "SubmissionDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Maximum size of the referendum queue for a single track."] - pub fn max_queued(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "FellowshipReferenda", - "MaxQueued", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of blocks after submission that a referendum must begin being decided by."] - #[doc = " Once this passes, then anyone may cancel the referendum."] - pub fn undeciding_timeout( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "FellowshipReferenda", - "UndecidingTimeout", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Quantization level for the referendum wakeup scheduler. A higher number will result in"] - #[doc = " fewer storage reads/writes needed for smaller voters, but also result in delays to the"] - #[doc = " automatic referendum status changes. Explicit servicing instructions are unaffected."] - pub fn alarm_interval( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "FellowshipReferenda", - "AlarmInterval", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Information concerning the different referendum tracks."] - pub fn tracks( - &self, - ) -> ::subxt::constants::Address< - ::std::vec::Vec<( - ::core::primitive::u16, - runtime_types::pallet_referenda::types::TrackInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - )>, - > { - ::subxt::constants::Address::new_static( - "FellowshipReferenda", - "Tracks", - [ - 35u8, 226u8, 207u8, 234u8, 184u8, 139u8, 187u8, 184u8, 128u8, 199u8, - 227u8, 15u8, 31u8, 196u8, 5u8, 207u8, 138u8, 174u8, 130u8, 201u8, - 200u8, 113u8, 86u8, 93u8, 221u8, 243u8, 229u8, 24u8, 18u8, 150u8, 56u8, - 159u8, - ], - ) - } - } - } - } - pub mod origins { - use super::root_mod; - use super::runtime_types; - } - pub mod whitelist { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_whitelist::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_whitelist::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WhitelistCall { - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for WhitelistCall { - const PALLET: &'static str = "Whitelist"; - const CALL: &'static str = "whitelist_call"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveWhitelistedCall { - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveWhitelistedCall { - const PALLET: &'static str = "Whitelist"; - const CALL: &'static str = "remove_whitelisted_call"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchWhitelistedCall { - pub call_hash: ::subxt::utils::H256, - pub call_encoded_len: ::core::primitive::u32, - pub call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for DispatchWhitelistedCall { - const PALLET: &'static str = "Whitelist"; - const CALL: &'static str = "dispatch_whitelisted_call"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchWhitelistedCallWithPreimage { - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for DispatchWhitelistedCallWithPreimage { - const PALLET: &'static str = "Whitelist"; - const CALL: &'static str = "dispatch_whitelisted_call_with_preimage"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::whitelist_call`]."] - pub fn whitelist_call( - &self, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Whitelist", - "whitelist_call", - types::WhitelistCall { call_hash }, - [ - 121u8, 165u8, 49u8, 37u8, 127u8, 38u8, 126u8, 213u8, 115u8, 148u8, - 122u8, 211u8, 24u8, 91u8, 147u8, 27u8, 87u8, 210u8, 84u8, 104u8, 229u8, - 155u8, 133u8, 30u8, 34u8, 249u8, 107u8, 110u8, 31u8, 191u8, 128u8, - 28u8, - ], - ) - } - #[doc = "See [`Pallet::remove_whitelisted_call`]."] - pub fn remove_whitelisted_call( - &self, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Whitelist", - "remove_whitelisted_call", - types::RemoveWhitelistedCall { call_hash }, - [ - 30u8, 47u8, 13u8, 231u8, 165u8, 219u8, 246u8, 210u8, 11u8, 38u8, 219u8, - 218u8, 151u8, 226u8, 101u8, 175u8, 0u8, 239u8, 35u8, 46u8, 156u8, - 104u8, 145u8, 173u8, 105u8, 100u8, 21u8, 189u8, 123u8, 227u8, 196u8, - 40u8, - ], - ) - } - #[doc = "See [`Pallet::dispatch_whitelisted_call`]."] - pub fn dispatch_whitelisted_call( - &self, - call_hash: ::subxt::utils::H256, - call_encoded_len: ::core::primitive::u32, - call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Whitelist", - "dispatch_whitelisted_call", - types::DispatchWhitelistedCall { - call_hash, - call_encoded_len, - call_weight_witness, - }, - [ - 112u8, 67u8, 72u8, 26u8, 3u8, 214u8, 86u8, 102u8, 29u8, 96u8, 222u8, - 24u8, 115u8, 15u8, 124u8, 160u8, 148u8, 184u8, 56u8, 162u8, 188u8, - 123u8, 213u8, 234u8, 208u8, 123u8, 133u8, 253u8, 43u8, 226u8, 66u8, - 116u8, - ], - ) - } - #[doc = "See [`Pallet::dispatch_whitelisted_call_with_preimage`]."] - pub fn dispatch_whitelisted_call_with_preimage( - &self, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Whitelist", - "dispatch_whitelisted_call_with_preimage", - types::DispatchWhitelistedCallWithPreimage { - call: ::std::boxed::Box::new(call), - }, - [ - 124u8, 129u8, 217u8, 156u8, 108u8, 254u8, 69u8, 224u8, 163u8, 104u8, - 29u8, 87u8, 221u8, 0u8, 252u8, 108u8, 48u8, 113u8, 72u8, 55u8, 171u8, - 57u8, 249u8, 224u8, 4u8, 229u8, 97u8, 108u8, 49u8, 139u8, 185u8, 84u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_whitelist::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CallWhitelisted { - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for CallWhitelisted { - const PALLET: &'static str = "Whitelist"; - const EVENT: &'static str = "CallWhitelisted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WhitelistedCallRemoved { - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for WhitelistedCallRemoved { - const PALLET: &'static str = "Whitelist"; - const EVENT: &'static str = "WhitelistedCallRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WhitelistedCallDispatched { - pub call_hash: ::subxt::utils::H256, - pub result: ::core::result::Result< - runtime_types::frame_support::dispatch::PostDispatchInfo, - runtime_types::sp_runtime::DispatchErrorWithPostInfo< - runtime_types::frame_support::dispatch::PostDispatchInfo, - >, - >, - } - impl ::subxt::events::StaticEvent for WhitelistedCallDispatched { - const PALLET: &'static str = "Whitelist"; - const EVENT: &'static str = "WhitelistedCallDispatched"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - pub fn whitelisted_call_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Whitelist", - "WhitelistedCall", - vec![], - [ - 82u8, 208u8, 214u8, 72u8, 225u8, 35u8, 51u8, 212u8, 25u8, 138u8, 30u8, - 87u8, 54u8, 232u8, 72u8, 132u8, 4u8, 9u8, 28u8, 143u8, 251u8, 106u8, - 167u8, 218u8, 130u8, 185u8, 253u8, 185u8, 113u8, 154u8, 202u8, 66u8, - ], - ) - } - pub fn whitelisted_call( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Whitelist", - "WhitelistedCall", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 82u8, 208u8, 214u8, 72u8, 225u8, 35u8, 51u8, 212u8, 25u8, 138u8, 30u8, - 87u8, 54u8, 232u8, 72u8, 132u8, 4u8, 9u8, 28u8, 143u8, 251u8, 106u8, - 167u8, 218u8, 130u8, 185u8, 253u8, 185u8, 113u8, 154u8, 202u8, 66u8, - ], - ) - } - } - } - } - pub mod claims { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_common::claims::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_common::claims::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Claim { - pub dest: ::subxt::utils::AccountId32, - pub ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, - } - impl ::subxt::blocks::StaticExtrinsic for Claim { - const PALLET: &'static str = "Claims"; - const CALL: &'static str = "claim"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MintClaim { - pub who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub value: ::core::primitive::u128, - pub vesting_schedule: ::core::option::Option<( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - )>, - pub statement: ::core::option::Option< - runtime_types::polkadot_runtime_common::claims::StatementKind, - >, - } - impl ::subxt::blocks::StaticExtrinsic for MintClaim { - const PALLET: &'static str = "Claims"; - const CALL: &'static str = "mint_claim"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimAttest { - pub dest: ::subxt::utils::AccountId32, - pub ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, - pub statement: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for ClaimAttest { - const PALLET: &'static str = "Claims"; - const CALL: &'static str = "claim_attest"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Attest { - pub statement: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for Attest { - const PALLET: &'static str = "Claims"; - const CALL: &'static str = "attest"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MoveClaim { - pub old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, - } - impl ::subxt::blocks::StaticExtrinsic for MoveClaim { - const PALLET: &'static str = "Claims"; - const CALL: &'static str = "move_claim"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::claim`]."] - pub fn claim( - &self, - dest: ::subxt::utils::AccountId32, - ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Claims", - "claim", - types::Claim { dest, ethereum_signature }, - [ - 218u8, 236u8, 60u8, 12u8, 231u8, 72u8, 155u8, 30u8, 116u8, 126u8, - 145u8, 166u8, 135u8, 118u8, 22u8, 112u8, 212u8, 140u8, 129u8, 97u8, - 9u8, 241u8, 159u8, 140u8, 252u8, 128u8, 4u8, 175u8, 180u8, 133u8, 70u8, - 55u8, - ], - ) - } - #[doc = "See [`Pallet::mint_claim`]."] - pub fn mint_claim( - &self, - who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - value: ::core::primitive::u128, - vesting_schedule: ::core::option::Option<( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - )>, - statement: ::core::option::Option< - runtime_types::polkadot_runtime_common::claims::StatementKind, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Claims", - "mint_claim", - types::MintClaim { who, value, vesting_schedule, statement }, - [ - 59u8, 71u8, 27u8, 16u8, 177u8, 189u8, 53u8, 54u8, 86u8, 157u8, 122u8, - 182u8, 246u8, 113u8, 225u8, 10u8, 31u8, 253u8, 15u8, 48u8, 182u8, - 198u8, 38u8, 211u8, 90u8, 75u8, 10u8, 68u8, 70u8, 152u8, 141u8, 222u8, - ], - ) - } - #[doc = "See [`Pallet::claim_attest`]."] - pub fn claim_attest( - &self, - dest: ::subxt::utils::AccountId32, - ethereum_signature : runtime_types :: polkadot_runtime_common :: claims :: EcdsaSignature, - statement: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Claims", - "claim_attest", - types::ClaimAttest { dest, ethereum_signature, statement }, - [ - 61u8, 16u8, 39u8, 50u8, 23u8, 249u8, 217u8, 155u8, 138u8, 128u8, 247u8, - 214u8, 185u8, 7u8, 87u8, 108u8, 15u8, 43u8, 44u8, 224u8, 204u8, 39u8, - 219u8, 188u8, 197u8, 104u8, 120u8, 144u8, 152u8, 161u8, 244u8, 37u8, - ], - ) - } - #[doc = "See [`Pallet::attest`]."] - pub fn attest( - &self, - statement: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Claims", - "attest", - types::Attest { statement }, - [ - 254u8, 56u8, 140u8, 129u8, 227u8, 155u8, 161u8, 107u8, 167u8, 148u8, - 167u8, 104u8, 139u8, 174u8, 204u8, 124u8, 126u8, 198u8, 165u8, 61u8, - 83u8, 197u8, 242u8, 13u8, 70u8, 153u8, 14u8, 62u8, 214u8, 129u8, 64u8, - 93u8, - ], - ) - } - #[doc = "See [`Pallet::move_claim`]."] - pub fn move_claim( - &self, - old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Claims", - "move_claim", - types::MoveClaim { old, new, maybe_preclaim }, - [ - 187u8, 200u8, 222u8, 83u8, 110u8, 49u8, 60u8, 134u8, 91u8, 215u8, 67u8, - 18u8, 187u8, 241u8, 191u8, 127u8, 222u8, 171u8, 151u8, 245u8, 161u8, - 196u8, 123u8, 99u8, 206u8, 110u8, 55u8, 82u8, 210u8, 151u8, 116u8, - 230u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_common::claims::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Someone claimed some DOTs."] - pub struct Claimed { - pub who: ::subxt::utils::AccountId32, - pub ethereum_address: - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Claimed { - const PALLET: &'static str = "Claims"; - const EVENT: &'static str = "Claimed"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - pub fn claims_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Claims", - vec![], - [ - 148u8, 115u8, 159u8, 169u8, 36u8, 116u8, 15u8, 108u8, 57u8, 195u8, - 226u8, 180u8, 187u8, 112u8, 114u8, 63u8, 3u8, 205u8, 113u8, 141u8, - 149u8, 149u8, 118u8, 246u8, 45u8, 245u8, 148u8, 108u8, 22u8, 184u8, - 152u8, 132u8, - ], - ) - } - pub fn claims( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Claims", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 148u8, 115u8, 159u8, 169u8, 36u8, 116u8, 15u8, 108u8, 57u8, 195u8, - 226u8, 180u8, 187u8, 112u8, 114u8, 63u8, 3u8, 205u8, 113u8, 141u8, - 149u8, 149u8, 118u8, 246u8, 45u8, 245u8, 148u8, 108u8, 22u8, 184u8, - 152u8, 132u8, - ], - ) - } - pub fn total( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Total", - vec![], - [ - 188u8, 31u8, 219u8, 189u8, 49u8, 213u8, 203u8, 89u8, 125u8, 58u8, - 232u8, 159u8, 131u8, 155u8, 166u8, 113u8, 99u8, 24u8, 40u8, 242u8, - 118u8, 183u8, 108u8, 230u8, 135u8, 150u8, 84u8, 86u8, 118u8, 91u8, - 168u8, 62u8, - ], - ) - } - #[doc = " Vesting schedule for a claim."] - #[doc = " First balance is the total amount that should be held for vesting."] - #[doc = " Second balance is how much should be unlocked per block."] - #[doc = " The block number is when the vesting should start."] - pub fn vesting_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u128, ::core::primitive::u128, ::core::primitive::u32), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Vesting", - vec![], - [ - 206u8, 106u8, 195u8, 101u8, 55u8, 137u8, 50u8, 105u8, 137u8, 87u8, - 230u8, 34u8, 255u8, 94u8, 210u8, 186u8, 179u8, 72u8, 24u8, 194u8, - 209u8, 173u8, 115u8, 65u8, 227u8, 224u8, 58u8, 113u8, 200u8, 166u8, - 108u8, 198u8, - ], - ) - } - #[doc = " Vesting schedule for a claim."] - #[doc = " First balance is the total amount that should be held for vesting."] - #[doc = " Second balance is how much should be unlocked per block."] - #[doc = " The block number is when the vesting should start."] - pub fn vesting( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u128, ::core::primitive::u128, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Vesting", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 206u8, 106u8, 195u8, 101u8, 55u8, 137u8, 50u8, 105u8, 137u8, 87u8, - 230u8, 34u8, 255u8, 94u8, 210u8, 186u8, 179u8, 72u8, 24u8, 194u8, - 209u8, 173u8, 115u8, 65u8, 227u8, 224u8, 58u8, 113u8, 200u8, 166u8, - 108u8, 198u8, - ], - ) - } - #[doc = " The statement kind that must be signed, if any."] - pub fn signing_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::StatementKind, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Signing", - vec![], - [ - 111u8, 90u8, 178u8, 121u8, 241u8, 28u8, 169u8, 231u8, 61u8, 189u8, - 113u8, 207u8, 26u8, 153u8, 189u8, 15u8, 192u8, 25u8, 22u8, 22u8, 124u8, - 26u8, 191u8, 39u8, 130u8, 164u8, 34u8, 4u8, 44u8, 91u8, 82u8, 186u8, - ], - ) - } - #[doc = " The statement kind that must be signed, if any."] - pub fn signing( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::StatementKind, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Signing", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 111u8, 90u8, 178u8, 121u8, 241u8, 28u8, 169u8, 231u8, 61u8, 189u8, - 113u8, 207u8, 26u8, 153u8, 189u8, 15u8, 192u8, 25u8, 22u8, 22u8, 124u8, - 26u8, 191u8, 39u8, 130u8, 164u8, 34u8, 4u8, 44u8, 91u8, 82u8, 186u8, - ], - ) - } - #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] - pub fn preclaims_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Preclaims", - vec![], - [ - 197u8, 114u8, 147u8, 235u8, 203u8, 255u8, 94u8, 113u8, 151u8, 119u8, - 224u8, 147u8, 48u8, 246u8, 124u8, 38u8, 190u8, 237u8, 226u8, 65u8, - 91u8, 163u8, 129u8, 40u8, 71u8, 137u8, 220u8, 242u8, 51u8, 75u8, 3u8, - 204u8, - ], - ) - } - #[doc = " Pre-claimed Ethereum accounts, by the Account ID that they are claimed to."] - pub fn preclaims( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Claims", - "Preclaims", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 197u8, 114u8, 147u8, 235u8, 203u8, 255u8, 94u8, 113u8, 151u8, 119u8, - 224u8, 147u8, 48u8, 246u8, 124u8, 38u8, 190u8, 237u8, 226u8, 65u8, - 91u8, 163u8, 129u8, 40u8, 71u8, 137u8, 220u8, 242u8, 51u8, 75u8, 3u8, - 204u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - pub fn prefix( - &self, - ) -> ::subxt::constants::Address<::std::vec::Vec<::core::primitive::u8>> { - ::subxt::constants::Address::new_static( - "Claims", - "Prefix", - [ - 64u8, 190u8, 244u8, 122u8, 87u8, 182u8, 217u8, 16u8, 55u8, 223u8, - 128u8, 6u8, 112u8, 30u8, 236u8, 222u8, 153u8, 53u8, 247u8, 102u8, - 196u8, 31u8, 6u8, 186u8, 251u8, 209u8, 114u8, 125u8, 213u8, 222u8, - 240u8, 8u8, - ], - ) - } - } - } - } - pub mod utility { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_utility::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_utility::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Batch { - pub calls: ::std::vec::Vec, - } - impl ::subxt::blocks::StaticExtrinsic for Batch { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "batch"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsDerivative { - pub index: ::core::primitive::u16, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for AsDerivative { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "as_derivative"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BatchAll { - pub calls: ::std::vec::Vec, - } - impl ::subxt::blocks::StaticExtrinsic for BatchAll { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "batch_all"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchAs { - pub as_origin: ::std::boxed::Box, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for DispatchAs { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "dispatch_as"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceBatch { - pub calls: ::std::vec::Vec, - } - impl ::subxt::blocks::StaticExtrinsic for ForceBatch { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "force_batch"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WithWeight { - pub call: ::std::boxed::Box, - pub weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for WithWeight { - const PALLET: &'static str = "Utility"; - const CALL: &'static str = "with_weight"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::batch`]."] - pub fn batch( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "batch", - types::Batch { calls }, - [ - 5u8, 41u8, 135u8, 62u8, 44u8, 217u8, 76u8, 178u8, 151u8, 220u8, 78u8, - 243u8, 42u8, 37u8, 213u8, 167u8, 251u8, 57u8, 69u8, 165u8, 112u8, - 238u8, 53u8, 227u8, 178u8, 65u8, 223u8, 248u8, 27u8, 144u8, 117u8, - 146u8, - ], - ) - } - #[doc = "See [`Pallet::as_derivative`]."] - pub fn as_derivative( - &self, - index: ::core::primitive::u16, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "as_derivative", - types::AsDerivative { index, call: ::std::boxed::Box::new(call) }, - [ - 81u8, 78u8, 139u8, 179u8, 200u8, 220u8, 245u8, 84u8, 230u8, 229u8, - 50u8, 142u8, 138u8, 224u8, 53u8, 34u8, 6u8, 127u8, 47u8, 209u8, 20u8, - 40u8, 87u8, 30u8, 213u8, 254u8, 236u8, 229u8, 207u8, 235u8, 226u8, - 26u8, - ], - ) - } - #[doc = "See [`Pallet::batch_all`]."] - pub fn batch_all( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "batch_all", - types::BatchAll { calls }, - [ - 93u8, 249u8, 147u8, 126u8, 56u8, 220u8, 148u8, 229u8, 181u8, 114u8, - 59u8, 232u8, 135u8, 243u8, 76u8, 117u8, 185u8, 81u8, 127u8, 162u8, - 218u8, 194u8, 233u8, 119u8, 165u8, 130u8, 27u8, 178u8, 72u8, 200u8, - 138u8, 149u8, - ], - ) - } - #[doc = "See [`Pallet::dispatch_as`]."] - pub fn dispatch_as( - &self, - as_origin: runtime_types::rococo_runtime::OriginCaller, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "dispatch_as", - types::DispatchAs { - as_origin: ::std::boxed::Box::new(as_origin), - call: ::std::boxed::Box::new(call), - }, - [ - 207u8, 223u8, 244u8, 79u8, 45u8, 145u8, 14u8, 128u8, 162u8, 63u8, 18u8, - 51u8, 51u8, 187u8, 86u8, 3u8, 218u8, 241u8, 83u8, 92u8, 179u8, 107u8, - 227u8, 74u8, 9u8, 91u8, 57u8, 148u8, 228u8, 103u8, 241u8, 202u8, - ], - ) - } - #[doc = "See [`Pallet::force_batch`]."] - pub fn force_batch( - &self, - calls: ::std::vec::Vec, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "force_batch", - types::ForceBatch { calls }, - [ - 142u8, 90u8, 213u8, 143u8, 7u8, 184u8, 17u8, 169u8, 71u8, 196u8, 11u8, - 169u8, 234u8, 237u8, 233u8, 3u8, 10u8, 67u8, 140u8, 92u8, 25u8, 252u8, - 13u8, 29u8, 147u8, 123u8, 70u8, 229u8, 175u8, 38u8, 101u8, 1u8, - ], - ) - } - #[doc = "See [`Pallet::with_weight`]."] - pub fn with_weight( - &self, - call: runtime_types::rococo_runtime::RuntimeCall, - weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Utility", - "with_weight", - types::WithWeight { call: ::std::boxed::Box::new(call), weight }, - [ - 77u8, 175u8, 91u8, 183u8, 236u8, 153u8, 70u8, 170u8, 189u8, 208u8, - 104u8, 205u8, 27u8, 216u8, 1u8, 121u8, 61u8, 81u8, 169u8, 220u8, 155u8, - 99u8, 245u8, 219u8, 91u8, 106u8, 2u8, 187u8, 110u8, 241u8, 252u8, - 222u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_utility::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] - #[doc = "well as the error."] - pub struct BatchInterrupted { - pub index: ::core::primitive::u32, - pub error: runtime_types::sp_runtime::DispatchError, - } - impl ::subxt::events::StaticEvent for BatchInterrupted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchInterrupted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches completed fully with no error."] - pub struct BatchCompleted; - impl ::subxt::events::StaticEvent for BatchCompleted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchCompleted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Batch of dispatches completed but has errors."] - pub struct BatchCompletedWithErrors; - impl ::subxt::events::StaticEvent for BatchCompletedWithErrors { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "BatchCompletedWithErrors"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single item within a Batch of dispatches has completed with no error."] - pub struct ItemCompleted; - impl ::subxt::events::StaticEvent for ItemCompleted { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "ItemCompleted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A single item within a Batch of dispatches has completed with error."] - pub struct ItemFailed { - pub error: runtime_types::sp_runtime::DispatchError, - } - impl ::subxt::events::StaticEvent for ItemFailed { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "ItemFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A call was dispatched."] - pub struct DispatchedAs { - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for DispatchedAs { - const PALLET: &'static str = "Utility"; - const EVENT: &'static str = "DispatchedAs"; - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The limit on the number of batched calls."] - pub fn batched_calls_limit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Utility", - "batched_calls_limit", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod identity { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_identity::pallet::Error; - #[doc = "Identity pallet declaration."] - pub type Call = runtime_types::pallet_identity::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddRegistrar { - pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for AddRegistrar { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "add_registrar"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetIdentity { - pub info: - ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for SetIdentity { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "set_identity"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetSubs { - pub subs: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - )>, - } - impl ::subxt::blocks::StaticExtrinsic for SetSubs { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "set_subs"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearIdentity; - impl ::subxt::blocks::StaticExtrinsic for ClearIdentity { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "clear_identity"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestJudgement { - #[codec(compact)] - pub reg_index: ::core::primitive::u32, - #[codec(compact)] - pub max_fee: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for RequestJudgement { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "request_judgement"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelRequest { - pub reg_index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for CancelRequest { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "cancel_request"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetFee { - #[codec(compact)] - pub index: ::core::primitive::u32, - #[codec(compact)] - pub fee: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for SetFee { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "set_fee"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetAccountId { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for SetAccountId { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "set_account_id"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetFields { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub fields: ::core::primitive::u64, - } - impl ::subxt::blocks::StaticExtrinsic for SetFields { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "set_fields"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProvideJudgement { - #[codec(compact)] - pub reg_index: ::core::primitive::u32, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub judgement: - runtime_types::pallet_identity::types::Judgement<::core::primitive::u128>, - pub identity: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for ProvideJudgement { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "provide_judgement"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillIdentity { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for KillIdentity { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "kill_identity"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub data: runtime_types::pallet_identity::types::Data, - } - impl ::subxt::blocks::StaticExtrinsic for AddSub { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "add_sub"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RenameSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub data: runtime_types::pallet_identity::types::Data, - } - impl ::subxt::blocks::StaticExtrinsic for RenameSub { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "rename_sub"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveSub { - pub sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveSub { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "remove_sub"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QuitSub; - impl ::subxt::blocks::StaticExtrinsic for QuitSub { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "quit_sub"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddUsernameAuthority { - pub authority: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub suffix: ::std::vec::Vec<::core::primitive::u8>, - pub allocation: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for AddUsernameAuthority { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "add_username_authority"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveUsernameAuthority { - pub authority: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveUsernameAuthority { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "remove_username_authority"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetUsernameFor { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub username: ::std::vec::Vec<::core::primitive::u8>, - pub signature: - ::core::option::Option, - } - impl ::subxt::blocks::StaticExtrinsic for SetUsernameFor { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "set_username_for"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptUsername { - pub username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - impl ::subxt::blocks::StaticExtrinsic for AcceptUsername { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "accept_username"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveExpiredApproval { - pub username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveExpiredApproval { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "remove_expired_approval"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPrimaryUsername { - pub username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - impl ::subxt::blocks::StaticExtrinsic for SetPrimaryUsername { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "set_primary_username"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveDanglingUsername { - pub username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveDanglingUsername { - const PALLET: &'static str = "Identity"; - const CALL: &'static str = "remove_dangling_username"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::add_registrar`]."] - pub fn add_registrar( - &self, - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "add_registrar", - types::AddRegistrar { account }, - [ - 6u8, 131u8, 82u8, 191u8, 37u8, 240u8, 158u8, 187u8, 247u8, 98u8, 175u8, - 200u8, 147u8, 78u8, 88u8, 176u8, 227u8, 179u8, 184u8, 194u8, 91u8, 1u8, - 1u8, 20u8, 121u8, 4u8, 96u8, 94u8, 103u8, 140u8, 247u8, 253u8, - ], - ) - } - #[doc = "See [`Pallet::set_identity`]."] - pub fn set_identity( - &self, - info: runtime_types::pallet_identity::legacy::IdentityInfo, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_identity", - types::SetIdentity { info: ::std::boxed::Box::new(info) }, - [ - 18u8, 86u8, 67u8, 10u8, 116u8, 254u8, 94u8, 95u8, 166u8, 30u8, 204u8, - 189u8, 174u8, 70u8, 191u8, 255u8, 149u8, 93u8, 156u8, 120u8, 105u8, - 138u8, 199u8, 181u8, 43u8, 150u8, 143u8, 254u8, 182u8, 81u8, 86u8, - 45u8, - ], - ) - } - #[doc = "See [`Pallet::set_subs`]."] - pub fn set_subs( - &self, - subs: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - )>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_subs", - types::SetSubs { subs }, - [ - 34u8, 184u8, 18u8, 155u8, 112u8, 247u8, 235u8, 75u8, 209u8, 236u8, - 21u8, 238u8, 43u8, 237u8, 223u8, 147u8, 48u8, 6u8, 39u8, 231u8, 174u8, - 164u8, 243u8, 184u8, 220u8, 151u8, 165u8, 69u8, 219u8, 122u8, 234u8, - 100u8, - ], - ) - } - #[doc = "See [`Pallet::clear_identity`]."] - pub fn clear_identity(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "clear_identity", - types::ClearIdentity {}, - [ - 43u8, 115u8, 205u8, 44u8, 24u8, 130u8, 220u8, 69u8, 247u8, 176u8, - 200u8, 175u8, 67u8, 183u8, 36u8, 200u8, 162u8, 132u8, 242u8, 25u8, - 21u8, 106u8, 197u8, 219u8, 141u8, 51u8, 204u8, 13u8, 191u8, 201u8, - 31u8, 31u8, - ], - ) - } - #[doc = "See [`Pallet::request_judgement`]."] - pub fn request_judgement( - &self, - reg_index: ::core::primitive::u32, - max_fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "request_judgement", - types::RequestJudgement { reg_index, max_fee }, - [ - 83u8, 85u8, 55u8, 184u8, 14u8, 54u8, 49u8, 212u8, 26u8, 148u8, 33u8, - 147u8, 182u8, 54u8, 180u8, 12u8, 61u8, 179u8, 216u8, 157u8, 103u8, - 52u8, 120u8, 252u8, 83u8, 203u8, 144u8, 65u8, 15u8, 3u8, 21u8, 33u8, - ], - ) - } - #[doc = "See [`Pallet::cancel_request`]."] - pub fn cancel_request( - &self, - reg_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "cancel_request", - types::CancelRequest { reg_index }, - [ - 81u8, 14u8, 133u8, 219u8, 43u8, 84u8, 163u8, 208u8, 21u8, 185u8, 75u8, - 117u8, 126u8, 33u8, 210u8, 106u8, 122u8, 210u8, 35u8, 207u8, 104u8, - 206u8, 41u8, 117u8, 247u8, 108u8, 56u8, 23u8, 123u8, 169u8, 169u8, - 61u8, - ], - ) - } - #[doc = "See [`Pallet::set_fee`]."] - pub fn set_fee( - &self, - index: ::core::primitive::u32, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_fee", - types::SetFee { index, fee }, - [ - 131u8, 20u8, 17u8, 127u8, 180u8, 65u8, 225u8, 144u8, 193u8, 60u8, - 131u8, 241u8, 30u8, 149u8, 8u8, 76u8, 29u8, 52u8, 102u8, 108u8, 127u8, - 130u8, 70u8, 18u8, 94u8, 145u8, 179u8, 109u8, 252u8, 219u8, 58u8, - 163u8, - ], - ) - } - #[doc = "See [`Pallet::set_account_id`]."] - pub fn set_account_id( - &self, - index: ::core::primitive::u32, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_account_id", - types::SetAccountId { index, new }, - [ - 68u8, 57u8, 39u8, 134u8, 39u8, 82u8, 156u8, 107u8, 113u8, 99u8, 9u8, - 163u8, 58u8, 249u8, 247u8, 208u8, 38u8, 203u8, 54u8, 153u8, 116u8, - 143u8, 81u8, 46u8, 228u8, 149u8, 127u8, 115u8, 252u8, 83u8, 33u8, - 101u8, - ], - ) - } - #[doc = "See [`Pallet::set_fields`]."] - pub fn set_fields( - &self, - index: ::core::primitive::u32, - fields: ::core::primitive::u64, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_fields", - types::SetFields { index, fields }, - [ - 75u8, 38u8, 58u8, 93u8, 92u8, 164u8, 146u8, 146u8, 183u8, 245u8, 135u8, - 235u8, 12u8, 148u8, 37u8, 193u8, 58u8, 66u8, 173u8, 223u8, 166u8, - 169u8, 54u8, 159u8, 141u8, 36u8, 25u8, 231u8, 190u8, 211u8, 254u8, - 38u8, - ], - ) - } - #[doc = "See [`Pallet::provide_judgement`]."] - pub fn provide_judgement( - &self, - reg_index: ::core::primitive::u32, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - judgement: runtime_types::pallet_identity::types::Judgement< - ::core::primitive::u128, - >, - identity: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "provide_judgement", - types::ProvideJudgement { reg_index, target, judgement, identity }, - [ - 145u8, 188u8, 61u8, 236u8, 183u8, 49u8, 49u8, 149u8, 240u8, 184u8, - 202u8, 75u8, 69u8, 0u8, 95u8, 103u8, 132u8, 24u8, 107u8, 221u8, 236u8, - 75u8, 231u8, 125u8, 39u8, 189u8, 45u8, 202u8, 116u8, 123u8, 236u8, - 96u8, - ], - ) - } - #[doc = "See [`Pallet::kill_identity`]."] - pub fn kill_identity( - &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "kill_identity", - types::KillIdentity { target }, - [ - 114u8, 249u8, 102u8, 62u8, 118u8, 105u8, 185u8, 61u8, 173u8, 52u8, - 57u8, 190u8, 102u8, 74u8, 108u8, 239u8, 142u8, 176u8, 116u8, 51u8, - 49u8, 197u8, 6u8, 183u8, 248u8, 202u8, 202u8, 140u8, 134u8, 59u8, - 103u8, 182u8, - ], - ) - } - #[doc = "See [`Pallet::add_sub`]."] - pub fn add_sub( - &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - data: runtime_types::pallet_identity::types::Data, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "add_sub", - types::AddSub { sub, data }, - [ - 3u8, 65u8, 137u8, 35u8, 238u8, 133u8, 56u8, 233u8, 37u8, 125u8, 221u8, - 186u8, 153u8, 74u8, 69u8, 196u8, 244u8, 82u8, 51u8, 7u8, 216u8, 29u8, - 18u8, 16u8, 198u8, 184u8, 0u8, 181u8, 71u8, 227u8, 144u8, 33u8, - ], - ) - } - #[doc = "See [`Pallet::rename_sub`]."] - pub fn rename_sub( - &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - data: runtime_types::pallet_identity::types::Data, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "rename_sub", - types::RenameSub { sub, data }, - [ - 252u8, 50u8, 201u8, 112u8, 49u8, 248u8, 223u8, 239u8, 219u8, 226u8, - 64u8, 68u8, 227u8, 20u8, 30u8, 24u8, 36u8, 77u8, 26u8, 235u8, 144u8, - 240u8, 11u8, 111u8, 145u8, 167u8, 184u8, 207u8, 173u8, 58u8, 152u8, - 202u8, - ], - ) - } - #[doc = "See [`Pallet::remove_sub`]."] - pub fn remove_sub( - &self, - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "remove_sub", - types::RemoveSub { sub }, - [ - 95u8, 249u8, 171u8, 27u8, 100u8, 186u8, 67u8, 214u8, 226u8, 6u8, 118u8, - 39u8, 91u8, 122u8, 1u8, 87u8, 1u8, 226u8, 101u8, 9u8, 199u8, 167u8, - 84u8, 202u8, 141u8, 196u8, 80u8, 195u8, 15u8, 114u8, 140u8, 144u8, - ], - ) - } - #[doc = "See [`Pallet::quit_sub`]."] - pub fn quit_sub(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "quit_sub", - types::QuitSub {}, - [ - 147u8, 131u8, 175u8, 171u8, 187u8, 201u8, 240u8, 26u8, 146u8, 224u8, - 74u8, 166u8, 242u8, 193u8, 204u8, 247u8, 168u8, 93u8, 18u8, 32u8, 27u8, - 208u8, 149u8, 146u8, 179u8, 172u8, 75u8, 112u8, 84u8, 141u8, 233u8, - 223u8, - ], - ) - } - #[doc = "See [`Pallet::add_username_authority`]."] - pub fn add_username_authority( - &self, - authority: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - suffix: ::std::vec::Vec<::core::primitive::u8>, - allocation: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "add_username_authority", - types::AddUsernameAuthority { authority, suffix, allocation }, - [ - 225u8, 197u8, 122u8, 209u8, 206u8, 241u8, 247u8, 232u8, 196u8, 110u8, - 75u8, 157u8, 44u8, 181u8, 35u8, 75u8, 182u8, 219u8, 100u8, 64u8, 208u8, - 112u8, 120u8, 229u8, 211u8, 69u8, 193u8, 214u8, 195u8, 98u8, 10u8, - 25u8, - ], - ) - } - #[doc = "See [`Pallet::remove_username_authority`]."] - pub fn remove_username_authority( - &self, - authority: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "remove_username_authority", - types::RemoveUsernameAuthority { authority }, - [ - 4u8, 182u8, 89u8, 1u8, 183u8, 15u8, 215u8, 48u8, 165u8, 97u8, 252u8, - 54u8, 223u8, 18u8, 211u8, 227u8, 226u8, 230u8, 185u8, 71u8, 202u8, - 95u8, 191u8, 6u8, 118u8, 144u8, 92u8, 98u8, 64u8, 243u8, 2u8, 137u8, - ], - ) - } - #[doc = "See [`Pallet::set_username_for`]."] - pub fn set_username_for( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - username: ::std::vec::Vec<::core::primitive::u8>, - signature: ::core::option::Option, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_username_for", - types::SetUsernameFor { who, username, signature }, - [ - 109u8, 128u8, 201u8, 28u8, 164u8, 222u8, 234u8, 197u8, 202u8, 156u8, - 53u8, 83u8, 51u8, 211u8, 222u8, 126u8, 227u8, 105u8, 72u8, 29u8, 25u8, - 188u8, 134u8, 247u8, 210u8, 183u8, 69u8, 94u8, 238u8, 91u8, 176u8, - 158u8, - ], - ) - } - #[doc = "See [`Pallet::accept_username`]."] - pub fn accept_username( - &self, - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "accept_username", - types::AcceptUsername { username }, - [ - 247u8, 162u8, 83u8, 250u8, 214u8, 7u8, 12u8, 253u8, 227u8, 4u8, 95u8, - 71u8, 150u8, 218u8, 216u8, 86u8, 137u8, 37u8, 114u8, 188u8, 18u8, - 232u8, 229u8, 179u8, 172u8, 251u8, 70u8, 29u8, 18u8, 86u8, 33u8, 129u8, - ], - ) - } - #[doc = "See [`Pallet::remove_expired_approval`]."] - pub fn remove_expired_approval( - &self, - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "remove_expired_approval", - types::RemoveExpiredApproval { username }, - [ - 159u8, 171u8, 27u8, 97u8, 224u8, 171u8, 14u8, 89u8, 65u8, 213u8, 208u8, - 67u8, 118u8, 146u8, 0u8, 131u8, 82u8, 186u8, 142u8, 52u8, 173u8, 90u8, - 104u8, 107u8, 114u8, 202u8, 123u8, 222u8, 49u8, 53u8, 59u8, 61u8, - ], - ) - } - #[doc = "See [`Pallet::set_primary_username`]."] - pub fn set_primary_username( - &self, - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "set_primary_username", - types::SetPrimaryUsername { username }, - [ - 3u8, 25u8, 56u8, 26u8, 108u8, 165u8, 84u8, 231u8, 16u8, 4u8, 6u8, - 232u8, 141u8, 7u8, 254u8, 50u8, 26u8, 230u8, 66u8, 245u8, 255u8, 101u8, - 183u8, 234u8, 197u8, 186u8, 132u8, 197u8, 251u8, 84u8, 212u8, 162u8, - ], - ) - } - #[doc = "See [`Pallet::remove_dangling_username`]."] - pub fn remove_dangling_username( - &self, - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Identity", - "remove_dangling_username", - types::RemoveDanglingUsername { username }, - [ - 220u8, 67u8, 52u8, 223u8, 169u8, 81u8, 202u8, 74u8, 199u8, 169u8, 89u8, - 60u8, 57u8, 153u8, 240u8, 105u8, 188u8, 222u8, 250u8, 247u8, 91u8, - 137u8, 37u8, 212u8, 10u8, 51u8, 9u8, 202u8, 165u8, 155u8, 222u8, 29u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_identity::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was set or reset (which will remove all judgements)."] - pub struct IdentitySet { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for IdentitySet { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentitySet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was cleared, and the given balance returned."] - pub struct IdentityCleared { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for IdentityCleared { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentityCleared"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A name was removed and the given balance slashed."] - pub struct IdentityKilled { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for IdentityKilled { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "IdentityKilled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement was asked from a registrar."] - pub struct JudgementRequested { - pub who: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for JudgementRequested { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementRequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement request was retracted."] - pub struct JudgementUnrequested { - pub who: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for JudgementUnrequested { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementUnrequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A judgement was given by a registrar."] - pub struct JudgementGiven { - pub target: ::subxt::utils::AccountId32, - pub registrar_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for JudgementGiven { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "JudgementGiven"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A registrar was added."] - pub struct RegistrarAdded { - pub registrar_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for RegistrarAdded { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "RegistrarAdded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was added to an identity and the deposit paid."] - pub struct SubIdentityAdded { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for SubIdentityAdded { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityAdded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was removed from an identity and the deposit freed."] - pub struct SubIdentityRemoved { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for SubIdentityRemoved { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sub-identity was cleared, and the given deposit repatriated from the"] - #[doc = "main identity account to the sub-identity account."] - pub struct SubIdentityRevoked { - pub sub: ::subxt::utils::AccountId32, - pub main: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for SubIdentityRevoked { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "SubIdentityRevoked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A username authority was added."] - pub struct AuthorityAdded { - pub authority: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for AuthorityAdded { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "AuthorityAdded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A username authority was removed."] - pub struct AuthorityRemoved { - pub authority: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for AuthorityRemoved { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "AuthorityRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A username was set for `who`."] - pub struct UsernameSet { - pub who: ::subxt::utils::AccountId32, - pub username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - impl ::subxt::events::StaticEvent for UsernameSet { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "UsernameSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A username was queued, but `who` must accept it prior to `expiration`."] - pub struct UsernameQueued { - pub who: ::subxt::utils::AccountId32, - pub username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub expiration: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for UsernameQueued { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "UsernameQueued"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A queued username passed its expiration without being claimed and was removed."] - pub struct PreapprovalExpired { - pub whose: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for PreapprovalExpired { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "PreapprovalExpired"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A username was set as a primary and can be looked up from `who`."] - pub struct PrimaryUsernameSet { - pub who: ::subxt::utils::AccountId32, - pub username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - impl ::subxt::events::StaticEvent for PrimaryUsernameSet { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "PrimaryUsernameSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A dangling username (as in, a username corresponding to an account that has removed its"] - #[doc = "identity) has been removed."] - pub struct DanglingUsernameRemoved { - pub who: ::subxt::utils::AccountId32, - pub username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - impl ::subxt::events::StaticEvent for DanglingUsernameRemoved { - const PALLET: &'static str = "Identity"; - const EVENT: &'static str = "DanglingUsernameRemoved"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Information that is pertinent to identify the entity behind an account. First item is the"] - #[doc = " registration, second is the account's primary username."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn identity_of_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::pallet_identity::types::Registration< - ::core::primitive::u128, - runtime_types::pallet_identity::legacy::IdentityInfo, - >, - ::core::option::Option< - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - >, - ), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "IdentityOf", - vec![], - [ - 0u8, 73u8, 213u8, 52u8, 49u8, 235u8, 238u8, 43u8, 119u8, 12u8, 35u8, - 162u8, 230u8, 24u8, 246u8, 200u8, 44u8, 254u8, 13u8, 84u8, 10u8, 27u8, - 159u8, 6u8, 176u8, 125u8, 24u8, 212u8, 250u8, 154u8, 181u8, 12u8, - ], - ) - } - #[doc = " Information that is pertinent to identify the entity behind an account. First item is the"] - #[doc = " registration, second is the account's primary username."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn identity_of( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::pallet_identity::types::Registration< - ::core::primitive::u128, - runtime_types::pallet_identity::legacy::IdentityInfo, - >, - ::core::option::Option< - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - >, - ), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "IdentityOf", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 0u8, 73u8, 213u8, 52u8, 49u8, 235u8, 238u8, 43u8, 119u8, 12u8, 35u8, - 162u8, 230u8, 24u8, 246u8, 200u8, 44u8, 254u8, 13u8, 84u8, 10u8, 27u8, - 159u8, 6u8, 176u8, 125u8, 24u8, 212u8, 250u8, 154u8, 181u8, 12u8, - ], - ) - } - #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] - #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] - pub fn super_of_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::subxt::utils::AccountId32, runtime_types::pallet_identity::types::Data), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "SuperOf", - vec![], - [ - 84u8, 72u8, 64u8, 14u8, 56u8, 9u8, 143u8, 100u8, 141u8, 163u8, 36u8, - 55u8, 38u8, 254u8, 164u8, 17u8, 3u8, 110u8, 88u8, 175u8, 161u8, 65u8, - 159u8, 40u8, 46u8, 8u8, 177u8, 81u8, 130u8, 38u8, 193u8, 28u8, - ], - ) - } - #[doc = " The super-identity of an alternative \"sub\" identity together with its name, within that"] - #[doc = " context. If the account is not some other account's sub-identity, then just `None`."] - pub fn super_of( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::subxt::utils::AccountId32, runtime_types::pallet_identity::types::Data), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "SuperOf", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 84u8, 72u8, 64u8, 14u8, 56u8, 9u8, 143u8, 100u8, 141u8, 163u8, 36u8, - 55u8, 38u8, 254u8, 164u8, 17u8, 3u8, 110u8, 88u8, 175u8, 161u8, 65u8, - 159u8, 40u8, 46u8, 8u8, 177u8, 81u8, 130u8, 38u8, 193u8, 28u8, - ], - ) - } - #[doc = " Alternative \"sub\" identities of this account."] - #[doc = ""] - #[doc = " The first item is the deposit, the second is a vector of the accounts."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn subs_of_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "SubsOf", - vec![], - [ - 164u8, 140u8, 52u8, 123u8, 220u8, 118u8, 147u8, 3u8, 67u8, 22u8, 191u8, - 18u8, 186u8, 21u8, 154u8, 8u8, 205u8, 224u8, 163u8, 173u8, 174u8, - 107u8, 144u8, 215u8, 116u8, 64u8, 159u8, 115u8, 159u8, 205u8, 91u8, - 28u8, - ], - ) - } - #[doc = " Alternative \"sub\" identities of this account."] - #[doc = ""] - #[doc = " The first item is the deposit, the second is a vector of the accounts."] - #[doc = ""] - #[doc = " TWOX-NOTE: OK ― `AccountId` is a secure hash."] - pub fn subs_of( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - ), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "SubsOf", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 164u8, 140u8, 52u8, 123u8, 220u8, 118u8, 147u8, 3u8, 67u8, 22u8, 191u8, - 18u8, 186u8, 21u8, 154u8, 8u8, 205u8, 224u8, 163u8, 173u8, 174u8, - 107u8, 144u8, 215u8, 116u8, 64u8, 159u8, 115u8, 159u8, 205u8, 91u8, - 28u8, - ], - ) - } - #[doc = " The set of registrars. Not expected to get very big as can only be added through a"] - #[doc = " special origin (likely a council motion)."] - #[doc = ""] - #[doc = " The index into this can be cast to `RegistrarIndex` to get a valid value."] - pub fn registrars( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::option::Option< - runtime_types::pallet_identity::types::RegistrarInfo< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - ::core::primitive::u64, - >, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "Registrars", - vec![], - [ - 167u8, 99u8, 159u8, 117u8, 103u8, 243u8, 208u8, 113u8, 57u8, 225u8, - 27u8, 25u8, 188u8, 120u8, 15u8, 40u8, 134u8, 169u8, 108u8, 134u8, 83u8, - 184u8, 223u8, 170u8, 194u8, 19u8, 168u8, 43u8, 119u8, 76u8, 94u8, - 154u8, - ], - ) - } - #[doc = " A map of the accounts who are authorized to grant usernames."] - pub fn username_authorities_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_identity::types::AuthorityProperties< - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "UsernameAuthorities", - vec![], - [ - 89u8, 102u8, 60u8, 184u8, 127u8, 244u8, 3u8, 61u8, 209u8, 78u8, 178u8, - 44u8, 159u8, 27u8, 7u8, 0u8, 22u8, 116u8, 42u8, 240u8, 130u8, 93u8, - 214u8, 182u8, 79u8, 222u8, 19u8, 20u8, 34u8, 198u8, 164u8, 146u8, - ], - ) - } - #[doc = " A map of the accounts who are authorized to grant usernames."] - pub fn username_authorities( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_identity::types::AuthorityProperties< - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "UsernameAuthorities", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 89u8, 102u8, 60u8, 184u8, 127u8, 244u8, 3u8, 61u8, 209u8, 78u8, 178u8, - 44u8, 159u8, 27u8, 7u8, 0u8, 22u8, 116u8, 42u8, 240u8, 130u8, 93u8, - 214u8, 182u8, 79u8, 222u8, 19u8, 20u8, 34u8, 198u8, 164u8, 146u8, - ], - ) - } - #[doc = " Reverse lookup from `username` to the `AccountId` that has registered it. The value should"] - #[doc = " be a key in the `IdentityOf` map, but it may not if the user has cleared their identity."] - #[doc = ""] - #[doc = " Multiple usernames may map to the same `AccountId`, but `IdentityOf` will only map to one"] - #[doc = " primary username."] - pub fn account_of_username_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "AccountOfUsername", - vec![], - [ - 131u8, 96u8, 207u8, 217u8, 223u8, 54u8, 51u8, 156u8, 8u8, 238u8, 134u8, - 57u8, 42u8, 110u8, 180u8, 107u8, 30u8, 109u8, 162u8, 110u8, 178u8, - 127u8, 151u8, 163u8, 89u8, 127u8, 181u8, 213u8, 74u8, 129u8, 207u8, - 15u8, - ], - ) - } - #[doc = " Reverse lookup from `username` to the `AccountId` that has registered it. The value should"] - #[doc = " be a key in the `IdentityOf` map, but it may not if the user has cleared their identity."] - #[doc = ""] - #[doc = " Multiple usernames may map to the same `AccountId`, but `IdentityOf` will only map to one"] - #[doc = " primary username."] - pub fn account_of_username( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "AccountOfUsername", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 131u8, 96u8, 207u8, 217u8, 223u8, 54u8, 51u8, 156u8, 8u8, 238u8, 134u8, - 57u8, 42u8, 110u8, 180u8, 107u8, 30u8, 109u8, 162u8, 110u8, 178u8, - 127u8, 151u8, 163u8, 89u8, 127u8, 181u8, 213u8, 74u8, 129u8, 207u8, - 15u8, - ], - ) - } - #[doc = " Usernames that an authority has granted, but that the account controller has not confirmed"] - #[doc = " that they want it. Used primarily in cases where the `AccountId` cannot provide a signature"] - #[doc = " because they are a pure proxy, multisig, etc. In order to confirm it, they should call"] - #[doc = " [`Call::accept_username`]."] - #[doc = ""] - #[doc = " First tuple item is the account and second is the acceptance deadline."] - pub fn pending_usernames_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::subxt::utils::AccountId32, ::core::primitive::u32), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "PendingUsernames", - vec![], - [ - 237u8, 213u8, 92u8, 249u8, 11u8, 169u8, 104u8, 7u8, 201u8, 133u8, - 164u8, 64u8, 191u8, 172u8, 169u8, 229u8, 206u8, 105u8, 190u8, 113u8, - 21u8, 13u8, 70u8, 74u8, 140u8, 125u8, 123u8, 48u8, 183u8, 181u8, 170u8, - 147u8, - ], - ) - } - #[doc = " Usernames that an authority has granted, but that the account controller has not confirmed"] - #[doc = " that they want it. Used primarily in cases where the `AccountId` cannot provide a signature"] - #[doc = " because they are a pure proxy, multisig, etc. In order to confirm it, they should call"] - #[doc = " [`Call::accept_username`]."] - #[doc = ""] - #[doc = " First tuple item is the account and second is the acceptance deadline."] - pub fn pending_usernames( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::subxt::utils::AccountId32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Identity", - "PendingUsernames", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 237u8, 213u8, 92u8, 249u8, 11u8, 169u8, 104u8, 7u8, 201u8, 133u8, - 164u8, 64u8, 191u8, 172u8, 169u8, 229u8, 206u8, 105u8, 190u8, 113u8, - 21u8, 13u8, 70u8, 74u8, 140u8, 125u8, 123u8, 48u8, 183u8, 181u8, 170u8, - 147u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The amount held on deposit for a registered identity."] - pub fn basic_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Identity", - "BasicDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount held on deposit per encoded byte for a registered identity."] - pub fn byte_deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Identity", - "ByteDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount held on deposit for a registered subaccount. This should account for the fact"] - #[doc = " that one storage item's value will increase by the size of an account ID, and there will"] - #[doc = " be another trie item whose value is the size of an account ID plus 32 bytes."] - pub fn sub_account_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Identity", - "SubAccountDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum number of sub-accounts allowed per identified account."] - pub fn max_sub_accounts( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Identity", - "MaxSubAccounts", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maxmimum number of registrars allowed in the system. Needed to bound the complexity"] - #[doc = " of, e.g., updating judgements."] - pub fn max_registrars( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Identity", - "MaxRegistrars", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of blocks within which a username grant must be accepted."] - pub fn pending_username_expiration( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Identity", - "PendingUsernameExpiration", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum length of a suffix."] - pub fn max_suffix_length( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Identity", - "MaxSuffixLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum length of a username, including its suffix and any system-added delimiters."] - pub fn max_username_length( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Identity", - "MaxUsernameLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod society { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_society::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_society::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bid { - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for Bid { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "bid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unbid; - impl ::subxt::blocks::StaticExtrinsic for Unbid { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "unbid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vouch { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub value: ::core::primitive::u128, - pub tip: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for Vouch { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "vouch"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Unvouch; - impl ::subxt::blocks::StaticExtrinsic for Unvouch { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "unvouch"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - pub candidate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub approve: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for Vote { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "vote"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DefenderVote { - pub approve: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for DefenderVote { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "defender_vote"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Payout; - impl ::subxt::blocks::StaticExtrinsic for Payout { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "payout"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WaiveRepay { - pub amount: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for WaiveRepay { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "waive_repay"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FoundSociety { - pub founder: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub max_members: ::core::primitive::u32, - pub max_intake: ::core::primitive::u32, - pub max_strikes: ::core::primitive::u32, - pub candidate_deposit: ::core::primitive::u128, - pub rules: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for FoundSociety { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "found_society"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Dissolve; - impl ::subxt::blocks::StaticExtrinsic for Dissolve { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "dissolve"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct JudgeSuspendedMember { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub forgive: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for JudgeSuspendedMember { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "judge_suspended_member"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetParameters { - pub max_members: ::core::primitive::u32, - pub max_intake: ::core::primitive::u32, - pub max_strikes: ::core::primitive::u32, - pub candidate_deposit: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for SetParameters { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "set_parameters"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PunishSkeptic; - impl ::subxt::blocks::StaticExtrinsic for PunishSkeptic { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "punish_skeptic"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimMembership; - impl ::subxt::blocks::StaticExtrinsic for ClaimMembership { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "claim_membership"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BestowMembership { - pub candidate: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for BestowMembership { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "bestow_membership"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KickCandidate { - pub candidate: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for KickCandidate { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "kick_candidate"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ResignCandidacy; - impl ::subxt::blocks::StaticExtrinsic for ResignCandidacy { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "resign_candidacy"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DropCandidate { - pub candidate: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for DropCandidate { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "drop_candidate"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CleanupCandidacy { - pub candidate: ::subxt::utils::AccountId32, - pub max: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for CleanupCandidacy { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "cleanup_candidacy"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CleanupChallenge { - pub challenge_round: ::core::primitive::u32, - pub max: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for CleanupChallenge { - const PALLET: &'static str = "Society"; - const CALL: &'static str = "cleanup_challenge"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::bid`]."] - pub fn bid( - &self, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "bid", - types::Bid { value }, - [ - 196u8, 8u8, 236u8, 188u8, 3u8, 185u8, 190u8, 227u8, 11u8, 146u8, 225u8, - 241u8, 196u8, 125u8, 128u8, 67u8, 244u8, 144u8, 10u8, 152u8, 161u8, - 60u8, 72u8, 33u8, 124u8, 137u8, 40u8, 200u8, 177u8, 21u8, 27u8, 45u8, - ], - ) - } - #[doc = "See [`Pallet::unbid`]."] - pub fn unbid(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "unbid", - types::Unbid {}, - [ - 188u8, 248u8, 46u8, 6u8, 82u8, 191u8, 129u8, 234u8, 187u8, 249u8, 69u8, - 242u8, 173u8, 185u8, 209u8, 51u8, 228u8, 80u8, 27u8, 111u8, 59u8, - 110u8, 180u8, 106u8, 205u8, 6u8, 121u8, 66u8, 232u8, 89u8, 166u8, - 154u8, - ], - ) - } - #[doc = "See [`Pallet::vouch`]."] - pub fn vouch( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - tip: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "vouch", - types::Vouch { who, value, tip }, - [ - 112u8, 149u8, 72u8, 181u8, 135u8, 149u8, 62u8, 134u8, 12u8, 214u8, 0u8, - 31u8, 142u8, 128u8, 27u8, 243u8, 210u8, 197u8, 72u8, 177u8, 164u8, - 112u8, 223u8, 28u8, 43u8, 149u8, 5u8, 249u8, 157u8, 150u8, 123u8, 58u8, - ], - ) - } - #[doc = "See [`Pallet::unvouch`]."] - pub fn unvouch(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "unvouch", - types::Unvouch {}, - [ - 205u8, 176u8, 119u8, 76u8, 199u8, 30u8, 22u8, 108u8, 111u8, 117u8, - 24u8, 9u8, 164u8, 14u8, 126u8, 124u8, 224u8, 50u8, 195u8, 136u8, 244u8, - 77u8, 238u8, 99u8, 97u8, 133u8, 151u8, 109u8, 245u8, 83u8, 159u8, - 136u8, - ], - ) - } - #[doc = "See [`Pallet::vote`]."] - pub fn vote( - &self, - candidate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - approve: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "vote", - types::Vote { candidate, approve }, - [ - 64u8, 168u8, 166u8, 195u8, 208u8, 246u8, 156u8, 39u8, 195u8, 28u8, - 153u8, 58u8, 52u8, 185u8, 166u8, 8u8, 108u8, 169u8, 44u8, 70u8, 244u8, - 244u8, 81u8, 27u8, 236u8, 79u8, 123u8, 176u8, 155u8, 40u8, 154u8, 70u8, - ], - ) - } - #[doc = "See [`Pallet::defender_vote`]."] - pub fn defender_vote( - &self, - approve: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "defender_vote", - types::DefenderVote { approve }, - [ - 38u8, 196u8, 123u8, 172u8, 243u8, 40u8, 208u8, 63u8, 231u8, 155u8, - 151u8, 181u8, 58u8, 122u8, 185u8, 86u8, 76u8, 124u8, 168u8, 225u8, - 37u8, 13u8, 127u8, 250u8, 122u8, 124u8, 140u8, 57u8, 242u8, 214u8, - 145u8, 119u8, - ], - ) - } - #[doc = "See [`Pallet::payout`]."] - pub fn payout(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "payout", - types::Payout {}, - [ - 214u8, 12u8, 233u8, 89u8, 186u8, 0u8, 61u8, 206u8, 251u8, 1u8, 55u8, - 0u8, 126u8, 105u8, 55u8, 109u8, 101u8, 104u8, 46u8, 98u8, 62u8, 228u8, - 64u8, 195u8, 61u8, 24u8, 48u8, 148u8, 146u8, 108u8, 67u8, 52u8, - ], - ) - } - #[doc = "See [`Pallet::waive_repay`]."] - pub fn waive_repay( - &self, - amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "waive_repay", - types::WaiveRepay { amount }, - [ - 83u8, 11u8, 65u8, 16u8, 92u8, 73u8, 39u8, 178u8, 16u8, 170u8, 41u8, - 70u8, 241u8, 255u8, 89u8, 121u8, 50u8, 140u8, 240u8, 31u8, 27u8, 51u8, - 51u8, 22u8, 241u8, 218u8, 127u8, 76u8, 52u8, 246u8, 214u8, 52u8, - ], - ) - } - #[doc = "See [`Pallet::found_society`]."] - pub fn found_society( - &self, - founder: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - max_members: ::core::primitive::u32, - max_intake: ::core::primitive::u32, - max_strikes: ::core::primitive::u32, - candidate_deposit: ::core::primitive::u128, - rules: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "found_society", - types::FoundSociety { - founder, - max_members, - max_intake, - max_strikes, - candidate_deposit, - rules, - }, - [ - 232u8, 23u8, 175u8, 166u8, 217u8, 99u8, 210u8, 160u8, 122u8, 68u8, - 169u8, 134u8, 248u8, 126u8, 186u8, 130u8, 97u8, 245u8, 69u8, 159u8, - 19u8, 52u8, 67u8, 144u8, 77u8, 154u8, 215u8, 67u8, 233u8, 96u8, 40u8, - 81u8, - ], - ) - } - #[doc = "See [`Pallet::dissolve`]."] - pub fn dissolve(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "dissolve", - types::Dissolve {}, - [ - 159u8, 138u8, 214u8, 34u8, 208u8, 201u8, 11u8, 33u8, 173u8, 66u8, - 243u8, 3u8, 226u8, 190u8, 199u8, 200u8, 215u8, 210u8, 226u8, 213u8, - 150u8, 217u8, 192u8, 88u8, 87u8, 202u8, 226u8, 105u8, 20u8, 201u8, - 50u8, 242u8, - ], - ) - } - #[doc = "See [`Pallet::judge_suspended_member`]."] - pub fn judge_suspended_member( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - forgive: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "judge_suspended_member", - types::JudgeSuspendedMember { who, forgive }, - [ - 219u8, 45u8, 90u8, 201u8, 128u8, 28u8, 215u8, 68u8, 125u8, 127u8, 57u8, - 207u8, 25u8, 110u8, 162u8, 30u8, 211u8, 208u8, 192u8, 182u8, 69u8, - 151u8, 233u8, 84u8, 81u8, 72u8, 74u8, 253u8, 106u8, 46u8, 157u8, 21u8, - ], - ) - } - #[doc = "See [`Pallet::set_parameters`]."] - pub fn set_parameters( - &self, - max_members: ::core::primitive::u32, - max_intake: ::core::primitive::u32, - max_strikes: ::core::primitive::u32, - candidate_deposit: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "set_parameters", - types::SetParameters { - max_members, - max_intake, - max_strikes, - candidate_deposit, - }, - [ - 141u8, 29u8, 233u8, 249u8, 125u8, 139u8, 186u8, 89u8, 112u8, 201u8, - 38u8, 108u8, 79u8, 204u8, 140u8, 185u8, 156u8, 202u8, 77u8, 178u8, - 205u8, 99u8, 36u8, 78u8, 68u8, 94u8, 160u8, 198u8, 176u8, 226u8, 35u8, - 229u8, - ], - ) - } - #[doc = "See [`Pallet::punish_skeptic`]."] - pub fn punish_skeptic(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "punish_skeptic", - types::PunishSkeptic {}, - [ - 69u8, 32u8, 105u8, 1u8, 25u8, 240u8, 148u8, 136u8, 141u8, 97u8, 247u8, - 14u8, 18u8, 169u8, 184u8, 247u8, 89u8, 145u8, 239u8, 51u8, 161u8, - 149u8, 37u8, 127u8, 160u8, 54u8, 144u8, 222u8, 54u8, 135u8, 184u8, - 244u8, - ], - ) - } - #[doc = "See [`Pallet::claim_membership`]."] - pub fn claim_membership(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "claim_membership", - types::ClaimMembership {}, - [ - 129u8, 50u8, 134u8, 231u8, 159u8, 194u8, 140u8, 16u8, 139u8, 189u8, - 131u8, 82u8, 150u8, 112u8, 138u8, 116u8, 3u8, 28u8, 183u8, 151u8, 19u8, - 122u8, 29u8, 152u8, 88u8, 123u8, 34u8, 84u8, 42u8, 12u8, 230u8, 220u8, - ], - ) - } - #[doc = "See [`Pallet::bestow_membership`]."] - pub fn bestow_membership( - &self, - candidate: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "bestow_membership", - types::BestowMembership { candidate }, - [ - 146u8, 123u8, 220u8, 105u8, 41u8, 24u8, 3u8, 83u8, 38u8, 64u8, 93u8, - 69u8, 149u8, 46u8, 177u8, 32u8, 197u8, 152u8, 186u8, 198u8, 39u8, 47u8, - 54u8, 174u8, 86u8, 41u8, 170u8, 74u8, 107u8, 141u8, 169u8, 222u8, - ], - ) - } - #[doc = "See [`Pallet::kick_candidate`]."] - pub fn kick_candidate( - &self, - candidate: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "kick_candidate", - types::KickCandidate { candidate }, - [ - 51u8, 17u8, 10u8, 153u8, 91u8, 22u8, 117u8, 204u8, 32u8, 141u8, 59u8, - 94u8, 240u8, 99u8, 247u8, 217u8, 233u8, 39u8, 132u8, 191u8, 225u8, - 74u8, 140u8, 182u8, 106u8, 74u8, 90u8, 129u8, 71u8, 240u8, 5u8, 70u8, - ], - ) - } - #[doc = "See [`Pallet::resign_candidacy`]."] - pub fn resign_candidacy(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "resign_candidacy", - types::ResignCandidacy {}, - [ - 40u8, 237u8, 128u8, 221u8, 162u8, 143u8, 104u8, 151u8, 11u8, 97u8, - 212u8, 53u8, 26u8, 145u8, 124u8, 196u8, 155u8, 118u8, 232u8, 251u8, - 42u8, 35u8, 11u8, 149u8, 78u8, 99u8, 6u8, 56u8, 23u8, 166u8, 167u8, - 116u8, - ], - ) - } - #[doc = "See [`Pallet::drop_candidate`]."] - pub fn drop_candidate( - &self, - candidate: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "drop_candidate", - types::DropCandidate { candidate }, - [ - 140u8, 7u8, 82u8, 134u8, 101u8, 180u8, 217u8, 22u8, 204u8, 194u8, - 125u8, 165u8, 69u8, 7u8, 193u8, 0u8, 33u8, 246u8, 43u8, 221u8, 110u8, - 105u8, 227u8, 61u8, 22u8, 110u8, 98u8, 141u8, 44u8, 212u8, 55u8, 157u8, - ], - ) - } - #[doc = "See [`Pallet::cleanup_candidacy`]."] - pub fn cleanup_candidacy( - &self, - candidate: ::subxt::utils::AccountId32, - max: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "cleanup_candidacy", - types::CleanupCandidacy { candidate, max }, - [ - 115u8, 111u8, 140u8, 201u8, 68u8, 53u8, 116u8, 204u8, 131u8, 66u8, - 13u8, 123u8, 157u8, 235u8, 252u8, 24u8, 126u8, 233u8, 80u8, 227u8, - 130u8, 231u8, 81u8, 23u8, 104u8, 39u8, 166u8, 3u8, 231u8, 137u8, 172u8, - 107u8, - ], - ) - } - #[doc = "See [`Pallet::cleanup_challenge`]."] - pub fn cleanup_challenge( - &self, - challenge_round: ::core::primitive::u32, - max: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Society", - "cleanup_challenge", - types::CleanupChallenge { challenge_round, max }, - [ - 255u8, 67u8, 39u8, 222u8, 23u8, 216u8, 63u8, 255u8, 82u8, 135u8, 30u8, - 135u8, 120u8, 255u8, 56u8, 223u8, 137u8, 72u8, 128u8, 165u8, 147u8, - 167u8, 93u8, 17u8, 118u8, 27u8, 32u8, 187u8, 220u8, 206u8, 123u8, - 242u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_society::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The society is founded by the given identity."] - pub struct Founded { - pub founder: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Founded { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Founded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A membership bid just happened. The given account is the candidate's ID and their offer"] - #[doc = "is the second."] - pub struct Bid { - pub candidate_id: ::subxt::utils::AccountId32, - pub offer: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Bid { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Bid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A membership bid just happened by vouching. The given account is the candidate's ID and"] - #[doc = "their offer is the second. The vouching party is the third."] - pub struct Vouch { - pub candidate_id: ::subxt::utils::AccountId32, - pub offer: ::core::primitive::u128, - pub vouching: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Vouch { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Vouch"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was dropped (due to an excess of bids in the system)."] - pub struct AutoUnbid { - pub candidate: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for AutoUnbid { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "AutoUnbid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was dropped (by their request)."] - pub struct Unbid { - pub candidate: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Unbid { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Unbid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was dropped (by request of who vouched for them)."] - pub struct Unvouch { - pub candidate: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Unvouch { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Unvouch"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A group of candidates have been inducted. The batch's primary is the first value, the"] - #[doc = "batch in full is the second."] - pub struct Inducted { - pub primary: ::subxt::utils::AccountId32, - pub candidates: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - impl ::subxt::events::StaticEvent for Inducted { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Inducted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A suspended member has been judged."] - pub struct SuspendedMemberJudgement { - pub who: ::subxt::utils::AccountId32, - pub judged: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for SuspendedMemberJudgement { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "SuspendedMemberJudgement"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate has been suspended"] - pub struct CandidateSuspended { - pub candidate: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for CandidateSuspended { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "CandidateSuspended"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has been suspended"] - pub struct MemberSuspended { - pub member: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for MemberSuspended { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "MemberSuspended"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A member has been challenged"] - pub struct Challenged { - pub member: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Challenged { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Challenged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A vote has been placed"] - pub struct Vote { - pub candidate: ::subxt::utils::AccountId32, - pub voter: ::subxt::utils::AccountId32, - pub vote: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for Vote { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Vote"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A vote has been placed for a defending member"] - pub struct DefenderVote { - pub voter: ::subxt::utils::AccountId32, - pub vote: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for DefenderVote { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "DefenderVote"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new set of \\[params\\] has been set for the group."] - pub struct NewParams { - pub params: runtime_types::pallet_society::GroupParams<::core::primitive::u128>, - } - impl ::subxt::events::StaticEvent for NewParams { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "NewParams"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Society is unfounded."] - pub struct Unfounded { - pub founder: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Unfounded { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Unfounded"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some funds were deposited into the society account."] - pub struct Deposit { - pub value: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Deposit { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Deposit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A \\[member\\] got elevated to \\[rank\\]."] - pub struct Elevated { - pub member: ::subxt::utils::AccountId32, - pub rank: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Elevated { - const PALLET: &'static str = "Society"; - const EVENT: &'static str = "Elevated"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The max number of members for the society at one time."] - pub fn parameters( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::GroupParams<::core::primitive::u128>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Parameters", - vec![], - [ - 69u8, 147u8, 95u8, 26u8, 245u8, 207u8, 83u8, 57u8, 229u8, 34u8, 205u8, - 202u8, 182u8, 180u8, 219u8, 86u8, 152u8, 140u8, 212u8, 145u8, 7u8, - 98u8, 185u8, 36u8, 60u8, 173u8, 120u8, 49u8, 164u8, 102u8, 133u8, - 248u8, - ], - ) - } - #[doc = " Amount of our account balance that is specifically for the next round's bid(s)."] - pub fn pot( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Pot", - vec![], - [ - 98u8, 77u8, 215u8, 220u8, 51u8, 87u8, 188u8, 65u8, 72u8, 231u8, 34u8, - 161u8, 61u8, 59u8, 66u8, 105u8, 128u8, 23u8, 249u8, 27u8, 10u8, 0u8, - 251u8, 16u8, 235u8, 163u8, 239u8, 74u8, 197u8, 226u8, 58u8, 215u8, - ], - ) - } - #[doc = " The first member."] - pub fn founder( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Founder", - vec![], - [ - 14u8, 6u8, 181u8, 186u8, 64u8, 213u8, 48u8, 110u8, 242u8, 50u8, 144u8, - 77u8, 38u8, 127u8, 161u8, 54u8, 204u8, 119u8, 1u8, 218u8, 12u8, 57u8, - 165u8, 32u8, 28u8, 34u8, 46u8, 12u8, 217u8, 65u8, 27u8, 1u8, - ], - ) - } - #[doc = " The most primary from the most recently approved rank 0 members in the society."] - pub fn head( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Head", - vec![], - [ - 95u8, 2u8, 23u8, 237u8, 130u8, 169u8, 84u8, 51u8, 1u8, 178u8, 234u8, - 194u8, 139u8, 35u8, 222u8, 150u8, 246u8, 176u8, 97u8, 103u8, 211u8, - 198u8, 165u8, 1u8, 224u8, 204u8, 10u8, 91u8, 6u8, 179u8, 189u8, 170u8, - ], - ) - } - #[doc = " A hash of the rules of this society concerning membership. Can only be set once and"] - #[doc = " only by the founder."] - pub fn rules( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Rules", - vec![], - [ - 119u8, 249u8, 119u8, 89u8, 243u8, 239u8, 149u8, 15u8, 238u8, 40u8, - 172u8, 198u8, 24u8, 107u8, 57u8, 39u8, 155u8, 36u8, 13u8, 72u8, 153u8, - 101u8, 39u8, 146u8, 38u8, 161u8, 195u8, 69u8, 79u8, 204u8, 172u8, - 207u8, - ], - ) - } - #[doc = " The current members and their rank. Doesn't include `SuspendedMembers`."] - pub fn members_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::MemberRecord, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Members", - vec![], - [ - 207u8, 227u8, 130u8, 247u8, 29u8, 198u8, 129u8, 83u8, 3u8, 6u8, 19u8, - 37u8, 163u8, 227u8, 0u8, 94u8, 8u8, 166u8, 111u8, 70u8, 101u8, 65u8, - 104u8, 8u8, 94u8, 84u8, 80u8, 158u8, 208u8, 152u8, 4u8, 33u8, - ], - ) - } - #[doc = " The current members and their rank. Doesn't include `SuspendedMembers`."] - pub fn members( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::MemberRecord, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Members", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 207u8, 227u8, 130u8, 247u8, 29u8, 198u8, 129u8, 83u8, 3u8, 6u8, 19u8, - 37u8, 163u8, 227u8, 0u8, 94u8, 8u8, 166u8, 111u8, 70u8, 101u8, 65u8, - 104u8, 8u8, 94u8, 84u8, 80u8, 158u8, 208u8, 152u8, 4u8, 33u8, - ], - ) - } - #[doc = " Information regarding rank-0 payouts, past and future."] - pub fn payouts_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::PayoutRecord< - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - ::core::primitive::u128, - )>, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Payouts", - vec![], - [ - 251u8, 249u8, 170u8, 219u8, 131u8, 113u8, 178u8, 165u8, 173u8, 36u8, - 175u8, 199u8, 57u8, 188u8, 59u8, 226u8, 4u8, 45u8, 36u8, 173u8, 113u8, - 50u8, 153u8, 205u8, 21u8, 132u8, 30u8, 111u8, 95u8, 51u8, 194u8, 126u8, - ], - ) - } - #[doc = " Information regarding rank-0 payouts, past and future."] - pub fn payouts( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::PayoutRecord< - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - ::core::primitive::u128, - )>, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Payouts", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 251u8, 249u8, 170u8, 219u8, 131u8, 113u8, 178u8, 165u8, 173u8, 36u8, - 175u8, 199u8, 57u8, 188u8, 59u8, 226u8, 4u8, 45u8, 36u8, 173u8, 113u8, - 50u8, 153u8, 205u8, 21u8, 132u8, 30u8, 111u8, 95u8, 51u8, 194u8, 126u8, - ], - ) - } - #[doc = " The number of items in `Members` currently. (Doesn't include `SuspendedMembers`.)"] - pub fn member_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "MemberCount", - vec![], - [ - 251u8, 200u8, 97u8, 38u8, 125u8, 162u8, 19u8, 100u8, 249u8, 254u8, - 42u8, 93u8, 64u8, 171u8, 2u8, 200u8, 129u8, 228u8, 211u8, 229u8, 152u8, - 170u8, 228u8, 158u8, 212u8, 94u8, 17u8, 226u8, 194u8, 87u8, 189u8, - 213u8, - ], - ) - } - #[doc = " The current items in `Members` keyed by their unique index. Keys are densely populated"] - #[doc = " `0..MemberCount` (does not include `MemberCount`)."] - pub fn member_by_index_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "MemberByIndex", - vec![], - [ - 13u8, 233u8, 212u8, 149u8, 220u8, 158u8, 17u8, 27u8, 201u8, 61u8, - 202u8, 248u8, 192u8, 37u8, 199u8, 73u8, 32u8, 140u8, 204u8, 206u8, - 239u8, 43u8, 241u8, 41u8, 9u8, 51u8, 125u8, 171u8, 47u8, 149u8, 63u8, - 159u8, - ], - ) - } - #[doc = " The current items in `Members` keyed by their unique index. Keys are densely populated"] - #[doc = " `0..MemberCount` (does not include `MemberCount`)."] - pub fn member_by_index( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "MemberByIndex", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 13u8, 233u8, 212u8, 149u8, 220u8, 158u8, 17u8, 27u8, 201u8, 61u8, - 202u8, 248u8, 192u8, 37u8, 199u8, 73u8, 32u8, 140u8, 204u8, 206u8, - 239u8, 43u8, 241u8, 41u8, 9u8, 51u8, 125u8, 171u8, 47u8, 149u8, 63u8, - 159u8, - ], - ) - } - #[doc = " The set of suspended members, with their old membership record."] - pub fn suspended_members_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::MemberRecord, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "SuspendedMembers", - vec![], - [ - 156u8, 11u8, 75u8, 79u8, 74u8, 79u8, 98u8, 89u8, 63u8, 83u8, 84u8, - 249u8, 177u8, 227u8, 113u8, 21u8, 26u8, 165u8, 129u8, 5u8, 129u8, - 152u8, 241u8, 85u8, 231u8, 139u8, 54u8, 102u8, 230u8, 203u8, 26u8, - 94u8, - ], - ) - } - #[doc = " The set of suspended members, with their old membership record."] - pub fn suspended_members( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::MemberRecord, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "SuspendedMembers", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 156u8, 11u8, 75u8, 79u8, 74u8, 79u8, 98u8, 89u8, 63u8, 83u8, 84u8, - 249u8, 177u8, 227u8, 113u8, 21u8, 26u8, 165u8, 129u8, 5u8, 129u8, - 152u8, 241u8, 85u8, 231u8, 139u8, 54u8, 102u8, 230u8, 203u8, 26u8, - 94u8, - ], - ) - } - #[doc = " The number of rounds which have passed."] - pub fn round_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "RoundCount", - vec![], - [ - 61u8, 189u8, 115u8, 157u8, 36u8, 97u8, 192u8, 96u8, 138u8, 168u8, - 222u8, 58u8, 117u8, 199u8, 176u8, 146u8, 232u8, 167u8, 52u8, 190u8, - 41u8, 11u8, 181u8, 214u8, 79u8, 183u8, 134u8, 86u8, 164u8, 47u8, 178u8, - 192u8, - ], - ) - } - #[doc = " The current bids, stored ordered by the value of the bid."] - pub fn bids( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_society::Bid< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Bids", - vec![], - [ - 220u8, 159u8, 208u8, 176u8, 118u8, 11u8, 21u8, 34u8, 3u8, 101u8, 233u8, - 212u8, 149u8, 156u8, 235u8, 135u8, 142u8, 220u8, 76u8, 99u8, 60u8, - 29u8, 204u8, 134u8, 53u8, 82u8, 80u8, 129u8, 208u8, 149u8, 96u8, 231u8, - ], - ) - } - pub fn candidates_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::Candidacy< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Candidates", - vec![], - [ - 52u8, 250u8, 201u8, 163u8, 0u8, 5u8, 156u8, 84u8, 96u8, 130u8, 228u8, - 205u8, 34u8, 75u8, 121u8, 209u8, 82u8, 15u8, 247u8, 21u8, 54u8, 177u8, - 138u8, 183u8, 64u8, 191u8, 209u8, 19u8, 38u8, 235u8, 129u8, 136u8, - ], - ) - } - pub fn candidates( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::Candidacy< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Candidates", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 52u8, 250u8, 201u8, 163u8, 0u8, 5u8, 156u8, 84u8, 96u8, 130u8, 228u8, - 205u8, 34u8, 75u8, 121u8, 209u8, 82u8, 15u8, 247u8, 21u8, 54u8, 177u8, - 138u8, 183u8, 64u8, 191u8, 209u8, 19u8, 38u8, 235u8, 129u8, 136u8, - ], - ) - } - #[doc = " The current skeptic."] - pub fn skeptic( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Skeptic", - vec![], - [ - 121u8, 103u8, 195u8, 11u8, 87u8, 129u8, 61u8, 69u8, 218u8, 17u8, 101u8, - 207u8, 249u8, 207u8, 18u8, 103u8, 253u8, 240u8, 132u8, 46u8, 47u8, - 27u8, 85u8, 194u8, 34u8, 145u8, 16u8, 208u8, 245u8, 192u8, 191u8, - 118u8, - ], - ) - } - #[doc = " Double map from Candidate -> Voter -> (Maybe) Vote."] - pub fn votes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::Vote, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Votes", - vec![], - [ - 34u8, 201u8, 151u8, 130u8, 149u8, 159u8, 32u8, 201u8, 127u8, 178u8, - 77u8, 214u8, 73u8, 158u8, 11u8, 247u8, 188u8, 156u8, 146u8, 59u8, - 160u8, 7u8, 109u8, 7u8, 131u8, 212u8, 185u8, 92u8, 172u8, 219u8, 140u8, - 238u8, - ], - ) - } - #[doc = " Double map from Candidate -> Voter -> (Maybe) Vote."] - pub fn votes_iter1( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::Vote, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Votes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 34u8, 201u8, 151u8, 130u8, 149u8, 159u8, 32u8, 201u8, 127u8, 178u8, - 77u8, 214u8, 73u8, 158u8, 11u8, 247u8, 188u8, 156u8, 146u8, 59u8, - 160u8, 7u8, 109u8, 7u8, 131u8, 212u8, 185u8, 92u8, 172u8, 219u8, 140u8, - 238u8, - ], - ) - } - #[doc = " Double map from Candidate -> Voter -> (Maybe) Vote."] - pub fn votes( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::Vote, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Votes", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 34u8, 201u8, 151u8, 130u8, 149u8, 159u8, 32u8, 201u8, 127u8, 178u8, - 77u8, 214u8, 73u8, 158u8, 11u8, 247u8, 188u8, 156u8, 146u8, 59u8, - 160u8, 7u8, 109u8, 7u8, 131u8, 212u8, 185u8, 92u8, 172u8, 219u8, 140u8, - 238u8, - ], - ) - } - #[doc = " Clear-cursor for Vote, map from Candidate -> (Maybe) Cursor."] - pub fn vote_clear_cursor_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "VoteClearCursor", - vec![], - [ - 157u8, 200u8, 216u8, 228u8, 235u8, 144u8, 13u8, 111u8, 252u8, 213u8, - 209u8, 114u8, 157u8, 159u8, 47u8, 125u8, 45u8, 152u8, 27u8, 145u8, - 55u8, 108u8, 217u8, 16u8, 251u8, 98u8, 172u8, 108u8, 23u8, 136u8, 93u8, - 250u8, - ], - ) - } - #[doc = " Clear-cursor for Vote, map from Candidate -> (Maybe) Cursor."] - pub fn vote_clear_cursor( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "VoteClearCursor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 157u8, 200u8, 216u8, 228u8, 235u8, 144u8, 13u8, 111u8, 252u8, 213u8, - 209u8, 114u8, 157u8, 159u8, 47u8, 125u8, 45u8, 152u8, 27u8, 145u8, - 55u8, 108u8, 217u8, 16u8, 251u8, 98u8, 172u8, 108u8, 23u8, 136u8, 93u8, - 250u8, - ], - ) - } - #[doc = " At the end of the claim period, this contains the most recently approved members (along with"] - #[doc = " their bid and round ID) who is from the most recent round with the lowest bid. They will"] - #[doc = " become the new `Head`."] - pub fn next_head( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::IntakeRecord< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "NextHead", - vec![], - [ - 64u8, 118u8, 253u8, 247u8, 56u8, 39u8, 156u8, 38u8, 150u8, 234u8, - 190u8, 11u8, 45u8, 236u8, 15u8, 181u8, 6u8, 165u8, 226u8, 99u8, 46u8, - 55u8, 254u8, 40u8, 2u8, 233u8, 22u8, 211u8, 133u8, 36u8, 177u8, 46u8, - ], - ) - } - #[doc = " The number of challenge rounds there have been. Used to identify stale DefenderVotes."] - pub fn challenge_round_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "ChallengeRoundCount", - vec![], - [ - 111u8, 74u8, 218u8, 126u8, 43u8, 20u8, 75u8, 119u8, 166u8, 4u8, 56u8, - 24u8, 206u8, 10u8, 236u8, 17u8, 62u8, 124u8, 129u8, 39u8, 197u8, 157u8, - 153u8, 147u8, 68u8, 167u8, 220u8, 125u8, 44u8, 95u8, 82u8, 64u8, - ], - ) - } - #[doc = " The defending member currently being challenged, along with a running tally of votes."] - pub fn defending( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::subxt::utils::AccountId32, - ::subxt::utils::AccountId32, - runtime_types::pallet_society::Tally, - ), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "Defending", - vec![], - [ - 22u8, 165u8, 42u8, 82u8, 129u8, 214u8, 77u8, 50u8, 110u8, 35u8, 16u8, - 44u8, 222u8, 47u8, 238u8, 209u8, 171u8, 254u8, 208u8, 3u8, 2u8, 87u8, - 48u8, 20u8, 227u8, 127u8, 188u8, 84u8, 118u8, 207u8, 68u8, 247u8, - ], - ) - } - #[doc = " Votes for the defender, keyed by challenge round."] - pub fn defender_votes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::Vote, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "DefenderVotes", - vec![], - [ - 208u8, 137u8, 138u8, 215u8, 215u8, 207u8, 236u8, 140u8, 175u8, 50u8, - 110u8, 228u8, 48u8, 174u8, 16u8, 59u8, 72u8, 108u8, 7u8, 183u8, 119u8, - 171u8, 125u8, 159u8, 93u8, 129u8, 186u8, 115u8, 208u8, 5u8, 194u8, - 199u8, - ], - ) - } - #[doc = " Votes for the defender, keyed by challenge round."] - pub fn defender_votes_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::Vote, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Society", - "DefenderVotes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 208u8, 137u8, 138u8, 215u8, 215u8, 207u8, 236u8, 140u8, 175u8, 50u8, - 110u8, 228u8, 48u8, 174u8, 16u8, 59u8, 72u8, 108u8, 7u8, 183u8, 119u8, - 171u8, 125u8, 159u8, 93u8, 129u8, 186u8, 115u8, 208u8, 5u8, 194u8, - 199u8, - ], - ) - } - #[doc = " Votes for the defender, keyed by challenge round."] - pub fn defender_votes( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_society::Vote, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Society", - "DefenderVotes", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 208u8, 137u8, 138u8, 215u8, 215u8, 207u8, 236u8, 140u8, 175u8, 50u8, - 110u8, 228u8, 48u8, 174u8, 16u8, 59u8, 72u8, 108u8, 7u8, 183u8, 119u8, - 171u8, 125u8, 159u8, 93u8, 129u8, 186u8, 115u8, 208u8, 5u8, 194u8, - 199u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The societies's pallet id"] - pub fn pallet_id( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "Society", - "PalletId", - [ - 56u8, 243u8, 53u8, 83u8, 154u8, 179u8, 170u8, 80u8, 133u8, 173u8, 61u8, - 161u8, 47u8, 225u8, 146u8, 21u8, 50u8, 229u8, 248u8, 27u8, 104u8, 58u8, - 129u8, 197u8, 102u8, 160u8, 168u8, 205u8, 154u8, 42u8, 217u8, 53u8, - ], - ) - } - #[doc = " The maximum number of strikes before a member gets funds slashed."] - pub fn grace_strikes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Society", - "GraceStrikes", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The amount of incentive paid within each period. Doesn't include VoterTip."] - pub fn period_spend(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Society", - "PeriodSpend", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The number of blocks on which new candidates should be voted on. Together with"] - #[doc = " `ClaimPeriod`, this sums to the number of blocks between candidate intake periods."] - pub fn voting_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Society", - "VotingPeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of blocks on which new candidates can claim their membership and be the"] - #[doc = " named head."] - pub fn claim_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Society", - "ClaimPeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum duration of the payout lock."] - pub fn max_lock_duration( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Society", - "MaxLockDuration", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of blocks between membership challenges."] - pub fn challenge_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Society", - "ChallengePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of payouts a member may have waiting unclaimed."] - pub fn max_payouts(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Society", - "MaxPayouts", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of bids at once."] - pub fn max_bids(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Society", - "MaxBids", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod recovery { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_recovery::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_recovery::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsRecovered { - pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for AsRecovered { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "as_recovered"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetRecovered { - pub lost: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for SetRecovered { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "set_recovered"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreateRecovery { - pub friends: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub threshold: ::core::primitive::u16, - pub delay_period: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for CreateRecovery { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "create_recovery"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InitiateRecovery { - pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for InitiateRecovery { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "initiate_recovery"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VouchRecovery { - pub lost: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for VouchRecovery { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "vouch_recovery"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimRecovery { - pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for ClaimRecovery { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "claim_recovery"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseRecovery { - pub rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for CloseRecovery { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "close_recovery"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveRecovery; - impl ::subxt::blocks::StaticExtrinsic for RemoveRecovery { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "remove_recovery"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelRecovered { - pub account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for CancelRecovered { - const PALLET: &'static str = "Recovery"; - const CALL: &'static str = "cancel_recovered"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::as_recovered`]."] - pub fn as_recovered( - &self, - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "as_recovered", - types::AsRecovered { account, call: ::std::boxed::Box::new(call) }, - [ - 20u8, 54u8, 178u8, 169u8, 196u8, 193u8, 82u8, 179u8, 72u8, 107u8, 67u8, - 43u8, 207u8, 31u8, 5u8, 111u8, 59u8, 115u8, 159u8, 219u8, 202u8, 149u8, - 118u8, 37u8, 248u8, 41u8, 94u8, 82u8, 231u8, 99u8, 163u8, 9u8, - ], - ) - } - #[doc = "See [`Pallet::set_recovered`]."] - pub fn set_recovered( - &self, - lost: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "set_recovered", - types::SetRecovered { lost, rescuer }, - [ - 194u8, 147u8, 14u8, 197u8, 132u8, 185u8, 122u8, 81u8, 61u8, 14u8, 10u8, - 177u8, 74u8, 184u8, 150u8, 217u8, 246u8, 149u8, 26u8, 165u8, 196u8, - 83u8, 230u8, 195u8, 213u8, 40u8, 51u8, 180u8, 23u8, 90u8, 3u8, 14u8, - ], - ) - } - #[doc = "See [`Pallet::create_recovery`]."] - pub fn create_recovery( - &self, - friends: ::std::vec::Vec<::subxt::utils::AccountId32>, - threshold: ::core::primitive::u16, - delay_period: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "create_recovery", - types::CreateRecovery { friends, threshold, delay_period }, - [ - 36u8, 175u8, 11u8, 85u8, 95u8, 170u8, 58u8, 193u8, 102u8, 18u8, 117u8, - 27u8, 199u8, 214u8, 70u8, 47u8, 129u8, 130u8, 109u8, 242u8, 240u8, - 255u8, 120u8, 176u8, 40u8, 243u8, 175u8, 71u8, 3u8, 91u8, 186u8, 220u8, - ], - ) - } - #[doc = "See [`Pallet::initiate_recovery`]."] - pub fn initiate_recovery( - &self, - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "initiate_recovery", - types::InitiateRecovery { account }, - [ - 60u8, 243u8, 229u8, 176u8, 221u8, 52u8, 44u8, 224u8, 233u8, 14u8, 89u8, - 100u8, 174u8, 74u8, 38u8, 32u8, 97u8, 48u8, 53u8, 74u8, 30u8, 242u8, - 19u8, 114u8, 145u8, 74u8, 69u8, 125u8, 227u8, 214u8, 144u8, 58u8, - ], - ) - } - #[doc = "See [`Pallet::vouch_recovery`]."] - pub fn vouch_recovery( - &self, - lost: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "vouch_recovery", - types::VouchRecovery { lost, rescuer }, - [ - 97u8, 190u8, 60u8, 15u8, 191u8, 117u8, 1u8, 217u8, 62u8, 40u8, 210u8, - 1u8, 237u8, 111u8, 48u8, 196u8, 180u8, 154u8, 198u8, 12u8, 108u8, 42u8, - 6u8, 234u8, 2u8, 113u8, 163u8, 111u8, 80u8, 146u8, 6u8, 73u8, - ], - ) - } - #[doc = "See [`Pallet::claim_recovery`]."] - pub fn claim_recovery( - &self, - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "claim_recovery", - types::ClaimRecovery { account }, - [ - 41u8, 47u8, 162u8, 88u8, 13u8, 166u8, 130u8, 146u8, 218u8, 162u8, - 166u8, 33u8, 89u8, 129u8, 177u8, 178u8, 68u8, 128u8, 161u8, 229u8, - 207u8, 3u8, 57u8, 35u8, 211u8, 208u8, 74u8, 155u8, 183u8, 173u8, 74u8, - 56u8, - ], - ) - } - #[doc = "See [`Pallet::close_recovery`]."] - pub fn close_recovery( - &self, - rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "close_recovery", - types::CloseRecovery { rescuer }, - [ - 161u8, 178u8, 117u8, 209u8, 119u8, 164u8, 135u8, 41u8, 25u8, 108u8, - 194u8, 175u8, 221u8, 65u8, 184u8, 137u8, 171u8, 97u8, 204u8, 61u8, - 159u8, 39u8, 192u8, 53u8, 246u8, 69u8, 113u8, 16u8, 170u8, 232u8, - 163u8, 10u8, - ], - ) - } - #[doc = "See [`Pallet::remove_recovery`]."] - pub fn remove_recovery(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "remove_recovery", - types::RemoveRecovery {}, - [ - 11u8, 38u8, 133u8, 172u8, 212u8, 252u8, 57u8, 216u8, 42u8, 202u8, - 206u8, 91u8, 115u8, 91u8, 242u8, 123u8, 95u8, 196u8, 172u8, 243u8, - 164u8, 1u8, 69u8, 180u8, 40u8, 68u8, 208u8, 221u8, 161u8, 250u8, 8u8, - 72u8, - ], - ) - } - #[doc = "See [`Pallet::cancel_recovered`]."] - pub fn cancel_recovered( - &self, - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Recovery", - "cancel_recovered", - types::CancelRecovered { account }, - [ - 100u8, 222u8, 80u8, 226u8, 187u8, 188u8, 111u8, 58u8, 190u8, 5u8, - 178u8, 144u8, 37u8, 98u8, 71u8, 145u8, 28u8, 248u8, 222u8, 188u8, 53u8, - 21u8, 127u8, 176u8, 249u8, 166u8, 250u8, 59u8, 170u8, 33u8, 251u8, - 239u8, - ], - ) - } - } - } - #[doc = "Events type."] - pub type Event = runtime_types::pallet_recovery::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A recovery process has been set up for an account."] - pub struct RecoveryCreated { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for RecoveryCreated { - const PALLET: &'static str = "Recovery"; - const EVENT: &'static str = "RecoveryCreated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A recovery process has been initiated for lost account by rescuer account."] - pub struct RecoveryInitiated { - pub lost_account: ::subxt::utils::AccountId32, - pub rescuer_account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for RecoveryInitiated { - const PALLET: &'static str = "Recovery"; - const EVENT: &'static str = "RecoveryInitiated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A recovery process for lost account by rescuer account has been vouched for by sender."] - pub struct RecoveryVouched { - pub lost_account: ::subxt::utils::AccountId32, - pub rescuer_account: ::subxt::utils::AccountId32, - pub sender: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for RecoveryVouched { - const PALLET: &'static str = "Recovery"; - const EVENT: &'static str = "RecoveryVouched"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A recovery process for lost account by rescuer account has been closed."] - pub struct RecoveryClosed { - pub lost_account: ::subxt::utils::AccountId32, - pub rescuer_account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for RecoveryClosed { - const PALLET: &'static str = "Recovery"; - const EVENT: &'static str = "RecoveryClosed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Lost account has been successfully recovered by rescuer account."] - pub struct AccountRecovered { - pub lost_account: ::subxt::utils::AccountId32, - pub rescuer_account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for AccountRecovered { - const PALLET: &'static str = "Recovery"; - const EVENT: &'static str = "AccountRecovered"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A recovery process has been removed for an account."] - pub struct RecoveryRemoved { - pub lost_account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for RecoveryRemoved { - const PALLET: &'static str = "Recovery"; - const EVENT: &'static str = "RecoveryRemoved"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The set of recoverable accounts and their recovery configuration."] - pub fn recoverable_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_recovery::RecoveryConfig< - ::core::primitive::u32, - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Recovery", - "Recoverable", - vec![], - [ - 112u8, 7u8, 56u8, 46u8, 138u8, 197u8, 63u8, 234u8, 140u8, 123u8, 145u8, - 106u8, 189u8, 190u8, 247u8, 61u8, 250u8, 67u8, 107u8, 42u8, 170u8, - 79u8, 54u8, 168u8, 33u8, 214u8, 91u8, 227u8, 5u8, 107u8, 38u8, 26u8, - ], - ) - } - #[doc = " The set of recoverable accounts and their recovery configuration."] - pub fn recoverable( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_recovery::RecoveryConfig< - ::core::primitive::u32, - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Recovery", - "Recoverable", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 112u8, 7u8, 56u8, 46u8, 138u8, 197u8, 63u8, 234u8, 140u8, 123u8, 145u8, - 106u8, 189u8, 190u8, 247u8, 61u8, 250u8, 67u8, 107u8, 42u8, 170u8, - 79u8, 54u8, 168u8, 33u8, 214u8, 91u8, 227u8, 5u8, 107u8, 38u8, 26u8, - ], - ) - } - #[doc = " Active recovery attempts."] - #[doc = ""] - #[doc = " First account is the account to be recovered, and the second account"] - #[doc = " is the user trying to recover the account."] - pub fn active_recoveries_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_recovery::ActiveRecovery< - ::core::primitive::u32, - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Recovery", - "ActiveRecoveries", - vec![], - [ - 104u8, 252u8, 28u8, 142u8, 48u8, 26u8, 91u8, 201u8, 184u8, 163u8, - 180u8, 197u8, 189u8, 71u8, 144u8, 88u8, 225u8, 13u8, 183u8, 84u8, - 244u8, 41u8, 164u8, 212u8, 153u8, 247u8, 191u8, 25u8, 162u8, 25u8, - 91u8, 123u8, - ], - ) - } - #[doc = " Active recovery attempts."] - #[doc = ""] - #[doc = " First account is the account to be recovered, and the second account"] - #[doc = " is the user trying to recover the account."] - pub fn active_recoveries_iter1( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_recovery::ActiveRecovery< - ::core::primitive::u32, - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Recovery", - "ActiveRecoveries", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 104u8, 252u8, 28u8, 142u8, 48u8, 26u8, 91u8, 201u8, 184u8, 163u8, - 180u8, 197u8, 189u8, 71u8, 144u8, 88u8, 225u8, 13u8, 183u8, 84u8, - 244u8, 41u8, 164u8, 212u8, 153u8, 247u8, 191u8, 25u8, 162u8, 25u8, - 91u8, 123u8, - ], - ) - } - #[doc = " Active recovery attempts."] - #[doc = ""] - #[doc = " First account is the account to be recovered, and the second account"] - #[doc = " is the user trying to recover the account."] - pub fn active_recoveries( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_recovery::ActiveRecovery< - ::core::primitive::u32, - ::core::primitive::u128, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::subxt::utils::AccountId32, - >, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Recovery", - "ActiveRecoveries", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 104u8, 252u8, 28u8, 142u8, 48u8, 26u8, 91u8, 201u8, 184u8, 163u8, - 180u8, 197u8, 189u8, 71u8, 144u8, 88u8, 225u8, 13u8, 183u8, 84u8, - 244u8, 41u8, 164u8, 212u8, 153u8, 247u8, 191u8, 25u8, 162u8, 25u8, - 91u8, 123u8, - ], - ) - } - #[doc = " The list of allowed proxy accounts."] - #[doc = ""] - #[doc = " Map from the user who can access it to the recovered account."] - pub fn proxy_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Recovery", - "Proxy", - vec![], - [ - 161u8, 242u8, 17u8, 183u8, 161u8, 47u8, 87u8, 110u8, 201u8, 177u8, - 199u8, 157u8, 30u8, 131u8, 49u8, 89u8, 182u8, 86u8, 152u8, 19u8, 199u8, - 33u8, 12u8, 138u8, 51u8, 215u8, 130u8, 5u8, 251u8, 115u8, 69u8, 159u8, - ], - ) - } - #[doc = " The list of allowed proxy accounts."] - #[doc = ""] - #[doc = " Map from the user who can access it to the recovered account."] - pub fn proxy( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Recovery", - "Proxy", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 161u8, 242u8, 17u8, 183u8, 161u8, 47u8, 87u8, 110u8, 201u8, 177u8, - 199u8, 157u8, 30u8, 131u8, 49u8, 89u8, 182u8, 86u8, 152u8, 19u8, 199u8, - 33u8, 12u8, 138u8, 51u8, 215u8, 130u8, 5u8, 251u8, 115u8, 69u8, 159u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The base amount of currency needed to reserve for creating a recovery configuration."] - #[doc = ""] - #[doc = " This is held for an additional storage item whose value size is"] - #[doc = " `2 + sizeof(BlockNumber, Balance)` bytes."] - pub fn config_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Recovery", - "ConfigDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per additional user when creating a recovery"] - #[doc = " configuration."] - #[doc = ""] - #[doc = " This is held for adding `sizeof(AccountId)` bytes more into a pre-existing storage"] - #[doc = " value."] - pub fn friend_deposit_factor( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Recovery", - "FriendDepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum amount of friends allowed in a recovery configuration."] - #[doc = ""] - #[doc = " NOTE: The threshold programmed in this Pallet uses u16, so it does"] - #[doc = " not really make sense to have a limit here greater than u16::MAX."] - #[doc = " But also, that is a lot more than you should probably set this value"] - #[doc = " to anyway..."] - pub fn max_friends(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Recovery", - "MaxFriends", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The base amount of currency needed to reserve for starting a recovery."] - #[doc = ""] - #[doc = " This is primarily held for deterring malicious recovery attempts, and should"] - #[doc = " have a value large enough that a bad actor would choose not to place this"] - #[doc = " deposit. It also acts to fund additional storage item whose value size is"] - #[doc = " `sizeof(BlockNumber, Balance + T * AccountId)` bytes. Where T is a configurable"] - #[doc = " threshold."] - pub fn recovery_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Recovery", - "RecoveryDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - } - } - } - pub mod vesting { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the vesting pallet."] - pub type Error = runtime_types::pallet_vesting::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_vesting::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vest; - impl ::subxt::blocks::StaticExtrinsic for Vest { - const PALLET: &'static str = "Vesting"; - const CALL: &'static str = "vest"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestOther { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for VestOther { - const PALLET: &'static str = "Vesting"; - const CALL: &'static str = "vest_other"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestedTransfer { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - } - impl ::subxt::blocks::StaticExtrinsic for VestedTransfer { - const PALLET: &'static str = "Vesting"; - const CALL: &'static str = "vested_transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceVestedTransfer { - pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - } - impl ::subxt::blocks::StaticExtrinsic for ForceVestedTransfer { - const PALLET: &'static str = "Vesting"; - const CALL: &'static str = "force_vested_transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MergeSchedules { - pub schedule1_index: ::core::primitive::u32, - pub schedule2_index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for MergeSchedules { - const PALLET: &'static str = "Vesting"; - const CALL: &'static str = "merge_schedules"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceRemoveVestingSchedule { - pub target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub schedule_index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceRemoveVestingSchedule { - const PALLET: &'static str = "Vesting"; - const CALL: &'static str = "force_remove_vesting_schedule"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::vest`]."] - pub fn vest(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Vesting", - "vest", - types::Vest {}, - [ - 149u8, 89u8, 178u8, 148u8, 127u8, 127u8, 155u8, 60u8, 114u8, 126u8, - 204u8, 123u8, 166u8, 70u8, 104u8, 208u8, 186u8, 69u8, 139u8, 181u8, - 151u8, 154u8, 235u8, 161u8, 191u8, 35u8, 111u8, 60u8, 21u8, 165u8, - 44u8, 122u8, - ], - ) - } - #[doc = "See [`Pallet::vest_other`]."] - pub fn vest_other( - &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Vesting", - "vest_other", - types::VestOther { target }, - [ - 238u8, 92u8, 25u8, 149u8, 27u8, 211u8, 196u8, 31u8, 211u8, 28u8, 241u8, - 30u8, 128u8, 35u8, 0u8, 227u8, 202u8, 215u8, 186u8, 69u8, 216u8, 110u8, - 199u8, 120u8, 134u8, 141u8, 176u8, 224u8, 234u8, 42u8, 152u8, 128u8, - ], - ) - } - #[doc = "See [`Pallet::vested_transfer`]."] - pub fn vested_transfer( - &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Vesting", - "vested_transfer", - types::VestedTransfer { target, schedule }, - [ - 198u8, 133u8, 254u8, 5u8, 22u8, 170u8, 205u8, 79u8, 218u8, 30u8, 81u8, - 207u8, 227u8, 121u8, 132u8, 14u8, 217u8, 43u8, 66u8, 206u8, 15u8, 80u8, - 173u8, 208u8, 128u8, 72u8, 223u8, 175u8, 93u8, 69u8, 128u8, 88u8, - ], - ) - } - #[doc = "See [`Pallet::force_vested_transfer`]."] - pub fn force_vested_transfer( - &self, - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Vesting", - "force_vested_transfer", - types::ForceVestedTransfer { source, target, schedule }, - [ - 112u8, 17u8, 176u8, 133u8, 169u8, 192u8, 155u8, 217u8, 153u8, 36u8, - 230u8, 45u8, 9u8, 192u8, 2u8, 201u8, 165u8, 60u8, 206u8, 226u8, 95u8, - 86u8, 239u8, 196u8, 109u8, 62u8, 224u8, 237u8, 88u8, 74u8, 209u8, - 251u8, - ], - ) - } - #[doc = "See [`Pallet::merge_schedules`]."] - pub fn merge_schedules( - &self, - schedule1_index: ::core::primitive::u32, - schedule2_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Vesting", - "merge_schedules", - types::MergeSchedules { schedule1_index, schedule2_index }, - [ - 45u8, 24u8, 13u8, 108u8, 26u8, 99u8, 61u8, 117u8, 195u8, 218u8, 182u8, - 23u8, 188u8, 157u8, 181u8, 81u8, 38u8, 136u8, 31u8, 226u8, 8u8, 190u8, - 33u8, 81u8, 86u8, 185u8, 156u8, 77u8, 157u8, 197u8, 41u8, 58u8, - ], - ) - } - #[doc = "See [`Pallet::force_remove_vesting_schedule`]."] - pub fn force_remove_vesting_schedule( - &self, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Vesting", - "force_remove_vesting_schedule", - types::ForceRemoveVestingSchedule { target, schedule_index }, - [ - 211u8, 253u8, 60u8, 15u8, 20u8, 53u8, 23u8, 13u8, 45u8, 223u8, 136u8, - 183u8, 162u8, 143u8, 196u8, 188u8, 35u8, 64u8, 174u8, 16u8, 47u8, 13u8, - 147u8, 173u8, 120u8, 143u8, 75u8, 89u8, 128u8, 187u8, 9u8, 18u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_vesting::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The amount vested has been updated. This could indicate a change in funds available."] - #[doc = "The balance given is the amount which is left unvested (and thus locked)."] - pub struct VestingUpdated { - pub account: ::subxt::utils::AccountId32, - pub unvested: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for VestingUpdated { - const PALLET: &'static str = "Vesting"; - const EVENT: &'static str = "VestingUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An \\[account\\] has become fully vested."] - pub struct VestingCompleted { - pub account: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for VestingCompleted { - const PALLET: &'static str = "Vesting"; - const EVENT: &'static str = "VestingCompleted"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Information regarding the vesting of a given account."] - pub fn vesting_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Vesting", - "Vesting", - vec![], - [ - 95u8, 168u8, 217u8, 248u8, 149u8, 86u8, 195u8, 93u8, 73u8, 206u8, - 105u8, 165u8, 33u8, 173u8, 232u8, 81u8, 147u8, 254u8, 50u8, 228u8, - 156u8, 92u8, 242u8, 149u8, 42u8, 91u8, 58u8, 209u8, 142u8, 221u8, - 230u8, 112u8, - ], - ) - } - #[doc = " Information regarding the vesting of a given account."] - pub fn vesting( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Vesting", - "Vesting", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 95u8, 168u8, 217u8, 248u8, 149u8, 86u8, 195u8, 93u8, 73u8, 206u8, - 105u8, 165u8, 33u8, 173u8, 232u8, 81u8, 147u8, 254u8, 50u8, 228u8, - 156u8, 92u8, 242u8, 149u8, 42u8, 91u8, 58u8, 209u8, 142u8, 221u8, - 230u8, 112u8, - ], - ) - } - #[doc = " Storage version of the pallet."] - #[doc = ""] - #[doc = " New networks start with latest version, as determined by the genesis build."] - pub fn storage_version( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_vesting::Releases, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Vesting", - "StorageVersion", - vec![], - [ - 230u8, 137u8, 180u8, 133u8, 142u8, 124u8, 231u8, 234u8, 223u8, 10u8, - 154u8, 98u8, 158u8, 253u8, 228u8, 80u8, 5u8, 9u8, 91u8, 210u8, 252u8, - 9u8, 13u8, 195u8, 193u8, 164u8, 129u8, 113u8, 128u8, 218u8, 8u8, 40u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount transferred to call `vested_transfer`."] - pub fn min_vested_transfer( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Vesting", - "MinVestedTransfer", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - pub fn max_vesting_schedules( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Vesting", - "MaxVestingSchedules", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod scheduler { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_scheduler::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_scheduler::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Schedule { - pub when: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for Schedule { - const PALLET: &'static str = "Scheduler"; - const CALL: &'static str = "schedule"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Cancel { - pub when: ::core::primitive::u32, - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Cancel { - const PALLET: &'static str = "Scheduler"; - const CALL: &'static str = "cancel"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleNamed { - pub id: [::core::primitive::u8; 32usize], - pub when: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for ScheduleNamed { - const PALLET: &'static str = "Scheduler"; - const CALL: &'static str = "schedule_named"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelNamed { - pub id: [::core::primitive::u8; 32usize], - } - impl ::subxt::blocks::StaticExtrinsic for CancelNamed { - const PALLET: &'static str = "Scheduler"; - const CALL: &'static str = "cancel_named"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleAfter { - pub after: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for ScheduleAfter { - const PALLET: &'static str = "Scheduler"; - const CALL: &'static str = "schedule_after"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleNamedAfter { - pub id: [::core::primitive::u8; 32usize], - pub after: ::core::primitive::u32, - pub maybe_periodic: - ::core::option::Option<(::core::primitive::u32, ::core::primitive::u32)>, - pub priority: ::core::primitive::u8, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for ScheduleNamedAfter { - const PALLET: &'static str = "Scheduler"; - const CALL: &'static str = "schedule_named_after"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::schedule`]."] - pub fn schedule( - &self, - when: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "schedule", - types::Schedule { - when, - maybe_periodic, - priority, - call: ::std::boxed::Box::new(call), - }, - [ - 219u8, 254u8, 58u8, 130u8, 48u8, 252u8, 236u8, 189u8, 212u8, 123u8, - 55u8, 211u8, 79u8, 50u8, 196u8, 105u8, 28u8, 69u8, 161u8, 139u8, 181u8, - 227u8, 4u8, 55u8, 79u8, 29u8, 103u8, 98u8, 254u8, 8u8, 161u8, 244u8, - ], - ) - } - #[doc = "See [`Pallet::cancel`]."] - pub fn cancel( - &self, - when: ::core::primitive::u32, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "cancel", - types::Cancel { when, index }, - [ - 183u8, 204u8, 143u8, 86u8, 17u8, 130u8, 132u8, 91u8, 133u8, 168u8, - 103u8, 129u8, 114u8, 56u8, 123u8, 42u8, 123u8, 120u8, 221u8, 211u8, - 26u8, 85u8, 82u8, 246u8, 192u8, 39u8, 254u8, 45u8, 147u8, 56u8, 178u8, - 133u8, - ], - ) - } - #[doc = "See [`Pallet::schedule_named`]."] - pub fn schedule_named( - &self, - id: [::core::primitive::u8; 32usize], - when: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "schedule_named", - types::ScheduleNamed { - id, - when, - maybe_periodic, - priority, - call: ::std::boxed::Box::new(call), - }, - [ - 119u8, 128u8, 238u8, 104u8, 78u8, 44u8, 28u8, 204u8, 145u8, 124u8, - 135u8, 62u8, 62u8, 121u8, 205u8, 128u8, 108u8, 74u8, 208u8, 172u8, - 38u8, 146u8, 34u8, 112u8, 158u8, 29u8, 118u8, 82u8, 201u8, 206u8, 37u8, - 114u8, - ], - ) - } - #[doc = "See [`Pallet::cancel_named`]."] - pub fn cancel_named( - &self, - id: [::core::primitive::u8; 32usize], - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "cancel_named", - types::CancelNamed { id }, - [ - 205u8, 35u8, 28u8, 57u8, 224u8, 7u8, 49u8, 233u8, 236u8, 163u8, 93u8, - 236u8, 103u8, 69u8, 65u8, 51u8, 121u8, 84u8, 9u8, 196u8, 147u8, 122u8, - 227u8, 200u8, 181u8, 233u8, 62u8, 240u8, 174u8, 83u8, 129u8, 193u8, - ], - ) - } - #[doc = "See [`Pallet::schedule_after`]."] - pub fn schedule_after( - &self, - after: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "schedule_after", - types::ScheduleAfter { - after, - maybe_periodic, - priority, - call: ::std::boxed::Box::new(call), - }, - [ - 47u8, 49u8, 34u8, 5u8, 143u8, 114u8, 51u8, 154u8, 214u8, 136u8, 249u8, - 124u8, 230u8, 234u8, 94u8, 105u8, 216u8, 5u8, 201u8, 117u8, 119u8, - 85u8, 53u8, 171u8, 9u8, 77u8, 24u8, 245u8, 153u8, 155u8, 186u8, 42u8, - ], - ) - } - #[doc = "See [`Pallet::schedule_named_after`]."] - pub fn schedule_named_after( - &self, - id: [::core::primitive::u8; 32usize], - after: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Scheduler", - "schedule_named_after", - types::ScheduleNamedAfter { - id, - after, - maybe_periodic, - priority, - call: ::std::boxed::Box::new(call), - }, - [ - 198u8, 30u8, 187u8, 235u8, 208u8, 8u8, 240u8, 207u8, 103u8, 108u8, - 88u8, 200u8, 95u8, 162u8, 212u8, 215u8, 121u8, 79u8, 214u8, 1u8, 209u8, - 119u8, 16u8, 143u8, 217u8, 119u8, 48u8, 57u8, 209u8, 89u8, 205u8, 16u8, - ], - ) - } - } - } - #[doc = "Events type."] - pub type Event = runtime_types::pallet_scheduler::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Scheduled some task."] - pub struct Scheduled { - pub when: ::core::primitive::u32, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Scheduled { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "Scheduled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Canceled some task."] - pub struct Canceled { - pub when: ::core::primitive::u32, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Canceled { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "Canceled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Dispatched some task."] - pub struct Dispatched { - pub task: (::core::primitive::u32, ::core::primitive::u32), - pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for Dispatched { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "Dispatched"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The call for the provided hash was not found so the task has been aborted."] - pub struct CallUnavailable { - pub task: (::core::primitive::u32, ::core::primitive::u32), - pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - } - impl ::subxt::events::StaticEvent for CallUnavailable { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "CallUnavailable"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given task was unable to be renewed since the agenda is full at that block."] - pub struct PeriodicFailed { - pub task: (::core::primitive::u32, ::core::primitive::u32), - pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - } - impl ::subxt::events::StaticEvent for PeriodicFailed { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "PeriodicFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given task can never be executed since it is overweight."] - pub struct PermanentlyOverweight { - pub task: (::core::primitive::u32, ::core::primitive::u32), - pub id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - } - impl ::subxt::events::StaticEvent for PermanentlyOverweight { - const PALLET: &'static str = "Scheduler"; - const EVENT: &'static str = "PermanentlyOverweight"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - pub fn incomplete_since( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "IncompleteSince", - vec![], - [ - 250u8, 83u8, 64u8, 167u8, 205u8, 59u8, 225u8, 97u8, 205u8, 12u8, 76u8, - 130u8, 197u8, 4u8, 111u8, 208u8, 92u8, 217u8, 145u8, 119u8, 38u8, - 135u8, 1u8, 242u8, 228u8, 143u8, 56u8, 25u8, 115u8, 233u8, 227u8, 66u8, - ], - ) - } - #[doc = " Items to be executed, indexed by the block number that they should be executed on."] - pub fn agenda_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::option::Option< - runtime_types::pallet_scheduler::Scheduled< - [::core::primitive::u8; 32usize], - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - ::core::primitive::u32, - runtime_types::rococo_runtime::OriginCaller, - ::subxt::utils::AccountId32, - >, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "Agenda", - vec![], - [ - 10u8, 123u8, 252u8, 106u8, 154u8, 9u8, 245u8, 203u8, 188u8, 254u8, - 20u8, 41u8, 6u8, 226u8, 78u8, 188u8, 0u8, 173u8, 143u8, 44u8, 117u8, - 249u8, 180u8, 13u8, 236u8, 224u8, 170u8, 202u8, 24u8, 3u8, 163u8, 37u8, - ], - ) - } - #[doc = " Items to be executed, indexed by the block number that they should be executed on."] - pub fn agenda( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::option::Option< - runtime_types::pallet_scheduler::Scheduled< - [::core::primitive::u8; 32usize], - runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - ::core::primitive::u32, - runtime_types::rococo_runtime::OriginCaller, - ::subxt::utils::AccountId32, - >, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "Agenda", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 10u8, 123u8, 252u8, 106u8, 154u8, 9u8, 245u8, 203u8, 188u8, 254u8, - 20u8, 41u8, 6u8, 226u8, 78u8, 188u8, 0u8, 173u8, 143u8, 44u8, 117u8, - 249u8, 180u8, 13u8, 236u8, 224u8, 170u8, 202u8, 24u8, 3u8, 163u8, 37u8, - ], - ) - } - #[doc = " Lookup from a name to the block number and index of the task."] - #[doc = ""] - #[doc = " For v3 -> v4 the previously unbounded identities are Blake2-256 hashed to form the v4"] - #[doc = " identities."] - pub fn lookup_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "Lookup", - vec![], - [ - 24u8, 87u8, 96u8, 127u8, 136u8, 205u8, 238u8, 174u8, 71u8, 110u8, 65u8, - 98u8, 228u8, 167u8, 99u8, 71u8, 171u8, 186u8, 12u8, 218u8, 137u8, 70u8, - 70u8, 228u8, 153u8, 111u8, 165u8, 114u8, 229u8, 136u8, 118u8, 131u8, - ], - ) - } - #[doc = " Lookup from a name to the block number and index of the task."] - #[doc = ""] - #[doc = " For v3 -> v4 the previously unbounded identities are Blake2-256 hashed to form the v4"] - #[doc = " identities."] - pub fn lookup( - &self, - _0: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Scheduler", - "Lookup", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 24u8, 87u8, 96u8, 127u8, 136u8, 205u8, 238u8, 174u8, 71u8, 110u8, 65u8, - 98u8, 228u8, 167u8, 99u8, 71u8, 171u8, 186u8, 12u8, 218u8, 137u8, 70u8, - 70u8, 228u8, 153u8, 111u8, 165u8, 114u8, 229u8, 136u8, 118u8, 131u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The maximum weight that may be scheduled per block for any dispatchables."] - pub fn maximum_weight( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "Scheduler", - "MaximumWeight", - [ - 149u8, 252u8, 129u8, 80u8, 169u8, 36u8, 79u8, 127u8, 240u8, 156u8, - 56u8, 202u8, 219u8, 86u8, 5u8, 65u8, 245u8, 148u8, 138u8, 243u8, 210u8, - 128u8, 234u8, 216u8, 240u8, 219u8, 123u8, 235u8, 21u8, 158u8, 237u8, - 112u8, - ], - ) - } - #[doc = " The maximum number of scheduled calls in the queue for a single block."] - #[doc = ""] - #[doc = " NOTE:"] - #[doc = " + Dependent pallets' benchmarks might require a higher limit for the setting. Set a"] - #[doc = " higher limit under `runtime-benchmarks` feature."] - pub fn max_scheduled_per_block( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Scheduler", - "MaxScheduledPerBlock", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod proxy { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_proxy::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_proxy::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Proxy { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub force_proxy_type: - ::core::option::Option, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for Proxy { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "proxy"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddProxy { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::rococo_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for AddProxy { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "add_proxy"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveProxy { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::rococo_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveProxy { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "remove_proxy"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveProxies; - impl ::subxt::blocks::StaticExtrinsic for RemoveProxies { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "remove_proxies"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CreatePure { - pub proxy_type: runtime_types::rococo_runtime::ProxyType, - pub delay: ::core::primitive::u32, - pub index: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for CreatePure { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "create_pure"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KillPure { - pub spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub proxy_type: runtime_types::rococo_runtime::ProxyType, - pub index: ::core::primitive::u16, - #[codec(compact)] - pub height: ::core::primitive::u32, - #[codec(compact)] - pub ext_index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for KillPure { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "kill_pure"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Announce { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for Announce { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "announce"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveAnnouncement { - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveAnnouncement { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "remove_announcement"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RejectAnnouncement { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for RejectAnnouncement { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "reject_announcement"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProxyAnnounced { - pub delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub force_proxy_type: - ::core::option::Option, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for ProxyAnnounced { - const PALLET: &'static str = "Proxy"; - const CALL: &'static str = "proxy_announced"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::proxy`]."] - pub fn proxy( - &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - force_proxy_type: ::core::option::Option< - runtime_types::rococo_runtime::ProxyType, - >, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "proxy", - types::Proxy { real, force_proxy_type, call: ::std::boxed::Box::new(call) }, - [ - 74u8, 71u8, 215u8, 190u8, 137u8, 131u8, 175u8, 185u8, 203u8, 159u8, - 177u8, 18u8, 81u8, 53u8, 39u8, 5u8, 170u8, 254u8, 118u8, 117u8, 122u8, - 40u8, 89u8, 245u8, 197u8, 214u8, 5u8, 29u8, 78u8, 119u8, 79u8, 94u8, - ], - ) - } - #[doc = "See [`Pallet::add_proxy`]."] - pub fn add_proxy( - &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "add_proxy", - types::AddProxy { delegate, proxy_type, delay }, - [ - 183u8, 95u8, 175u8, 194u8, 140u8, 90u8, 170u8, 28u8, 251u8, 192u8, - 151u8, 138u8, 76u8, 170u8, 207u8, 228u8, 169u8, 124u8, 19u8, 161u8, - 181u8, 87u8, 121u8, 214u8, 101u8, 16u8, 30u8, 122u8, 125u8, 33u8, - 156u8, 197u8, - ], - ) - } - #[doc = "See [`Pallet::remove_proxy`]."] - pub fn remove_proxy( - &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "remove_proxy", - types::RemoveProxy { delegate, proxy_type, delay }, - [ - 225u8, 127u8, 66u8, 209u8, 96u8, 176u8, 66u8, 143u8, 58u8, 248u8, 7u8, - 95u8, 206u8, 250u8, 239u8, 199u8, 58u8, 128u8, 118u8, 204u8, 148u8, - 80u8, 4u8, 147u8, 20u8, 29u8, 35u8, 188u8, 21u8, 175u8, 107u8, 223u8, - ], - ) - } - #[doc = "See [`Pallet::remove_proxies`]."] - pub fn remove_proxies(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "remove_proxies", - types::RemoveProxies {}, - [ - 1u8, 126u8, 36u8, 227u8, 185u8, 34u8, 218u8, 236u8, 125u8, 231u8, 68u8, - 185u8, 145u8, 63u8, 250u8, 225u8, 103u8, 3u8, 189u8, 37u8, 172u8, - 195u8, 197u8, 216u8, 99u8, 210u8, 240u8, 162u8, 158u8, 132u8, 24u8, - 6u8, - ], - ) - } - #[doc = "See [`Pallet::create_pure`]."] - pub fn create_pure( - &self, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - index: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "create_pure", - types::CreatePure { proxy_type, delay, index }, - [ - 224u8, 201u8, 76u8, 254u8, 224u8, 64u8, 123u8, 29u8, 77u8, 114u8, - 213u8, 47u8, 9u8, 51u8, 87u8, 4u8, 142u8, 93u8, 212u8, 229u8, 148u8, - 159u8, 143u8, 56u8, 0u8, 34u8, 249u8, 228u8, 37u8, 242u8, 188u8, 28u8, - ], - ) - } - #[doc = "See [`Pallet::kill_pure`]."] - pub fn kill_pure( - &self, - spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::rococo_runtime::ProxyType, - index: ::core::primitive::u16, - height: ::core::primitive::u32, - ext_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "kill_pure", - types::KillPure { spawner, proxy_type, index, height, ext_index }, - [ - 59u8, 143u8, 9u8, 128u8, 44u8, 243u8, 110u8, 190u8, 82u8, 230u8, 253u8, - 123u8, 30u8, 59u8, 114u8, 141u8, 255u8, 162u8, 42u8, 179u8, 222u8, - 124u8, 235u8, 148u8, 5u8, 45u8, 254u8, 235u8, 75u8, 224u8, 58u8, 148u8, - ], - ) - } - #[doc = "See [`Pallet::announce`]."] - pub fn announce( - &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "announce", - types::Announce { real, call_hash }, - [ - 105u8, 218u8, 232u8, 82u8, 80u8, 10u8, 11u8, 1u8, 93u8, 241u8, 121u8, - 198u8, 167u8, 218u8, 95u8, 15u8, 75u8, 122u8, 155u8, 233u8, 10u8, - 175u8, 145u8, 73u8, 214u8, 230u8, 67u8, 107u8, 23u8, 239u8, 69u8, - 240u8, - ], - ) - } - #[doc = "See [`Pallet::remove_announcement`]."] - pub fn remove_announcement( - &self, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "remove_announcement", - types::RemoveAnnouncement { real, call_hash }, - [ - 40u8, 237u8, 179u8, 128u8, 201u8, 183u8, 20u8, 47u8, 99u8, 182u8, 81u8, - 31u8, 27u8, 212u8, 133u8, 36u8, 8u8, 248u8, 57u8, 230u8, 138u8, 80u8, - 241u8, 147u8, 69u8, 236u8, 156u8, 167u8, 205u8, 49u8, 60u8, 16u8, - ], - ) - } - #[doc = "See [`Pallet::reject_announcement`]."] - pub fn reject_announcement( - &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "reject_announcement", - types::RejectAnnouncement { delegate, call_hash }, - [ - 150u8, 178u8, 49u8, 160u8, 211u8, 75u8, 58u8, 228u8, 121u8, 253u8, - 167u8, 72u8, 68u8, 105u8, 159u8, 52u8, 41u8, 155u8, 92u8, 26u8, 169u8, - 177u8, 102u8, 36u8, 1u8, 47u8, 87u8, 189u8, 223u8, 238u8, 244u8, 110u8, - ], - ) - } - #[doc = "See [`Pallet::proxy_announced`]."] - pub fn proxy_announced( - &self, - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - force_proxy_type: ::core::option::Option< - runtime_types::rococo_runtime::ProxyType, - >, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Proxy", - "proxy_announced", - types::ProxyAnnounced { - delegate, - real, - force_proxy_type, - call: ::std::boxed::Box::new(call), - }, - [ - 99u8, 158u8, 92u8, 113u8, 118u8, 104u8, 39u8, 235u8, 181u8, 160u8, - 68u8, 234u8, 142u8, 98u8, 98u8, 56u8, 87u8, 18u8, 75u8, 149u8, 57u8, - 134u8, 147u8, 139u8, 245u8, 126u8, 33u8, 121u8, 78u8, 112u8, 167u8, - 213u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_proxy::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was executed correctly, with the given."] - pub struct ProxyExecuted { - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for ProxyExecuted { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyExecuted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A pure account has been created by new proxy with given"] - #[doc = "disambiguation index and proxy type."] - pub struct PureCreated { - pub pure: ::subxt::utils::AccountId32, - pub who: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::rococo_runtime::ProxyType, - pub disambiguation_index: ::core::primitive::u16, - } - impl ::subxt::events::StaticEvent for PureCreated { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "PureCreated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An announcement was placed to make a call in the future."] - pub struct Announced { - pub real: ::subxt::utils::AccountId32, - pub proxy: ::subxt::utils::AccountId32, - pub call_hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Announced { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "Announced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was added."] - pub struct ProxyAdded { - pub delegator: ::subxt::utils::AccountId32, - pub delegatee: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::rococo_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ProxyAdded { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyAdded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A proxy was removed."] - pub struct ProxyRemoved { - pub delegator: ::subxt::utils::AccountId32, - pub delegatee: ::subxt::utils::AccountId32, - pub proxy_type: runtime_types::rococo_runtime::ProxyType, - pub delay: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for ProxyRemoved { - const PALLET: &'static str = "Proxy"; - const EVENT: &'static str = "ProxyRemoved"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] - #[doc = " which are being delegated to, together with the amount held on deposit."] - pub fn proxies_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::ProxyDefinition< - ::subxt::utils::AccountId32, - runtime_types::rococo_runtime::ProxyType, - ::core::primitive::u32, - >, - >, - ::core::primitive::u128, - ), - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Proxy", - "Proxies", - vec![], - [ - 92u8, 131u8, 10u8, 14u8, 241u8, 148u8, 230u8, 81u8, 54u8, 152u8, 147u8, - 180u8, 85u8, 28u8, 87u8, 215u8, 110u8, 13u8, 158u8, 207u8, 77u8, 102u8, - 97u8, 57u8, 179u8, 237u8, 153u8, 148u8, 99u8, 141u8, 15u8, 126u8, - ], - ) - } - #[doc = " The set of account proxies. Maps the account which has delegated to the accounts"] - #[doc = " which are being delegated to, together with the amount held on deposit."] - pub fn proxies( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::ProxyDefinition< - ::subxt::utils::AccountId32, - runtime_types::rococo_runtime::ProxyType, - ::core::primitive::u32, - >, - >, - ::core::primitive::u128, - ), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Proxy", - "Proxies", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 92u8, 131u8, 10u8, 14u8, 241u8, 148u8, 230u8, 81u8, 54u8, 152u8, 147u8, - 180u8, 85u8, 28u8, 87u8, 215u8, 110u8, 13u8, 158u8, 207u8, 77u8, 102u8, - 97u8, 57u8, 179u8, 237u8, 153u8, 148u8, 99u8, 141u8, 15u8, 126u8, - ], - ) - } - #[doc = " The announcements made by the proxy (key)."] - pub fn announcements_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::Announcement< - ::subxt::utils::AccountId32, - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - ::core::primitive::u128, - ), - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Proxy", - "Announcements", - vec![], - [ - 129u8, 228u8, 198u8, 210u8, 90u8, 69u8, 151u8, 198u8, 206u8, 174u8, - 148u8, 58u8, 134u8, 14u8, 53u8, 56u8, 234u8, 71u8, 84u8, 247u8, 246u8, - 207u8, 117u8, 221u8, 84u8, 72u8, 254u8, 215u8, 102u8, 49u8, 21u8, - 173u8, - ], - ) - } - #[doc = " The announcements made by the proxy (key)."] - pub fn announcements( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_proxy::Announcement< - ::subxt::utils::AccountId32, - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - ::core::primitive::u128, - ), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Proxy", - "Announcements", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 129u8, 228u8, 198u8, 210u8, 90u8, 69u8, 151u8, 198u8, 206u8, 174u8, - 148u8, 58u8, 134u8, 14u8, 53u8, 56u8, 234u8, 71u8, 84u8, 247u8, 246u8, - 207u8, 117u8, 221u8, 84u8, 72u8, 254u8, 215u8, 102u8, 49u8, 21u8, - 173u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The base amount of currency needed to reserve for creating a proxy."] - #[doc = ""] - #[doc = " This is held for an additional storage item whose value size is"] - #[doc = " `sizeof(Balance)` bytes and whose key size is `sizeof(AccountId)` bytes."] - pub fn proxy_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "ProxyDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per proxy added."] - #[doc = ""] - #[doc = " This is held for adding 32 bytes plus an instance of `ProxyType` more into a"] - #[doc = " pre-existing storage value. Thus, when configuring `ProxyDepositFactor` one should take"] - #[doc = " into account `32 + proxy_type.encode().len()` bytes of data."] - pub fn proxy_deposit_factor( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "ProxyDepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum amount of proxies allowed for a single account."] - pub fn max_proxies(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Proxy", - "MaxProxies", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum amount of time-delayed announcements that are allowed to be pending."] - pub fn max_pending(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Proxy", - "MaxPending", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The base amount of currency needed to reserve for creating an announcement."] - #[doc = ""] - #[doc = " This is held when a new storage item holding a `Balance` is created (typically 16"] - #[doc = " bytes)."] - pub fn announcement_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "AnnouncementDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per announcement made."] - #[doc = ""] - #[doc = " This is held for adding an `AccountId`, `Hash` and `BlockNumber` (typically 68 bytes)"] - #[doc = " into a pre-existing storage value."] - pub fn announcement_deposit_factor( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Proxy", - "AnnouncementDepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - } - } - } - pub mod multisig { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_multisig::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_multisig::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMultiThreshold1 { - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for AsMultiThreshold1 { - const PALLET: &'static str = "Multisig"; - const CALL: &'static str = "as_multi_threshold_1"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - pub call: ::std::boxed::Box, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for AsMulti { - const PALLET: &'static str = "Multisig"; - const CALL: &'static str = "as_multi"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - pub call_hash: [::core::primitive::u8; 32usize], - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for ApproveAsMulti { - const PALLET: &'static str = "Multisig"; - const CALL: &'static str = "approve_as_multi"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelAsMulti { - pub threshold: ::core::primitive::u16, - pub other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - pub timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::blocks::StaticExtrinsic for CancelAsMulti { - const PALLET: &'static str = "Multisig"; - const CALL: &'static str = "cancel_as_multi"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::as_multi_threshold_1`]."] - pub fn as_multi_threshold_1( - &self, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Multisig", - "as_multi_threshold_1", - types::AsMultiThreshold1 { - other_signatories, - call: ::std::boxed::Box::new(call), - }, - [ - 159u8, 81u8, 109u8, 96u8, 255u8, 133u8, 93u8, 91u8, 29u8, 69u8, 187u8, - 64u8, 171u8, 147u8, 221u8, 53u8, 11u8, 254u8, 255u8, 152u8, 67u8, - 107u8, 35u8, 235u8, 251u8, 174u8, 151u8, 17u8, 109u8, 173u8, 47u8, - 149u8, - ], - ) - } - #[doc = "See [`Pallet::as_multi`]."] - pub fn as_multi( - &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call: runtime_types::rococo_runtime::RuntimeCall, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Multisig", - "as_multi", - types::AsMulti { - threshold, - other_signatories, - maybe_timepoint, - call: ::std::boxed::Box::new(call), - max_weight, - }, - [ - 141u8, 34u8, 201u8, 168u8, 75u8, 84u8, 20u8, 51u8, 4u8, 4u8, 222u8, - 118u8, 38u8, 214u8, 248u8, 100u8, 97u8, 73u8, 144u8, 167u8, 187u8, - 228u8, 178u8, 246u8, 197u8, 244u8, 37u8, 163u8, 6u8, 219u8, 242u8, - 20u8, - ], - ) - } - #[doc = "See [`Pallet::approve_as_multi`]."] - pub fn approve_as_multi( - &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call_hash: [::core::primitive::u8; 32usize], - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Multisig", - "approve_as_multi", - types::ApproveAsMulti { - threshold, - other_signatories, - maybe_timepoint, - call_hash, - max_weight, - }, - [ - 248u8, 46u8, 131u8, 35u8, 204u8, 12u8, 218u8, 150u8, 88u8, 131u8, 89u8, - 13u8, 95u8, 122u8, 87u8, 107u8, 136u8, 154u8, 92u8, 199u8, 108u8, 92u8, - 207u8, 171u8, 113u8, 8u8, 47u8, 248u8, 65u8, 26u8, 203u8, 135u8, - ], - ) - } - #[doc = "See [`Pallet::cancel_as_multi`]."] - pub fn cancel_as_multi( - &self, - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - call_hash: [::core::primitive::u8; 32usize], - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Multisig", - "cancel_as_multi", - types::CancelAsMulti { threshold, other_signatories, timepoint, call_hash }, - [ - 212u8, 179u8, 123u8, 40u8, 209u8, 228u8, 181u8, 0u8, 109u8, 28u8, 27u8, - 48u8, 15u8, 47u8, 203u8, 54u8, 106u8, 114u8, 28u8, 118u8, 101u8, 201u8, - 95u8, 187u8, 46u8, 182u8, 4u8, 30u8, 227u8, 105u8, 14u8, 81u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_multisig::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new multisig operation has begun."] - pub struct NewMultisig { - pub approving: ::subxt::utils::AccountId32, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for NewMultisig { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "NewMultisig"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been approved by someone."] - pub struct MultisigApproval { - pub approving: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for MultisigApproval { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigApproval"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been executed."] - pub struct MultisigExecuted { - pub approving: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for MultisigExecuted { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigExecuted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A multisig operation has been cancelled."] - pub struct MultisigCancelled { - pub cancelling: ::subxt::utils::AccountId32, - pub timepoint: runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - pub multisig: ::subxt::utils::AccountId32, - pub call_hash: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for MultisigCancelled { - const PALLET: &'static str = "Multisig"; - const EVENT: &'static str = "MultisigCancelled"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The set of open multisig operations."] - pub fn multisigs_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - vec![], - [ - 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, - 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, - 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, - ], - ) - } - #[doc = " The set of open multisig operations."] - pub fn multisigs_iter1( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, - 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, - 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, - ], - ) - } - #[doc = " The set of open multisig operations."] - pub fn multisigs( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow<[::core::primitive::u8; 32usize]>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_multisig::Multisig< - ::core::primitive::u32, - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Multisig", - "Multisigs", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 154u8, 109u8, 45u8, 18u8, 155u8, 151u8, 81u8, 28u8, 86u8, 127u8, 189u8, - 151u8, 49u8, 61u8, 12u8, 149u8, 84u8, 61u8, 110u8, 197u8, 200u8, 140u8, - 37u8, 100u8, 14u8, 162u8, 158u8, 161u8, 48u8, 117u8, 102u8, 61u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The base amount of currency needed to reserve for creating a multisig execution or to"] - #[doc = " store a dispatch call for later."] - #[doc = ""] - #[doc = " This is held for an additional storage item whose value size is"] - #[doc = " `4 + sizeof((BlockNumber, Balance, AccountId))` bytes and whose key size is"] - #[doc = " `32 + sizeof(AccountId)` bytes."] - pub fn deposit_base(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Multisig", - "DepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount of currency needed per unit threshold when creating a multisig execution."] - #[doc = ""] - #[doc = " This is held for adding 32 bytes more into a pre-existing storage value."] - pub fn deposit_factor( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Multisig", - "DepositFactor", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum amount of signatories allowed in the multisig."] - pub fn max_signatories( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Multisig", - "MaxSignatories", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod preimage { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_preimage::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_preimage::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NotePreimage { - pub bytes: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for NotePreimage { - const PALLET: &'static str = "Preimage"; - const CALL: &'static str = "note_preimage"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnnotePreimage { - pub hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for UnnotePreimage { - const PALLET: &'static str = "Preimage"; - const CALL: &'static str = "unnote_preimage"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestPreimage { - pub hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for RequestPreimage { - const PALLET: &'static str = "Preimage"; - const CALL: &'static str = "request_preimage"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnrequestPreimage { - pub hash: ::subxt::utils::H256, - } - impl ::subxt::blocks::StaticExtrinsic for UnrequestPreimage { - const PALLET: &'static str = "Preimage"; - const CALL: &'static str = "unrequest_preimage"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EnsureUpdated { - pub hashes: ::std::vec::Vec<::subxt::utils::H256>, - } - impl ::subxt::blocks::StaticExtrinsic for EnsureUpdated { - const PALLET: &'static str = "Preimage"; - const CALL: &'static str = "ensure_updated"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::note_preimage`]."] - pub fn note_preimage( - &self, - bytes: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "note_preimage", - types::NotePreimage { bytes }, - [ - 121u8, 88u8, 18u8, 92u8, 176u8, 15u8, 192u8, 198u8, 146u8, 198u8, 38u8, - 242u8, 213u8, 83u8, 7u8, 230u8, 14u8, 110u8, 235u8, 32u8, 215u8, 26u8, - 192u8, 217u8, 113u8, 224u8, 206u8, 96u8, 177u8, 198u8, 246u8, 33u8, - ], - ) - } - #[doc = "See [`Pallet::unnote_preimage`]."] - pub fn unnote_preimage( - &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "unnote_preimage", - types::UnnotePreimage { hash }, - [ - 188u8, 116u8, 222u8, 22u8, 127u8, 215u8, 2u8, 133u8, 96u8, 202u8, - 190u8, 123u8, 203u8, 43u8, 200u8, 161u8, 226u8, 24u8, 49u8, 36u8, - 221u8, 160u8, 130u8, 119u8, 30u8, 138u8, 144u8, 85u8, 5u8, 164u8, - 252u8, 222u8, - ], - ) - } - #[doc = "See [`Pallet::request_preimage`]."] - pub fn request_preimage( - &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "request_preimage", - types::RequestPreimage { hash }, - [ - 87u8, 0u8, 204u8, 111u8, 43u8, 115u8, 64u8, 209u8, 133u8, 13u8, 83u8, - 45u8, 164u8, 166u8, 233u8, 105u8, 242u8, 238u8, 235u8, 208u8, 113u8, - 134u8, 93u8, 242u8, 86u8, 32u8, 7u8, 152u8, 107u8, 208u8, 79u8, 59u8, - ], - ) - } - #[doc = "See [`Pallet::unrequest_preimage`]."] - pub fn unrequest_preimage( - &self, - hash: ::subxt::utils::H256, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "unrequest_preimage", - types::UnrequestPreimage { hash }, - [ - 55u8, 37u8, 224u8, 149u8, 142u8, 120u8, 8u8, 68u8, 183u8, 225u8, 255u8, - 240u8, 254u8, 111u8, 58u8, 200u8, 113u8, 217u8, 177u8, 203u8, 107u8, - 104u8, 233u8, 87u8, 252u8, 53u8, 33u8, 112u8, 116u8, 254u8, 117u8, - 134u8, - ], - ) - } - #[doc = "See [`Pallet::ensure_updated`]."] - pub fn ensure_updated( - &self, - hashes: ::std::vec::Vec<::subxt::utils::H256>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Preimage", - "ensure_updated", - types::EnsureUpdated { hashes }, - [ - 254u8, 228u8, 88u8, 44u8, 126u8, 235u8, 188u8, 153u8, 61u8, 27u8, - 103u8, 253u8, 163u8, 161u8, 113u8, 243u8, 87u8, 136u8, 2u8, 231u8, - 209u8, 188u8, 215u8, 106u8, 192u8, 225u8, 75u8, 125u8, 224u8, 96u8, - 221u8, 90u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_preimage::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A preimage has been noted."] - pub struct Noted { - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Noted { - const PALLET: &'static str = "Preimage"; - const EVENT: &'static str = "Noted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A preimage has been requested."] - pub struct Requested { - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Requested { - const PALLET: &'static str = "Preimage"; - const EVENT: &'static str = "Requested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A preimage has ben cleared."] - pub struct Cleared { - pub hash: ::subxt::utils::H256, - } - impl ::subxt::events::StaticEvent for Cleared { - const PALLET: &'static str = "Preimage"; - const EVENT: &'static str = "Cleared"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The request status of a given hash."] - pub fn status_for_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_preimage::OldRequestStatus< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "StatusFor", - vec![], - [ - 187u8, 100u8, 54u8, 112u8, 96u8, 129u8, 36u8, 149u8, 127u8, 226u8, - 126u8, 171u8, 72u8, 189u8, 59u8, 126u8, 204u8, 125u8, 67u8, 204u8, - 231u8, 6u8, 212u8, 135u8, 166u8, 252u8, 5u8, 46u8, 111u8, 120u8, 54u8, - 209u8, - ], - ) - } - #[doc = " The request status of a given hash."] - pub fn status_for( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_preimage::OldRequestStatus< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "StatusFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 187u8, 100u8, 54u8, 112u8, 96u8, 129u8, 36u8, 149u8, 127u8, 226u8, - 126u8, 171u8, 72u8, 189u8, 59u8, 126u8, 204u8, 125u8, 67u8, 204u8, - 231u8, 6u8, 212u8, 135u8, 166u8, 252u8, 5u8, 46u8, 111u8, 120u8, 54u8, - 209u8, - ], - ) - } - #[doc = " The request status of a given hash."] - pub fn request_status_for_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_preimage::RequestStatus< - ::subxt::utils::AccountId32, - runtime_types::frame_support::traits::tokens::fungible::HoldConsideration, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "RequestStatusFor", - vec![], - [ - 72u8, 59u8, 254u8, 211u8, 96u8, 223u8, 10u8, 64u8, 6u8, 139u8, 213u8, - 85u8, 14u8, 29u8, 166u8, 37u8, 140u8, 124u8, 186u8, 156u8, 172u8, - 157u8, 73u8, 5u8, 121u8, 117u8, 51u8, 6u8, 249u8, 203u8, 75u8, 190u8, - ], - ) - } - #[doc = " The request status of a given hash."] - pub fn request_status_for( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_preimage::RequestStatus< - ::subxt::utils::AccountId32, - runtime_types::frame_support::traits::tokens::fungible::HoldConsideration, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "RequestStatusFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 72u8, 59u8, 254u8, 211u8, 96u8, 223u8, 10u8, 64u8, 6u8, 139u8, 213u8, - 85u8, 14u8, 29u8, 166u8, 37u8, 140u8, 124u8, 186u8, 156u8, 172u8, - 157u8, 73u8, 5u8, 121u8, 117u8, 51u8, 6u8, 249u8, 203u8, 75u8, 190u8, - ], - ) - } - pub fn preimage_for_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "PreimageFor", - vec![], - [ - 106u8, 5u8, 17u8, 46u8, 6u8, 184u8, 177u8, 113u8, 169u8, 34u8, 119u8, - 141u8, 117u8, 40u8, 30u8, 94u8, 187u8, 35u8, 206u8, 216u8, 143u8, - 208u8, 49u8, 156u8, 200u8, 255u8, 109u8, 200u8, 210u8, 134u8, 24u8, - 139u8, - ], - ) - } - pub fn preimage_for_iter1( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "PreimageFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 106u8, 5u8, 17u8, 46u8, 6u8, 184u8, 177u8, 113u8, 169u8, 34u8, 119u8, - 141u8, 117u8, 40u8, 30u8, 94u8, 187u8, 35u8, 206u8, 216u8, 143u8, - 208u8, 49u8, 156u8, 200u8, 255u8, 109u8, 200u8, 210u8, 134u8, 24u8, - 139u8, - ], - ) - } - pub fn preimage_for( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Preimage", - "PreimageFor", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 106u8, 5u8, 17u8, 46u8, 6u8, 184u8, 177u8, 113u8, 169u8, 34u8, 119u8, - 141u8, 117u8, 40u8, 30u8, 94u8, 187u8, 35u8, 206u8, 216u8, 143u8, - 208u8, 49u8, 156u8, 200u8, 255u8, 109u8, 200u8, 210u8, 134u8, 24u8, - 139u8, - ], - ) - } - } - } - } - pub mod asset_rate { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_asset_rate::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_asset_rate::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Create { - pub asset_kind: ::std::boxed::Box< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - pub rate: runtime_types::sp_arithmetic::fixed_point::FixedU128, - } - impl ::subxt::blocks::StaticExtrinsic for Create { - const PALLET: &'static str = "AssetRate"; - const CALL: &'static str = "create"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Update { - pub asset_kind: ::std::boxed::Box< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - pub rate: runtime_types::sp_arithmetic::fixed_point::FixedU128, - } - impl ::subxt::blocks::StaticExtrinsic for Update { - const PALLET: &'static str = "AssetRate"; - const CALL: &'static str = "update"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Remove { - pub asset_kind: ::std::boxed::Box< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - } - impl ::subxt::blocks::StaticExtrinsic for Remove { - const PALLET: &'static str = "AssetRate"; - const CALL: &'static str = "remove"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::create`]."] - pub fn create( - &self, - asset_kind : runtime_types :: polkadot_runtime_common :: impls :: VersionedLocatableAsset, - rate: runtime_types::sp_arithmetic::fixed_point::FixedU128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "AssetRate", - "create", - types::Create { asset_kind: ::std::boxed::Box::new(asset_kind), rate }, - [ - 163u8, 173u8, 223u8, 197u8, 42u8, 251u8, 151u8, 159u8, 252u8, 132u8, - 225u8, 224u8, 207u8, 127u8, 38u8, 0u8, 101u8, 46u8, 29u8, 65u8, 2u8, - 241u8, 3u8, 79u8, 218u8, 10u8, 159u8, 122u8, 48u8, 7u8, 225u8, 103u8, - ], - ) - } - #[doc = "See [`Pallet::update`]."] - pub fn update( - &self, - asset_kind : runtime_types :: polkadot_runtime_common :: impls :: VersionedLocatableAsset, - rate: runtime_types::sp_arithmetic::fixed_point::FixedU128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "AssetRate", - "update", - types::Update { asset_kind: ::std::boxed::Box::new(asset_kind), rate }, - [ - 21u8, 51u8, 198u8, 111u8, 185u8, 155u8, 215u8, 34u8, 5u8, 135u8, 138u8, - 77u8, 76u8, 158u8, 63u8, 240u8, 117u8, 39u8, 83u8, 146u8, 70u8, 136u8, - 61u8, 159u8, 30u8, 66u8, 85u8, 41u8, 122u8, 174u8, 25u8, 49u8, - ], - ) - } - #[doc = "See [`Pallet::remove`]."] - pub fn remove( - &self, - asset_kind : runtime_types :: polkadot_runtime_common :: impls :: VersionedLocatableAsset, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "AssetRate", - "remove", - types::Remove { asset_kind: ::std::boxed::Box::new(asset_kind) }, - [ - 205u8, 34u8, 63u8, 131u8, 204u8, 76u8, 186u8, 233u8, 160u8, 45u8, - 231u8, 159u8, 186u8, 60u8, 97u8, 218u8, 174u8, 144u8, 106u8, 58u8, - 69u8, 23u8, 244u8, 129u8, 19u8, 250u8, 16u8, 99u8, 165u8, 165u8, 101u8, - 18u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_asset_rate::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssetRateCreated { - pub asset_kind: - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - pub rate: runtime_types::sp_arithmetic::fixed_point::FixedU128, - } - impl ::subxt::events::StaticEvent for AssetRateCreated { - const PALLET: &'static str = "AssetRate"; - const EVENT: &'static str = "AssetRateCreated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssetRateRemoved { - pub asset_kind: - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - } - impl ::subxt::events::StaticEvent for AssetRateRemoved { - const PALLET: &'static str = "AssetRate"; - const EVENT: &'static str = "AssetRateRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssetRateUpdated { - pub asset_kind: - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - pub old: runtime_types::sp_arithmetic::fixed_point::FixedU128, - pub new: runtime_types::sp_arithmetic::fixed_point::FixedU128, - } - impl ::subxt::events::StaticEvent for AssetRateUpdated { - const PALLET: &'static str = "AssetRate"; - const EVENT: &'static str = "AssetRateUpdated"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Maps an asset to its fixed point representation in the native balance."] - #[doc = ""] - #[doc = " E.g. `native_amount = asset_amount * ConversionRateToNative::::get(asset_kind)`"] - pub fn conversion_rate_to_native_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "AssetRate", - "ConversionRateToNative", - vec![], - [ - 230u8, 127u8, 110u8, 126u8, 79u8, 168u8, 134u8, 97u8, 195u8, 105u8, - 16u8, 57u8, 197u8, 104u8, 87u8, 144u8, 83u8, 188u8, 85u8, 253u8, 230u8, - 194u8, 183u8, 235u8, 152u8, 222u8, 40u8, 20u8, 135u8, 98u8, 140u8, - 108u8, - ], - ) - } - #[doc = " Maps an asset to its fixed point representation in the native balance."] - #[doc = ""] - #[doc = " E.g. `native_amount = asset_amount * ConversionRateToNative::::get(asset_kind)`"] - pub fn conversion_rate_to_native( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "AssetRate", - "ConversionRateToNative", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 230u8, 127u8, 110u8, 126u8, 79u8, 168u8, 134u8, 97u8, 195u8, 105u8, - 16u8, 57u8, 197u8, 104u8, 87u8, 144u8, 83u8, 188u8, 85u8, 253u8, 230u8, - 194u8, 183u8, 235u8, 152u8, 222u8, 40u8, 20u8, 135u8, 98u8, 140u8, - 108u8, - ], - ) - } - } - } - } - pub mod bounties { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_bounties::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_bounties::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeBounty { - #[codec(compact)] - pub value: ::core::primitive::u128, - pub description: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for ProposeBounty { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "propose_bounty"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApproveBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ApproveBounty { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "approve_bounty"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub fee: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ProposeCurator { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "propose_curator"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for UnassignCurator { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "unassign_curator"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptCurator { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for AcceptCurator { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "accept_curator"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AwardBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for AwardBounty { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "award_bounty"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ClaimBounty { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "claim_bounty"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseBounty { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for CloseBounty { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "close_bounty"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExtendBountyExpiry { - #[codec(compact)] - pub bounty_id: ::core::primitive::u32, - pub remark: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for ExtendBountyExpiry { - const PALLET: &'static str = "Bounties"; - const CALL: &'static str = "extend_bounty_expiry"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::propose_bounty`]."] - pub fn propose_bounty( - &self, - value: ::core::primitive::u128, - description: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "propose_bounty", - types::ProposeBounty { value, description }, - [ - 131u8, 169u8, 55u8, 102u8, 212u8, 139u8, 9u8, 65u8, 75u8, 112u8, 6u8, - 180u8, 92u8, 124u8, 43u8, 42u8, 38u8, 40u8, 226u8, 24u8, 28u8, 34u8, - 169u8, 220u8, 184u8, 206u8, 109u8, 227u8, 53u8, 228u8, 88u8, 25u8, - ], - ) - } - #[doc = "See [`Pallet::approve_bounty`]."] - pub fn approve_bounty( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "approve_bounty", - types::ApproveBounty { bounty_id }, - [ - 85u8, 12u8, 177u8, 91u8, 183u8, 124u8, 175u8, 148u8, 188u8, 200u8, - 237u8, 144u8, 6u8, 67u8, 159u8, 48u8, 177u8, 222u8, 183u8, 137u8, - 173u8, 131u8, 128u8, 219u8, 255u8, 243u8, 80u8, 224u8, 126u8, 136u8, - 90u8, 47u8, - ], - ) - } - #[doc = "See [`Pallet::propose_curator`]."] - pub fn propose_curator( - &self, - bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "propose_curator", - types::ProposeCurator { bounty_id, curator, fee }, - [ - 238u8, 102u8, 86u8, 97u8, 169u8, 16u8, 133u8, 41u8, 24u8, 247u8, 149u8, - 200u8, 95u8, 213u8, 45u8, 62u8, 41u8, 247u8, 170u8, 62u8, 211u8, 194u8, - 5u8, 108u8, 129u8, 145u8, 108u8, 67u8, 84u8, 97u8, 237u8, 54u8, - ], - ) - } - #[doc = "See [`Pallet::unassign_curator`]."] - pub fn unassign_curator( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "unassign_curator", - types::UnassignCurator { bounty_id }, - [ - 98u8, 94u8, 107u8, 111u8, 151u8, 182u8, 71u8, 239u8, 214u8, 88u8, - 108u8, 11u8, 51u8, 163u8, 102u8, 162u8, 245u8, 247u8, 244u8, 159u8, - 197u8, 23u8, 171u8, 6u8, 60u8, 146u8, 144u8, 101u8, 68u8, 133u8, 245u8, - 74u8, - ], - ) - } - #[doc = "See [`Pallet::accept_curator`]."] - pub fn accept_curator( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "accept_curator", - types::AcceptCurator { bounty_id }, - [ - 178u8, 142u8, 138u8, 15u8, 243u8, 10u8, 222u8, 169u8, 150u8, 200u8, - 85u8, 185u8, 39u8, 167u8, 134u8, 3u8, 186u8, 84u8, 43u8, 140u8, 11u8, - 70u8, 56u8, 197u8, 39u8, 84u8, 138u8, 139u8, 198u8, 104u8, 41u8, 238u8, - ], - ) - } - #[doc = "See [`Pallet::award_bounty`]."] - pub fn award_bounty( - &self, - bounty_id: ::core::primitive::u32, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "award_bounty", - types::AwardBounty { bounty_id, beneficiary }, - [ - 231u8, 248u8, 65u8, 2u8, 199u8, 19u8, 126u8, 23u8, 206u8, 206u8, 230u8, - 77u8, 53u8, 152u8, 230u8, 234u8, 211u8, 153u8, 82u8, 149u8, 93u8, 91u8, - 19u8, 72u8, 214u8, 92u8, 65u8, 207u8, 142u8, 168u8, 133u8, 87u8, - ], - ) - } - #[doc = "See [`Pallet::claim_bounty`]."] - pub fn claim_bounty( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "claim_bounty", - types::ClaimBounty { bounty_id }, - [ - 211u8, 143u8, 123u8, 205u8, 140u8, 43u8, 176u8, 103u8, 110u8, 125u8, - 158u8, 131u8, 103u8, 62u8, 69u8, 215u8, 220u8, 110u8, 11u8, 3u8, 30u8, - 193u8, 235u8, 177u8, 96u8, 241u8, 140u8, 53u8, 62u8, 133u8, 170u8, - 25u8, - ], - ) - } - #[doc = "See [`Pallet::close_bounty`]."] - pub fn close_bounty( - &self, - bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "close_bounty", - types::CloseBounty { bounty_id }, - [ - 144u8, 234u8, 109u8, 39u8, 227u8, 231u8, 104u8, 48u8, 45u8, 196u8, - 217u8, 220u8, 241u8, 197u8, 157u8, 227u8, 154u8, 156u8, 181u8, 69u8, - 146u8, 77u8, 203u8, 167u8, 79u8, 102u8, 15u8, 253u8, 135u8, 53u8, 96u8, - 60u8, - ], - ) - } - #[doc = "See [`Pallet::extend_bounty_expiry`]."] - pub fn extend_bounty_expiry( - &self, - bounty_id: ::core::primitive::u32, - remark: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Bounties", - "extend_bounty_expiry", - types::ExtendBountyExpiry { bounty_id, remark }, - [ - 102u8, 118u8, 89u8, 189u8, 138u8, 157u8, 216u8, 10u8, 239u8, 3u8, - 200u8, 217u8, 219u8, 19u8, 195u8, 182u8, 105u8, 220u8, 11u8, 146u8, - 222u8, 79u8, 95u8, 136u8, 188u8, 230u8, 248u8, 119u8, 30u8, 6u8, 242u8, - 194u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_bounties::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New bounty proposal."] - pub struct BountyProposed { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BountyProposed { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyProposed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty proposal was rejected; funds were slashed."] - pub struct BountyRejected { - pub index: ::core::primitive::u32, - pub bond: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for BountyRejected { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyRejected"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty proposal is funded and became active."] - pub struct BountyBecameActive { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BountyBecameActive { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyBecameActive"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is awarded to a beneficiary."] - pub struct BountyAwarded { - pub index: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for BountyAwarded { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyAwarded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is claimed by beneficiary."] - pub struct BountyClaimed { - pub index: ::core::primitive::u32, - pub payout: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for BountyClaimed { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyClaimed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is cancelled."] - pub struct BountyCanceled { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BountyCanceled { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyCanceled"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty expiry is extended."] - pub struct BountyExtended { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BountyExtended { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyExtended"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty is approved."] - pub struct BountyApproved { - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BountyApproved { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "BountyApproved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty curator is proposed."] - pub struct CuratorProposed { - pub bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for CuratorProposed { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "CuratorProposed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty curator is unassigned."] - pub struct CuratorUnassigned { - pub bounty_id: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for CuratorUnassigned { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "CuratorUnassigned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bounty curator is accepted."] - pub struct CuratorAccepted { - pub bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for CuratorAccepted { - const PALLET: &'static str = "Bounties"; - const EVENT: &'static str = "CuratorAccepted"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Number of bounty proposals that have been made."] - pub fn bounty_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyCount", - vec![], - [ - 120u8, 204u8, 26u8, 150u8, 37u8, 81u8, 43u8, 223u8, 180u8, 252u8, - 142u8, 144u8, 109u8, 5u8, 184u8, 72u8, 223u8, 230u8, 66u8, 196u8, 14u8, - 14u8, 164u8, 190u8, 246u8, 168u8, 190u8, 56u8, 212u8, 73u8, 175u8, - 26u8, - ], - ) - } - #[doc = " Bounties that have been made."] - pub fn bounties_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bounties::Bounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "Bounties", - vec![], - [ - 183u8, 96u8, 172u8, 86u8, 167u8, 129u8, 51u8, 179u8, 238u8, 155u8, - 196u8, 77u8, 158u8, 102u8, 188u8, 19u8, 79u8, 178u8, 145u8, 189u8, - 44u8, 117u8, 47u8, 97u8, 30u8, 149u8, 239u8, 212u8, 167u8, 127u8, - 108u8, 55u8, - ], - ) - } - #[doc = " Bounties that have been made."] - pub fn bounties( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_bounties::Bounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "Bounties", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 183u8, 96u8, 172u8, 86u8, 167u8, 129u8, 51u8, 179u8, 238u8, 155u8, - 196u8, 77u8, 158u8, 102u8, 188u8, 19u8, 79u8, 178u8, 145u8, 189u8, - 44u8, 117u8, 47u8, 97u8, 30u8, 149u8, 239u8, 212u8, 167u8, 127u8, - 108u8, 55u8, - ], - ) - } - #[doc = " The description of each bounty."] - pub fn bounty_descriptions_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyDescriptions", - vec![], - [ - 71u8, 40u8, 133u8, 84u8, 55u8, 207u8, 169u8, 189u8, 160u8, 51u8, 202u8, - 144u8, 15u8, 226u8, 97u8, 114u8, 54u8, 247u8, 53u8, 26u8, 36u8, 54u8, - 186u8, 163u8, 198u8, 100u8, 191u8, 121u8, 186u8, 160u8, 85u8, 97u8, - ], - ) - } - #[doc = " The description of each bounty."] - pub fn bounty_descriptions( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyDescriptions", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 71u8, 40u8, 133u8, 84u8, 55u8, 207u8, 169u8, 189u8, 160u8, 51u8, 202u8, - 144u8, 15u8, 226u8, 97u8, 114u8, 54u8, 247u8, 53u8, 26u8, 36u8, 54u8, - 186u8, 163u8, 198u8, 100u8, 191u8, 121u8, 186u8, 160u8, 85u8, 97u8, - ], - ) - } - #[doc = " Bounty indices that have been approved but not yet funded."] - pub fn bounty_approvals( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Bounties", - "BountyApprovals", - vec![], - [ - 182u8, 228u8, 0u8, 46u8, 176u8, 25u8, 222u8, 180u8, 51u8, 57u8, 14u8, - 0u8, 69u8, 160u8, 64u8, 27u8, 88u8, 29u8, 227u8, 146u8, 2u8, 121u8, - 27u8, 85u8, 45u8, 110u8, 244u8, 62u8, 134u8, 77u8, 175u8, 188u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The amount held on deposit for placing a bounty proposal."] - pub fn bounty_deposit_base( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyDepositBase", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The delay period for which a bounty beneficiary need to wait before claim the payout."] - pub fn bounty_deposit_payout_delay( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyDepositPayoutDelay", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Bounty duration in blocks."] - pub fn bounty_update_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyUpdatePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The curator deposit is calculated as a percentage of the curator fee."] - #[doc = ""] - #[doc = " This deposit has optional upper and lower bounds with `CuratorDepositMax` and"] - #[doc = " `CuratorDepositMin`."] - pub fn curator_deposit_multiplier( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMultiplier", - [ - 65u8, 93u8, 120u8, 165u8, 204u8, 81u8, 159u8, 163u8, 93u8, 135u8, - 114u8, 121u8, 147u8, 35u8, 215u8, 213u8, 4u8, 223u8, 83u8, 37u8, 225u8, - 200u8, 189u8, 156u8, 140u8, 36u8, 58u8, 46u8, 42u8, 232u8, 155u8, 0u8, - ], - ) - } - #[doc = " Maximum amount of funds that should be placed in a deposit for making a proposal."] - pub fn curator_deposit_max( - &self, - ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMax", - [ - 198u8, 51u8, 89u8, 159u8, 124u8, 251u8, 51u8, 80u8, 167u8, 193u8, 44u8, - 199u8, 80u8, 36u8, 41u8, 130u8, 137u8, 229u8, 178u8, 208u8, 37u8, - 215u8, 169u8, 183u8, 180u8, 191u8, 140u8, 240u8, 250u8, 61u8, 42u8, - 147u8, - ], - ) - } - #[doc = " Minimum amount of funds that should be placed in a deposit for making a proposal."] - pub fn curator_deposit_min( - &self, - ) -> ::subxt::constants::Address<::core::option::Option<::core::primitive::u128>> { - ::subxt::constants::Address::new_static( - "Bounties", - "CuratorDepositMin", - [ - 198u8, 51u8, 89u8, 159u8, 124u8, 251u8, 51u8, 80u8, 167u8, 193u8, 44u8, - 199u8, 80u8, 36u8, 41u8, 130u8, 137u8, 229u8, 178u8, 208u8, 37u8, - 215u8, 169u8, 183u8, 180u8, 191u8, 140u8, 240u8, 250u8, 61u8, 42u8, - 147u8, - ], - ) - } - #[doc = " Minimum value for a bounty."] - pub fn bounty_value_minimum( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Bounties", - "BountyValueMinimum", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The amount held on deposit per byte within the tip report reason or bounty description."] - pub fn data_deposit_per_byte( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Bounties", - "DataDepositPerByte", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Maximum acceptable reason length."] - #[doc = ""] - #[doc = " Benchmarks depend on this value, be sure to update weights file when changing this value"] - pub fn maximum_reason_length( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Bounties", - "MaximumReasonLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod child_bounties { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_child_bounties::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_child_bounties::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub description: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for AddChildBounty { - const PALLET: &'static str = "ChildBounties"; - const CALL: &'static str = "add_child_bounty"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProposeCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - pub curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub fee: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ProposeCurator { - const PALLET: &'static str = "ChildBounties"; - const CALL: &'static str = "propose_curator"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AcceptCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for AcceptCurator { - const PALLET: &'static str = "ChildBounties"; - const CALL: &'static str = "accept_curator"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignCurator { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for UnassignCurator { - const PALLET: &'static str = "ChildBounties"; - const CALL: &'static str = "unassign_curator"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AwardChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for AwardChildBounty { - const PALLET: &'static str = "ChildBounties"; - const CALL: &'static str = "award_child_bounty"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClaimChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ClaimChildBounty { - const PALLET: &'static str = "ChildBounties"; - const CALL: &'static str = "claim_child_bounty"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CloseChildBounty { - #[codec(compact)] - pub parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - pub child_bounty_id: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for CloseChildBounty { - const PALLET: &'static str = "ChildBounties"; - const CALL: &'static str = "close_child_bounty"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::add_child_bounty`]."] - pub fn add_child_bounty( - &self, - parent_bounty_id: ::core::primitive::u32, - value: ::core::primitive::u128, - description: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "add_child_bounty", - types::AddChildBounty { parent_bounty_id, value, description }, - [ - 249u8, 159u8, 185u8, 144u8, 114u8, 142u8, 104u8, 215u8, 136u8, 52u8, - 255u8, 125u8, 54u8, 243u8, 220u8, 171u8, 254u8, 49u8, 105u8, 134u8, - 137u8, 221u8, 100u8, 111u8, 72u8, 38u8, 184u8, 122u8, 72u8, 204u8, - 182u8, 123u8, - ], - ) - } - #[doc = "See [`Pallet::propose_curator`]."] - pub fn propose_curator( - &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - fee: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "propose_curator", - types::ProposeCurator { parent_bounty_id, child_bounty_id, curator, fee }, - [ - 30u8, 186u8, 200u8, 181u8, 73u8, 219u8, 129u8, 195u8, 100u8, 30u8, - 36u8, 9u8, 131u8, 110u8, 136u8, 145u8, 146u8, 44u8, 96u8, 207u8, 74u8, - 59u8, 61u8, 94u8, 186u8, 184u8, 89u8, 170u8, 126u8, 64u8, 234u8, 177u8, - ], - ) - } - #[doc = "See [`Pallet::accept_curator`]."] - pub fn accept_curator( - &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "accept_curator", - types::AcceptCurator { parent_bounty_id, child_bounty_id }, - [ - 80u8, 117u8, 237u8, 83u8, 230u8, 230u8, 159u8, 136u8, 87u8, 17u8, - 239u8, 110u8, 190u8, 12u8, 52u8, 63u8, 171u8, 118u8, 82u8, 168u8, - 190u8, 255u8, 91u8, 85u8, 117u8, 226u8, 51u8, 28u8, 116u8, 230u8, - 137u8, 123u8, - ], - ) - } - #[doc = "See [`Pallet::unassign_curator`]."] - pub fn unassign_curator( - &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "unassign_curator", - types::UnassignCurator { parent_bounty_id, child_bounty_id }, - [ - 120u8, 208u8, 75u8, 141u8, 220u8, 153u8, 79u8, 28u8, 255u8, 227u8, - 239u8, 10u8, 243u8, 116u8, 0u8, 226u8, 205u8, 208u8, 91u8, 193u8, - 154u8, 81u8, 169u8, 240u8, 120u8, 48u8, 102u8, 35u8, 25u8, 136u8, 92u8, - 141u8, - ], - ) - } - #[doc = "See [`Pallet::award_child_bounty`]."] - pub fn award_child_bounty( - &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "award_child_bounty", - types::AwardChildBounty { parent_bounty_id, child_bounty_id, beneficiary }, - [ - 45u8, 172u8, 88u8, 8u8, 142u8, 34u8, 30u8, 132u8, 61u8, 31u8, 187u8, - 174u8, 21u8, 5u8, 248u8, 185u8, 142u8, 193u8, 29u8, 83u8, 225u8, 213u8, - 153u8, 247u8, 67u8, 219u8, 58u8, 206u8, 102u8, 55u8, 218u8, 154u8, - ], - ) - } - #[doc = "See [`Pallet::claim_child_bounty`]."] - pub fn claim_child_bounty( - &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "claim_child_bounty", - types::ClaimChildBounty { parent_bounty_id, child_bounty_id }, - [ - 114u8, 134u8, 242u8, 240u8, 103u8, 141u8, 181u8, 214u8, 193u8, 222u8, - 23u8, 19u8, 68u8, 174u8, 190u8, 60u8, 94u8, 235u8, 14u8, 115u8, 155u8, - 199u8, 0u8, 106u8, 37u8, 144u8, 92u8, 188u8, 2u8, 149u8, 235u8, 244u8, - ], - ) - } - #[doc = "See [`Pallet::close_child_bounty`]."] - pub fn close_child_bounty( - &self, - parent_bounty_id: ::core::primitive::u32, - child_bounty_id: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ChildBounties", - "close_child_bounty", - types::CloseChildBounty { parent_bounty_id, child_bounty_id }, - [ - 121u8, 20u8, 81u8, 13u8, 102u8, 102u8, 162u8, 24u8, 133u8, 35u8, 203u8, - 58u8, 28u8, 195u8, 114u8, 31u8, 254u8, 252u8, 118u8, 57u8, 30u8, 211u8, - 217u8, 124u8, 148u8, 244u8, 144u8, 224u8, 39u8, 155u8, 162u8, 91u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_child_bounties::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is added."] - pub struct Added { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Added { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Added"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is awarded to a beneficiary."] - pub struct Awarded { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - pub beneficiary: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Awarded { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Awarded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is claimed by beneficiary."] - pub struct Claimed { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - pub payout: ::core::primitive::u128, - pub beneficiary: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Claimed { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Claimed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A child-bounty is cancelled."] - pub struct Canceled { - pub index: ::core::primitive::u32, - pub child_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Canceled { - const PALLET: &'static str = "ChildBounties"; - const EVENT: &'static str = "Canceled"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Number of total child bounties."] - pub fn child_bounty_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyCount", - vec![], - [ - 206u8, 1u8, 40u8, 132u8, 51u8, 139u8, 234u8, 20u8, 89u8, 86u8, 247u8, - 107u8, 169u8, 252u8, 5u8, 180u8, 218u8, 24u8, 232u8, 94u8, 82u8, 135u8, - 24u8, 16u8, 134u8, 23u8, 201u8, 86u8, 12u8, 19u8, 199u8, 0u8, - ], - ) - } - #[doc = " Number of child bounties per parent bounty."] - #[doc = " Map of parent bounty index to number of child bounties."] - pub fn parent_child_bounties_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ParentChildBounties", - vec![], - [ - 52u8, 179u8, 242u8, 212u8, 91u8, 185u8, 176u8, 52u8, 100u8, 200u8, 1u8, - 41u8, 184u8, 234u8, 234u8, 8u8, 123u8, 252u8, 131u8, 55u8, 109u8, - 123u8, 89u8, 75u8, 101u8, 165u8, 117u8, 175u8, 92u8, 71u8, 62u8, 67u8, - ], - ) - } - #[doc = " Number of child bounties per parent bounty."] - #[doc = " Map of parent bounty index to number of child bounties."] - pub fn parent_child_bounties( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ParentChildBounties", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 52u8, 179u8, 242u8, 212u8, 91u8, 185u8, 176u8, 52u8, 100u8, 200u8, 1u8, - 41u8, 184u8, 234u8, 234u8, 8u8, 123u8, 252u8, 131u8, 55u8, 109u8, - 123u8, 89u8, 75u8, 101u8, 165u8, 117u8, 175u8, 92u8, 71u8, 62u8, 67u8, - ], - ) - } - #[doc = " Child bounties that have been added."] - pub fn child_bounties_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_child_bounties::ChildBounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBounties", - vec![], - [ - 165u8, 240u8, 158u8, 204u8, 183u8, 190u8, 129u8, 65u8, 226u8, 8u8, - 182u8, 103u8, 46u8, 162u8, 35u8, 155u8, 131u8, 45u8, 163u8, 64u8, - 154u8, 137u8, 126u8, 249u8, 238u8, 156u8, 233u8, 78u8, 28u8, 95u8, - 242u8, 147u8, - ], - ) - } - #[doc = " Child bounties that have been added."] - pub fn child_bounties_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_child_bounties::ChildBounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBounties", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 165u8, 240u8, 158u8, 204u8, 183u8, 190u8, 129u8, 65u8, 226u8, 8u8, - 182u8, 103u8, 46u8, 162u8, 35u8, 155u8, 131u8, 45u8, 163u8, 64u8, - 154u8, 137u8, 126u8, 249u8, 238u8, 156u8, 233u8, 78u8, 28u8, 95u8, - 242u8, 147u8, - ], - ) - } - #[doc = " Child bounties that have been added."] - pub fn child_bounties( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_child_bounties::ChildBounty< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBounties", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 165u8, 240u8, 158u8, 204u8, 183u8, 190u8, 129u8, 65u8, 226u8, 8u8, - 182u8, 103u8, 46u8, 162u8, 35u8, 155u8, 131u8, 45u8, 163u8, 64u8, - 154u8, 137u8, 126u8, 249u8, 238u8, 156u8, 233u8, 78u8, 28u8, 95u8, - 242u8, 147u8, - ], - ) - } - #[doc = " The description of each child-bounty."] - pub fn child_bounty_descriptions_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyDescriptions", - vec![], - [ - 192u8, 0u8, 220u8, 156u8, 109u8, 65u8, 113u8, 102u8, 119u8, 0u8, 109u8, - 141u8, 211u8, 128u8, 237u8, 61u8, 28u8, 56u8, 206u8, 93u8, 183u8, 74u8, - 192u8, 220u8, 76u8, 175u8, 85u8, 105u8, 179u8, 11u8, 164u8, 100u8, - ], - ) - } - #[doc = " The description of each child-bounty."] - pub fn child_bounty_descriptions( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildBountyDescriptions", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 192u8, 0u8, 220u8, 156u8, 109u8, 65u8, 113u8, 102u8, 119u8, 0u8, 109u8, - 141u8, 211u8, 128u8, 237u8, 61u8, 28u8, 56u8, 206u8, 93u8, 183u8, 74u8, - 192u8, 220u8, 76u8, 175u8, 85u8, 105u8, 179u8, 11u8, 164u8, 100u8, - ], - ) - } - #[doc = " The cumulative child-bounty curator fee for each parent bounty."] - pub fn children_curator_fees_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildrenCuratorFees", - vec![], - [ - 32u8, 16u8, 190u8, 193u8, 6u8, 80u8, 163u8, 16u8, 85u8, 111u8, 39u8, - 141u8, 209u8, 70u8, 213u8, 167u8, 22u8, 12u8, 93u8, 17u8, 104u8, 94u8, - 129u8, 37u8, 179u8, 41u8, 156u8, 117u8, 39u8, 202u8, 227u8, 235u8, - ], - ) - } - #[doc = " The cumulative child-bounty curator fee for each parent bounty."] - pub fn children_curator_fees( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ChildBounties", - "ChildrenCuratorFees", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 32u8, 16u8, 190u8, 193u8, 6u8, 80u8, 163u8, 16u8, 85u8, 111u8, 39u8, - 141u8, 209u8, 70u8, 213u8, 167u8, 22u8, 12u8, 93u8, 17u8, 104u8, 94u8, - 129u8, 37u8, 179u8, 41u8, 156u8, 117u8, 39u8, 202u8, 227u8, 235u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Maximum number of child bounties that can be added to a parent bounty."] - pub fn max_active_child_bounty_count( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "ChildBounties", - "MaxActiveChildBountyCount", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Minimum value for a child-bounty."] - pub fn child_bounty_value_minimum( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "ChildBounties", - "ChildBountyValueMinimum", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - } - } - } - pub mod nis { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_nis::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_nis::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlaceBid { - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub duration: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for PlaceBid { - const PALLET: &'static str = "Nis"; - const CALL: &'static str = "place_bid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RetractBid { - #[codec(compact)] - pub amount: ::core::primitive::u128, - pub duration: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for RetractBid { - const PALLET: &'static str = "Nis"; - const CALL: &'static str = "retract_bid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FundDeficit; - impl ::subxt::blocks::StaticExtrinsic for FundDeficit { - const PALLET: &'static str = "Nis"; - const CALL: &'static str = "fund_deficit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ThawPrivate { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub maybe_proportion: ::core::option::Option< - runtime_types::sp_arithmetic::per_things::Perquintill, - >, - } - impl ::subxt::blocks::StaticExtrinsic for ThawPrivate { - const PALLET: &'static str = "Nis"; - const CALL: &'static str = "thaw_private"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ThawCommunal { - #[codec(compact)] - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ThawCommunal { - const PALLET: &'static str = "Nis"; - const CALL: &'static str = "thaw_communal"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Communify { - #[codec(compact)] - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Communify { - const PALLET: &'static str = "Nis"; - const CALL: &'static str = "communify"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Privatize { - #[codec(compact)] - pub index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for Privatize { - const PALLET: &'static str = "Nis"; - const CALL: &'static str = "privatize"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::place_bid`]."] - pub fn place_bid( - &self, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Nis", - "place_bid", - types::PlaceBid { amount, duration }, - [ - 138u8, 214u8, 63u8, 53u8, 233u8, 95u8, 186u8, 83u8, 235u8, 121u8, 4u8, - 41u8, 210u8, 214u8, 35u8, 196u8, 89u8, 102u8, 115u8, 130u8, 151u8, - 212u8, 13u8, 34u8, 198u8, 103u8, 160u8, 39u8, 22u8, 151u8, 216u8, - 243u8, - ], - ) - } - #[doc = "See [`Pallet::retract_bid`]."] - pub fn retract_bid( - &self, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Nis", - "retract_bid", - types::RetractBid { amount, duration }, - [ - 156u8, 140u8, 160u8, 45u8, 107u8, 72u8, 2u8, 129u8, 149u8, 89u8, 103u8, - 95u8, 189u8, 42u8, 0u8, 21u8, 51u8, 236u8, 113u8, 33u8, 136u8, 115u8, - 93u8, 223u8, 72u8, 139u8, 46u8, 76u8, 128u8, 134u8, 209u8, 252u8, - ], - ) - } - #[doc = "See [`Pallet::fund_deficit`]."] - pub fn fund_deficit(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Nis", - "fund_deficit", - types::FundDeficit {}, - [ - 49u8, 183u8, 23u8, 249u8, 232u8, 74u8, 238u8, 100u8, 165u8, 242u8, - 42u8, 6u8, 58u8, 91u8, 28u8, 229u8, 5u8, 180u8, 108u8, 164u8, 63u8, - 20u8, 92u8, 122u8, 222u8, 149u8, 190u8, 194u8, 64u8, 114u8, 22u8, - 176u8, - ], - ) - } - #[doc = "See [`Pallet::thaw_private`]."] - pub fn thaw_private( - &self, - index: ::core::primitive::u32, - maybe_proportion: ::core::option::Option< - runtime_types::sp_arithmetic::per_things::Perquintill, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Nis", - "thaw_private", - types::ThawPrivate { index, maybe_proportion }, - [ - 202u8, 131u8, 103u8, 88u8, 165u8, 203u8, 191u8, 48u8, 99u8, 26u8, 1u8, - 133u8, 8u8, 139u8, 216u8, 195u8, 22u8, 91u8, 240u8, 188u8, 228u8, 54u8, - 140u8, 156u8, 66u8, 13u8, 53u8, 184u8, 157u8, 177u8, 227u8, 52u8, - ], - ) - } - #[doc = "See [`Pallet::thaw_communal`]."] - pub fn thaw_communal( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Nis", - "thaw_communal", - types::ThawCommunal { index }, - [ - 106u8, 64u8, 53u8, 173u8, 59u8, 135u8, 254u8, 38u8, 119u8, 2u8, 4u8, - 109u8, 21u8, 220u8, 218u8, 220u8, 34u8, 10u8, 86u8, 248u8, 166u8, - 226u8, 183u8, 117u8, 211u8, 16u8, 53u8, 236u8, 0u8, 187u8, 140u8, - 221u8, - ], - ) - } - #[doc = "See [`Pallet::communify`]."] - pub fn communify( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Nis", - "communify", - types::Communify { index }, - [ - 206u8, 141u8, 231u8, 98u8, 101u8, 34u8, 101u8, 190u8, 22u8, 246u8, - 238u8, 30u8, 48u8, 104u8, 128u8, 115u8, 49u8, 78u8, 30u8, 230u8, 59u8, - 173u8, 70u8, 89u8, 82u8, 212u8, 105u8, 236u8, 86u8, 244u8, 248u8, - 144u8, - ], - ) - } - #[doc = "See [`Pallet::privatize`]."] - pub fn privatize( - &self, - index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Nis", - "privatize", - types::Privatize { index }, - [ - 228u8, 215u8, 197u8, 40u8, 194u8, 170u8, 139u8, 192u8, 214u8, 61u8, - 107u8, 132u8, 89u8, 122u8, 58u8, 12u8, 11u8, 231u8, 186u8, 73u8, 106u8, - 99u8, 134u8, 216u8, 206u8, 118u8, 221u8, 223u8, 187u8, 206u8, 246u8, - 255u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_nis::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bid was successfully placed."] - pub struct BidPlaced { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub duration: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BidPlaced { - const PALLET: &'static str = "Nis"; - const EVENT: &'static str = "BidPlaced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bid was successfully removed (before being accepted)."] - pub struct BidRetracted { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub duration: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BidRetracted { - const PALLET: &'static str = "Nis"; - const EVENT: &'static str = "BidRetracted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bid was dropped from a queue because of another, more substantial, bid was present."] - pub struct BidDropped { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub duration: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BidDropped { - const PALLET: &'static str = "Nis"; - const EVENT: &'static str = "BidDropped"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A bid was accepted. The balance may not be released until expiry."] - pub struct Issued { - pub index: ::core::primitive::u32, - pub expiry: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Issued { - const PALLET: &'static str = "Nis"; - const EVENT: &'static str = "Issued"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An receipt has been (at least partially) thawed."] - pub struct Thawed { - pub index: ::core::primitive::u32, - pub who: ::subxt::utils::AccountId32, - pub proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - pub amount: ::core::primitive::u128, - pub dropped: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for Thawed { - const PALLET: &'static str = "Nis"; - const EVENT: &'static str = "Thawed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An automatic funding of the deficit was made."] - pub struct Funded { - pub deficit: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Funded { - const PALLET: &'static str = "Nis"; - const EVENT: &'static str = "Funded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A receipt was transfered."] - pub struct Transferred { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for Transferred { - const PALLET: &'static str = "Nis"; - const EVENT: &'static str = "Transferred"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The totals of items and balances within each queue. Saves a lot of storage reads in the"] - #[doc = " case of sparsely packed queues."] - #[doc = ""] - #[doc = " The vector is indexed by duration in `Period`s, offset by one, so information on the queue"] - #[doc = " whose duration is one `Period` would be storage `0`."] - pub fn queue_totals( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - ::core::primitive::u128, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Nis", - "QueueTotals", - vec![], - [ - 40u8, 120u8, 43u8, 203u8, 97u8, 129u8, 61u8, 184u8, 137u8, 45u8, 201u8, - 90u8, 227u8, 161u8, 52u8, 179u8, 9u8, 74u8, 104u8, 225u8, 209u8, 62u8, - 69u8, 222u8, 124u8, 202u8, 36u8, 137u8, 183u8, 102u8, 234u8, 58u8, - ], - ) - } - #[doc = " The queues of bids. Indexed by duration (in `Period`s)."] - pub fn queues_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_nis::pallet::Bid< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Nis", - "Queues", - vec![], - [ - 144u8, 181u8, 173u8, 134u8, 6u8, 165u8, 174u8, 91u8, 75u8, 241u8, - 142u8, 192u8, 246u8, 71u8, 132u8, 146u8, 181u8, 158u8, 125u8, 34u8, - 5u8, 151u8, 136u8, 148u8, 228u8, 11u8, 226u8, 229u8, 8u8, 50u8, 205u8, - 75u8, - ], - ) - } - #[doc = " The queues of bids. Indexed by duration (in `Period`s)."] - pub fn queues( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_nis::pallet::Bid< - ::core::primitive::u128, - ::subxt::utils::AccountId32, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Nis", - "Queues", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 144u8, 181u8, 173u8, 134u8, 6u8, 165u8, 174u8, 91u8, 75u8, 241u8, - 142u8, 192u8, 246u8, 71u8, 132u8, 146u8, 181u8, 158u8, 125u8, 34u8, - 5u8, 151u8, 136u8, 148u8, 228u8, 11u8, 226u8, 229u8, 8u8, 50u8, 205u8, - 75u8, - ], - ) - } - #[doc = " Summary information over the general state."] - pub fn summary( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nis::pallet::SummaryRecord< - ::core::primitive::u32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Nis", - "Summary", - vec![], - [ - 106u8, 21u8, 103u8, 47u8, 211u8, 234u8, 50u8, 222u8, 25u8, 209u8, 67u8, - 117u8, 111u8, 6u8, 231u8, 245u8, 109u8, 52u8, 177u8, 20u8, 179u8, - 253u8, 251u8, 197u8, 218u8, 163u8, 229u8, 187u8, 172u8, 122u8, 126u8, - 57u8, - ], - ) - } - #[doc = " The currently outstanding receipts, indexed according to the order of creation."] - pub fn receipts_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nis::pallet::ReceiptRecord< - ::subxt::utils::AccountId32, - ::core::primitive::u32, - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Nis", - "Receipts", - vec![], - [ - 123u8, 179u8, 0u8, 14u8, 5u8, 132u8, 165u8, 192u8, 163u8, 22u8, 174u8, - 22u8, 252u8, 44u8, 167u8, 22u8, 116u8, 170u8, 186u8, 118u8, 131u8, 5u8, - 237u8, 121u8, 35u8, 146u8, 206u8, 239u8, 155u8, 108u8, 46u8, 0u8, - ], - ) - } - #[doc = " The currently outstanding receipts, indexed according to the order of creation."] - pub fn receipts( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_nis::pallet::ReceiptRecord< - ::subxt::utils::AccountId32, - ::core::primitive::u32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Nis", - "Receipts", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 123u8, 179u8, 0u8, 14u8, 5u8, 132u8, 165u8, 192u8, 163u8, 22u8, 174u8, - 22u8, 252u8, 44u8, 167u8, 22u8, 116u8, 170u8, 186u8, 118u8, 131u8, 5u8, - 237u8, 121u8, 35u8, 146u8, 206u8, 239u8, 155u8, 108u8, 46u8, 0u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The treasury's pallet id, used for deriving its sovereign account ID."] - pub fn pallet_id( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "Nis", - "PalletId", - [ - 56u8, 243u8, 53u8, 83u8, 154u8, 179u8, 170u8, 80u8, 133u8, 173u8, 61u8, - 161u8, 47u8, 225u8, 146u8, 21u8, 50u8, 229u8, 248u8, 27u8, 104u8, 58u8, - 129u8, 197u8, 102u8, 160u8, 168u8, 205u8, 154u8, 42u8, 217u8, 53u8, - ], - ) - } - #[doc = " Number of duration queues in total. This sets the maximum duration supported, which is"] - #[doc = " this value multiplied by `Period`."] - pub fn queue_count(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Nis", - "QueueCount", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Maximum number of items that may be in each duration queue."] - #[doc = ""] - #[doc = " Must be larger than zero."] - pub fn max_queue_len(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Nis", - "MaxQueueLen", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " Portion of the queue which is free from ordering and just a FIFO."] - #[doc = ""] - #[doc = " Must be no greater than `MaxQueueLen`."] - pub fn fifo_queue_len( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Nis", - "FifoQueueLen", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The base period for the duration queues. This is the common multiple across all"] - #[doc = " supported freezing durations that can be bid upon."] - pub fn base_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Nis", - "BasePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The minimum amount of funds that may be placed in a bid. Note that this"] - #[doc = " does not actually limit the amount which may be represented in a receipt since bids may"] - #[doc = " be split up by the system."] - #[doc = ""] - #[doc = " It should be at least big enough to ensure that there is no possible storage spam attack"] - #[doc = " or queue-filling attack."] - pub fn min_bid(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Nis", - "MinBid", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The minimum amount of funds which may intentionally be left remaining under a single"] - #[doc = " receipt."] - pub fn min_receipt( - &self, - ) -> ::subxt::constants::Address< - runtime_types::sp_arithmetic::per_things::Perquintill, - > { - ::subxt::constants::Address::new_static( - "Nis", - "MinReceipt", - [ - 184u8, 78u8, 161u8, 6u8, 214u8, 205u8, 82u8, 205u8, 126u8, 46u8, 7u8, - 198u8, 186u8, 10u8, 66u8, 116u8, 191u8, 223u8, 17u8, 246u8, 196u8, - 190u8, 222u8, 226u8, 62u8, 35u8, 191u8, 127u8, 60u8, 171u8, 85u8, - 201u8, - ], - ) - } - #[doc = " The number of blocks between consecutive attempts to dequeue bids and create receipts."] - #[doc = ""] - #[doc = " A larger value results in fewer storage hits each block, but a slower period to get to"] - #[doc = " the target."] - pub fn intake_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Nis", - "IntakePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum amount of bids that can consolidated into receipts in a single intake. A"] - #[doc = " larger value here means less of the block available for transactions should there be a"] - #[doc = " glut of bids."] - pub fn max_intake_weight( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "Nis", - "MaxIntakeWeight", - [ - 149u8, 252u8, 129u8, 80u8, 169u8, 36u8, 79u8, 127u8, 240u8, 156u8, - 56u8, 202u8, 219u8, 86u8, 5u8, 65u8, 245u8, 148u8, 138u8, 243u8, 210u8, - 128u8, 234u8, 216u8, 240u8, 219u8, 123u8, 235u8, 21u8, 158u8, 237u8, - 112u8, - ], - ) - } - #[doc = " The maximum proportion which may be thawed and the period over which it is reset."] - pub fn thaw_throttle( - &self, - ) -> ::subxt::constants::Address<( - runtime_types::sp_arithmetic::per_things::Perquintill, - ::core::primitive::u32, - )> { - ::subxt::constants::Address::new_static( - "Nis", - "ThawThrottle", - [ - 41u8, 240u8, 41u8, 161u8, 238u8, 241u8, 63u8, 205u8, 122u8, 230u8, - 158u8, 65u8, 212u8, 229u8, 123u8, 215u8, 69u8, 204u8, 207u8, 193u8, - 149u8, 229u8, 193u8, 245u8, 210u8, 63u8, 106u8, 42u8, 27u8, 182u8, - 66u8, 167u8, - ], - ) - } - } - } - } - pub mod nis_counterpart_balances { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_balances::pallet::Error2; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_balances::pallet::Call2; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAllowDeath { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for TransferAllowDeath { - const PALLET: &'static str = "NisCounterpartBalances"; - const CALL: &'static str = "transfer_allow_death"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceTransfer { - pub source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceTransfer { - const PALLET: &'static str = "NisCounterpartBalances"; - const CALL: &'static str = "force_transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferKeepAlive { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub value: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for TransferKeepAlive { - const PALLET: &'static str = "NisCounterpartBalances"; - const CALL: &'static str = "transfer_keep_alive"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAll { - pub dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub keep_alive: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for TransferAll { - const PALLET: &'static str = "NisCounterpartBalances"; - const CALL: &'static str = "transfer_all"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnreserve { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub amount: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceUnreserve { - const PALLET: &'static str = "NisCounterpartBalances"; - const CALL: &'static str = "force_unreserve"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UpgradeAccounts { - pub who: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - impl ::subxt::blocks::StaticExtrinsic for UpgradeAccounts { - const PALLET: &'static str = "NisCounterpartBalances"; - const CALL: &'static str = "upgrade_accounts"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetBalance { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - pub new_free: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSetBalance { - const PALLET: &'static str = "NisCounterpartBalances"; - const CALL: &'static str = "force_set_balance"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceAdjustTotalIssuance { - pub direction: runtime_types::pallet_balances::types::AdjustmentDirection, - #[codec(compact)] - pub delta: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for ForceAdjustTotalIssuance { - const PALLET: &'static str = "NisCounterpartBalances"; - const CALL: &'static str = "force_adjust_total_issuance"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::transfer_allow_death`]."] - pub fn transfer_allow_death( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NisCounterpartBalances", - "transfer_allow_death", - types::TransferAllowDeath { dest, value }, - [ - 51u8, 166u8, 195u8, 10u8, 139u8, 218u8, 55u8, 130u8, 6u8, 194u8, 35u8, - 140u8, 27u8, 205u8, 214u8, 222u8, 102u8, 43u8, 143u8, 145u8, 86u8, - 219u8, 210u8, 147u8, 13u8, 39u8, 51u8, 21u8, 237u8, 179u8, 132u8, - 130u8, - ], - ) - } - #[doc = "See [`Pallet::force_transfer`]."] - pub fn force_transfer( - &self, - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NisCounterpartBalances", - "force_transfer", - types::ForceTransfer { source, dest, value }, - [ - 154u8, 93u8, 222u8, 27u8, 12u8, 248u8, 63u8, 213u8, 224u8, 86u8, 250u8, - 153u8, 249u8, 102u8, 83u8, 160u8, 79u8, 125u8, 105u8, 222u8, 77u8, - 180u8, 90u8, 105u8, 81u8, 217u8, 60u8, 25u8, 213u8, 51u8, 185u8, 96u8, - ], - ) - } - #[doc = "See [`Pallet::transfer_keep_alive`]."] - pub fn transfer_keep_alive( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NisCounterpartBalances", - "transfer_keep_alive", - types::TransferKeepAlive { dest, value }, - [ - 245u8, 14u8, 190u8, 193u8, 32u8, 210u8, 74u8, 92u8, 25u8, 182u8, 76u8, - 55u8, 247u8, 83u8, 114u8, 75u8, 143u8, 236u8, 117u8, 25u8, 54u8, 157u8, - 208u8, 207u8, 233u8, 89u8, 70u8, 161u8, 235u8, 242u8, 222u8, 59u8, - ], - ) - } - #[doc = "See [`Pallet::transfer_all`]."] - pub fn transfer_all( - &self, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NisCounterpartBalances", - "transfer_all", - types::TransferAll { dest, keep_alive }, - [ - 105u8, 132u8, 49u8, 144u8, 195u8, 250u8, 34u8, 46u8, 213u8, 248u8, - 112u8, 188u8, 81u8, 228u8, 136u8, 18u8, 67u8, 172u8, 37u8, 38u8, 238u8, - 9u8, 34u8, 15u8, 67u8, 34u8, 148u8, 195u8, 223u8, 29u8, 154u8, 6u8, - ], - ) - } - #[doc = "See [`Pallet::force_unreserve`]."] - pub fn force_unreserve( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NisCounterpartBalances", - "force_unreserve", - types::ForceUnreserve { who, amount }, - [ - 142u8, 151u8, 64u8, 205u8, 46u8, 64u8, 62u8, 122u8, 108u8, 49u8, 223u8, - 140u8, 120u8, 153u8, 35u8, 165u8, 187u8, 38u8, 157u8, 200u8, 123u8, - 199u8, 198u8, 168u8, 208u8, 159u8, 39u8, 134u8, 92u8, 103u8, 84u8, - 171u8, - ], - ) - } - #[doc = "See [`Pallet::upgrade_accounts`]."] - pub fn upgrade_accounts( - &self, - who: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NisCounterpartBalances", - "upgrade_accounts", - types::UpgradeAccounts { who }, - [ - 66u8, 200u8, 179u8, 104u8, 65u8, 2u8, 101u8, 56u8, 130u8, 161u8, 224u8, - 233u8, 255u8, 124u8, 70u8, 122u8, 8u8, 49u8, 103u8, 178u8, 68u8, 47u8, - 214u8, 166u8, 217u8, 116u8, 178u8, 50u8, 212u8, 164u8, 98u8, 226u8, - ], - ) - } - #[doc = "See [`Pallet::force_set_balance`]."] - pub fn force_set_balance( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - new_free: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NisCounterpartBalances", - "force_set_balance", - types::ForceSetBalance { who, new_free }, - [ - 114u8, 229u8, 59u8, 204u8, 180u8, 83u8, 17u8, 4u8, 59u8, 4u8, 55u8, - 39u8, 151u8, 196u8, 124u8, 60u8, 209u8, 65u8, 193u8, 11u8, 44u8, 164u8, - 116u8, 93u8, 169u8, 30u8, 199u8, 165u8, 55u8, 231u8, 223u8, 43u8, - ], - ) - } - #[doc = "See [`Pallet::force_adjust_total_issuance`]."] - pub fn force_adjust_total_issuance( - &self, - direction: runtime_types::pallet_balances::types::AdjustmentDirection, - delta: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "NisCounterpartBalances", - "force_adjust_total_issuance", - types::ForceAdjustTotalIssuance { direction, delta }, - [ - 208u8, 134u8, 56u8, 133u8, 232u8, 164u8, 10u8, 213u8, 53u8, 193u8, - 190u8, 63u8, 236u8, 186u8, 96u8, 122u8, 104u8, 87u8, 173u8, 38u8, 58u8, - 176u8, 21u8, 78u8, 42u8, 106u8, 46u8, 248u8, 251u8, 190u8, 150u8, - 202u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_balances::pallet::Event2; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was created with some free balance."] - pub struct Endowed { - pub account: ::subxt::utils::AccountId32, - pub free_balance: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Endowed { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Endowed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] - #[doc = "resulting in an outright loss."] - pub struct DustLost { - pub account: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DustLost { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "DustLost"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Transfer succeeded."] - pub struct Transfer { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Transfer { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Transfer"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A balance was set by root."] - pub struct BalanceSet { - pub who: ::subxt::utils::AccountId32, - pub free: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for BalanceSet { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "BalanceSet"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was reserved (moved from free to reserved)."] - pub struct Reserved { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Reserved { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Reserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was unreserved (moved from reserved to free)."] - pub struct Unreserved { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unreserved { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Unreserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was moved from the reserve of the first account to the second account."] - #[doc = "Final argument indicates the destination balance type."] - pub struct ReserveRepatriated { - pub from: ::subxt::utils::AccountId32, - pub to: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - } - impl ::subxt::events::StaticEvent for ReserveRepatriated { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "ReserveRepatriated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was deposited (e.g. for transaction fees)."] - pub struct Deposit { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Deposit { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Deposit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] - pub struct Withdraw { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdraw { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Withdraw"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] - pub struct Slashed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Slashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was minted into an account."] - pub struct Minted { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Minted { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Minted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was burned from an account."] - pub struct Burned { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Burned { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Burned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was suspended from an account (it can be restored later)."] - pub struct Suspended { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Suspended { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Suspended"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some amount was restored into an account."] - pub struct Restored { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Restored { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Restored"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An account was upgraded."] - pub struct Upgraded { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Upgraded { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Upgraded"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] - pub struct Issued { - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Issued { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Issued"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] - pub struct Rescinded { - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Rescinded { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Rescinded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was locked."] - pub struct Locked { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Locked { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Locked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was unlocked."] - pub struct Unlocked { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unlocked { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Unlocked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was frozen."] - pub struct Frozen { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Frozen { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Frozen"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some balance was thawed."] - pub struct Thawed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Thawed { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "Thawed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `TotalIssuance` was forcefully changed."] - pub struct TotalIssuanceForced { - pub old: ::core::primitive::u128, - pub new: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for TotalIssuanceForced { - const PALLET: &'static str = "NisCounterpartBalances"; - const EVENT: &'static str = "TotalIssuanceForced"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The total units issued in the system."] - pub fn total_issuance( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "TotalIssuance", - vec![], - [ - 116u8, 70u8, 119u8, 194u8, 69u8, 37u8, 116u8, 206u8, 171u8, 70u8, - 171u8, 210u8, 226u8, 111u8, 184u8, 204u8, 206u8, 11u8, 68u8, 72u8, - 255u8, 19u8, 194u8, 11u8, 27u8, 194u8, 81u8, 204u8, 59u8, 224u8, 202u8, - 185u8, - ], - ) - } - #[doc = " The total units of outstanding deactivated balance in the system."] - pub fn inactive_issuance( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "InactiveIssuance", - vec![], - [ - 212u8, 185u8, 19u8, 50u8, 250u8, 72u8, 173u8, 50u8, 4u8, 104u8, 161u8, - 249u8, 77u8, 247u8, 204u8, 248u8, 11u8, 18u8, 57u8, 4u8, 82u8, 110u8, - 30u8, 216u8, 16u8, 37u8, 87u8, 67u8, 189u8, 235u8, 214u8, 155u8, - ], - ) - } - #[doc = " The Balances pallet example of storing the balance of an account."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " You can also store the balance of an account in the `System` pallet."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = System"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] - #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] - #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] - #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] - pub fn account_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Account", - vec![], - [ - 213u8, 38u8, 200u8, 69u8, 218u8, 0u8, 112u8, 181u8, 160u8, 23u8, 96u8, - 90u8, 3u8, 88u8, 126u8, 22u8, 103u8, 74u8, 64u8, 69u8, 29u8, 247u8, - 18u8, 17u8, 234u8, 143u8, 189u8, 22u8, 247u8, 194u8, 154u8, 249u8, - ], - ) - } - #[doc = " The Balances pallet example of storing the balance of an account."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = StorageMapShim, frame_system::Provider, AccountId, Self::AccountData>"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " You can also store the balance of an account in the `System` pallet."] - #[doc = ""] - #[doc = " # Example"] - #[doc = ""] - #[doc = " ```nocompile"] - #[doc = " impl pallet_balances::Config for Runtime {"] - #[doc = " type AccountStore = System"] - #[doc = " }"] - #[doc = " ```"] - #[doc = ""] - #[doc = " But this comes with tradeoffs, storing account balances in the system pallet stores"] - #[doc = " `frame_system` data alongside the account data contrary to storing account balances in the"] - #[doc = " `Balances` pallet, which uses a `StorageMap` to store balances data only."] - #[doc = " NOTE: This is only used in the case that this pallet is used to store balances."] - pub fn account( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_balances::types::AccountData<::core::primitive::u128>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Account", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 213u8, 38u8, 200u8, 69u8, 218u8, 0u8, 112u8, 181u8, 160u8, 23u8, 96u8, - 90u8, 3u8, 88u8, 126u8, 22u8, 103u8, 74u8, 64u8, 69u8, 29u8, 247u8, - 18u8, 17u8, 234u8, 143u8, 189u8, 22u8, 247u8, 194u8, 154u8, 249u8, - ], - ) - } - #[doc = " Any liquidity locks on some account balances."] - #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] - pub fn locks_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Locks", - vec![], - [ - 10u8, 223u8, 55u8, 0u8, 249u8, 69u8, 168u8, 41u8, 75u8, 35u8, 120u8, - 167u8, 18u8, 132u8, 9u8, 20u8, 91u8, 51u8, 27u8, 69u8, 136u8, 187u8, - 13u8, 220u8, 163u8, 122u8, 26u8, 141u8, 174u8, 249u8, 85u8, 37u8, - ], - ) - } - #[doc = " Any liquidity locks on some account balances."] - #[doc = " NOTE: Should only be accessed when setting, changing and freeing a lock."] - pub fn locks( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - runtime_types::pallet_balances::types::BalanceLock<::core::primitive::u128>, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Locks", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 10u8, 223u8, 55u8, 0u8, 249u8, 69u8, 168u8, 41u8, 75u8, 35u8, 120u8, - 167u8, 18u8, 132u8, 9u8, 20u8, 91u8, 51u8, 27u8, 69u8, 136u8, 187u8, - 13u8, 220u8, 163u8, 122u8, 26u8, 141u8, 174u8, 249u8, 85u8, 37u8, - ], - ) - } - #[doc = " Named reserves on some account balances."] - pub fn reserves_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::ReserveData< - [::core::primitive::u8; 8usize], - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Reserves", - vec![], - [ - 112u8, 10u8, 241u8, 77u8, 64u8, 187u8, 106u8, 159u8, 13u8, 153u8, - 140u8, 178u8, 182u8, 50u8, 1u8, 55u8, 149u8, 92u8, 196u8, 229u8, 170u8, - 106u8, 193u8, 88u8, 255u8, 244u8, 2u8, 193u8, 62u8, 235u8, 204u8, 91u8, - ], - ) - } - #[doc = " Named reserves on some account balances."] - pub fn reserves( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::ReserveData< - [::core::primitive::u8; 8usize], - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Reserves", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 112u8, 10u8, 241u8, 77u8, 64u8, 187u8, 106u8, 159u8, 13u8, 153u8, - 140u8, 178u8, 182u8, 50u8, 1u8, 55u8, 149u8, 92u8, 196u8, 229u8, 170u8, - 106u8, 193u8, 88u8, 255u8, 244u8, 2u8, 193u8, 62u8, 235u8, 204u8, 91u8, - ], - ) - } - #[doc = " Holds on account balances."] - pub fn holds_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - runtime_types::rococo_runtime::RuntimeHoldReason, - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Holds", - vec![], - [ - 181u8, 39u8, 29u8, 45u8, 45u8, 198u8, 129u8, 210u8, 189u8, 183u8, - 121u8, 125u8, 57u8, 90u8, 95u8, 107u8, 51u8, 13u8, 22u8, 105u8, 191u8, - 61u8, 54u8, 182u8, 50u8, 200u8, 137u8, 247u8, 180u8, 158u8, 16u8, - 193u8, - ], - ) - } - #[doc = " Holds on account balances."] - pub fn holds( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - runtime_types::rococo_runtime::RuntimeHoldReason, - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Holds", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 181u8, 39u8, 29u8, 45u8, 45u8, 198u8, 129u8, 210u8, 189u8, 183u8, - 121u8, 125u8, 57u8, 90u8, 95u8, 107u8, 51u8, 13u8, 22u8, 105u8, 191u8, - 61u8, 54u8, 182u8, 50u8, 200u8, 137u8, 247u8, 180u8, 158u8, 16u8, - 193u8, - ], - ) - } - #[doc = " Freeze locks on account balances."] - pub fn freezes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Freezes", - vec![], - [ - 69u8, 49u8, 165u8, 76u8, 135u8, 142u8, 179u8, 118u8, 50u8, 109u8, 53u8, - 112u8, 110u8, 94u8, 30u8, 93u8, 173u8, 38u8, 27u8, 142u8, 19u8, 5u8, - 163u8, 4u8, 68u8, 218u8, 179u8, 224u8, 118u8, 218u8, 115u8, 64u8, - ], - ) - } - #[doc = " Freeze locks on account balances."] - pub fn freezes( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::pallet_balances::types::IdAmount< - (), - ::core::primitive::u128, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "NisCounterpartBalances", - "Freezes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 69u8, 49u8, 165u8, 76u8, 135u8, 142u8, 179u8, 118u8, 50u8, 109u8, 53u8, - 112u8, 110u8, 94u8, 30u8, 93u8, 173u8, 38u8, 27u8, 142u8, 19u8, 5u8, - 163u8, 4u8, 68u8, 218u8, 179u8, 224u8, 118u8, 218u8, 115u8, 64u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The minimum amount required to keep an account open. MUST BE GREATER THAN ZERO!"] - #[doc = ""] - #[doc = " If you *really* need it to be zero, you can enable the feature `insecure_zero_ed` for"] - #[doc = " this pallet. However, you do so at your own risk: this will open up a major DoS vector."] - #[doc = " In case you have multiple sources of provider references, you may also get unexpected"] - #[doc = " behaviour if you set this to zero."] - #[doc = ""] - #[doc = " Bottom line: Do yourself a favour and make it at least one!"] - pub fn existential_deposit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "NisCounterpartBalances", - "ExistentialDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The maximum number of locks that should exist on an account."] - #[doc = " Not strictly enforced, but used for weight estimation."] - pub fn max_locks(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "NisCounterpartBalances", - "MaxLocks", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of named reserves that can exist on an account."] - pub fn max_reserves(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "NisCounterpartBalances", - "MaxReserves", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of individual freeze locks that can exist on an account at any time."] - pub fn max_freezes(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "NisCounterpartBalances", - "MaxFreezes", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod parachains_origin { - use super::root_mod; - use super::runtime_types; - } - pub mod configuration { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_parachains::configuration::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::configuration::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidationUpgradeCooldown { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetValidationUpgradeCooldown { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_validation_upgrade_cooldown"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetValidationUpgradeDelay { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetValidationUpgradeDelay { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_validation_upgrade_delay"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCodeRetentionPeriod { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetCodeRetentionPeriod { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_code_retention_period"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxCodeSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxCodeSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_code_size"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxPovSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxPovSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_pov_size"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxHeadDataSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxHeadDataSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_head_data_size"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCoretimeCores { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetCoretimeCores { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_coretime_cores"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetOnDemandRetries { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetOnDemandRetries { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_on_demand_retries"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetGroupRotationFrequency { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetGroupRotationFrequency { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_group_rotation_frequency"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetParasAvailabilityPeriod { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetParasAvailabilityPeriod { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_paras_availability_period"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetSchedulingLookahead { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetSchedulingLookahead { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_scheduling_lookahead"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxValidatorsPerCore { - pub new: ::core::option::Option<::core::primitive::u32>, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxValidatorsPerCore { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_validators_per_core"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxValidators { - pub new: ::core::option::Option<::core::primitive::u32>, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxValidators { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_validators"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDisputePeriod { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetDisputePeriod { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_dispute_period"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetDisputePostConclusionAcceptancePeriod { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetDisputePostConclusionAcceptancePeriod { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_dispute_post_conclusion_acceptance_period"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNoShowSlots { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetNoShowSlots { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_no_show_slots"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNDelayTranches { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetNDelayTranches { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_n_delay_tranches"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetZerothDelayTrancheWidth { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetZerothDelayTrancheWidth { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_zeroth_delay_tranche_width"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNeededApprovals { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetNeededApprovals { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_needed_approvals"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetRelayVrfModuloSamples { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetRelayVrfModuloSamples { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_relay_vrf_modulo_samples"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardQueueCount { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxUpwardQueueCount { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_upward_queue_count"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardQueueSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxUpwardQueueSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_upward_queue_size"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxDownwardMessageSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxDownwardMessageSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_downward_message_size"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardMessageSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxUpwardMessageSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_upward_message_size"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxUpwardMessageNumPerCandidate { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxUpwardMessageNumPerCandidate { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_max_upward_message_num_per_candidate"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpOpenRequestTtl { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpOpenRequestTtl { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_open_request_ttl"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpSenderDeposit { - pub new: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpSenderDeposit { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_sender_deposit"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpRecipientDeposit { - pub new: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpRecipientDeposit { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_recipient_deposit"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxCapacity { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpChannelMaxCapacity { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_channel_max_capacity"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxTotalSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpChannelMaxTotalSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_channel_max_total_size"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParachainInboundChannels { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpMaxParachainInboundChannels { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_max_parachain_inbound_channels"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpChannelMaxMessageSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpChannelMaxMessageSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_channel_max_message_size"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxParachainOutboundChannels { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpMaxParachainOutboundChannels { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_max_parachain_outbound_channels"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetHrmpMaxMessageNumPerCandidate { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetHrmpMaxMessageNumPerCandidate { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_hrmp_max_message_num_per_candidate"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetPvfVotingTtl { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetPvfVotingTtl { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_pvf_voting_ttl"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinimumValidationUpgradeDelay { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMinimumValidationUpgradeDelay { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_minimum_validation_upgrade_delay"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetBypassConsistencyCheck { - pub new: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for SetBypassConsistencyCheck { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_bypass_consistency_check"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetAsyncBackingParams { - pub new: - runtime_types::polkadot_primitives::v6::async_backing::AsyncBackingParams, - } - impl ::subxt::blocks::StaticExtrinsic for SetAsyncBackingParams { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_async_backing_params"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetExecutorParams { - pub new: - runtime_types::polkadot_primitives::v6::executor_params::ExecutorParams, - } - impl ::subxt::blocks::StaticExtrinsic for SetExecutorParams { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_executor_params"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetOnDemandBaseFee { - pub new: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for SetOnDemandBaseFee { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_on_demand_base_fee"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetOnDemandFeeVariability { - pub new: runtime_types::sp_arithmetic::per_things::Perbill, - } - impl ::subxt::blocks::StaticExtrinsic for SetOnDemandFeeVariability { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_on_demand_fee_variability"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetOnDemandQueueMaxSize { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetOnDemandQueueMaxSize { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_on_demand_queue_max_size"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetOnDemandTargetQueueUtilization { - pub new: runtime_types::sp_arithmetic::per_things::Perbill, - } - impl ::subxt::blocks::StaticExtrinsic for SetOnDemandTargetQueueUtilization { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_on_demand_target_queue_utilization"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetOnDemandTtl { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetOnDemandTtl { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_on_demand_ttl"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMinimumBackingVotes { - pub new: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMinimumBackingVotes { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_minimum_backing_votes"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNodeFeature { - pub index: ::core::primitive::u8, - pub value: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for SetNodeFeature { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_node_feature"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetApprovalVotingParams { - pub new: runtime_types::polkadot_primitives::vstaging::ApprovalVotingParams, - } - impl ::subxt::blocks::StaticExtrinsic for SetApprovalVotingParams { - const PALLET: &'static str = "Configuration"; - const CALL: &'static str = "set_approval_voting_params"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::set_validation_upgrade_cooldown`]."] - pub fn set_validation_upgrade_cooldown( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_validation_upgrade_cooldown", - types::SetValidationUpgradeCooldown { new }, - [ - 233u8, 224u8, 19u8, 198u8, 27u8, 104u8, 64u8, 248u8, 223u8, 51u8, - 175u8, 162u8, 183u8, 43u8, 108u8, 246u8, 162u8, 210u8, 53u8, 56u8, - 174u8, 203u8, 79u8, 143u8, 13u8, 101u8, 100u8, 11u8, 127u8, 76u8, 71u8, - 228u8, - ], - ) - } - #[doc = "See [`Pallet::set_validation_upgrade_delay`]."] - pub fn set_validation_upgrade_delay( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_validation_upgrade_delay", - types::SetValidationUpgradeDelay { new }, - [ - 13u8, 139u8, 210u8, 115u8, 20u8, 121u8, 55u8, 118u8, 101u8, 236u8, - 95u8, 79u8, 46u8, 44u8, 129u8, 129u8, 60u8, 198u8, 13u8, 17u8, 115u8, - 187u8, 181u8, 37u8, 75u8, 153u8, 13u8, 196u8, 49u8, 204u8, 26u8, 198u8, - ], - ) - } - #[doc = "See [`Pallet::set_code_retention_period`]."] - pub fn set_code_retention_period( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_code_retention_period", - types::SetCodeRetentionPeriod { new }, - [ - 169u8, 77u8, 107u8, 175u8, 172u8, 177u8, 169u8, 194u8, 219u8, 6u8, - 192u8, 40u8, 55u8, 241u8, 128u8, 111u8, 95u8, 67u8, 173u8, 247u8, - 220u8, 66u8, 45u8, 76u8, 108u8, 137u8, 220u8, 194u8, 86u8, 41u8, 245u8, - 226u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_code_size`]."] - pub fn set_max_code_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_code_size", - types::SetMaxCodeSize { new }, - [ - 122u8, 74u8, 244u8, 226u8, 89u8, 175u8, 191u8, 163u8, 34u8, 79u8, - 118u8, 254u8, 236u8, 215u8, 8u8, 182u8, 71u8, 180u8, 224u8, 165u8, - 226u8, 242u8, 124u8, 34u8, 38u8, 27u8, 29u8, 140u8, 187u8, 93u8, 131u8, - 168u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_pov_size`]."] - pub fn set_max_pov_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_pov_size", - types::SetMaxPovSize { new }, - [ - 170u8, 106u8, 163u8, 4u8, 27u8, 72u8, 250u8, 59u8, 133u8, 128u8, 177u8, - 209u8, 22u8, 42u8, 230u8, 40u8, 192u8, 198u8, 56u8, 195u8, 31u8, 20u8, - 35u8, 196u8, 119u8, 183u8, 141u8, 38u8, 52u8, 54u8, 31u8, 122u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_head_data_size`]."] - pub fn set_max_head_data_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_head_data_size", - types::SetMaxHeadDataSize { new }, - [ - 216u8, 146u8, 104u8, 253u8, 123u8, 192u8, 123u8, 82u8, 149u8, 22u8, - 31u8, 107u8, 67u8, 102u8, 163u8, 239u8, 57u8, 183u8, 93u8, 20u8, 126u8, - 39u8, 36u8, 242u8, 252u8, 68u8, 150u8, 121u8, 147u8, 186u8, 39u8, - 181u8, - ], - ) - } - #[doc = "See [`Pallet::set_coretime_cores`]."] - pub fn set_coretime_cores( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_coretime_cores", - types::SetCoretimeCores { new }, - [ - 179u8, 131u8, 211u8, 152u8, 167u8, 6u8, 108u8, 94u8, 179u8, 97u8, 87u8, - 227u8, 57u8, 120u8, 133u8, 130u8, 59u8, 243u8, 224u8, 2u8, 11u8, 86u8, - 251u8, 77u8, 159u8, 177u8, 145u8, 34u8, 117u8, 93u8, 28u8, 52u8, - ], - ) - } - #[doc = "See [`Pallet::set_on_demand_retries`]."] - pub fn set_on_demand_retries( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_on_demand_retries", - types::SetOnDemandRetries { new }, - [ - 228u8, 78u8, 216u8, 66u8, 17u8, 51u8, 84u8, 14u8, 80u8, 67u8, 24u8, - 138u8, 177u8, 108u8, 203u8, 87u8, 240u8, 125u8, 111u8, 223u8, 216u8, - 212u8, 69u8, 236u8, 216u8, 178u8, 166u8, 145u8, 115u8, 47u8, 147u8, - 235u8, - ], - ) - } - #[doc = "See [`Pallet::set_group_rotation_frequency`]."] - pub fn set_group_rotation_frequency( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_group_rotation_frequency", - types::SetGroupRotationFrequency { new }, - [ - 33u8, 142u8, 63u8, 205u8, 128u8, 109u8, 157u8, 33u8, 122u8, 91u8, 57u8, - 223u8, 134u8, 80u8, 108u8, 187u8, 147u8, 120u8, 104u8, 170u8, 32u8, - 135u8, 102u8, 38u8, 82u8, 20u8, 123u8, 211u8, 245u8, 91u8, 134u8, 44u8, - ], - ) - } - #[doc = "See [`Pallet::set_paras_availability_period`]."] - pub fn set_paras_availability_period( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_paras_availability_period", - types::SetParasAvailabilityPeriod { new }, - [ - 83u8, 171u8, 219u8, 129u8, 231u8, 54u8, 45u8, 19u8, 167u8, 21u8, 232u8, - 205u8, 166u8, 83u8, 234u8, 101u8, 205u8, 248u8, 74u8, 39u8, 130u8, - 15u8, 92u8, 39u8, 239u8, 111u8, 215u8, 165u8, 149u8, 11u8, 89u8, 119u8, - ], - ) - } - #[doc = "See [`Pallet::set_scheduling_lookahead`]."] - pub fn set_scheduling_lookahead( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_scheduling_lookahead", - types::SetSchedulingLookahead { new }, - [ - 176u8, 115u8, 251u8, 197u8, 19u8, 106u8, 253u8, 224u8, 149u8, 96u8, - 238u8, 106u8, 19u8, 19u8, 89u8, 249u8, 186u8, 89u8, 144u8, 116u8, - 251u8, 30u8, 157u8, 237u8, 125u8, 153u8, 86u8, 6u8, 251u8, 170u8, 73u8, - 216u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_validators_per_core`]."] - pub fn set_max_validators_per_core( - &self, - new: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_validators_per_core", - types::SetMaxValidatorsPerCore { new }, - [ - 152u8, 112u8, 244u8, 133u8, 209u8, 166u8, 55u8, 155u8, 12u8, 216u8, - 62u8, 111u8, 81u8, 52u8, 194u8, 121u8, 172u8, 201u8, 204u8, 139u8, - 198u8, 238u8, 9u8, 49u8, 119u8, 236u8, 46u8, 0u8, 179u8, 234u8, 92u8, - 45u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_validators`]."] - pub fn set_max_validators( - &self, - new: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_validators", - types::SetMaxValidators { new }, - [ - 219u8, 76u8, 191u8, 139u8, 250u8, 154u8, 232u8, 176u8, 248u8, 154u8, - 185u8, 89u8, 135u8, 151u8, 183u8, 132u8, 72u8, 63u8, 101u8, 183u8, - 142u8, 169u8, 163u8, 226u8, 24u8, 139u8, 78u8, 155u8, 3u8, 136u8, - 142u8, 137u8, - ], - ) - } - #[doc = "See [`Pallet::set_dispute_period`]."] - pub fn set_dispute_period( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_dispute_period", - types::SetDisputePeriod { new }, - [ - 104u8, 229u8, 235u8, 207u8, 136u8, 207u8, 181u8, 99u8, 0u8, 84u8, - 200u8, 244u8, 220u8, 52u8, 64u8, 26u8, 232u8, 212u8, 242u8, 190u8, - 67u8, 180u8, 171u8, 200u8, 181u8, 23u8, 32u8, 240u8, 231u8, 217u8, - 23u8, 146u8, - ], - ) - } - #[doc = "See [`Pallet::set_dispute_post_conclusion_acceptance_period`]."] - pub fn set_dispute_post_conclusion_acceptance_period( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_dispute_post_conclusion_acceptance_period", - types::SetDisputePostConclusionAcceptancePeriod { new }, - [ - 251u8, 176u8, 139u8, 76u8, 7u8, 246u8, 198u8, 190u8, 39u8, 249u8, 95u8, - 226u8, 53u8, 186u8, 112u8, 101u8, 229u8, 80u8, 240u8, 185u8, 108u8, - 228u8, 91u8, 103u8, 128u8, 218u8, 231u8, 210u8, 164u8, 197u8, 84u8, - 149u8, - ], - ) - } - #[doc = "See [`Pallet::set_no_show_slots`]."] - pub fn set_no_show_slots( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_no_show_slots", - types::SetNoShowSlots { new }, - [ - 123u8, 204u8, 253u8, 222u8, 224u8, 215u8, 247u8, 154u8, 225u8, 79u8, - 29u8, 171u8, 107u8, 216u8, 215u8, 14u8, 8u8, 230u8, 49u8, 97u8, 20u8, - 84u8, 70u8, 33u8, 254u8, 63u8, 186u8, 7u8, 184u8, 135u8, 74u8, 139u8, - ], - ) - } - #[doc = "See [`Pallet::set_n_delay_tranches`]."] - pub fn set_n_delay_tranches( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_n_delay_tranches", - types::SetNDelayTranches { new }, - [ - 157u8, 177u8, 251u8, 227u8, 118u8, 250u8, 129u8, 254u8, 33u8, 250u8, - 61u8, 148u8, 189u8, 92u8, 49u8, 119u8, 107u8, 40u8, 255u8, 119u8, - 241u8, 188u8, 109u8, 240u8, 229u8, 169u8, 31u8, 62u8, 174u8, 14u8, - 247u8, 235u8, - ], - ) - } - #[doc = "See [`Pallet::set_zeroth_delay_tranche_width`]."] - pub fn set_zeroth_delay_tranche_width( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_zeroth_delay_tranche_width", - types::SetZerothDelayTrancheWidth { new }, - [ - 30u8, 195u8, 15u8, 51u8, 210u8, 159u8, 254u8, 207u8, 121u8, 172u8, - 107u8, 241u8, 55u8, 100u8, 159u8, 55u8, 76u8, 47u8, 86u8, 93u8, 221u8, - 34u8, 136u8, 97u8, 224u8, 141u8, 46u8, 181u8, 246u8, 137u8, 79u8, 57u8, - ], - ) - } - #[doc = "See [`Pallet::set_needed_approvals`]."] - pub fn set_needed_approvals( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_needed_approvals", - types::SetNeededApprovals { new }, - [ - 245u8, 105u8, 16u8, 120u8, 28u8, 231u8, 6u8, 50u8, 143u8, 102u8, 1u8, - 97u8, 224u8, 232u8, 187u8, 164u8, 200u8, 31u8, 129u8, 139u8, 79u8, - 170u8, 14u8, 147u8, 117u8, 13u8, 98u8, 16u8, 64u8, 169u8, 46u8, 41u8, - ], - ) - } - #[doc = "See [`Pallet::set_relay_vrf_modulo_samples`]."] - pub fn set_relay_vrf_modulo_samples( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_relay_vrf_modulo_samples", - types::SetRelayVrfModuloSamples { new }, - [ - 96u8, 100u8, 42u8, 61u8, 244u8, 226u8, 135u8, 187u8, 56u8, 193u8, - 247u8, 236u8, 38u8, 40u8, 242u8, 222u8, 176u8, 209u8, 211u8, 217u8, - 178u8, 32u8, 160u8, 56u8, 23u8, 60u8, 222u8, 166u8, 134u8, 72u8, 153u8, - 14u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_upward_queue_count`]."] - pub fn set_max_upward_queue_count( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_upward_queue_count", - types::SetMaxUpwardQueueCount { new }, - [ - 187u8, 102u8, 178u8, 141u8, 245u8, 8u8, 221u8, 174u8, 128u8, 239u8, - 104u8, 120u8, 202u8, 220u8, 46u8, 27u8, 175u8, 26u8, 1u8, 170u8, 193u8, - 70u8, 176u8, 13u8, 223u8, 57u8, 153u8, 161u8, 228u8, 175u8, 226u8, - 202u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_upward_queue_size`]."] - pub fn set_max_upward_queue_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_upward_queue_size", - types::SetMaxUpwardQueueSize { new }, - [ - 245u8, 234u8, 151u8, 232u8, 49u8, 193u8, 60u8, 21u8, 103u8, 238u8, - 194u8, 73u8, 238u8, 160u8, 48u8, 88u8, 143u8, 197u8, 110u8, 230u8, - 213u8, 149u8, 171u8, 94u8, 77u8, 6u8, 139u8, 191u8, 158u8, 62u8, 181u8, - 32u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_downward_message_size`]."] - pub fn set_max_downward_message_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_downward_message_size", - types::SetMaxDownwardMessageSize { new }, - [ - 63u8, 112u8, 231u8, 193u8, 226u8, 6u8, 119u8, 35u8, 60u8, 34u8, 85u8, - 15u8, 168u8, 16u8, 176u8, 116u8, 169u8, 114u8, 42u8, 208u8, 89u8, - 188u8, 22u8, 145u8, 248u8, 87u8, 74u8, 168u8, 0u8, 202u8, 112u8, 13u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_upward_message_size`]."] - pub fn set_max_upward_message_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_upward_message_size", - types::SetMaxUpwardMessageSize { new }, - [ - 237u8, 108u8, 33u8, 245u8, 65u8, 209u8, 201u8, 97u8, 126u8, 194u8, - 195u8, 8u8, 144u8, 223u8, 148u8, 242u8, 97u8, 214u8, 38u8, 231u8, - 123u8, 143u8, 34u8, 199u8, 100u8, 183u8, 211u8, 111u8, 250u8, 245u8, - 10u8, 38u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_upward_message_num_per_candidate`]."] - pub fn set_max_upward_message_num_per_candidate( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_max_upward_message_num_per_candidate", - types::SetMaxUpwardMessageNumPerCandidate { new }, - [ - 183u8, 121u8, 87u8, 193u8, 8u8, 160u8, 107u8, 80u8, 50u8, 8u8, 75u8, - 185u8, 195u8, 248u8, 75u8, 174u8, 210u8, 108u8, 149u8, 20u8, 66u8, - 153u8, 20u8, 203u8, 92u8, 99u8, 27u8, 69u8, 212u8, 212u8, 35u8, 49u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_open_request_ttl`]."] - pub fn set_hrmp_open_request_ttl( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_open_request_ttl", - types::SetHrmpOpenRequestTtl { new }, - [ - 233u8, 46u8, 165u8, 59u8, 196u8, 77u8, 161u8, 124u8, 252u8, 98u8, 8u8, - 52u8, 80u8, 17u8, 12u8, 50u8, 25u8, 127u8, 143u8, 252u8, 230u8, 10u8, - 193u8, 251u8, 167u8, 73u8, 40u8, 63u8, 203u8, 119u8, 208u8, 254u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_sender_deposit`]."] - pub fn set_hrmp_sender_deposit( - &self, - new: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_sender_deposit", - types::SetHrmpSenderDeposit { new }, - [ - 4u8, 141u8, 15u8, 87u8, 237u8, 39u8, 225u8, 108u8, 159u8, 240u8, 121u8, - 212u8, 225u8, 155u8, 168u8, 28u8, 61u8, 119u8, 232u8, 216u8, 194u8, - 172u8, 147u8, 16u8, 50u8, 100u8, 146u8, 146u8, 69u8, 252u8, 94u8, 47u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_recipient_deposit`]."] - pub fn set_hrmp_recipient_deposit( - &self, - new: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_recipient_deposit", - types::SetHrmpRecipientDeposit { new }, - [ - 242u8, 193u8, 202u8, 91u8, 69u8, 252u8, 101u8, 52u8, 162u8, 107u8, - 165u8, 69u8, 90u8, 150u8, 62u8, 239u8, 167u8, 2u8, 221u8, 3u8, 231u8, - 252u8, 82u8, 125u8, 212u8, 174u8, 47u8, 216u8, 219u8, 237u8, 242u8, - 144u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_channel_max_capacity`]."] - pub fn set_hrmp_channel_max_capacity( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_channel_max_capacity", - types::SetHrmpChannelMaxCapacity { new }, - [ - 140u8, 138u8, 197u8, 45u8, 144u8, 102u8, 150u8, 172u8, 110u8, 6u8, - 99u8, 130u8, 62u8, 217u8, 119u8, 110u8, 180u8, 132u8, 102u8, 161u8, - 78u8, 59u8, 209u8, 44u8, 120u8, 183u8, 13u8, 88u8, 89u8, 15u8, 224u8, - 224u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_channel_max_total_size`]."] - pub fn set_hrmp_channel_max_total_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_channel_max_total_size", - types::SetHrmpChannelMaxTotalSize { new }, - [ - 149u8, 21u8, 229u8, 107u8, 125u8, 28u8, 17u8, 155u8, 45u8, 230u8, 50u8, - 64u8, 16u8, 171u8, 24u8, 58u8, 246u8, 57u8, 247u8, 20u8, 34u8, 217u8, - 206u8, 157u8, 40u8, 205u8, 187u8, 205u8, 199u8, 24u8, 115u8, 214u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_max_parachain_inbound_channels`]."] - pub fn set_hrmp_max_parachain_inbound_channels( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_max_parachain_inbound_channels", - types::SetHrmpMaxParachainInboundChannels { new }, - [ - 203u8, 10u8, 55u8, 21u8, 21u8, 254u8, 74u8, 97u8, 34u8, 117u8, 160u8, - 183u8, 168u8, 235u8, 11u8, 9u8, 137u8, 141u8, 150u8, 80u8, 32u8, 41u8, - 118u8, 40u8, 28u8, 74u8, 155u8, 7u8, 63u8, 217u8, 39u8, 104u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_channel_max_message_size`]."] - pub fn set_hrmp_channel_max_message_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_channel_max_message_size", - types::SetHrmpChannelMaxMessageSize { new }, - [ - 153u8, 216u8, 55u8, 31u8, 189u8, 173u8, 23u8, 6u8, 213u8, 103u8, 205u8, - 154u8, 115u8, 105u8, 84u8, 133u8, 94u8, 254u8, 47u8, 128u8, 130u8, - 114u8, 227u8, 102u8, 214u8, 146u8, 215u8, 183u8, 179u8, 151u8, 43u8, - 187u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_max_parachain_outbound_channels`]."] - pub fn set_hrmp_max_parachain_outbound_channels( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_max_parachain_outbound_channels", - types::SetHrmpMaxParachainOutboundChannels { new }, - [ - 91u8, 100u8, 158u8, 17u8, 123u8, 31u8, 6u8, 92u8, 80u8, 92u8, 83u8, - 195u8, 234u8, 207u8, 55u8, 88u8, 75u8, 81u8, 219u8, 131u8, 234u8, 5u8, - 75u8, 236u8, 57u8, 93u8, 70u8, 145u8, 255u8, 171u8, 25u8, 174u8, - ], - ) - } - #[doc = "See [`Pallet::set_hrmp_max_message_num_per_candidate`]."] - pub fn set_hrmp_max_message_num_per_candidate( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_hrmp_max_message_num_per_candidate", - types::SetHrmpMaxMessageNumPerCandidate { new }, - [ - 179u8, 44u8, 231u8, 12u8, 166u8, 160u8, 223u8, 164u8, 218u8, 173u8, - 157u8, 49u8, 16u8, 220u8, 0u8, 224u8, 67u8, 194u8, 210u8, 207u8, 237u8, - 96u8, 96u8, 24u8, 71u8, 237u8, 30u8, 152u8, 105u8, 245u8, 157u8, 218u8, - ], - ) - } - #[doc = "See [`Pallet::set_pvf_voting_ttl`]."] - pub fn set_pvf_voting_ttl( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_pvf_voting_ttl", - types::SetPvfVotingTtl { new }, - [ - 115u8, 135u8, 76u8, 222u8, 214u8, 80u8, 103u8, 250u8, 194u8, 34u8, - 129u8, 245u8, 216u8, 69u8, 166u8, 247u8, 138u8, 94u8, 135u8, 228u8, - 90u8, 145u8, 2u8, 244u8, 73u8, 178u8, 61u8, 251u8, 21u8, 197u8, 202u8, - 246u8, - ], - ) - } - #[doc = "See [`Pallet::set_minimum_validation_upgrade_delay`]."] - pub fn set_minimum_validation_upgrade_delay( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_minimum_validation_upgrade_delay", - types::SetMinimumValidationUpgradeDelay { new }, - [ - 143u8, 217u8, 201u8, 206u8, 206u8, 244u8, 116u8, 118u8, 13u8, 169u8, - 132u8, 125u8, 253u8, 178u8, 196u8, 12u8, 251u8, 32u8, 201u8, 133u8, - 50u8, 59u8, 37u8, 169u8, 198u8, 112u8, 136u8, 47u8, 205u8, 141u8, - 191u8, 212u8, - ], - ) - } - #[doc = "See [`Pallet::set_bypass_consistency_check`]."] - pub fn set_bypass_consistency_check( - &self, - new: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_bypass_consistency_check", - types::SetBypassConsistencyCheck { new }, - [ - 11u8, 211u8, 68u8, 221u8, 178u8, 108u8, 101u8, 55u8, 107u8, 135u8, - 203u8, 112u8, 173u8, 161u8, 23u8, 104u8, 95u8, 200u8, 46u8, 231u8, - 114u8, 3u8, 8u8, 89u8, 147u8, 141u8, 55u8, 65u8, 125u8, 45u8, 218u8, - 78u8, - ], - ) - } - #[doc = "See [`Pallet::set_async_backing_params`]."] - pub fn set_async_backing_params( - &self, - new: runtime_types::polkadot_primitives::v6::async_backing::AsyncBackingParams, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_async_backing_params", - types::SetAsyncBackingParams { new }, - [ - 28u8, 148u8, 243u8, 41u8, 68u8, 91u8, 113u8, 162u8, 126u8, 115u8, - 122u8, 220u8, 126u8, 19u8, 119u8, 236u8, 20u8, 112u8, 181u8, 76u8, - 191u8, 225u8, 44u8, 207u8, 85u8, 246u8, 10u8, 167u8, 132u8, 211u8, - 14u8, 83u8, - ], - ) - } - #[doc = "See [`Pallet::set_executor_params`]."] - pub fn set_executor_params( - &self, - new: runtime_types::polkadot_primitives::v6::executor_params::ExecutorParams, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_executor_params", - types::SetExecutorParams { new }, - [ - 79u8, 167u8, 242u8, 14u8, 22u8, 177u8, 240u8, 134u8, 154u8, 77u8, - 233u8, 188u8, 110u8, 223u8, 25u8, 52u8, 58u8, 241u8, 226u8, 255u8, 2u8, - 26u8, 8u8, 241u8, 125u8, 33u8, 63u8, 204u8, 93u8, 31u8, 229u8, 0u8, - ], - ) - } - #[doc = "See [`Pallet::set_on_demand_base_fee`]."] - pub fn set_on_demand_base_fee( - &self, - new: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_on_demand_base_fee", - types::SetOnDemandBaseFee { new }, - [ - 181u8, 205u8, 34u8, 186u8, 152u8, 91u8, 76u8, 55u8, 128u8, 116u8, 44u8, - 32u8, 71u8, 33u8, 247u8, 146u8, 134u8, 15u8, 181u8, 229u8, 105u8, 67u8, - 148u8, 214u8, 211u8, 84u8, 93u8, 122u8, 235u8, 204u8, 63u8, 13u8, - ], - ) - } - #[doc = "See [`Pallet::set_on_demand_fee_variability`]."] - pub fn set_on_demand_fee_variability( - &self, - new: runtime_types::sp_arithmetic::per_things::Perbill, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_on_demand_fee_variability", - types::SetOnDemandFeeVariability { new }, - [ - 255u8, 132u8, 238u8, 200u8, 152u8, 248u8, 89u8, 87u8, 160u8, 38u8, - 38u8, 7u8, 137u8, 178u8, 176u8, 10u8, 63u8, 250u8, 95u8, 68u8, 39u8, - 147u8, 5u8, 214u8, 223u8, 44u8, 225u8, 10u8, 233u8, 155u8, 202u8, - 232u8, - ], - ) - } - #[doc = "See [`Pallet::set_on_demand_queue_max_size`]."] - pub fn set_on_demand_queue_max_size( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_on_demand_queue_max_size", - types::SetOnDemandQueueMaxSize { new }, - [ - 207u8, 222u8, 29u8, 91u8, 8u8, 250u8, 0u8, 153u8, 230u8, 206u8, 87u8, - 4u8, 248u8, 28u8, 120u8, 55u8, 24u8, 45u8, 103u8, 75u8, 25u8, 239u8, - 61u8, 238u8, 11u8, 63u8, 82u8, 219u8, 154u8, 27u8, 130u8, 173u8, - ], - ) - } - #[doc = "See [`Pallet::set_on_demand_target_queue_utilization`]."] - pub fn set_on_demand_target_queue_utilization( - &self, - new: runtime_types::sp_arithmetic::per_things::Perbill, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_on_demand_target_queue_utilization", - types::SetOnDemandTargetQueueUtilization { new }, - [ - 78u8, 98u8, 234u8, 149u8, 254u8, 231u8, 174u8, 232u8, 246u8, 16u8, - 218u8, 142u8, 156u8, 247u8, 70u8, 214u8, 144u8, 159u8, 71u8, 241u8, - 178u8, 102u8, 251u8, 153u8, 208u8, 222u8, 121u8, 139u8, 66u8, 146u8, - 94u8, 147u8, - ], - ) - } - #[doc = "See [`Pallet::set_on_demand_ttl`]."] - pub fn set_on_demand_ttl( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_on_demand_ttl", - types::SetOnDemandTtl { new }, - [ - 248u8, 250u8, 204u8, 180u8, 134u8, 226u8, 77u8, 206u8, 21u8, 247u8, - 184u8, 68u8, 164u8, 54u8, 230u8, 135u8, 237u8, 226u8, 62u8, 253u8, - 116u8, 47u8, 31u8, 202u8, 110u8, 225u8, 211u8, 105u8, 72u8, 175u8, - 171u8, 169u8, - ], - ) - } - #[doc = "See [`Pallet::set_minimum_backing_votes`]."] - pub fn set_minimum_backing_votes( - &self, - new: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_minimum_backing_votes", - types::SetMinimumBackingVotes { new }, - [ - 55u8, 209u8, 98u8, 156u8, 31u8, 150u8, 61u8, 19u8, 3u8, 55u8, 113u8, - 209u8, 171u8, 143u8, 241u8, 93u8, 178u8, 169u8, 39u8, 241u8, 98u8, - 53u8, 12u8, 148u8, 175u8, 50u8, 164u8, 38u8, 34u8, 183u8, 105u8, 178u8, - ], - ) - } - #[doc = "See [`Pallet::set_node_feature`]."] - pub fn set_node_feature( - &self, - index: ::core::primitive::u8, - value: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_node_feature", - types::SetNodeFeature { index, value }, - [ - 255u8, 19u8, 208u8, 76u8, 122u8, 6u8, 42u8, 182u8, 118u8, 151u8, 245u8, - 80u8, 162u8, 243u8, 45u8, 57u8, 122u8, 148u8, 98u8, 170u8, 157u8, 40u8, - 92u8, 234u8, 12u8, 141u8, 54u8, 80u8, 97u8, 249u8, 115u8, 27u8, - ], - ) - } - #[doc = "See [`Pallet::set_approval_voting_params`]."] - pub fn set_approval_voting_params( - &self, - new: runtime_types::polkadot_primitives::vstaging::ApprovalVotingParams, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Configuration", - "set_approval_voting_params", - types::SetApprovalVotingParams { new }, - [ - 248u8, 81u8, 74u8, 103u8, 28u8, 108u8, 190u8, 177u8, 201u8, 252u8, - 87u8, 236u8, 20u8, 189u8, 192u8, 173u8, 40u8, 160u8, 170u8, 187u8, - 42u8, 108u8, 184u8, 131u8, 120u8, 237u8, 229u8, 240u8, 128u8, 49u8, - 163u8, 11u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The active configuration for the current session."] - pub fn active_config( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::configuration::HostConfiguration< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Configuration", - "ActiveConfig", - vec![], - [ - 241u8, 129u8, 175u8, 69u8, 121u8, 171u8, 135u8, 98u8, 205u8, 87u8, - 244u8, 201u8, 27u8, 143u8, 112u8, 77u8, 83u8, 107u8, 22u8, 120u8, 58u8, - 74u8, 48u8, 72u8, 236u8, 132u8, 248u8, 60u8, 131u8, 107u8, 7u8, 98u8, - ], - ) - } - #[doc = " Pending configuration changes."] - #[doc = ""] - #[doc = " This is a list of configuration changes, each with a session index at which it should"] - #[doc = " be applied."] - #[doc = ""] - #[doc = " The list is sorted ascending by session index. Also, this list can only contain at most"] - #[doc = " 2 items: for the next session and for the `scheduled_session`."] pub fn pending_configs (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < (:: core :: primitive :: u32 , runtime_types :: polkadot_runtime_parachains :: configuration :: HostConfiguration < :: core :: primitive :: u32 > ,) > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "Configuration", - "PendingConfigs", - vec![], - [ - 29u8, 220u8, 218u8, 233u8, 222u8, 28u8, 203u8, 86u8, 0u8, 34u8, 78u8, - 157u8, 206u8, 57u8, 211u8, 206u8, 34u8, 22u8, 126u8, 92u8, 13u8, 71u8, - 156u8, 156u8, 121u8, 2u8, 30u8, 72u8, 37u8, 12u8, 88u8, 210u8, - ], - ) - } - #[doc = " If this is set, then the configuration setters will bypass the consistency checks. This"] - #[doc = " is meant to be used only as the last resort."] - pub fn bypass_consistency_check( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Configuration", - "BypassConsistencyCheck", - vec![], - [ - 109u8, 201u8, 130u8, 189u8, 167u8, 112u8, 171u8, 180u8, 100u8, 146u8, - 23u8, 174u8, 199u8, 230u8, 185u8, 155u8, 178u8, 45u8, 24u8, 66u8, - 211u8, 234u8, 11u8, 103u8, 148u8, 12u8, 247u8, 101u8, 147u8, 18u8, - 11u8, 89u8, - ], - ) - } - } - } - } - pub mod paras_shared { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::shared::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - } - pub struct TransactionApi; - impl TransactionApi {} - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current session index."] - pub fn current_session_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasShared", - "CurrentSessionIndex", - vec![], - [ - 250u8, 164u8, 179u8, 84u8, 199u8, 245u8, 116u8, 48u8, 86u8, 127u8, - 50u8, 117u8, 236u8, 41u8, 107u8, 238u8, 151u8, 236u8, 68u8, 78u8, - 152u8, 5u8, 155u8, 107u8, 69u8, 197u8, 222u8, 94u8, 150u8, 2u8, 31u8, - 191u8, - ], - ) - } - #[doc = " All the validators actively participating in parachain consensus."] - #[doc = " Indices are into the broader validator set."] - pub fn active_validator_indices( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasShared", - "ActiveValidatorIndices", - vec![], - [ - 80u8, 207u8, 217u8, 195u8, 69u8, 151u8, 27u8, 205u8, 227u8, 89u8, 71u8, - 180u8, 91u8, 116u8, 82u8, 193u8, 108u8, 115u8, 40u8, 247u8, 160u8, - 39u8, 85u8, 99u8, 42u8, 87u8, 54u8, 168u8, 230u8, 201u8, 212u8, 39u8, - ], - ) - } - #[doc = " The parachain attestation keys of the validators actively participating in parachain"] - #[doc = " consensus. This should be the same length as `ActiveValidatorIndices`."] - pub fn active_validator_keys( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasShared", - "ActiveValidatorKeys", - vec![], - [ - 155u8, 151u8, 155u8, 8u8, 23u8, 38u8, 91u8, 12u8, 94u8, 69u8, 228u8, - 185u8, 14u8, 219u8, 215u8, 98u8, 235u8, 222u8, 157u8, 180u8, 230u8, - 121u8, 205u8, 167u8, 156u8, 134u8, 180u8, 213u8, 87u8, 61u8, 174u8, - 222u8, - ], - ) - } - #[doc = " All allowed relay-parents."] - pub fn allowed_relay_parents( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::shared::AllowedRelayParentsTracker< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasShared", - "AllowedRelayParents", - vec![], - [ - 12u8, 170u8, 241u8, 120u8, 39u8, 216u8, 90u8, 37u8, 119u8, 212u8, - 161u8, 90u8, 233u8, 124u8, 92u8, 43u8, 212u8, 206u8, 153u8, 103u8, - 156u8, 79u8, 74u8, 7u8, 60u8, 35u8, 86u8, 16u8, 0u8, 224u8, 202u8, - 61u8, - ], - ) - } - } - } - } - pub mod para_inclusion { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_parachains::inclusion::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::inclusion::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - } - pub struct TransactionApi; - impl TransactionApi {} - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was backed. `[candidate, head_data]`"] - pub struct CandidateBacked( - pub runtime_types::polkadot_primitives::v6::CandidateReceipt<::subxt::utils::H256>, - pub runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub runtime_types::polkadot_primitives::v6::CoreIndex, - pub runtime_types::polkadot_primitives::v6::GroupIndex, - ); - impl ::subxt::events::StaticEvent for CandidateBacked { - const PALLET: &'static str = "ParaInclusion"; - const EVENT: &'static str = "CandidateBacked"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate was included. `[candidate, head_data]`"] - pub struct CandidateIncluded( - pub runtime_types::polkadot_primitives::v6::CandidateReceipt<::subxt::utils::H256>, - pub runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub runtime_types::polkadot_primitives::v6::CoreIndex, - pub runtime_types::polkadot_primitives::v6::GroupIndex, - ); - impl ::subxt::events::StaticEvent for CandidateIncluded { - const PALLET: &'static str = "ParaInclusion"; - const EVENT: &'static str = "CandidateIncluded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A candidate timed out. `[candidate, head_data]`"] - pub struct CandidateTimedOut( - pub runtime_types::polkadot_primitives::v6::CandidateReceipt<::subxt::utils::H256>, - pub runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub runtime_types::polkadot_primitives::v6::CoreIndex, - ); - impl ::subxt::events::StaticEvent for CandidateTimedOut { - const PALLET: &'static str = "ParaInclusion"; - const EVENT: &'static str = "CandidateTimedOut"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some upward messages have been received and will be processed."] - pub struct UpwardMessagesReceived { - pub from: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub count: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for UpwardMessagesReceived { - const PALLET: &'static str = "ParaInclusion"; - const EVENT: &'static str = "UpwardMessagesReceived"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The latest bitfield for each validator, referred to by their index in the validator set."] pub fn availability_bitfields_iter (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: AvailabilityBitfieldRecord < :: core :: primitive :: u32 > , () , () , :: subxt :: storage :: address :: Yes >{ - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "AvailabilityBitfields", - vec![], - [ - 163u8, 169u8, 217u8, 160u8, 147u8, 165u8, 186u8, 21u8, 171u8, 177u8, - 74u8, 69u8, 55u8, 205u8, 46u8, 13u8, 253u8, 83u8, 55u8, 190u8, 22u8, - 61u8, 32u8, 209u8, 54u8, 120u8, 187u8, 39u8, 114u8, 70u8, 212u8, 170u8, - ], - ) - } - #[doc = " The latest bitfield for each validator, referred to by their index in the validator set."] pub fn availability_bitfields (& self , _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_primitives :: v6 :: ValidatorIndex > ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: AvailabilityBitfieldRecord < :: core :: primitive :: u32 > , :: subxt :: storage :: address :: Yes , () , () >{ - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "AvailabilityBitfields", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 163u8, 169u8, 217u8, 160u8, 147u8, 165u8, 186u8, 21u8, 171u8, 177u8, - 74u8, 69u8, 55u8, 205u8, 46u8, 13u8, 253u8, 83u8, 55u8, 190u8, 22u8, - 61u8, 32u8, 209u8, 54u8, 120u8, 187u8, 39u8, 114u8, 70u8, 212u8, 170u8, - ], - ) - } - #[doc = " Candidates pending availability by `ParaId`."] pub fn pending_availability_iter (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: CandidatePendingAvailability < :: subxt :: utils :: H256 , :: core :: primitive :: u32 > , () , () , :: subxt :: storage :: address :: Yes >{ - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "PendingAvailability", - vec![], - [ - 164u8, 175u8, 34u8, 182u8, 190u8, 147u8, 42u8, 185u8, 162u8, 130u8, - 33u8, 159u8, 234u8, 242u8, 90u8, 119u8, 2u8, 195u8, 48u8, 150u8, 135u8, - 87u8, 8u8, 142u8, 243u8, 142u8, 57u8, 121u8, 225u8, 218u8, 22u8, 132u8, - ], - ) - } - #[doc = " Candidates pending availability by `ParaId`."] pub fn pending_availability (& self , _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_parachain_primitives :: primitives :: Id > ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: inclusion :: CandidatePendingAvailability < :: subxt :: utils :: H256 , :: core :: primitive :: u32 > , :: subxt :: storage :: address :: Yes , () , () >{ - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "PendingAvailability", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 164u8, 175u8, 34u8, 182u8, 190u8, 147u8, 42u8, 185u8, 162u8, 130u8, - 33u8, 159u8, 234u8, 242u8, 90u8, 119u8, 2u8, 195u8, 48u8, 150u8, 135u8, - 87u8, 8u8, 142u8, 243u8, 142u8, 57u8, 121u8, 225u8, 218u8, 22u8, 132u8, - ], - ) - } - #[doc = " The commitments of candidates pending availability, by `ParaId`."] - pub fn pending_availability_commitments_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::CandidateCommitments< - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "PendingAvailabilityCommitments", - vec![], - [ - 196u8, 210u8, 210u8, 16u8, 246u8, 105u8, 121u8, 178u8, 5u8, 48u8, 40u8, - 183u8, 63u8, 147u8, 48u8, 74u8, 20u8, 83u8, 76u8, 84u8, 41u8, 30u8, - 182u8, 246u8, 164u8, 108u8, 113u8, 16u8, 169u8, 64u8, 97u8, 202u8, - ], - ) - } - #[doc = " The commitments of candidates pending availability, by `ParaId`."] - pub fn pending_availability_commitments( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::CandidateCommitments< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaInclusion", - "PendingAvailabilityCommitments", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 196u8, 210u8, 210u8, 16u8, 246u8, 105u8, 121u8, 178u8, 5u8, 48u8, 40u8, - 183u8, 63u8, 147u8, 48u8, 74u8, 20u8, 83u8, 76u8, 84u8, 41u8, 30u8, - 182u8, 246u8, 164u8, 108u8, 113u8, 16u8, 169u8, 64u8, 97u8, 202u8, - ], - ) - } - } - } - } - pub mod para_inherent { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_parachains::paras_inherent::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::paras_inherent::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Enter { - pub data: runtime_types::polkadot_primitives::v6::InherentData< - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - >, - } - impl ::subxt::blocks::StaticExtrinsic for Enter { - const PALLET: &'static str = "ParaInherent"; - const CALL: &'static str = "enter"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::enter`]."] - pub fn enter( - &self, - data: runtime_types::polkadot_primitives::v6::InherentData< - runtime_types::sp_runtime::generic::header::Header<::core::primitive::u32>, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParaInherent", - "enter", - types::Enter { data }, - [ - 43u8, 145u8, 39u8, 208u8, 205u8, 120u8, 57u8, 196u8, 192u8, 128u8, - 144u8, 83u8, 121u8, 232u8, 191u8, 82u8, 200u8, 129u8, 139u8, 27u8, - 126u8, 177u8, 240u8, 158u8, 232u8, 180u8, 26u8, 180u8, 116u8, 148u8, - 168u8, 41u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Whether the paras inherent was included within this block."] - #[doc = ""] - #[doc = " The `Option<()>` is effectively a `bool`, but it never hits storage in the `None` variant"] - #[doc = " due to the guarantees of FRAME's storage APIs."] - #[doc = ""] - #[doc = " If this is `None` at the end of the block, we panic and render the block invalid."] - pub fn included( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaInherent", - "Included", - vec![], - [ - 108u8, 164u8, 163u8, 34u8, 27u8, 124u8, 202u8, 167u8, 48u8, 130u8, - 155u8, 211u8, 148u8, 130u8, 76u8, 16u8, 5u8, 250u8, 211u8, 174u8, 90u8, - 77u8, 198u8, 153u8, 175u8, 168u8, 131u8, 244u8, 27u8, 93u8, 60u8, 46u8, - ], - ) - } - #[doc = " Scraped on chain data for extracting resolved disputes as well as backing votes."] - pub fn on_chain_votes( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::ScrapedOnChainVotes< - ::subxt::utils::H256, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaInherent", - "OnChainVotes", - vec![], - [ - 65u8, 20u8, 36u8, 37u8, 239u8, 150u8, 32u8, 78u8, 226u8, 88u8, 80u8, - 240u8, 12u8, 156u8, 176u8, 75u8, 231u8, 204u8, 37u8, 24u8, 204u8, - 228u8, 75u8, 235u8, 43u8, 163u8, 174u8, 152u8, 166u8, 17u8, 232u8, - 33u8, - ], - ) - } - } - } - } - pub mod para_scheduler { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " All the validator groups. One for each core. Indices are into `ActiveValidators` - not the"] - #[doc = " broader set of Polkadot validators, but instead just the subset used for parachains during"] - #[doc = " this session."] - #[doc = ""] - #[doc = " Bound: The number of cores is the sum of the numbers of parachains and parathread"] - #[doc = " multiplexers. Reasonably, 100-1000. The dominant factor is the number of validators: safe"] - #[doc = " upper bound at 10k."] - pub fn validator_groups( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - ::std::vec::Vec, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "ValidatorGroups", - vec![], - [ - 129u8, 58u8, 65u8, 112u8, 4u8, 172u8, 167u8, 19u8, 96u8, 154u8, 159u8, - 83u8, 94u8, 125u8, 60u8, 43u8, 60u8, 70u8, 1u8, 58u8, 222u8, 31u8, - 73u8, 53u8, 71u8, 181u8, 49u8, 64u8, 212u8, 90u8, 128u8, 185u8, - ], - ) - } - #[doc = " One entry for each availability core. Entries are `None` if the core is not currently"] - #[doc = " occupied. Can be temporarily `Some` if scheduled but not occupied."] - #[doc = " The i'th parachain belongs to the i'th core, with the remaining cores all being"] - #[doc = " parathread-multiplexers."] - #[doc = ""] - #[doc = " Bounded by the maximum of either of these two values:"] - #[doc = " * The number of parachains and parathread multiplexers"] - #[doc = " * The number of validators divided by `configuration.max_validators_per_core`."] - pub fn availability_cores( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_runtime_parachains::scheduler::pallet::CoreOccupied< - ::core::primitive::u32, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "AvailabilityCores", - vec![], - [ - 250u8, 177u8, 44u8, 237u8, 5u8, 116u8, 135u8, 99u8, 136u8, 209u8, - 181u8, 145u8, 254u8, 57u8, 42u8, 92u8, 236u8, 67u8, 128u8, 171u8, - 200u8, 88u8, 40u8, 31u8, 163u8, 128u8, 15u8, 96u8, 181u8, 224u8, 162u8, - 188u8, - ], - ) - } - #[doc = " The block number where the session start occurred. Used to track how many group rotations"] - #[doc = " have occurred."] - #[doc = ""] - #[doc = " Note that in the context of parachains modules the session change is signaled during"] - #[doc = " the block and enacted at the end of the block (at the finalization stage, to be exact)."] - #[doc = " Thus for all intents and purposes the effect of the session change is observed at the"] - #[doc = " block following the session change, block number of which we save in this storage value."] - pub fn session_start_block( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "SessionStartBlock", - vec![], - [ - 185u8, 76u8, 120u8, 75u8, 154u8, 31u8, 33u8, 243u8, 16u8, 77u8, 100u8, - 249u8, 21u8, 44u8, 199u8, 195u8, 37u8, 9u8, 218u8, 148u8, 222u8, 90u8, - 113u8, 34u8, 152u8, 215u8, 114u8, 134u8, 81u8, 139u8, 164u8, 71u8, - ], - ) - } - #[doc = " One entry for each availability core. The `VecDeque` represents the assignments to be"] - #[doc = " scheduled on that core. `None` is used to signal to not schedule the next para of the core"] - #[doc = " as there is one currently being scheduled. Not using `None` here would overwrite the"] - #[doc = " `CoreState` in the runtime API. The value contained here will not be valid after the end of"] - #[doc = " a block. Runtime APIs should be used to determine scheduled cores/ for the upcoming block."] pub fn claim_queue (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: subxt :: utils :: KeyedVec < runtime_types :: polkadot_primitives :: v6 :: CoreIndex , :: std :: vec :: Vec < runtime_types :: polkadot_runtime_parachains :: scheduler :: pallet :: ParasEntry < :: core :: primitive :: u32 > > > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "ParaScheduler", - "ClaimQueue", - vec![], - [ - 192u8, 65u8, 227u8, 114u8, 125u8, 169u8, 134u8, 70u8, 201u8, 99u8, - 246u8, 23u8, 0u8, 143u8, 163u8, 87u8, 216u8, 1u8, 184u8, 124u8, 23u8, - 180u8, 132u8, 143u8, 202u8, 81u8, 144u8, 242u8, 15u8, 141u8, 124u8, - 126u8, - ], - ) - } - } - } - } - pub mod paras { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_parachains::paras::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::paras::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetCurrentCode { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub new_code: - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSetCurrentCode { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "force_set_current_code"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetCurrentHead { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub new_head: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSetCurrentHead { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "force_set_current_head"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceScheduleCodeUpgrade { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub new_code: - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - pub relay_parent_number: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceScheduleCodeUpgrade { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "force_schedule_code_upgrade"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceNoteNewHead { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub new_head: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - } - impl ::subxt::blocks::StaticExtrinsic for ForceNoteNewHead { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "force_note_new_head"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceQueueAction { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for ForceQueueAction { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "force_queue_action"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddTrustedValidationCode { - pub validation_code: - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - } - impl ::subxt::blocks::StaticExtrinsic for AddTrustedValidationCode { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "add_trusted_validation_code"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PokeUnusedValidationCode { pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } - impl ::subxt::blocks::StaticExtrinsic for PokeUnusedValidationCode { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "poke_unused_validation_code"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IncludePvfCheckStatement { - pub stmt: runtime_types::polkadot_primitives::v6::PvfCheckStatement, - pub signature: runtime_types::polkadot_primitives::v6::validator_app::Signature, - } - impl ::subxt::blocks::StaticExtrinsic for IncludePvfCheckStatement { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "include_pvf_check_statement"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetMostRecentContext { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub context: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSetMostRecentContext { - const PALLET: &'static str = "Paras"; - const CALL: &'static str = "force_set_most_recent_context"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::force_set_current_code`]."] - pub fn force_set_current_code( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - new_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_set_current_code", - types::ForceSetCurrentCode { para, new_code }, - [ - 204u8, 159u8, 184u8, 235u8, 65u8, 225u8, 223u8, 130u8, 139u8, 140u8, - 219u8, 58u8, 142u8, 253u8, 236u8, 239u8, 148u8, 190u8, 27u8, 234u8, - 165u8, 125u8, 129u8, 235u8, 98u8, 33u8, 172u8, 71u8, 90u8, 41u8, 182u8, - 80u8, - ], - ) - } - #[doc = "See [`Pallet::force_set_current_head`]."] - pub fn force_set_current_head( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - new_head: runtime_types::polkadot_parachain_primitives::primitives::HeadData, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_set_current_head", - types::ForceSetCurrentHead { para, new_head }, - [ - 184u8, 247u8, 184u8, 248u8, 89u8, 64u8, 18u8, 193u8, 254u8, 71u8, - 220u8, 195u8, 124u8, 212u8, 178u8, 169u8, 155u8, 189u8, 11u8, 135u8, - 247u8, 39u8, 253u8, 196u8, 111u8, 242u8, 189u8, 91u8, 226u8, 219u8, - 232u8, 238u8, - ], - ) - } - #[doc = "See [`Pallet::force_schedule_code_upgrade`]."] - pub fn force_schedule_code_upgrade( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - new_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode, - relay_parent_number: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_schedule_code_upgrade", - types::ForceScheduleCodeUpgrade { para, new_code, relay_parent_number }, - [ - 131u8, 179u8, 138u8, 151u8, 167u8, 191u8, 2u8, 68u8, 85u8, 111u8, - 166u8, 65u8, 67u8, 52u8, 201u8, 41u8, 132u8, 128u8, 35u8, 177u8, 91u8, - 185u8, 114u8, 2u8, 123u8, 133u8, 164u8, 121u8, 170u8, 243u8, 223u8, - 61u8, - ], - ) - } - #[doc = "See [`Pallet::force_note_new_head`]."] - pub fn force_note_new_head( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - new_head: runtime_types::polkadot_parachain_primitives::primitives::HeadData, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_note_new_head", - types::ForceNoteNewHead { para, new_head }, - [ - 215u8, 12u8, 228u8, 208u8, 7u8, 24u8, 207u8, 60u8, 183u8, 241u8, 212u8, - 203u8, 139u8, 149u8, 9u8, 236u8, 77u8, 15u8, 242u8, 70u8, 62u8, 204u8, - 187u8, 91u8, 110u8, 73u8, 210u8, 2u8, 8u8, 118u8, 182u8, 171u8, - ], - ) - } - #[doc = "See [`Pallet::force_queue_action`]."] - pub fn force_queue_action( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_queue_action", - types::ForceQueueAction { para }, - [ - 112u8, 247u8, 239u8, 8u8, 91u8, 23u8, 111u8, 84u8, 179u8, 61u8, 235u8, - 49u8, 140u8, 110u8, 40u8, 226u8, 150u8, 253u8, 146u8, 193u8, 136u8, - 133u8, 100u8, 127u8, 38u8, 165u8, 159u8, 17u8, 205u8, 190u8, 6u8, - 117u8, - ], - ) - } - #[doc = "See [`Pallet::add_trusted_validation_code`]."] - pub fn add_trusted_validation_code( - &self, - validation_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "add_trusted_validation_code", - types::AddTrustedValidationCode { validation_code }, - [ - 196u8, 123u8, 133u8, 223u8, 3u8, 205u8, 127u8, 23u8, 82u8, 201u8, - 107u8, 47u8, 23u8, 75u8, 139u8, 198u8, 178u8, 171u8, 160u8, 61u8, - 132u8, 250u8, 76u8, 110u8, 3u8, 144u8, 90u8, 253u8, 89u8, 141u8, 162u8, - 135u8, - ], - ) - } - #[doc = "See [`Pallet::poke_unused_validation_code`]."] - pub fn poke_unused_validation_code( - &self, - validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "poke_unused_validation_code", - types::PokeUnusedValidationCode { validation_code_hash }, - [ - 180u8, 53u8, 213u8, 27u8, 150u8, 195u8, 50u8, 1u8, 62u8, 246u8, 244u8, - 229u8, 115u8, 202u8, 55u8, 140u8, 108u8, 28u8, 245u8, 66u8, 165u8, - 128u8, 105u8, 221u8, 7u8, 87u8, 242u8, 19u8, 88u8, 132u8, 36u8, 32u8, - ], - ) - } - #[doc = "See [`Pallet::include_pvf_check_statement`]."] - pub fn include_pvf_check_statement( - &self, - stmt: runtime_types::polkadot_primitives::v6::PvfCheckStatement, - signature: runtime_types::polkadot_primitives::v6::validator_app::Signature, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "include_pvf_check_statement", - types::IncludePvfCheckStatement { stmt, signature }, - [ - 104u8, 113u8, 121u8, 186u8, 41u8, 70u8, 254u8, 44u8, 207u8, 94u8, 61u8, - 148u8, 106u8, 240u8, 165u8, 223u8, 231u8, 190u8, 157u8, 97u8, 55u8, - 90u8, 229u8, 112u8, 129u8, 224u8, 29u8, 180u8, 242u8, 203u8, 195u8, - 19u8, - ], - ) - } - #[doc = "See [`Pallet::force_set_most_recent_context`]."] - pub fn force_set_most_recent_context( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - context: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Paras", - "force_set_most_recent_context", - types::ForceSetMostRecentContext { para, context }, - [ - 243u8, 17u8, 20u8, 229u8, 91u8, 87u8, 42u8, 159u8, 119u8, 61u8, 201u8, - 246u8, 79u8, 151u8, 209u8, 183u8, 35u8, 31u8, 2u8, 210u8, 187u8, 105u8, - 66u8, 106u8, 119u8, 241u8, 63u8, 63u8, 233u8, 68u8, 244u8, 137u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_parachains::paras::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Current code has been updated for a Para. `para_id`"] - pub struct CurrentCodeUpdated( - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for CurrentCodeUpdated { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "CurrentCodeUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Current head has been updated for a Para. `para_id`"] - pub struct CurrentHeadUpdated( - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for CurrentHeadUpdated { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "CurrentHeadUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A code upgrade has been scheduled for a Para. `para_id`"] - pub struct CodeUpgradeScheduled( - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for CodeUpgradeScheduled { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "CodeUpgradeScheduled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new head has been noted for a Para. `para_id`"] - pub struct NewHeadNoted( - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for NewHeadNoted { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "NewHeadNoted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A para has been queued to execute pending actions. `para_id`"] - pub struct ActionQueued( - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - pub ::core::primitive::u32, - ); - impl ::subxt::events::StaticEvent for ActionQueued { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "ActionQueued"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given para either initiated or subscribed to a PVF check for the given validation"] - #[doc = "code. `code_hash` `para_id`"] - pub struct PvfCheckStarted( - pub runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for PvfCheckStarted { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "PvfCheckStarted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given validation code was accepted by the PVF pre-checking vote."] - #[doc = "`code_hash` `para_id`"] - pub struct PvfCheckAccepted( - pub runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for PvfCheckAccepted { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "PvfCheckAccepted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The given validation code was rejected by the PVF pre-checking vote."] - #[doc = "`code_hash` `para_id`"] - pub struct PvfCheckRejected( - pub runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for PvfCheckRejected { - const PALLET: &'static str = "Paras"; - const EVENT: &'static str = "PvfCheckRejected"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " All currently active PVF pre-checking votes."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no PVF pre-checking votes that exists in list but not in the set and vice versa."] - pub fn pvf_active_vote_map_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::PvfCheckActiveVoteState< - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PvfActiveVoteMap", - vec![], - [ - 72u8, 55u8, 139u8, 104u8, 161u8, 63u8, 114u8, 153u8, 16u8, 221u8, 60u8, - 88u8, 52u8, 207u8, 123u8, 193u8, 11u8, 30u8, 19u8, 39u8, 231u8, 39u8, - 251u8, 44u8, 248u8, 129u8, 181u8, 173u8, 248u8, 89u8, 43u8, 106u8, - ], - ) - } - #[doc = " All currently active PVF pre-checking votes."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no PVF pre-checking votes that exists in list but not in the set and vice versa."] - pub fn pvf_active_vote_map( - &self, - _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::PvfCheckActiveVoteState< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PvfActiveVoteMap", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 72u8, 55u8, 139u8, 104u8, 161u8, 63u8, 114u8, 153u8, 16u8, 221u8, 60u8, - 88u8, 52u8, 207u8, 123u8, 193u8, 11u8, 30u8, 19u8, 39u8, 231u8, 39u8, - 251u8, 44u8, 248u8, 129u8, 181u8, 173u8, 248u8, 89u8, 43u8, 106u8, - ], - ) - } - #[doc = " The list of all currently active PVF votes. Auxiliary to `PvfActiveVoteMap`."] pub fn pvf_active_vote_list (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "Paras", - "PvfActiveVoteList", - vec![], - [ - 172u8, 215u8, 137u8, 191u8, 52u8, 104u8, 106u8, 118u8, 134u8, 82u8, - 137u8, 6u8, 175u8, 158u8, 58u8, 230u8, 231u8, 152u8, 195u8, 17u8, 51u8, - 133u8, 10u8, 205u8, 212u8, 6u8, 24u8, 59u8, 114u8, 222u8, 96u8, 42u8, - ], - ) - } - #[doc = " All lease holding parachains. Ordered ascending by `ParaId`. On demand parachains are not"] - #[doc = " included."] - #[doc = ""] - #[doc = " Consider using the [`ParachainsCache`] type of modifying."] - pub fn parachains( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "Parachains", - vec![], - [ - 242u8, 228u8, 175u8, 107u8, 242u8, 39u8, 52u8, 181u8, 32u8, 171u8, - 21u8, 169u8, 204u8, 19u8, 21u8, 217u8, 121u8, 239u8, 218u8, 252u8, - 80u8, 188u8, 119u8, 157u8, 235u8, 218u8, 221u8, 113u8, 0u8, 108u8, - 245u8, 210u8, - ], - ) - } - #[doc = " The current lifecycle of a all known Para IDs."] - pub fn para_lifecycles_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaLifecycle, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "ParaLifecycles", - vec![], - [ - 2u8, 203u8, 32u8, 194u8, 76u8, 227u8, 250u8, 9u8, 168u8, 201u8, 171u8, - 180u8, 18u8, 169u8, 206u8, 183u8, 48u8, 189u8, 204u8, 192u8, 237u8, - 233u8, 156u8, 255u8, 102u8, 22u8, 101u8, 110u8, 194u8, 55u8, 118u8, - 81u8, - ], - ) - } - #[doc = " The current lifecycle of a all known Para IDs."] - pub fn para_lifecycles( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaLifecycle, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "ParaLifecycles", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 2u8, 203u8, 32u8, 194u8, 76u8, 227u8, 250u8, 9u8, 168u8, 201u8, 171u8, - 180u8, 18u8, 169u8, 206u8, 183u8, 48u8, 189u8, 204u8, 192u8, 237u8, - 233u8, 156u8, 255u8, 102u8, 22u8, 101u8, 110u8, 194u8, 55u8, 118u8, - 81u8, - ], - ) - } - #[doc = " The head-data of every registered para."] - pub fn heads_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "Heads", - vec![], - [ - 222u8, 116u8, 180u8, 190u8, 172u8, 192u8, 174u8, 132u8, 225u8, 180u8, - 119u8, 90u8, 5u8, 39u8, 92u8, 230u8, 116u8, 202u8, 92u8, 99u8, 135u8, - 201u8, 10u8, 58u8, 55u8, 211u8, 209u8, 86u8, 93u8, 133u8, 99u8, 139u8, - ], - ) - } - #[doc = " The head-data of every registered para."] - pub fn heads( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "Heads", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 222u8, 116u8, 180u8, 190u8, 172u8, 192u8, 174u8, 132u8, 225u8, 180u8, - 119u8, 90u8, 5u8, 39u8, 92u8, 230u8, 116u8, 202u8, 92u8, 99u8, 135u8, - 201u8, 10u8, 58u8, 55u8, 211u8, 209u8, 86u8, 93u8, 133u8, 99u8, 139u8, - ], - ) - } - #[doc = " The context (relay-chain block number) of the most recent parachain head."] - pub fn most_recent_context_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "MostRecentContext", - vec![], - [ - 196u8, 150u8, 125u8, 121u8, 196u8, 182u8, 2u8, 5u8, 244u8, 170u8, 75u8, - 57u8, 162u8, 8u8, 104u8, 94u8, 114u8, 32u8, 192u8, 236u8, 120u8, 91u8, - 84u8, 118u8, 216u8, 143u8, 61u8, 208u8, 57u8, 180u8, 216u8, 243u8, - ], - ) - } - #[doc = " The context (relay-chain block number) of the most recent parachain head."] - pub fn most_recent_context( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "MostRecentContext", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 196u8, 150u8, 125u8, 121u8, 196u8, 182u8, 2u8, 5u8, 244u8, 170u8, 75u8, - 57u8, 162u8, 8u8, 104u8, 94u8, 114u8, 32u8, 192u8, 236u8, 120u8, 91u8, - 84u8, 118u8, 216u8, 143u8, 61u8, 208u8, 57u8, 180u8, 216u8, 243u8, - ], - ) - } - #[doc = " The validation code hash of every live para."] - #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn current_code_hash_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CurrentCodeHash", - vec![], - [ - 251u8, 100u8, 30u8, 46u8, 191u8, 60u8, 45u8, 221u8, 218u8, 20u8, 154u8, - 233u8, 211u8, 198u8, 151u8, 195u8, 99u8, 210u8, 126u8, 165u8, 240u8, - 129u8, 183u8, 252u8, 104u8, 119u8, 38u8, 155u8, 150u8, 198u8, 127u8, - 103u8, - ], - ) - } - #[doc = " The validation code hash of every live para."] - #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn current_code_hash( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CurrentCodeHash", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 251u8, 100u8, 30u8, 46u8, 191u8, 60u8, 45u8, 221u8, 218u8, 20u8, 154u8, - 233u8, 211u8, 198u8, 151u8, 195u8, 99u8, 210u8, 126u8, 165u8, 240u8, - 129u8, 183u8, 252u8, 104u8, 119u8, 38u8, 155u8, 150u8, 198u8, 127u8, - 103u8, - ], - ) - } - #[doc = " Actual past code hash, indicated by the para id as well as the block number at which it"] - #[doc = " became outdated."] - #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn past_code_hash_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeHash", - vec![], - [ - 73u8, 209u8, 188u8, 36u8, 127u8, 42u8, 171u8, 136u8, 29u8, 126u8, - 220u8, 209u8, 230u8, 22u8, 12u8, 63u8, 8u8, 102u8, 45u8, 158u8, 178u8, - 232u8, 8u8, 6u8, 71u8, 188u8, 140u8, 41u8, 10u8, 215u8, 22u8, 153u8, - ], - ) - } - #[doc = " Actual past code hash, indicated by the para id as well as the block number at which it"] - #[doc = " became outdated."] - #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn past_code_hash_iter1( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeHash", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 73u8, 209u8, 188u8, 36u8, 127u8, 42u8, 171u8, 136u8, 29u8, 126u8, - 220u8, 209u8, 230u8, 22u8, 12u8, 63u8, 8u8, 102u8, 45u8, 158u8, 178u8, - 232u8, 8u8, 6u8, 71u8, 188u8, 140u8, 41u8, 10u8, 215u8, 22u8, 153u8, - ], - ) - } - #[doc = " Actual past code hash, indicated by the para id as well as the block number at which it"] - #[doc = " became outdated."] - #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn past_code_hash( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeHash", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 73u8, 209u8, 188u8, 36u8, 127u8, 42u8, 171u8, 136u8, 29u8, 126u8, - 220u8, 209u8, 230u8, 22u8, 12u8, 63u8, 8u8, 102u8, 45u8, 158u8, 178u8, - 232u8, 8u8, 6u8, 71u8, 188u8, 140u8, 41u8, 10u8, 215u8, 22u8, 153u8, - ], - ) - } - #[doc = " Past code of parachains. The parachains themselves may not be registered anymore,"] - #[doc = " but we also keep their code on-chain for the same amount of time as outdated code"] - #[doc = " to keep it available for approval checkers."] - pub fn past_code_meta_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaPastCodeMeta< - ::core::primitive::u32, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeMeta", - vec![], - [ - 233u8, 47u8, 137u8, 174u8, 98u8, 64u8, 11u8, 75u8, 93u8, 222u8, 78u8, - 58u8, 66u8, 245u8, 151u8, 39u8, 144u8, 36u8, 84u8, 176u8, 239u8, 183u8, - 197u8, 176u8, 158u8, 139u8, 121u8, 189u8, 29u8, 244u8, 229u8, 73u8, - ], - ) - } - #[doc = " Past code of parachains. The parachains themselves may not be registered anymore,"] - #[doc = " but we also keep their code on-chain for the same amount of time as outdated code"] - #[doc = " to keep it available for approval checkers."] - pub fn past_code_meta( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaPastCodeMeta< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodeMeta", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 233u8, 47u8, 137u8, 174u8, 98u8, 64u8, 11u8, 75u8, 93u8, 222u8, 78u8, - 58u8, 66u8, 245u8, 151u8, 39u8, 144u8, 36u8, 84u8, 176u8, 239u8, 183u8, - 197u8, 176u8, 158u8, 139u8, 121u8, 189u8, 29u8, 244u8, 229u8, 73u8, - ], - ) - } - #[doc = " Which paras have past code that needs pruning and the relay-chain block at which the code"] - #[doc = " was replaced. Note that this is the actual height of the included block, not the expected"] - #[doc = " height at which the code upgrade would be applied, although they may be equal."] - #[doc = " This is to ensure the entire acceptance period is covered, not an offset acceptance period"] - #[doc = " starting from the time at which the parachain perceives a code upgrade as having occurred."] - #[doc = " Multiple entries for a single para are permitted. Ordered ascending by block number."] - pub fn past_code_pruning( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "PastCodePruning", - vec![], - [ - 67u8, 190u8, 51u8, 133u8, 173u8, 24u8, 151u8, 111u8, 108u8, 152u8, - 106u8, 18u8, 29u8, 80u8, 104u8, 120u8, 91u8, 138u8, 209u8, 49u8, 255u8, - 211u8, 53u8, 195u8, 61u8, 188u8, 183u8, 53u8, 37u8, 230u8, 53u8, 183u8, - ], - ) - } - #[doc = " The block number at which the planned code change is expected for a para."] - #[doc = " The change will be applied after the first parablock for this ID included which executes"] - #[doc = " in the context of a relay chain block with a number >= `expected_at`."] - pub fn future_code_upgrades_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "FutureCodeUpgrades", - vec![], - [ - 163u8, 168u8, 23u8, 138u8, 198u8, 70u8, 135u8, 221u8, 167u8, 187u8, - 15u8, 144u8, 228u8, 8u8, 138u8, 125u8, 101u8, 154u8, 11u8, 74u8, 173u8, - 167u8, 17u8, 97u8, 240u8, 6u8, 20u8, 161u8, 25u8, 111u8, 242u8, 9u8, - ], - ) - } - #[doc = " The block number at which the planned code change is expected for a para."] - #[doc = " The change will be applied after the first parablock for this ID included which executes"] - #[doc = " in the context of a relay chain block with a number >= `expected_at`."] - pub fn future_code_upgrades( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "FutureCodeUpgrades", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 163u8, 168u8, 23u8, 138u8, 198u8, 70u8, 135u8, 221u8, 167u8, 187u8, - 15u8, 144u8, 228u8, 8u8, 138u8, 125u8, 101u8, 154u8, 11u8, 74u8, 173u8, - 167u8, 17u8, 97u8, 240u8, 6u8, 20u8, 161u8, 25u8, 111u8, 242u8, 9u8, - ], - ) - } - #[doc = " The actual future code hash of a para."] - #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn future_code_hash_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "FutureCodeHash", - vec![], - [ - 62u8, 238u8, 183u8, 12u8, 197u8, 119u8, 163u8, 239u8, 192u8, 228u8, - 110u8, 58u8, 128u8, 223u8, 32u8, 137u8, 109u8, 127u8, 41u8, 83u8, 91u8, - 98u8, 156u8, 118u8, 96u8, 147u8, 16u8, 31u8, 5u8, 92u8, 227u8, 230u8, - ], - ) - } - #[doc = " The actual future code hash of a para."] - #[doc = ""] - #[doc = " Corresponding code can be retrieved with [`CodeByHash`]."] - pub fn future_code_hash( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCodeHash, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "FutureCodeHash", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 62u8, 238u8, 183u8, 12u8, 197u8, 119u8, 163u8, 239u8, 192u8, 228u8, - 110u8, 58u8, 128u8, 223u8, 32u8, 137u8, 109u8, 127u8, 41u8, 83u8, 91u8, - 98u8, 156u8, 118u8, 96u8, 147u8, 16u8, 31u8, 5u8, 92u8, 227u8, 230u8, - ], - ) - } - #[doc = " This is used by the relay-chain to communicate to a parachain a go-ahead with in the upgrade"] - #[doc = " procedure."] - #[doc = ""] - #[doc = " This value is absent when there are no upgrades scheduled or during the time the relay chain"] - #[doc = " performs the checks. It is set at the first relay-chain block when the corresponding"] - #[doc = " parachain can switch its upgrade function. As soon as the parachain's block is included, the"] - #[doc = " value gets reset to `None`."] - #[doc = ""] - #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] - #[doc = " the format will require migration of parachains."] - pub fn upgrade_go_ahead_signal_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::UpgradeGoAhead, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeGoAheadSignal", - vec![], - [ - 41u8, 80u8, 120u8, 6u8, 98u8, 85u8, 36u8, 37u8, 170u8, 189u8, 56u8, - 127u8, 155u8, 180u8, 112u8, 195u8, 135u8, 214u8, 235u8, 87u8, 197u8, - 247u8, 125u8, 26u8, 232u8, 82u8, 250u8, 90u8, 126u8, 106u8, 62u8, - 217u8, - ], - ) - } - #[doc = " This is used by the relay-chain to communicate to a parachain a go-ahead with in the upgrade"] - #[doc = " procedure."] - #[doc = ""] - #[doc = " This value is absent when there are no upgrades scheduled or during the time the relay chain"] - #[doc = " performs the checks. It is set at the first relay-chain block when the corresponding"] - #[doc = " parachain can switch its upgrade function. As soon as the parachain's block is included, the"] - #[doc = " value gets reset to `None`."] - #[doc = ""] - #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] - #[doc = " the format will require migration of parachains."] - pub fn upgrade_go_ahead_signal( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::UpgradeGoAhead, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeGoAheadSignal", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 41u8, 80u8, 120u8, 6u8, 98u8, 85u8, 36u8, 37u8, 170u8, 189u8, 56u8, - 127u8, 155u8, 180u8, 112u8, 195u8, 135u8, 214u8, 235u8, 87u8, 197u8, - 247u8, 125u8, 26u8, 232u8, 82u8, 250u8, 90u8, 126u8, 106u8, 62u8, - 217u8, - ], - ) - } - #[doc = " This is used by the relay-chain to communicate that there are restrictions for performing"] - #[doc = " an upgrade for this parachain."] - #[doc = ""] - #[doc = " This may be a because the parachain waits for the upgrade cooldown to expire. Another"] - #[doc = " potential use case is when we want to perform some maintenance (such as storage migration)"] - #[doc = " we could restrict upgrades to make the process simpler."] - #[doc = ""] - #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] - #[doc = " the format will require migration of parachains."] - pub fn upgrade_restriction_signal_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::UpgradeRestriction, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeRestrictionSignal", - vec![], - [ - 158u8, 105u8, 62u8, 252u8, 149u8, 145u8, 34u8, 92u8, 119u8, 204u8, - 46u8, 96u8, 117u8, 183u8, 134u8, 20u8, 172u8, 243u8, 145u8, 113u8, - 74u8, 119u8, 96u8, 107u8, 129u8, 109u8, 96u8, 143u8, 77u8, 14u8, 56u8, - 117u8, - ], - ) - } - #[doc = " This is used by the relay-chain to communicate that there are restrictions for performing"] - #[doc = " an upgrade for this parachain."] - #[doc = ""] - #[doc = " This may be a because the parachain waits for the upgrade cooldown to expire. Another"] - #[doc = " potential use case is when we want to perform some maintenance (such as storage migration)"] - #[doc = " we could restrict upgrades to make the process simpler."] - #[doc = ""] - #[doc = " NOTE that this field is used by parachains via merkle storage proofs, therefore changing"] - #[doc = " the format will require migration of parachains."] - pub fn upgrade_restriction_signal( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::UpgradeRestriction, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeRestrictionSignal", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 158u8, 105u8, 62u8, 252u8, 149u8, 145u8, 34u8, 92u8, 119u8, 204u8, - 46u8, 96u8, 117u8, 183u8, 134u8, 20u8, 172u8, 243u8, 145u8, 113u8, - 74u8, 119u8, 96u8, 107u8, 129u8, 109u8, 96u8, 143u8, 77u8, 14u8, 56u8, - 117u8, - ], - ) - } - #[doc = " The list of parachains that are awaiting for their upgrade restriction to cooldown."] - #[doc = ""] - #[doc = " Ordered ascending by block number."] - pub fn upgrade_cooldowns( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpgradeCooldowns", - vec![], - [ - 180u8, 197u8, 115u8, 209u8, 126u8, 120u8, 133u8, 54u8, 232u8, 192u8, - 47u8, 17u8, 21u8, 8u8, 231u8, 67u8, 1u8, 89u8, 127u8, 38u8, 179u8, - 190u8, 169u8, 110u8, 20u8, 92u8, 139u8, 227u8, 26u8, 59u8, 245u8, - 174u8, - ], - ) - } - #[doc = " The list of upcoming code upgrades. Each item is a pair of which para performs a code"] - #[doc = " upgrade and at which relay-chain block it is expected at."] - #[doc = ""] - #[doc = " Ordered ascending by block number."] - pub fn upcoming_upgrades( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpcomingUpgrades", - vec![], - [ - 38u8, 195u8, 15u8, 56u8, 225u8, 199u8, 105u8, 84u8, 128u8, 51u8, 44u8, - 248u8, 237u8, 32u8, 36u8, 72u8, 77u8, 137u8, 124u8, 88u8, 242u8, 185u8, - 50u8, 148u8, 216u8, 156u8, 209u8, 101u8, 207u8, 127u8, 66u8, 95u8, - ], - ) - } - #[doc = " The actions to perform during the start of a specific session index."] - pub fn actions_queue_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "ActionsQueue", - vec![], - [ - 13u8, 25u8, 129u8, 203u8, 95u8, 206u8, 254u8, 240u8, 170u8, 209u8, - 55u8, 117u8, 70u8, 220u8, 139u8, 102u8, 9u8, 229u8, 139u8, 120u8, 67u8, - 246u8, 214u8, 59u8, 81u8, 116u8, 54u8, 67u8, 129u8, 32u8, 67u8, 92u8, - ], - ) - } - #[doc = " The actions to perform during the start of a specific session index."] - pub fn actions_queue( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "ActionsQueue", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 13u8, 25u8, 129u8, 203u8, 95u8, 206u8, 254u8, 240u8, 170u8, 209u8, - 55u8, 117u8, 70u8, 220u8, 139u8, 102u8, 9u8, 229u8, 139u8, 120u8, 67u8, - 246u8, 214u8, 59u8, 81u8, 116u8, 54u8, 67u8, 129u8, 32u8, 67u8, 92u8, - ], - ) - } - #[doc = " Upcoming paras instantiation arguments."] - #[doc = ""] - #[doc = " NOTE that after PVF pre-checking is enabled the para genesis arg will have it's code set"] - #[doc = " to empty. Instead, the code will be saved into the storage right away via `CodeByHash`."] - pub fn upcoming_paras_genesis_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpcomingParasGenesis", - vec![], - [ - 215u8, 121u8, 106u8, 13u8, 102u8, 47u8, 129u8, 221u8, 153u8, 91u8, - 23u8, 94u8, 11u8, 39u8, 19u8, 180u8, 136u8, 136u8, 254u8, 152u8, 250u8, - 150u8, 40u8, 87u8, 135u8, 121u8, 219u8, 151u8, 111u8, 35u8, 43u8, - 195u8, - ], - ) - } - #[doc = " Upcoming paras instantiation arguments."] - #[doc = ""] - #[doc = " NOTE that after PVF pre-checking is enabled the para genesis arg will have it's code set"] - #[doc = " to empty. Instead, the code will be saved into the storage right away via `CodeByHash`."] - pub fn upcoming_paras_genesis( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "UpcomingParasGenesis", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 215u8, 121u8, 106u8, 13u8, 102u8, 47u8, 129u8, 221u8, 153u8, 91u8, - 23u8, 94u8, 11u8, 39u8, 19u8, 180u8, 136u8, 136u8, 254u8, 152u8, 250u8, - 150u8, 40u8, 87u8, 135u8, 121u8, 219u8, 151u8, 111u8, 35u8, 43u8, - 195u8, - ], - ) - } - #[doc = " The number of reference on the validation code in [`CodeByHash`] storage."] - pub fn code_by_hash_refs_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CodeByHashRefs", - vec![], - [ - 47u8, 50u8, 103u8, 161u8, 130u8, 252u8, 157u8, 35u8, 174u8, 37u8, - 102u8, 60u8, 195u8, 30u8, 164u8, 203u8, 67u8, 129u8, 107u8, 181u8, - 166u8, 205u8, 230u8, 91u8, 36u8, 187u8, 253u8, 150u8, 39u8, 168u8, - 223u8, 16u8, - ], - ) - } - #[doc = " The number of reference on the validation code in [`CodeByHash`] storage."] - pub fn code_by_hash_refs( - &self, - _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CodeByHashRefs", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 47u8, 50u8, 103u8, 161u8, 130u8, 252u8, 157u8, 35u8, 174u8, 37u8, - 102u8, 60u8, 195u8, 30u8, 164u8, 203u8, 67u8, 129u8, 107u8, 181u8, - 166u8, 205u8, 230u8, 91u8, 36u8, 187u8, 253u8, 150u8, 39u8, 168u8, - 223u8, 16u8, - ], - ) - } - #[doc = " Validation code stored by its hash."] - #[doc = ""] - #[doc = " This storage is consistent with [`FutureCodeHash`], [`CurrentCodeHash`] and"] - #[doc = " [`PastCodeHash`]."] - pub fn code_by_hash_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CodeByHash", - vec![], - [ - 155u8, 102u8, 73u8, 180u8, 127u8, 211u8, 181u8, 44u8, 56u8, 235u8, - 49u8, 4u8, 25u8, 213u8, 116u8, 200u8, 232u8, 203u8, 190u8, 90u8, 93u8, - 6u8, 57u8, 227u8, 240u8, 92u8, 157u8, 129u8, 3u8, 148u8, 45u8, 143u8, - ], - ) - } - #[doc = " Validation code stored by its hash."] - #[doc = ""] - #[doc = " This storage is consistent with [`FutureCodeHash`], [`CurrentCodeHash`] and"] - #[doc = " [`PastCodeHash`]."] - pub fn code_by_hash( - &self, - _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Paras", - "CodeByHash", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 155u8, 102u8, 73u8, 180u8, 127u8, 211u8, 181u8, 44u8, 56u8, 235u8, - 49u8, 4u8, 25u8, 213u8, 116u8, 200u8, 232u8, 203u8, 190u8, 90u8, 93u8, - 6u8, 57u8, 227u8, 240u8, 92u8, 157u8, 129u8, 3u8, 148u8, 45u8, 143u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - pub fn unsigned_priority( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Paras", - "UnsignedPriority", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - } - } - } - pub mod initializer { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::initializer::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceApprove { - pub up_to: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceApprove { - const PALLET: &'static str = "Initializer"; - const CALL: &'static str = "force_approve"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::force_approve`]."] - pub fn force_approve( - &self, - up_to: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Initializer", - "force_approve", - types::ForceApprove { up_to }, - [ - 232u8, 166u8, 27u8, 229u8, 157u8, 240u8, 18u8, 137u8, 5u8, 159u8, - 179u8, 239u8, 218u8, 41u8, 181u8, 42u8, 159u8, 243u8, 246u8, 214u8, - 227u8, 77u8, 58u8, 70u8, 241u8, 114u8, 175u8, 124u8, 77u8, 102u8, - 105u8, 199u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Whether the parachains modules have been initialized within this block."] - #[doc = ""] - #[doc = " Semantically a `bool`, but this guarantees it should never hit the trie,"] - #[doc = " as this is cleared in `on_finalize` and Frame optimizes `None` values to be empty values."] - #[doc = ""] - #[doc = " As a `bool`, `set(false)` and `remove()` both lead to the next `get()` being false, but one"] - #[doc = " of them writes to the trie and one does not. This confusion makes `Option<()>` more suitable"] - #[doc = " for the semantics of this variable."] - pub fn has_initialized( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Initializer", - "HasInitialized", - vec![], - [ - 156u8, 208u8, 212u8, 86u8, 105u8, 148u8, 252u8, 11u8, 140u8, 67u8, - 231u8, 86u8, 1u8, 147u8, 178u8, 79u8, 27u8, 249u8, 137u8, 103u8, 178u8, - 50u8, 114u8, 157u8, 239u8, 86u8, 89u8, 233u8, 86u8, 58u8, 37u8, 67u8, - ], - ) - } - #[doc = " Buffered session changes along with the block number at which they should be applied."] - #[doc = ""] - #[doc = " Typically this will be empty or one element long. Apart from that this item never hits"] - #[doc = " the storage."] - #[doc = ""] - #[doc = " However this is a `Vec` regardless to handle various edge cases that may occur at runtime"] - #[doc = " upgrade boundaries or if governance intervenes."] pub fn buffered_session_changes (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < runtime_types :: polkadot_runtime_parachains :: initializer :: BufferedSessionChange > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "Initializer", - "BufferedSessionChanges", - vec![], - [ - 99u8, 153u8, 100u8, 11u8, 28u8, 62u8, 163u8, 239u8, 177u8, 55u8, 151u8, - 242u8, 227u8, 59u8, 176u8, 10u8, 227u8, 51u8, 252u8, 191u8, 233u8, - 36u8, 1u8, 131u8, 255u8, 56u8, 6u8, 65u8, 5u8, 185u8, 114u8, 139u8, - ], - ) - } - } - } - } - pub mod dmp { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The downward messages addressed for a certain para."] - pub fn downward_message_queues_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundDownwardMessage< - ::core::primitive::u32, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DownwardMessageQueues", - vec![], - [ - 38u8, 183u8, 133u8, 200u8, 199u8, 135u8, 68u8, 232u8, 189u8, 168u8, - 3u8, 219u8, 201u8, 180u8, 156u8, 79u8, 134u8, 164u8, 94u8, 114u8, - 102u8, 25u8, 108u8, 53u8, 219u8, 155u8, 102u8, 100u8, 58u8, 28u8, - 246u8, 20u8, - ], - ) - } - #[doc = " The downward messages addressed for a certain para."] - pub fn downward_message_queues( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundDownwardMessage< - ::core::primitive::u32, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DownwardMessageQueues", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 38u8, 183u8, 133u8, 200u8, 199u8, 135u8, 68u8, 232u8, 189u8, 168u8, - 3u8, 219u8, 201u8, 180u8, 156u8, 79u8, 134u8, 164u8, 94u8, 114u8, - 102u8, 25u8, 108u8, 53u8, 219u8, 155u8, 102u8, 100u8, 58u8, 28u8, - 246u8, 20u8, - ], - ) - } - #[doc = " A mapping that stores the downward message queue MQC head for each para."] - #[doc = ""] - #[doc = " Each link in this chain has a form:"] - #[doc = " `(prev_head, B, H(M))`, where"] - #[doc = " - `prev_head`: is the previous head hash or zero if none."] - #[doc = " - `B`: is the relay-chain block number in which a message was appended."] - #[doc = " - `H(M)`: is the hash of the message being appended."] - pub fn downward_message_queue_heads_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DownwardMessageQueueHeads", - vec![], - [ - 135u8, 165u8, 240u8, 0u8, 25u8, 110u8, 9u8, 108u8, 251u8, 225u8, 109u8, - 184u8, 90u8, 132u8, 9u8, 151u8, 12u8, 118u8, 153u8, 212u8, 140u8, - 205u8, 94u8, 98u8, 110u8, 167u8, 155u8, 43u8, 61u8, 35u8, 52u8, 56u8, - ], - ) - } - #[doc = " A mapping that stores the downward message queue MQC head for each para."] - #[doc = ""] - #[doc = " Each link in this chain has a form:"] - #[doc = " `(prev_head, B, H(M))`, where"] - #[doc = " - `prev_head`: is the previous head hash or zero if none."] - #[doc = " - `B`: is the relay-chain block number in which a message was appended."] - #[doc = " - `H(M)`: is the hash of the message being appended."] - pub fn downward_message_queue_heads( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DownwardMessageQueueHeads", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 135u8, 165u8, 240u8, 0u8, 25u8, 110u8, 9u8, 108u8, 251u8, 225u8, 109u8, - 184u8, 90u8, 132u8, 9u8, 151u8, 12u8, 118u8, 153u8, 212u8, 140u8, - 205u8, 94u8, 98u8, 110u8, 167u8, 155u8, 43u8, 61u8, 35u8, 52u8, 56u8, - ], - ) - } - #[doc = " The factor to multiply the base delivery fee by."] - pub fn delivery_fee_factor_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DeliveryFeeFactor", - vec![], - [ - 43u8, 5u8, 63u8, 235u8, 115u8, 155u8, 130u8, 27u8, 75u8, 216u8, 177u8, - 135u8, 203u8, 147u8, 167u8, 95u8, 208u8, 188u8, 25u8, 14u8, 84u8, 63u8, - 116u8, 41u8, 148u8, 110u8, 115u8, 215u8, 196u8, 36u8, 75u8, 102u8, - ], - ) - } - #[doc = " The factor to multiply the base delivery fee by."] - pub fn delivery_fee_factor( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Dmp", - "DeliveryFeeFactor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 43u8, 5u8, 63u8, 235u8, 115u8, 155u8, 130u8, 27u8, 75u8, 216u8, 177u8, - 135u8, 203u8, 147u8, 167u8, 95u8, 208u8, 188u8, 25u8, 14u8, 84u8, 63u8, - 116u8, 41u8, 148u8, 110u8, 115u8, 215u8, 196u8, 36u8, 75u8, 102u8, - ], - ) - } - } - } - } - pub mod hrmp { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_parachains::hrmp::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::hrmp::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpInitOpenChannel { - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub proposed_max_capacity: ::core::primitive::u32, - pub proposed_max_message_size: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for HrmpInitOpenChannel { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "hrmp_init_open_channel"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpAcceptOpenChannel { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for HrmpAcceptOpenChannel { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "hrmp_accept_open_channel"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpCloseChannel { - pub channel_id: - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - } - impl ::subxt::blocks::StaticExtrinsic for HrmpCloseChannel { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "hrmp_close_channel"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceCleanHrmp { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub num_inbound: ::core::primitive::u32, - pub num_outbound: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceCleanHrmp { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "force_clean_hrmp"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceProcessHrmpOpen { - pub channels: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceProcessHrmpOpen { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "force_process_hrmp_open"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceProcessHrmpClose { - pub channels: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceProcessHrmpClose { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "force_process_hrmp_close"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpCancelOpenRequest { - pub channel_id: - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - pub open_requests: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for HrmpCancelOpenRequest { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "hrmp_cancel_open_request"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceOpenHrmpChannel { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub max_capacity: ::core::primitive::u32, - pub max_message_size: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceOpenHrmpChannel { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "force_open_hrmp_channel"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EstablishSystemChannel { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for EstablishSystemChannel { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "establish_system_channel"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PokeChannelDeposits { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for PokeChannelDeposits { - const PALLET: &'static str = "Hrmp"; - const CALL: &'static str = "poke_channel_deposits"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::hrmp_init_open_channel`]."] - pub fn hrmp_init_open_channel( - &self, - recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - proposed_max_capacity: ::core::primitive::u32, - proposed_max_message_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "hrmp_init_open_channel", - types::HrmpInitOpenChannel { - recipient, - proposed_max_capacity, - proposed_max_message_size, - }, - [ - 89u8, 39u8, 43u8, 191u8, 235u8, 40u8, 253u8, 129u8, 174u8, 108u8, 26u8, - 206u8, 7u8, 146u8, 206u8, 56u8, 53u8, 104u8, 138u8, 203u8, 108u8, - 195u8, 190u8, 231u8, 223u8, 33u8, 32u8, 157u8, 148u8, 235u8, 67u8, - 82u8, - ], - ) - } - #[doc = "See [`Pallet::hrmp_accept_open_channel`]."] - pub fn hrmp_accept_open_channel( - &self, - sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "hrmp_accept_open_channel", - types::HrmpAcceptOpenChannel { sender }, - [ - 133u8, 77u8, 88u8, 40u8, 47u8, 81u8, 95u8, 206u8, 165u8, 41u8, 191u8, - 241u8, 130u8, 244u8, 70u8, 227u8, 69u8, 80u8, 130u8, 126u8, 34u8, 69u8, - 214u8, 81u8, 7u8, 199u8, 249u8, 162u8, 234u8, 233u8, 195u8, 156u8, - ], - ) - } - #[doc = "See [`Pallet::hrmp_close_channel`]."] - pub fn hrmp_close_channel( - &self, - channel_id : runtime_types :: polkadot_parachain_primitives :: primitives :: HrmpChannelId, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "hrmp_close_channel", - types::HrmpCloseChannel { channel_id }, - [ - 174u8, 225u8, 93u8, 69u8, 133u8, 145u8, 156u8, 94u8, 185u8, 254u8, - 60u8, 209u8, 232u8, 79u8, 237u8, 173u8, 180u8, 45u8, 117u8, 165u8, - 202u8, 195u8, 84u8, 68u8, 241u8, 164u8, 151u8, 216u8, 96u8, 20u8, 7u8, - 45u8, - ], - ) - } - #[doc = "See [`Pallet::force_clean_hrmp`]."] - pub fn force_clean_hrmp( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - num_inbound: ::core::primitive::u32, - num_outbound: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "force_clean_hrmp", - types::ForceCleanHrmp { para, num_inbound, num_outbound }, - [ - 0u8, 184u8, 199u8, 44u8, 26u8, 150u8, 124u8, 255u8, 40u8, 63u8, 74u8, - 31u8, 133u8, 22u8, 241u8, 84u8, 44u8, 184u8, 128u8, 54u8, 175u8, 127u8, - 255u8, 232u8, 239u8, 26u8, 50u8, 27u8, 81u8, 223u8, 136u8, 110u8, - ], - ) - } - #[doc = "See [`Pallet::force_process_hrmp_open`]."] - pub fn force_process_hrmp_open( - &self, - channels: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "force_process_hrmp_open", - types::ForceProcessHrmpOpen { channels }, - [ - 66u8, 138u8, 220u8, 119u8, 251u8, 148u8, 72u8, 167u8, 49u8, 156u8, - 227u8, 174u8, 153u8, 145u8, 190u8, 195u8, 192u8, 183u8, 41u8, 213u8, - 134u8, 8u8, 114u8, 30u8, 191u8, 81u8, 208u8, 54u8, 120u8, 36u8, 195u8, - 246u8, - ], - ) - } - #[doc = "See [`Pallet::force_process_hrmp_close`]."] - pub fn force_process_hrmp_close( - &self, - channels: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "force_process_hrmp_close", - types::ForceProcessHrmpClose { channels }, - [ - 22u8, 60u8, 113u8, 94u8, 199u8, 101u8, 204u8, 34u8, 158u8, 77u8, 228u8, - 29u8, 180u8, 249u8, 46u8, 103u8, 206u8, 155u8, 164u8, 229u8, 70u8, - 189u8, 218u8, 171u8, 173u8, 22u8, 210u8, 73u8, 232u8, 99u8, 225u8, - 176u8, - ], - ) - } - #[doc = "See [`Pallet::hrmp_cancel_open_request`]."] - pub fn hrmp_cancel_open_request( - &self, - channel_id : runtime_types :: polkadot_parachain_primitives :: primitives :: HrmpChannelId, - open_requests: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "hrmp_cancel_open_request", - types::HrmpCancelOpenRequest { channel_id, open_requests }, - [ - 10u8, 192u8, 79u8, 120u8, 6u8, 88u8, 139u8, 75u8, 87u8, 32u8, 125u8, - 47u8, 178u8, 132u8, 156u8, 232u8, 28u8, 123u8, 74u8, 10u8, 180u8, 90u8, - 145u8, 123u8, 40u8, 89u8, 235u8, 25u8, 237u8, 137u8, 114u8, 173u8, - ], - ) - } - #[doc = "See [`Pallet::force_open_hrmp_channel`]."] - pub fn force_open_hrmp_channel( - &self, - sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - max_capacity: ::core::primitive::u32, - max_message_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "force_open_hrmp_channel", - types::ForceOpenHrmpChannel { - sender, - recipient, - max_capacity, - max_message_size, - }, - [ - 37u8, 251u8, 1u8, 201u8, 129u8, 217u8, 193u8, 179u8, 98u8, 153u8, - 226u8, 139u8, 107u8, 222u8, 3u8, 76u8, 104u8, 248u8, 31u8, 241u8, 90u8, - 189u8, 56u8, 92u8, 118u8, 68u8, 177u8, 70u8, 5u8, 44u8, 234u8, 27u8, - ], - ) - } - #[doc = "See [`Pallet::establish_system_channel`]."] - pub fn establish_system_channel( - &self, - sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "establish_system_channel", - types::EstablishSystemChannel { sender, recipient }, - [ - 179u8, 12u8, 66u8, 57u8, 24u8, 114u8, 175u8, 141u8, 80u8, 157u8, 204u8, - 122u8, 116u8, 139u8, 35u8, 51u8, 68u8, 36u8, 61u8, 135u8, 221u8, 40u8, - 135u8, 21u8, 91u8, 60u8, 51u8, 51u8, 32u8, 224u8, 71u8, 182u8, - ], - ) - } - #[doc = "See [`Pallet::poke_channel_deposits`]."] - pub fn poke_channel_deposits( - &self, - sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Hrmp", - "poke_channel_deposits", - types::PokeChannelDeposits { sender, recipient }, - [ - 93u8, 153u8, 50u8, 127u8, 136u8, 255u8, 6u8, 155u8, 73u8, 216u8, 145u8, - 229u8, 200u8, 75u8, 94u8, 39u8, 117u8, 188u8, 62u8, 172u8, 210u8, - 212u8, 37u8, 11u8, 166u8, 31u8, 101u8, 129u8, 29u8, 229u8, 200u8, 16u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Open HRMP channel requested."] - pub struct OpenChannelRequested { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub proposed_max_capacity: ::core::primitive::u32, - pub proposed_max_message_size: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for OpenChannelRequested { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "OpenChannelRequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An HRMP channel request sent by the receiver was canceled by either party."] - pub struct OpenChannelCanceled { - pub by_parachain: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub channel_id: - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - } - impl ::subxt::events::StaticEvent for OpenChannelCanceled { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "OpenChannelCanceled"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Open HRMP channel accepted."] - pub struct OpenChannelAccepted { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for OpenChannelAccepted { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "OpenChannelAccepted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "HRMP channel closed."] - pub struct ChannelClosed { - pub by_parachain: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub channel_id: - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - } - impl ::subxt::events::StaticEvent for ChannelClosed { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "ChannelClosed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An HRMP channel was opened via Root origin."] - pub struct HrmpChannelForceOpened { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub proposed_max_capacity: ::core::primitive::u32, - pub proposed_max_message_size: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for HrmpChannelForceOpened { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "HrmpChannelForceOpened"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An HRMP channel was opened between two system chains."] - pub struct HrmpSystemChannelOpened { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub proposed_max_capacity: ::core::primitive::u32, - pub proposed_max_message_size: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for HrmpSystemChannelOpened { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "HrmpSystemChannelOpened"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An HRMP channel's deposits were updated."] - pub struct OpenChannelDepositsUpdated { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for OpenChannelDepositsUpdated { - const PALLET: &'static str = "Hrmp"; - const EVENT: &'static str = "OpenChannelDepositsUpdated"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The set of pending HRMP open channel requests."] - #[doc = ""] - #[doc = " The set is accompanied by a list for iteration."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no channels that exists in list but not in the set and vice versa."] - pub fn hrmp_open_channel_requests_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::hrmp::HrmpOpenChannelRequest, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequests", - vec![], - [ - 164u8, 97u8, 52u8, 242u8, 255u8, 67u8, 248u8, 170u8, 204u8, 92u8, 81u8, - 144u8, 11u8, 63u8, 145u8, 167u8, 8u8, 174u8, 221u8, 147u8, 125u8, - 144u8, 243u8, 33u8, 235u8, 104u8, 240u8, 99u8, 96u8, 211u8, 163u8, - 121u8, - ], - ) - } - #[doc = " The set of pending HRMP open channel requests."] - #[doc = ""] - #[doc = " The set is accompanied by a list for iteration."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no channels that exists in list but not in the set and vice versa."] - pub fn hrmp_open_channel_requests( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::hrmp::HrmpOpenChannelRequest, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequests", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 164u8, 97u8, 52u8, 242u8, 255u8, 67u8, 248u8, 170u8, 204u8, 92u8, 81u8, - 144u8, 11u8, 63u8, 145u8, 167u8, 8u8, 174u8, 221u8, 147u8, 125u8, - 144u8, 243u8, 33u8, 235u8, 104u8, 240u8, 99u8, 96u8, 211u8, 163u8, - 121u8, - ], - ) - } - pub fn hrmp_open_channel_requests_list( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequestsList", - vec![], - [ - 45u8, 190u8, 124u8, 26u8, 37u8, 249u8, 140u8, 254u8, 101u8, 249u8, - 27u8, 117u8, 218u8, 3u8, 126u8, 114u8, 143u8, 65u8, 122u8, 246u8, - 237u8, 173u8, 145u8, 175u8, 133u8, 119u8, 127u8, 81u8, 59u8, 206u8, - 159u8, 39u8, - ], - ) - } - #[doc = " This mapping tracks how many open channel requests are initiated by a given sender para."] - #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items that has"] - #[doc = " `(X, _)` as the number of `HrmpOpenChannelRequestCount` for `X`."] - pub fn hrmp_open_channel_request_count_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequestCount", - vec![], - [ - 136u8, 72u8, 56u8, 31u8, 229u8, 99u8, 241u8, 14u8, 159u8, 243u8, 179u8, - 222u8, 252u8, 56u8, 63u8, 24u8, 204u8, 130u8, 47u8, 161u8, 133u8, - 227u8, 237u8, 146u8, 239u8, 46u8, 127u8, 113u8, 190u8, 230u8, 61u8, - 182u8, - ], - ) - } - #[doc = " This mapping tracks how many open channel requests are initiated by a given sender para."] - #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items that has"] - #[doc = " `(X, _)` as the number of `HrmpOpenChannelRequestCount` for `X`."] - pub fn hrmp_open_channel_request_count( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpOpenChannelRequestCount", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 136u8, 72u8, 56u8, 31u8, 229u8, 99u8, 241u8, 14u8, 159u8, 243u8, 179u8, - 222u8, 252u8, 56u8, 63u8, 24u8, 204u8, 130u8, 47u8, 161u8, 133u8, - 227u8, 237u8, 146u8, 239u8, 46u8, 127u8, 113u8, 190u8, 230u8, 61u8, - 182u8, - ], - ) - } - #[doc = " This mapping tracks how many open channel requests were accepted by a given recipient para."] - #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items `(_, X)` with"] - #[doc = " `confirmed` set to true, as the number of `HrmpAcceptedChannelRequestCount` for `X`."] - pub fn hrmp_accepted_channel_request_count_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpAcceptedChannelRequestCount", - vec![], - [ - 29u8, 100u8, 52u8, 28u8, 180u8, 84u8, 132u8, 120u8, 117u8, 172u8, - 169u8, 40u8, 237u8, 92u8, 89u8, 87u8, 230u8, 148u8, 140u8, 226u8, 60u8, - 169u8, 100u8, 162u8, 139u8, 205u8, 180u8, 92u8, 0u8, 110u8, 55u8, - 158u8, - ], - ) - } - #[doc = " This mapping tracks how many open channel requests were accepted by a given recipient para."] - #[doc = " Invariant: `HrmpOpenChannelRequests` should contain the same number of items `(_, X)` with"] - #[doc = " `confirmed` set to true, as the number of `HrmpAcceptedChannelRequestCount` for `X`."] - pub fn hrmp_accepted_channel_request_count( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpAcceptedChannelRequestCount", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 29u8, 100u8, 52u8, 28u8, 180u8, 84u8, 132u8, 120u8, 117u8, 172u8, - 169u8, 40u8, 237u8, 92u8, 89u8, 87u8, 230u8, 148u8, 140u8, 226u8, 60u8, - 169u8, 100u8, 162u8, 139u8, 205u8, 180u8, 92u8, 0u8, 110u8, 55u8, - 158u8, - ], - ) - } - #[doc = " A set of pending HRMP close channel requests that are going to be closed during the session"] - #[doc = " change. Used for checking if a given channel is registered for closure."] - #[doc = ""] - #[doc = " The set is accompanied by a list for iteration."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no channels that exists in list but not in the set and vice versa."] - pub fn hrmp_close_channel_requests_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpCloseChannelRequests", - vec![], - [ - 155u8, 13u8, 73u8, 166u8, 58u8, 67u8, 138u8, 58u8, 215u8, 172u8, 241u8, - 168u8, 57u8, 4u8, 230u8, 248u8, 31u8, 183u8, 227u8, 224u8, 139u8, - 172u8, 229u8, 228u8, 16u8, 120u8, 124u8, 81u8, 213u8, 253u8, 102u8, - 226u8, - ], - ) - } - #[doc = " A set of pending HRMP close channel requests that are going to be closed during the session"] - #[doc = " change. Used for checking if a given channel is registered for closure."] - #[doc = ""] - #[doc = " The set is accompanied by a list for iteration."] - #[doc = ""] - #[doc = " Invariant:"] - #[doc = " - There are no channels that exists in list but not in the set and vice versa."] - pub fn hrmp_close_channel_requests( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpCloseChannelRequests", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 155u8, 13u8, 73u8, 166u8, 58u8, 67u8, 138u8, 58u8, 215u8, 172u8, 241u8, - 168u8, 57u8, 4u8, 230u8, 248u8, 31u8, 183u8, 227u8, 224u8, 139u8, - 172u8, 229u8, 228u8, 16u8, 120u8, 124u8, 81u8, 213u8, 253u8, 102u8, - 226u8, - ], - ) - } - pub fn hrmp_close_channel_requests_list( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpCloseChannelRequestsList", - vec![], - [ - 78u8, 194u8, 214u8, 232u8, 91u8, 72u8, 109u8, 113u8, 88u8, 86u8, 136u8, - 26u8, 226u8, 30u8, 11u8, 188u8, 57u8, 77u8, 169u8, 64u8, 14u8, 187u8, - 27u8, 127u8, 76u8, 99u8, 114u8, 73u8, 221u8, 23u8, 208u8, 69u8, - ], - ) - } - #[doc = " The HRMP watermark associated with each para."] - #[doc = " Invariant:"] - #[doc = " - each para `P` used here as a key should satisfy `Paras::is_valid_para(P)` within a"] - #[doc = " session."] - pub fn hrmp_watermarks_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpWatermarks", - vec![], - [ - 245u8, 104u8, 137u8, 120u8, 131u8, 7u8, 178u8, 85u8, 96u8, 124u8, - 241u8, 2u8, 86u8, 63u8, 116u8, 77u8, 217u8, 235u8, 162u8, 38u8, 104u8, - 248u8, 121u8, 1u8, 111u8, 191u8, 191u8, 115u8, 65u8, 67u8, 2u8, 238u8, - ], - ) - } - #[doc = " The HRMP watermark associated with each para."] - #[doc = " Invariant:"] - #[doc = " - each para `P` used here as a key should satisfy `Paras::is_valid_para(P)` within a"] - #[doc = " session."] - pub fn hrmp_watermarks( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpWatermarks", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 245u8, 104u8, 137u8, 120u8, 131u8, 7u8, 178u8, 85u8, 96u8, 124u8, - 241u8, 2u8, 86u8, 63u8, 116u8, 77u8, 217u8, 235u8, 162u8, 38u8, 104u8, - 248u8, 121u8, 1u8, 111u8, 191u8, 191u8, 115u8, 65u8, 67u8, 2u8, 238u8, - ], - ) - } - #[doc = " HRMP channel data associated with each para."] - #[doc = " Invariant:"] - #[doc = " - each participant in the channel should satisfy `Paras::is_valid_para(P)` within a session."] - pub fn hrmp_channels_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::hrmp::HrmpChannel, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannels", - vec![], - [ - 174u8, 90u8, 72u8, 93u8, 43u8, 140u8, 181u8, 170u8, 138u8, 171u8, - 179u8, 156u8, 33u8, 87u8, 63u8, 1u8, 131u8, 59u8, 230u8, 14u8, 40u8, - 240u8, 186u8, 66u8, 191u8, 130u8, 48u8, 218u8, 225u8, 22u8, 33u8, - 122u8, - ], - ) - } - #[doc = " HRMP channel data associated with each para."] - #[doc = " Invariant:"] - #[doc = " - each participant in the channel should satisfy `Paras::is_valid_para(P)` within a session."] - pub fn hrmp_channels( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::hrmp::HrmpChannel, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannels", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 174u8, 90u8, 72u8, 93u8, 43u8, 140u8, 181u8, 170u8, 138u8, 171u8, - 179u8, 156u8, 33u8, 87u8, 63u8, 1u8, 131u8, 59u8, 230u8, 14u8, 40u8, - 240u8, 186u8, 66u8, 191u8, 130u8, 48u8, 218u8, 225u8, 22u8, 33u8, - 122u8, - ], - ) - } - #[doc = " Ingress/egress indexes allow to find all the senders and receivers given the opposite side."] - #[doc = " I.e."] - #[doc = ""] - #[doc = " (a) ingress index allows to find all the senders for a given recipient."] - #[doc = " (b) egress index allows to find all the recipients for a given sender."] - #[doc = ""] - #[doc = " Invariants:"] - #[doc = " - for each ingress index entry for `P` each item `I` in the index should present in"] - #[doc = " `HrmpChannels` as `(I, P)`."] - #[doc = " - for each egress index entry for `P` each item `E` in the index should present in"] - #[doc = " `HrmpChannels` as `(P, E)`."] - #[doc = " - there should be no other dangling channels in `HrmpChannels`."] - #[doc = " - the vectors are sorted."] - pub fn hrmp_ingress_channels_index_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpIngressChannelsIndex", - vec![], - [ - 125u8, 229u8, 102u8, 230u8, 74u8, 109u8, 173u8, 67u8, 176u8, 169u8, - 57u8, 24u8, 75u8, 129u8, 246u8, 198u8, 63u8, 49u8, 56u8, 102u8, 149u8, - 139u8, 138u8, 207u8, 150u8, 220u8, 29u8, 208u8, 203u8, 0u8, 93u8, - 105u8, - ], - ) - } - #[doc = " Ingress/egress indexes allow to find all the senders and receivers given the opposite side."] - #[doc = " I.e."] - #[doc = ""] - #[doc = " (a) ingress index allows to find all the senders for a given recipient."] - #[doc = " (b) egress index allows to find all the recipients for a given sender."] - #[doc = ""] - #[doc = " Invariants:"] - #[doc = " - for each ingress index entry for `P` each item `I` in the index should present in"] - #[doc = " `HrmpChannels` as `(I, P)`."] - #[doc = " - for each egress index entry for `P` each item `E` in the index should present in"] - #[doc = " `HrmpChannels` as `(P, E)`."] - #[doc = " - there should be no other dangling channels in `HrmpChannels`."] - #[doc = " - the vectors are sorted."] - pub fn hrmp_ingress_channels_index( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpIngressChannelsIndex", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 125u8, 229u8, 102u8, 230u8, 74u8, 109u8, 173u8, 67u8, 176u8, 169u8, - 57u8, 24u8, 75u8, 129u8, 246u8, 198u8, 63u8, 49u8, 56u8, 102u8, 149u8, - 139u8, 138u8, 207u8, 150u8, 220u8, 29u8, 208u8, 203u8, 0u8, 93u8, - 105u8, - ], - ) - } - pub fn hrmp_egress_channels_index_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpEgressChannelsIndex", - vec![], - [ - 237u8, 183u8, 188u8, 57u8, 20u8, 238u8, 166u8, 7u8, 94u8, 155u8, 22u8, - 9u8, 173u8, 209u8, 210u8, 17u8, 160u8, 79u8, 243u8, 4u8, 245u8, 240u8, - 65u8, 195u8, 116u8, 98u8, 206u8, 104u8, 53u8, 64u8, 241u8, 41u8, - ], - ) - } - pub fn hrmp_egress_channels_index( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpEgressChannelsIndex", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 237u8, 183u8, 188u8, 57u8, 20u8, 238u8, 166u8, 7u8, 94u8, 155u8, 22u8, - 9u8, 173u8, 209u8, 210u8, 17u8, 160u8, 79u8, 243u8, 4u8, 245u8, 240u8, - 65u8, 195u8, 116u8, 98u8, 206u8, 104u8, 53u8, 64u8, 241u8, 41u8, - ], - ) - } - #[doc = " Storage for the messages for each channel."] - #[doc = " Invariant: cannot be non-empty if the corresponding channel in `HrmpChannels` is `None`."] - pub fn hrmp_channel_contents_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundHrmpMessage< - ::core::primitive::u32, - >, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannelContents", - vec![], - [ - 55u8, 16u8, 135u8, 69u8, 54u8, 180u8, 246u8, 124u8, 104u8, 92u8, 45u8, - 18u8, 223u8, 145u8, 43u8, 190u8, 121u8, 59u8, 35u8, 195u8, 234u8, - 219u8, 30u8, 246u8, 168u8, 187u8, 45u8, 171u8, 254u8, 204u8, 60u8, - 121u8, - ], - ) - } - #[doc = " Storage for the messages for each channel."] - #[doc = " Invariant: cannot be non-empty if the corresponding channel in `HrmpChannels` is `None`."] - pub fn hrmp_channel_contents( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - runtime_types::polkadot_core_primitives::InboundHrmpMessage< - ::core::primitive::u32, - >, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannelContents", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 55u8, 16u8, 135u8, 69u8, 54u8, 180u8, 246u8, 124u8, 104u8, 92u8, 45u8, - 18u8, 223u8, 145u8, 43u8, 190u8, 121u8, 59u8, 35u8, 195u8, 234u8, - 219u8, 30u8, 246u8, 168u8, 187u8, 45u8, 171u8, 254u8, 204u8, 60u8, - 121u8, - ], - ) - } - #[doc = " Maintains a mapping that can be used to answer the question: What paras sent a message at"] - #[doc = " the given block number for a given receiver. Invariants:"] - #[doc = " - The inner `Vec` is never empty."] - #[doc = " - The inner `Vec` cannot store two same `ParaId`."] - #[doc = " - The outer vector is sorted ascending by block number and cannot store two items with the"] - #[doc = " same block number."] - pub fn hrmp_channel_digests_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - ::core::primitive::u32, - ::std::vec::Vec< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - )>, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannelDigests", - vec![], - [ - 90u8, 90u8, 139u8, 78u8, 47u8, 2u8, 104u8, 211u8, 42u8, 246u8, 193u8, - 210u8, 142u8, 223u8, 17u8, 136u8, 3u8, 182u8, 25u8, 56u8, 72u8, 72u8, - 162u8, 131u8, 36u8, 34u8, 162u8, 176u8, 159u8, 113u8, 7u8, 207u8, - ], - ) - } - #[doc = " Maintains a mapping that can be used to answer the question: What paras sent a message at"] - #[doc = " the given block number for a given receiver. Invariants:"] - #[doc = " - The inner `Vec` is never empty."] - #[doc = " - The inner `Vec` cannot store two same `ParaId`."] - #[doc = " - The outer vector is sorted ascending by block number and cannot store two items with the"] - #[doc = " same block number."] - pub fn hrmp_channel_digests( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<( - ::core::primitive::u32, - ::std::vec::Vec< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Hrmp", - "HrmpChannelDigests", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 90u8, 90u8, 139u8, 78u8, 47u8, 2u8, 104u8, 211u8, 42u8, 246u8, 193u8, - 210u8, 142u8, 223u8, 17u8, 136u8, 3u8, 182u8, 25u8, 56u8, 72u8, 72u8, - 162u8, 131u8, 36u8, 34u8, 162u8, 176u8, 159u8, 113u8, 7u8, 207u8, - ], - ) - } - } - } - } - pub mod para_session_info { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Assignment keys for the current session."] - #[doc = " Note that this API is private due to it being prone to 'off-by-one' at session boundaries."] - #[doc = " When in doubt, use `Sessions` API instead."] - pub fn assignment_keys_unsafe( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "AssignmentKeysUnsafe", - vec![], - [ - 51u8, 155u8, 91u8, 101u8, 118u8, 243u8, 134u8, 138u8, 147u8, 59u8, - 195u8, 186u8, 54u8, 187u8, 36u8, 14u8, 91u8, 141u8, 60u8, 139u8, 28u8, - 74u8, 111u8, 232u8, 198u8, 229u8, 61u8, 63u8, 72u8, 214u8, 152u8, 2u8, - ], - ) - } - #[doc = " The earliest session for which previous session info is stored."] - pub fn earliest_stored_session( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "EarliestStoredSession", - vec![], - [ - 139u8, 176u8, 46u8, 139u8, 217u8, 35u8, 62u8, 91u8, 183u8, 7u8, 114u8, - 226u8, 60u8, 237u8, 105u8, 73u8, 20u8, 216u8, 194u8, 205u8, 178u8, - 237u8, 84u8, 66u8, 181u8, 29u8, 31u8, 218u8, 48u8, 60u8, 198u8, 86u8, - ], - ) - } - #[doc = " Session information in a rolling window."] - #[doc = " Should have an entry in range `EarliestStoredSession..=CurrentSessionIndex`."] - #[doc = " Does not have any entries before the session index in the first session change notification."] - pub fn sessions_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::SessionInfo, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "Sessions", - vec![], - [ - 254u8, 40u8, 169u8, 18u8, 252u8, 203u8, 49u8, 182u8, 123u8, 19u8, - 241u8, 150u8, 227u8, 153u8, 108u8, 109u8, 66u8, 129u8, 157u8, 27u8, - 130u8, 215u8, 105u8, 18u8, 163u8, 72u8, 182u8, 243u8, 31u8, 157u8, - 103u8, 111u8, - ], - ) - } - #[doc = " Session information in a rolling window."] - #[doc = " Should have an entry in range `EarliestStoredSession..=CurrentSessionIndex`."] - #[doc = " Does not have any entries before the session index in the first session change notification."] - pub fn sessions( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::SessionInfo, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "Sessions", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 254u8, 40u8, 169u8, 18u8, 252u8, 203u8, 49u8, 182u8, 123u8, 19u8, - 241u8, 150u8, 227u8, 153u8, 108u8, 109u8, 66u8, 129u8, 157u8, 27u8, - 130u8, 215u8, 105u8, 18u8, 163u8, 72u8, 182u8, 243u8, 31u8, 157u8, - 103u8, 111u8, - ], - ) - } - #[doc = " The validator account keys of the validators actively participating in parachain consensus."] - pub fn account_keys_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "AccountKeys", - vec![], - [ - 30u8, 98u8, 58u8, 140u8, 96u8, 231u8, 205u8, 111u8, 194u8, 100u8, - 185u8, 242u8, 210u8, 143u8, 110u8, 144u8, 170u8, 187u8, 62u8, 196u8, - 73u8, 88u8, 118u8, 168u8, 117u8, 116u8, 153u8, 229u8, 108u8, 46u8, - 154u8, 220u8, - ], - ) - } - #[doc = " The validator account keys of the validators actively participating in parachain consensus."] - pub fn account_keys( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "AccountKeys", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 30u8, 98u8, 58u8, 140u8, 96u8, 231u8, 205u8, 111u8, 194u8, 100u8, - 185u8, 242u8, 210u8, 143u8, 110u8, 144u8, 170u8, 187u8, 62u8, 196u8, - 73u8, 88u8, 118u8, 168u8, 117u8, 116u8, 153u8, 229u8, 108u8, 46u8, - 154u8, 220u8, - ], - ) - } - #[doc = " Executor parameter set for a given session index"] - pub fn session_executor_params_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::executor_params::ExecutorParams, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "SessionExecutorParams", - vec![], - [ - 38u8, 80u8, 118u8, 112u8, 189u8, 55u8, 95u8, 184u8, 19u8, 8u8, 114u8, - 6u8, 173u8, 80u8, 254u8, 98u8, 107u8, 202u8, 215u8, 107u8, 149u8, - 157u8, 145u8, 8u8, 249u8, 255u8, 83u8, 199u8, 47u8, 179u8, 208u8, 83u8, - ], - ) - } - #[doc = " Executor parameter set for a given session index"] - pub fn session_executor_params( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::executor_params::ExecutorParams, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParaSessionInfo", - "SessionExecutorParams", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 38u8, 80u8, 118u8, 112u8, 189u8, 55u8, 95u8, 184u8, 19u8, 8u8, 114u8, - 6u8, 173u8, 80u8, 254u8, 98u8, 107u8, 202u8, 215u8, 107u8, 149u8, - 157u8, 145u8, 8u8, 249u8, 255u8, 83u8, 199u8, 47u8, 179u8, 208u8, 83u8, - ], - ) - } - } - } - } - pub mod paras_disputes { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_parachains::disputes::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::disputes::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnfreeze; - impl ::subxt::blocks::StaticExtrinsic for ForceUnfreeze { - const PALLET: &'static str = "ParasDisputes"; - const CALL: &'static str = "force_unfreeze"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::force_unfreeze`]."] - pub fn force_unfreeze(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasDisputes", - "force_unfreeze", - types::ForceUnfreeze {}, - [ - 148u8, 19u8, 139u8, 154u8, 111u8, 166u8, 74u8, 136u8, 127u8, 157u8, - 20u8, 47u8, 220u8, 108u8, 152u8, 108u8, 24u8, 232u8, 11u8, 53u8, 26u8, - 4u8, 23u8, 58u8, 195u8, 61u8, 159u8, 6u8, 139u8, 7u8, 197u8, 88u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_parachains::disputes::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A dispute has been initiated. \\[candidate hash, dispute location\\]"] - pub struct DisputeInitiated( - pub runtime_types::polkadot_core_primitives::CandidateHash, - pub runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, - ); - impl ::subxt::events::StaticEvent for DisputeInitiated { - const PALLET: &'static str = "ParasDisputes"; - const EVENT: &'static str = "DisputeInitiated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A dispute has concluded for or against a candidate."] - #[doc = "`\\[para id, candidate hash, dispute result\\]`"] - pub struct DisputeConcluded( - pub runtime_types::polkadot_core_primitives::CandidateHash, - pub runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, - ); - impl ::subxt::events::StaticEvent for DisputeConcluded { - const PALLET: &'static str = "ParasDisputes"; - const EVENT: &'static str = "DisputeConcluded"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A dispute has concluded with supermajority against a candidate."] - #[doc = "Block authors should no longer build on top of this head and should"] - #[doc = "instead revert the block at the given height. This should be the"] - #[doc = "number of the child of the last known valid block in the chain."] - pub struct Revert(pub ::core::primitive::u32); - impl ::subxt::events::StaticEvent for Revert { - const PALLET: &'static str = "ParasDisputes"; - const EVENT: &'static str = "Revert"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The last pruned session, if any. All data stored by this module"] - #[doc = " references sessions."] - pub fn last_pruned_session( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "LastPrunedSession", - vec![], - [ - 98u8, 107u8, 200u8, 158u8, 182u8, 120u8, 24u8, 242u8, 24u8, 163u8, - 237u8, 72u8, 153u8, 19u8, 38u8, 85u8, 239u8, 208u8, 194u8, 22u8, 173u8, - 100u8, 219u8, 10u8, 194u8, 42u8, 120u8, 146u8, 225u8, 62u8, 80u8, - 229u8, - ], - ) - } - #[doc = " All ongoing or concluded disputes for the last several sessions."] - pub fn disputes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::DisputeState<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Disputes", - vec![], - [ - 38u8, 237u8, 141u8, 222u8, 135u8, 82u8, 210u8, 166u8, 192u8, 122u8, - 175u8, 96u8, 91u8, 1u8, 225u8, 182u8, 128u8, 4u8, 159u8, 56u8, 180u8, - 176u8, 157u8, 20u8, 105u8, 202u8, 192u8, 213u8, 164u8, 24u8, 227u8, - 15u8, - ], - ) - } - #[doc = " All ongoing or concluded disputes for the last several sessions."] - pub fn disputes_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::DisputeState<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Disputes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 38u8, 237u8, 141u8, 222u8, 135u8, 82u8, 210u8, 166u8, 192u8, 122u8, - 175u8, 96u8, 91u8, 1u8, 225u8, 182u8, 128u8, 4u8, 159u8, 56u8, 180u8, - 176u8, 157u8, 20u8, 105u8, 202u8, 192u8, 213u8, 164u8, 24u8, 227u8, - 15u8, - ], - ) - } - #[doc = " All ongoing or concluded disputes for the last several sessions."] - pub fn disputes( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow< - runtime_types::polkadot_core_primitives::CandidateHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::DisputeState<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Disputes", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 38u8, 237u8, 141u8, 222u8, 135u8, 82u8, 210u8, 166u8, 192u8, 122u8, - 175u8, 96u8, 91u8, 1u8, 225u8, 182u8, 128u8, 4u8, 159u8, 56u8, 180u8, - 176u8, 157u8, 20u8, 105u8, 202u8, 192u8, 213u8, 164u8, 24u8, 227u8, - 15u8, - ], - ) - } - #[doc = " Backing votes stored for each dispute."] - #[doc = " This storage is used for slashing."] - pub fn backers_on_disputes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "BackersOnDisputes", - vec![], - [ - 136u8, 171u8, 20u8, 204u8, 135u8, 153u8, 144u8, 241u8, 46u8, 193u8, - 65u8, 22u8, 116u8, 161u8, 144u8, 186u8, 31u8, 194u8, 202u8, 225u8, - 14u8, 137u8, 240u8, 243u8, 119u8, 144u8, 102u8, 245u8, 133u8, 126u8, - 103u8, 32u8, - ], - ) - } - #[doc = " Backing votes stored for each dispute."] - #[doc = " This storage is used for slashing."] - pub fn backers_on_disputes_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "BackersOnDisputes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 136u8, 171u8, 20u8, 204u8, 135u8, 153u8, 144u8, 241u8, 46u8, 193u8, - 65u8, 22u8, 116u8, 161u8, 144u8, 186u8, 31u8, 194u8, 202u8, 225u8, - 14u8, 137u8, 240u8, 243u8, 119u8, 144u8, 102u8, 245u8, 133u8, 126u8, - 103u8, 32u8, - ], - ) - } - #[doc = " Backing votes stored for each dispute."] - #[doc = " This storage is used for slashing."] - pub fn backers_on_disputes( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow< - runtime_types::polkadot_core_primitives::CandidateHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "BackersOnDisputes", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 136u8, 171u8, 20u8, 204u8, 135u8, 153u8, 144u8, 241u8, 46u8, 193u8, - 65u8, 22u8, 116u8, 161u8, 144u8, 186u8, 31u8, 194u8, 202u8, 225u8, - 14u8, 137u8, 240u8, 243u8, 119u8, 144u8, 102u8, 245u8, 133u8, 126u8, - 103u8, 32u8, - ], - ) - } - #[doc = " All included blocks on the chain, as well as the block number in this chain that"] - #[doc = " should be reverted back to if the candidate is disputed and determined to be invalid."] - pub fn included_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Included", - vec![], - [ - 47u8, 105u8, 189u8, 233u8, 206u8, 153u8, 162u8, 217u8, 141u8, 118u8, - 31u8, 85u8, 87u8, 53u8, 100u8, 187u8, 31u8, 245u8, 50u8, 171u8, 4u8, - 203u8, 163u8, 109u8, 212u8, 162u8, 86u8, 124u8, 172u8, 157u8, 165u8, - 21u8, - ], - ) - } - #[doc = " All included blocks on the chain, as well as the block number in this chain that"] - #[doc = " should be reverted back to if the candidate is disputed and determined to be invalid."] - pub fn included_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Included", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 47u8, 105u8, 189u8, 233u8, 206u8, 153u8, 162u8, 217u8, 141u8, 118u8, - 31u8, 85u8, 87u8, 53u8, 100u8, 187u8, 31u8, 245u8, 50u8, 171u8, 4u8, - 203u8, 163u8, 109u8, 212u8, 162u8, 86u8, 124u8, 172u8, 157u8, 165u8, - 21u8, - ], - ) - } - #[doc = " All included blocks on the chain, as well as the block number in this chain that"] - #[doc = " should be reverted back to if the candidate is disputed and determined to be invalid."] - pub fn included( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow< - runtime_types::polkadot_core_primitives::CandidateHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Included", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 47u8, 105u8, 189u8, 233u8, 206u8, 153u8, 162u8, 217u8, 141u8, 118u8, - 31u8, 85u8, 87u8, 53u8, 100u8, 187u8, 31u8, 245u8, 50u8, 171u8, 4u8, - 203u8, 163u8, 109u8, 212u8, 162u8, 86u8, 124u8, 172u8, 157u8, 165u8, - 21u8, - ], - ) - } - #[doc = " Whether the chain is frozen. Starts as `None`. When this is `Some`,"] - #[doc = " the chain will not accept any new parachain blocks for backing or inclusion,"] - #[doc = " and its value indicates the last valid block number in the chain."] - #[doc = " It can only be set back to `None` by governance intervention."] - pub fn frozen( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option<::core::primitive::u32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasDisputes", - "Frozen", - vec![], - [ - 245u8, 136u8, 43u8, 156u8, 7u8, 74u8, 31u8, 190u8, 184u8, 119u8, 182u8, - 66u8, 18u8, 136u8, 30u8, 248u8, 24u8, 121u8, 26u8, 177u8, 169u8, 208u8, - 218u8, 208u8, 80u8, 116u8, 31u8, 144u8, 49u8, 201u8, 198u8, 197u8, - ], - ) - } - } - } - } - pub mod paras_slashing { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = - runtime_types::polkadot_runtime_parachains::disputes::slashing::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = - runtime_types::polkadot_runtime_parachains::disputes::slashing::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportDisputeLostUnsigned { - pub dispute_proof: ::std::boxed::Box< - runtime_types::polkadot_primitives::v6::slashing::DisputeProof, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - impl ::subxt::blocks::StaticExtrinsic for ReportDisputeLostUnsigned { - const PALLET: &'static str = "ParasSlashing"; - const CALL: &'static str = "report_dispute_lost_unsigned"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::report_dispute_lost_unsigned`]."] - pub fn report_dispute_lost_unsigned( - &self, - dispute_proof: runtime_types::polkadot_primitives::v6::slashing::DisputeProof, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasSlashing", - "report_dispute_lost_unsigned", - types::ReportDisputeLostUnsigned { - dispute_proof: ::std::boxed::Box::new(dispute_proof), - key_owner_proof, - }, - [ - 57u8, 99u8, 246u8, 126u8, 203u8, 239u8, 64u8, 182u8, 167u8, 204u8, - 96u8, 221u8, 126u8, 94u8, 254u8, 210u8, 18u8, 182u8, 207u8, 32u8, - 250u8, 249u8, 116u8, 156u8, 210u8, 63u8, 254u8, 74u8, 86u8, 101u8, - 28u8, 229u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Validators pending dispute slashes."] - pub fn unapplied_slashes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::slashing::PendingSlashes, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasSlashing", - "UnappliedSlashes", - vec![], - [ - 114u8, 171u8, 137u8, 142u8, 180u8, 125u8, 226u8, 240u8, 99u8, 181u8, - 68u8, 221u8, 91u8, 124u8, 172u8, 93u8, 103u8, 12u8, 95u8, 43u8, 67u8, - 59u8, 29u8, 133u8, 140u8, 17u8, 141u8, 228u8, 145u8, 201u8, 82u8, - 126u8, - ], - ) - } - #[doc = " Validators pending dispute slashes."] - pub fn unapplied_slashes_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::slashing::PendingSlashes, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasSlashing", - "UnappliedSlashes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 114u8, 171u8, 137u8, 142u8, 180u8, 125u8, 226u8, 240u8, 99u8, 181u8, - 68u8, 221u8, 91u8, 124u8, 172u8, 93u8, 103u8, 12u8, 95u8, 43u8, 67u8, - 59u8, 29u8, 133u8, 140u8, 17u8, 141u8, 228u8, 145u8, 201u8, 82u8, - 126u8, - ], - ) - } - #[doc = " Validators pending dispute slashes."] - pub fn unapplied_slashes( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow< - runtime_types::polkadot_core_primitives::CandidateHash, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_primitives::v6::slashing::PendingSlashes, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasSlashing", - "UnappliedSlashes", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 114u8, 171u8, 137u8, 142u8, 180u8, 125u8, 226u8, 240u8, 99u8, 181u8, - 68u8, 221u8, 91u8, 124u8, 172u8, 93u8, 103u8, 12u8, 95u8, 43u8, 67u8, - 59u8, 29u8, 133u8, 140u8, 17u8, 141u8, 228u8, 145u8, 201u8, 82u8, - 126u8, - ], - ) - } - #[doc = " `ValidatorSetCount` per session."] - pub fn validator_set_counts_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "ParasSlashing", - "ValidatorSetCounts", - vec![], - [ - 195u8, 220u8, 79u8, 140u8, 114u8, 80u8, 241u8, 103u8, 4u8, 7u8, 53u8, - 100u8, 16u8, 78u8, 104u8, 171u8, 134u8, 110u8, 158u8, 191u8, 37u8, - 94u8, 211u8, 26u8, 17u8, 70u8, 50u8, 34u8, 70u8, 234u8, 186u8, 69u8, - ], - ) - } - #[doc = " `ValidatorSetCount` per session."] - pub fn validator_set_counts( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "ParasSlashing", - "ValidatorSetCounts", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 195u8, 220u8, 79u8, 140u8, 114u8, 80u8, 241u8, 103u8, 4u8, 7u8, 53u8, - 100u8, 16u8, 78u8, 104u8, 171u8, 134u8, 110u8, 158u8, 191u8, 37u8, - 94u8, 211u8, 26u8, 17u8, 70u8, 50u8, 34u8, 70u8, 234u8, 186u8, 69u8, - ], - ) - } - } - } - } - pub mod message_queue { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_message_queue::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_message_queue::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReapPage { pub message_origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , pub page_index : :: core :: primitive :: u32 , } - impl ::subxt::blocks::StaticExtrinsic for ReapPage { - const PALLET: &'static str = "MessageQueue"; - const CALL: &'static str = "reap_page"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExecuteOverweight { pub message_origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , pub page : :: core :: primitive :: u32 , pub index : :: core :: primitive :: u32 , pub weight_limit : runtime_types :: sp_weights :: weight_v2 :: Weight , } - impl ::subxt::blocks::StaticExtrinsic for ExecuteOverweight { - const PALLET: &'static str = "MessageQueue"; - const CALL: &'static str = "execute_overweight"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::reap_page`]."] - pub fn reap_page( - &self, - message_origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin, - page_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "MessageQueue", - "reap_page", - types::ReapPage { message_origin, page_index }, - [ - 217u8, 3u8, 106u8, 158u8, 151u8, 194u8, 234u8, 4u8, 254u8, 4u8, 200u8, - 201u8, 107u8, 140u8, 220u8, 201u8, 245u8, 14u8, 23u8, 156u8, 41u8, - 106u8, 39u8, 90u8, 214u8, 1u8, 183u8, 45u8, 3u8, 83u8, 242u8, 30u8, - ], - ) - } - #[doc = "See [`Pallet::execute_overweight`]."] - pub fn execute_overweight( - &self, - message_origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin, - page: ::core::primitive::u32, - index: ::core::primitive::u32, - weight_limit: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "MessageQueue", - "execute_overweight", - types::ExecuteOverweight { message_origin, page, index, weight_limit }, - [ - 101u8, 2u8, 86u8, 225u8, 217u8, 229u8, 143u8, 214u8, 146u8, 190u8, - 182u8, 102u8, 251u8, 18u8, 179u8, 187u8, 113u8, 29u8, 182u8, 24u8, - 34u8, 179u8, 64u8, 249u8, 139u8, 76u8, 50u8, 238u8, 132u8, 167u8, - 115u8, 141u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_message_queue::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Message discarded due to an error in the `MessageProcessor` (usually a format error)."] - pub struct ProcessingFailed { - pub id: ::subxt::utils::H256, - pub origin: - runtime_types::polkadot_runtime_parachains::inclusion::AggregateMessageOrigin, - pub error: runtime_types::frame_support::traits::messages::ProcessMessageError, - } - impl ::subxt::events::StaticEvent for ProcessingFailed { - const PALLET: &'static str = "MessageQueue"; - const EVENT: &'static str = "ProcessingFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Message is processed."] - pub struct Processed { - pub id: ::subxt::utils::H256, - pub origin: - runtime_types::polkadot_runtime_parachains::inclusion::AggregateMessageOrigin, - pub weight_used: runtime_types::sp_weights::weight_v2::Weight, - pub success: ::core::primitive::bool, - } - impl ::subxt::events::StaticEvent for Processed { - const PALLET: &'static str = "MessageQueue"; - const EVENT: &'static str = "Processed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Message placed in overweight queue."] - pub struct OverweightEnqueued { - pub id: [::core::primitive::u8; 32usize], - pub origin: - runtime_types::polkadot_runtime_parachains::inclusion::AggregateMessageOrigin, - pub page_index: ::core::primitive::u32, - pub message_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for OverweightEnqueued { - const PALLET: &'static str = "MessageQueue"; - const EVENT: &'static str = "OverweightEnqueued"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "This page was reaped."] - pub struct PageReaped { - pub origin: - runtime_types::polkadot_runtime_parachains::inclusion::AggregateMessageOrigin, - pub index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for PageReaped { - const PALLET: &'static str = "MessageQueue"; - const EVENT: &'static str = "PageReaped"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The index of the first and last (non-empty) pages."] pub fn book_state_for_iter (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: pallet_message_queue :: BookState < runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin > , () , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes >{ - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "BookStateFor", - vec![], - [ - 32u8, 61u8, 161u8, 81u8, 134u8, 136u8, 252u8, 113u8, 204u8, 115u8, - 206u8, 180u8, 33u8, 185u8, 137u8, 155u8, 178u8, 189u8, 234u8, 201u8, - 31u8, 230u8, 156u8, 72u8, 37u8, 56u8, 152u8, 91u8, 50u8, 82u8, 191u8, - 2u8, - ], - ) - } - #[doc = " The index of the first and last (non-empty) pages."] pub fn book_state_for (& self , _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin > ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: pallet_message_queue :: BookState < runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "BookStateFor", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 32u8, 61u8, 161u8, 81u8, 134u8, 136u8, 252u8, 113u8, 204u8, 115u8, - 206u8, 180u8, 33u8, 185u8, 137u8, 155u8, 178u8, 189u8, 234u8, 201u8, - 31u8, 230u8, 156u8, 72u8, 37u8, 56u8, 152u8, 91u8, 50u8, 82u8, 191u8, - 2u8, - ], - ) - } - #[doc = " The origin at which we should begin servicing."] - pub fn service_head( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::inclusion::AggregateMessageOrigin, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "ServiceHead", - vec![], - [ - 17u8, 130u8, 229u8, 193u8, 127u8, 237u8, 60u8, 232u8, 99u8, 109u8, - 102u8, 228u8, 124u8, 103u8, 24u8, 188u8, 151u8, 121u8, 55u8, 97u8, - 85u8, 63u8, 131u8, 60u8, 99u8, 12u8, 88u8, 230u8, 86u8, 50u8, 12u8, - 75u8, - ], - ) - } - #[doc = " The map of page indices to pages."] - pub fn pages_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_message_queue::Page<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "Pages", - vec![], - [ - 56u8, 181u8, 157u8, 16u8, 157u8, 123u8, 106u8, 93u8, 199u8, 208u8, - 153u8, 53u8, 168u8, 188u8, 124u8, 77u8, 140u8, 163u8, 113u8, 16u8, - 232u8, 47u8, 10u8, 185u8, 113u8, 230u8, 47u8, 91u8, 253u8, 196u8, 95u8, - 102u8, - ], - ) - } - #[doc = " The map of page indices to pages."] - pub fn pages_iter1( - &self, - _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_message_queue::Page<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "Pages", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 56u8, 181u8, 157u8, 16u8, 157u8, 123u8, 106u8, 93u8, 199u8, 208u8, - 153u8, 53u8, 168u8, 188u8, 124u8, 77u8, 140u8, 163u8, 113u8, 16u8, - 232u8, 47u8, 10u8, 185u8, 113u8, 230u8, 47u8, 91u8, 253u8, 196u8, 95u8, - 102u8, - ], - ) - } - #[doc = " The map of page indices to pages."] - pub fn pages( - &self, - _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin >, - _1: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_message_queue::Page<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "MessageQueue", - "Pages", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 56u8, 181u8, 157u8, 16u8, 157u8, 123u8, 106u8, 93u8, 199u8, 208u8, - 153u8, 53u8, 168u8, 188u8, 124u8, 77u8, 140u8, 163u8, 113u8, 16u8, - 232u8, 47u8, 10u8, 185u8, 113u8, 230u8, 47u8, 91u8, 253u8, 196u8, 95u8, - 102u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The size of the page; this implies the maximum message size which can be sent."] - #[doc = ""] - #[doc = " A good value depends on the expected message sizes, their weights, the weight that is"] - #[doc = " available for processing them and the maximal needed message size. The maximal message"] - #[doc = " size is slightly lower than this as defined by [`MaxMessageLenOf`]."] - pub fn heap_size(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "MessageQueue", - "HeapSize", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of stale pages (i.e. of overweight messages) allowed before culling"] - #[doc = " can happen. Once there are more stale pages than this, then historical pages may be"] - #[doc = " dropped, even if they contain unprocessed overweight messages."] - pub fn max_stale(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "MessageQueue", - "MaxStale", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The amount of weight (if any) which should be provided to the message queue for"] - #[doc = " servicing enqueued items."] - #[doc = ""] - #[doc = " This may be legitimately `None` in the case that you will call"] - #[doc = " `ServiceQueues::service_queues` manually."] - pub fn service_weight( - &self, - ) -> ::subxt::constants::Address< - ::core::option::Option, - > { - ::subxt::constants::Address::new_static( - "MessageQueue", - "ServiceWeight", - [ - 204u8, 140u8, 63u8, 167u8, 49u8, 8u8, 148u8, 163u8, 190u8, 224u8, 15u8, - 103u8, 86u8, 153u8, 248u8, 117u8, 223u8, 117u8, 210u8, 80u8, 205u8, - 155u8, 40u8, 11u8, 59u8, 63u8, 129u8, 156u8, 17u8, 83u8, 177u8, 250u8, - ], - ) - } - } - } - } - pub mod on_demand_assignment_provider { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlaceOrderAllowDeath { - pub max_amount: ::core::primitive::u128, - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for PlaceOrderAllowDeath { - const PALLET: &'static str = "OnDemandAssignmentProvider"; - const CALL: &'static str = "place_order_allow_death"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PlaceOrderKeepAlive { - pub max_amount: ::core::primitive::u128, - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for PlaceOrderKeepAlive { - const PALLET: &'static str = "OnDemandAssignmentProvider"; - const CALL: &'static str = "place_order_keep_alive"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::place_order_allow_death`]."] - pub fn place_order_allow_death( - &self, - max_amount: ::core::primitive::u128, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "OnDemandAssignmentProvider", - "place_order_allow_death", - types::PlaceOrderAllowDeath { max_amount, para_id }, - [ - 42u8, 115u8, 192u8, 118u8, 20u8, 174u8, 114u8, 94u8, 177u8, 195u8, - 175u8, 214u8, 175u8, 25u8, 167u8, 135u8, 194u8, 251u8, 186u8, 185u8, - 218u8, 153u8, 182u8, 166u8, 28u8, 238u8, 72u8, 64u8, 115u8, 67u8, 58u8, - 165u8, - ], - ) - } - #[doc = "See [`Pallet::place_order_keep_alive`]."] - pub fn place_order_keep_alive( - &self, - max_amount: ::core::primitive::u128, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "OnDemandAssignmentProvider", - "place_order_keep_alive", - types::PlaceOrderKeepAlive { max_amount, para_id }, - [ - 112u8, 56u8, 202u8, 218u8, 85u8, 138u8, 45u8, 213u8, 119u8, 36u8, 62u8, - 138u8, 217u8, 95u8, 25u8, 86u8, 119u8, 192u8, 57u8, 245u8, 34u8, 225u8, - 247u8, 116u8, 114u8, 230u8, 130u8, 180u8, 163u8, 190u8, 106u8, 5u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An order was placed at some spot price amount."] - pub struct OnDemandOrderPlaced { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub spot_price: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for OnDemandOrderPlaced { - const PALLET: &'static str = "OnDemandAssignmentProvider"; - const EVENT: &'static str = "OnDemandOrderPlaced"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The value of the spot traffic multiplier changed."] - pub struct SpotTrafficSet { - pub traffic: runtime_types::sp_arithmetic::fixed_point::FixedU128, - } - impl ::subxt::events::StaticEvent for SpotTrafficSet { - const PALLET: &'static str = "OnDemandAssignmentProvider"; - const EVENT: &'static str = "SpotTrafficSet"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Keeps track of the multiplier used to calculate the current spot price for the on demand"] - #[doc = " assigner."] - pub fn spot_traffic( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_arithmetic::fixed_point::FixedU128, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "OnDemandAssignmentProvider", - "SpotTraffic", - vec![], - [ - 8u8, 236u8, 233u8, 156u8, 211u8, 45u8, 192u8, 58u8, 108u8, 247u8, 47u8, - 97u8, 229u8, 26u8, 188u8, 67u8, 98u8, 43u8, 11u8, 11u8, 1u8, 127u8, - 15u8, 75u8, 25u8, 19u8, 220u8, 16u8, 121u8, 223u8, 207u8, 226u8, - ], - ) - } - #[doc = " The order storage entry. Uses a VecDeque to be able to push to the front of the"] - #[doc = " queue from the scheduler on session boundaries."] pub fn on_demand_queue (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , :: std :: vec :: Vec < runtime_types :: polkadot_runtime_parachains :: assigner_on_demand :: EnqueuedOrder > , :: subxt :: storage :: address :: Yes , :: subxt :: storage :: address :: Yes , () >{ - ::subxt::storage::address::Address::new_static( - "OnDemandAssignmentProvider", - "OnDemandQueue", - vec![], - [ - 241u8, 10u8, 89u8, 240u8, 227u8, 90u8, 218u8, 35u8, 80u8, 244u8, 219u8, - 112u8, 177u8, 143u8, 43u8, 228u8, 224u8, 165u8, 217u8, 65u8, 17u8, - 182u8, 61u8, 173u8, 214u8, 140u8, 224u8, 68u8, 68u8, 226u8, 208u8, - 156u8, - ], - ) - } - #[doc = " Maps a `ParaId` to `CoreIndex` and keeps track of how many assignments the scheduler has in"] - #[doc = " it's lookahead. Keeping track of this affinity prevents parallel execution of the same"] - #[doc = " `ParaId` on two or more `CoreIndex`es."] pub fn para_id_affinity_iter (& self ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: assigner_on_demand :: CoreAffinityCount , () , () , :: subxt :: storage :: address :: Yes >{ - ::subxt::storage::address::Address::new_static( - "OnDemandAssignmentProvider", - "ParaIdAffinity", - vec![], - [ - 145u8, 117u8, 2u8, 170u8, 99u8, 68u8, 166u8, 236u8, 247u8, 80u8, 202u8, - 87u8, 116u8, 244u8, 218u8, 172u8, 41u8, 187u8, 170u8, 163u8, 187u8, - 13u8, 9u8, 19u8, 55u8, 167u8, 67u8, 30u8, 57u8, 162u8, 226u8, 65u8, - ], - ) - } - #[doc = " Maps a `ParaId` to `CoreIndex` and keeps track of how many assignments the scheduler has in"] - #[doc = " it's lookahead. Keeping track of this affinity prevents parallel execution of the same"] - #[doc = " `ParaId` on two or more `CoreIndex`es."] pub fn para_id_affinity (& self , _0 : impl :: std :: borrow :: Borrow < runtime_types :: polkadot_parachain_primitives :: primitives :: Id > ,) -> :: subxt :: storage :: address :: Address :: < :: subxt :: storage :: address :: StaticStorageMapKey , runtime_types :: polkadot_runtime_parachains :: assigner_on_demand :: CoreAffinityCount , :: subxt :: storage :: address :: Yes , () , () >{ - ::subxt::storage::address::Address::new_static( - "OnDemandAssignmentProvider", - "ParaIdAffinity", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 145u8, 117u8, 2u8, 170u8, 99u8, 68u8, 166u8, 236u8, 247u8, 80u8, 202u8, - 87u8, 116u8, 244u8, 218u8, 172u8, 41u8, 187u8, 170u8, 163u8, 187u8, - 13u8, 9u8, 19u8, 55u8, 167u8, 67u8, 30u8, 57u8, 162u8, 226u8, 65u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The default value for the spot traffic multiplier."] - pub fn traffic_default_value( - &self, - ) -> ::subxt::constants::Address - { - ::subxt::constants::Address::new_static( - "OnDemandAssignmentProvider", - "TrafficDefaultValue", - [ - 62u8, 145u8, 102u8, 227u8, 159u8, 92u8, 27u8, 54u8, 159u8, 228u8, - 193u8, 99u8, 75u8, 196u8, 26u8, 250u8, 229u8, 230u8, 88u8, 109u8, - 246u8, 100u8, 152u8, 158u8, 14u8, 25u8, 224u8, 173u8, 224u8, 41u8, - 105u8, 231u8, - ], - ) - } - } - } - } - pub mod parachains_assignment_provider { - use super::root_mod; - use super::runtime_types; - } - pub mod coretime_assignment_provider { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = - runtime_types::polkadot_runtime_parachains::assigner_coretime::pallet::Error; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Scheduled assignment sets."] - #[doc = ""] - #[doc = " Assignments as of the given block number. They will go into state once the block number is"] - #[doc = " reached (and replace whatever was in there before)."] - pub fn core_schedules_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::assigner_coretime::Schedule< - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "CoretimeAssignmentProvider", - "CoreSchedules", - vec![], - [ - 34u8, 85u8, 91u8, 158u8, 28u8, 200u8, 76u8, 188u8, 253u8, 91u8, 153u8, - 42u8, 42u8, 227u8, 119u8, 181u8, 247u8, 44u8, 29u8, 24u8, 128u8, 49u8, - 57u8, 248u8, 24u8, 145u8, 34u8, 74u8, 21u8, 225u8, 159u8, 232u8, - ], - ) - } - #[doc = " Scheduled assignment sets."] - #[doc = ""] - #[doc = " Assignments as of the given block number. They will go into state once the block number is"] - #[doc = " reached (and replace whatever was in there before)."] - pub fn core_schedules_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::assigner_coretime::Schedule< - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "CoretimeAssignmentProvider", - "CoreSchedules", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 34u8, 85u8, 91u8, 158u8, 28u8, 200u8, 76u8, 188u8, 253u8, 91u8, 153u8, - 42u8, 42u8, 227u8, 119u8, 181u8, 247u8, 44u8, 29u8, 24u8, 128u8, 49u8, - 57u8, 248u8, 24u8, 145u8, 34u8, 74u8, 21u8, 225u8, 159u8, 232u8, - ], - ) - } - #[doc = " Scheduled assignment sets."] - #[doc = ""] - #[doc = " Assignments as of the given block number. They will go into state once the block number is"] - #[doc = " reached (and replace whatever was in there before)."] - pub fn core_schedules( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::assigner_coretime::Schedule< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "CoretimeAssignmentProvider", - "CoreSchedules", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 34u8, 85u8, 91u8, 158u8, 28u8, 200u8, 76u8, 188u8, 253u8, 91u8, 153u8, - 42u8, 42u8, 227u8, 119u8, 181u8, 247u8, 44u8, 29u8, 24u8, 128u8, 49u8, - 57u8, 248u8, 24u8, 145u8, 34u8, 74u8, 21u8, 225u8, 159u8, 232u8, - ], - ) - } - #[doc = " Assignments which are currently active."] - #[doc = ""] - #[doc = " They will be picked from `PendingAssignments` once we reach the scheduled block number in"] - #[doc = " `PendingAssignments`."] - pub fn core_descriptors_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::assigner_coretime::CoreDescriptor< - ::core::primitive::u32, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "CoretimeAssignmentProvider", - "CoreDescriptors", - vec![], - [ - 1u8, 90u8, 208u8, 119u8, 150u8, 241u8, 133u8, 74u8, 22u8, 166u8, 13u8, - 7u8, 73u8, 136u8, 105u8, 61u8, 251u8, 245u8, 164u8, 7u8, 45u8, 68u8, - 190u8, 224u8, 34u8, 22u8, 30u8, 250u8, 171u8, 152u8, 238u8, 120u8, - ], - ) - } - #[doc = " Assignments which are currently active."] - #[doc = ""] - #[doc = " They will be picked from `PendingAssignments` once we reach the scheduled block number in"] - #[doc = " `PendingAssignments`."] - pub fn core_descriptors( - &self, - _0: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_parachains::assigner_coretime::CoreDescriptor< - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "CoretimeAssignmentProvider", - "CoreDescriptors", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 1u8, 90u8, 208u8, 119u8, 150u8, 241u8, 133u8, 74u8, 22u8, 166u8, 13u8, - 7u8, 73u8, 136u8, 105u8, 61u8, 251u8, 245u8, 164u8, 7u8, 45u8, 68u8, - 190u8, 224u8, 34u8, 22u8, 30u8, 250u8, 171u8, 152u8, 238u8, 120u8, - ], - ) - } - } - } - } - pub mod registrar { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_common::paras_registrar::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_common::paras_registrar::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Register { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub genesis_head: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub validation_code: - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - } - impl ::subxt::blocks::StaticExtrinsic for Register { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "register"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceRegister { - pub who: ::subxt::utils::AccountId32, - pub deposit: ::core::primitive::u128, - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub genesis_head: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub validation_code: - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - } - impl ::subxt::blocks::StaticExtrinsic for ForceRegister { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "force_register"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Deregister { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for Deregister { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "deregister"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Swap { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub other: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for Swap { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "swap"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveLock { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for RemoveLock { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "remove_lock"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Reserve; - impl ::subxt::blocks::StaticExtrinsic for Reserve { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "reserve"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddLock { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for AddLock { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "add_lock"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduleCodeUpgrade { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub new_code: - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - } - impl ::subxt::blocks::StaticExtrinsic for ScheduleCodeUpgrade { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "schedule_code_upgrade"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetCurrentHead { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub new_head: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - } - impl ::subxt::blocks::StaticExtrinsic for SetCurrentHead { - const PALLET: &'static str = "Registrar"; - const CALL: &'static str = "set_current_head"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::register`]."] - pub fn register( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - genesis_head : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData, - validation_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "register", - types::Register { id, genesis_head, validation_code }, - [ - 208u8, 1u8, 38u8, 95u8, 53u8, 67u8, 148u8, 138u8, 189u8, 212u8, 250u8, - 160u8, 99u8, 220u8, 231u8, 55u8, 220u8, 21u8, 188u8, 81u8, 162u8, - 219u8, 93u8, 136u8, 255u8, 22u8, 5u8, 147u8, 40u8, 46u8, 141u8, 77u8, - ], - ) - } - #[doc = "See [`Pallet::force_register`]."] - pub fn force_register( - &self, - who: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - genesis_head : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData, - validation_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "force_register", - types::ForceRegister { who, deposit, id, genesis_head, validation_code }, - [ - 73u8, 118u8, 161u8, 95u8, 234u8, 106u8, 174u8, 143u8, 34u8, 235u8, - 140u8, 166u8, 210u8, 101u8, 53u8, 191u8, 194u8, 17u8, 189u8, 187u8, - 86u8, 91u8, 112u8, 248u8, 109u8, 208u8, 37u8, 70u8, 26u8, 195u8, 90u8, - 207u8, - ], - ) - } - #[doc = "See [`Pallet::deregister`]."] - pub fn deregister( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "deregister", - types::Deregister { id }, - [ - 212u8, 38u8, 98u8, 234u8, 146u8, 188u8, 71u8, 244u8, 238u8, 255u8, 3u8, - 89u8, 52u8, 242u8, 126u8, 187u8, 185u8, 193u8, 174u8, 187u8, 196u8, - 3u8, 66u8, 77u8, 173u8, 115u8, 52u8, 210u8, 69u8, 221u8, 109u8, 112u8, - ], - ) - } - #[doc = "See [`Pallet::swap`]."] - pub fn swap( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - other: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "swap", - types::Swap { id, other }, - [ - 235u8, 169u8, 16u8, 199u8, 107u8, 54u8, 35u8, 160u8, 219u8, 156u8, - 177u8, 205u8, 83u8, 45u8, 30u8, 233u8, 8u8, 143u8, 27u8, 123u8, 156u8, - 65u8, 128u8, 233u8, 218u8, 230u8, 98u8, 206u8, 231u8, 95u8, 224u8, - 35u8, - ], - ) - } - #[doc = "See [`Pallet::remove_lock`]."] - pub fn remove_lock( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "remove_lock", - types::RemoveLock { para }, - [ - 239u8, 207u8, 248u8, 246u8, 244u8, 128u8, 113u8, 114u8, 6u8, 232u8, - 218u8, 123u8, 241u8, 190u8, 255u8, 48u8, 26u8, 248u8, 33u8, 86u8, 87u8, - 219u8, 65u8, 104u8, 66u8, 68u8, 34u8, 201u8, 43u8, 159u8, 141u8, 100u8, - ], - ) - } - #[doc = "See [`Pallet::reserve`]."] - pub fn reserve(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "reserve", - types::Reserve {}, - [ - 50u8, 72u8, 218u8, 145u8, 224u8, 93u8, 219u8, 220u8, 121u8, 35u8, - 104u8, 11u8, 139u8, 114u8, 171u8, 101u8, 40u8, 13u8, 33u8, 39u8, 245u8, - 146u8, 138u8, 159u8, 245u8, 236u8, 26u8, 0u8, 20u8, 243u8, 128u8, 81u8, - ], - ) - } - #[doc = "See [`Pallet::add_lock`]."] - pub fn add_lock( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "add_lock", - types::AddLock { para }, - [ - 158u8, 27u8, 55u8, 53u8, 71u8, 221u8, 37u8, 73u8, 23u8, 165u8, 129u8, - 17u8, 167u8, 79u8, 112u8, 35u8, 231u8, 8u8, 241u8, 151u8, 207u8, 235u8, - 224u8, 104u8, 102u8, 108u8, 10u8, 244u8, 33u8, 67u8, 45u8, 13u8, - ], - ) - } - #[doc = "See [`Pallet::schedule_code_upgrade`]."] - pub fn schedule_code_upgrade( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - new_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "schedule_code_upgrade", - types::ScheduleCodeUpgrade { para, new_code }, - [ - 234u8, 22u8, 133u8, 175u8, 218u8, 250u8, 119u8, 175u8, 23u8, 250u8, - 175u8, 48u8, 247u8, 208u8, 235u8, 167u8, 24u8, 248u8, 247u8, 236u8, - 239u8, 9u8, 78u8, 195u8, 146u8, 172u8, 41u8, 105u8, 183u8, 253u8, 1u8, - 170u8, - ], - ) - } - #[doc = "See [`Pallet::set_current_head`]."] - pub fn set_current_head( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - new_head: runtime_types::polkadot_parachain_primitives::primitives::HeadData, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Registrar", - "set_current_head", - types::SetCurrentHead { para, new_head }, - [ - 201u8, 49u8, 104u8, 135u8, 80u8, 233u8, 154u8, 193u8, 143u8, 209u8, - 10u8, 209u8, 234u8, 252u8, 142u8, 216u8, 220u8, 249u8, 23u8, 252u8, - 73u8, 169u8, 204u8, 242u8, 59u8, 19u8, 18u8, 35u8, 115u8, 209u8, 79u8, - 112u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Registered { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub manager: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Registered { - const PALLET: &'static str = "Registrar"; - const EVENT: &'static str = "Registered"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Deregistered { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for Deregistered { - const PALLET: &'static str = "Registrar"; - const EVENT: &'static str = "Deregistered"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Reserved { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for Reserved { - const PALLET: &'static str = "Registrar"; - const EVENT: &'static str = "Reserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Swapped { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub other_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for Swapped { - const PALLET: &'static str = "Registrar"; - const EVENT: &'static str = "Swapped"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Pending swap operations."] - pub fn pending_swap_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::Id, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "PendingSwap", - vec![], - [ - 75u8, 6u8, 68u8, 43u8, 108u8, 147u8, 220u8, 90u8, 190u8, 86u8, 209u8, - 141u8, 9u8, 254u8, 103u8, 10u8, 94u8, 187u8, 155u8, 249u8, 140u8, - 167u8, 248u8, 196u8, 67u8, 169u8, 186u8, 192u8, 139u8, 188u8, 48u8, - 221u8, - ], - ) - } - #[doc = " Pending swap operations."] - pub fn pending_swap( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "PendingSwap", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 75u8, 6u8, 68u8, 43u8, 108u8, 147u8, 220u8, 90u8, 190u8, 86u8, 209u8, - 141u8, 9u8, 254u8, 103u8, 10u8, 94u8, 187u8, 155u8, 249u8, 140u8, - 167u8, 248u8, 196u8, 67u8, 169u8, 186u8, 192u8, 139u8, 188u8, 48u8, - 221u8, - ], - ) - } - #[doc = " Amount held on deposit for each para and the original depositor."] - #[doc = ""] - #[doc = " The given account ID is responsible for registering the code and initial head data, but may"] - #[doc = " only do so if it isn't yet registered. (After that, it's up to governance to do so.)"] - pub fn paras_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::paras_registrar::ParaInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "Paras", - vec![], - [ - 125u8, 62u8, 50u8, 209u8, 40u8, 170u8, 61u8, 62u8, 61u8, 246u8, 103u8, - 229u8, 213u8, 94u8, 249u8, 49u8, 18u8, 90u8, 138u8, 14u8, 101u8, 133u8, - 28u8, 167u8, 5u8, 77u8, 113u8, 207u8, 57u8, 142u8, 77u8, 117u8, - ], - ) - } - #[doc = " Amount held on deposit for each para and the original depositor."] - #[doc = ""] - #[doc = " The given account ID is responsible for registering the code and initial head data, but may"] - #[doc = " only do so if it isn't yet registered. (After that, it's up to governance to do so.)"] - pub fn paras( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::paras_registrar::ParaInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "Paras", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 125u8, 62u8, 50u8, 209u8, 40u8, 170u8, 61u8, 62u8, 61u8, 246u8, 103u8, - 229u8, 213u8, 94u8, 249u8, 49u8, 18u8, 90u8, 138u8, 14u8, 101u8, 133u8, - 28u8, 167u8, 5u8, 77u8, 113u8, 207u8, 57u8, 142u8, 77u8, 117u8, - ], - ) - } - #[doc = " The next free `ParaId`."] - pub fn next_free_para_id( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Registrar", - "NextFreeParaId", - vec![], - [ - 52u8, 14u8, 56u8, 196u8, 79u8, 221u8, 32u8, 14u8, 154u8, 247u8, 94u8, - 219u8, 11u8, 11u8, 104u8, 137u8, 167u8, 195u8, 180u8, 101u8, 35u8, - 235u8, 67u8, 144u8, 128u8, 209u8, 189u8, 227u8, 177u8, 74u8, 42u8, - 15u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The deposit to be paid to run a on-demand parachain."] - #[doc = " This should include the cost for storing the genesis head and validation code."] - pub fn para_deposit(&self) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Registrar", - "ParaDeposit", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " The deposit to be paid per byte stored on chain."] - pub fn data_deposit_per_byte( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Registrar", - "DataDepositPerByte", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - } - } - } - pub mod slots { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_common::slots::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_common::slots::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceLease { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub leaser: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - pub period_begin: ::core::primitive::u32, - pub period_count: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceLease { - const PALLET: &'static str = "Slots"; - const CALL: &'static str = "force_lease"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ClearAllLeases { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for ClearAllLeases { - const PALLET: &'static str = "Slots"; - const CALL: &'static str = "clear_all_leases"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TriggerOnboard { - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for TriggerOnboard { - const PALLET: &'static str = "Slots"; - const CALL: &'static str = "trigger_onboard"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::force_lease`]."] - pub fn force_lease( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - period_begin: ::core::primitive::u32, - period_count: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Slots", - "force_lease", - types::ForceLease { para, leaser, amount, period_begin, period_count }, - [ - 27u8, 203u8, 227u8, 16u8, 65u8, 135u8, 140u8, 244u8, 218u8, 231u8, - 78u8, 190u8, 169u8, 156u8, 233u8, 31u8, 20u8, 119u8, 158u8, 34u8, - 130u8, 51u8, 38u8, 176u8, 142u8, 139u8, 152u8, 139u8, 26u8, 184u8, - 238u8, 227u8, - ], - ) - } - #[doc = "See [`Pallet::clear_all_leases`]."] - pub fn clear_all_leases( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Slots", - "clear_all_leases", - types::ClearAllLeases { para }, - [ - 201u8, 71u8, 106u8, 50u8, 65u8, 107u8, 191u8, 41u8, 52u8, 106u8, 51u8, - 87u8, 19u8, 199u8, 244u8, 93u8, 104u8, 148u8, 116u8, 198u8, 169u8, - 137u8, 28u8, 78u8, 54u8, 230u8, 161u8, 16u8, 79u8, 248u8, 28u8, 183u8, - ], - ) - } - #[doc = "See [`Pallet::trigger_onboard`]."] - pub fn trigger_onboard( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Slots", - "trigger_onboard", - types::TriggerOnboard { para }, - [ - 192u8, 239u8, 65u8, 186u8, 200u8, 27u8, 23u8, 235u8, 2u8, 229u8, 230u8, - 192u8, 240u8, 51u8, 62u8, 80u8, 253u8, 105u8, 178u8, 134u8, 252u8, 2u8, - 153u8, 29u8, 235u8, 249u8, 92u8, 246u8, 136u8, 169u8, 109u8, 4u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_common::slots::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new `[lease_period]` is beginning."] - pub struct NewLeasePeriod { - pub lease_period: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for NewLeasePeriod { - const PALLET: &'static str = "Slots"; - const EVENT: &'static str = "NewLeasePeriod"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A para has won the right to a continuous set of lease periods as a parachain."] - #[doc = "First balance is any extra amount reserved on top of the para's existing deposit."] - #[doc = "Second balance is the total amount reserved."] - pub struct Leased { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub leaser: ::subxt::utils::AccountId32, - pub period_begin: ::core::primitive::u32, - pub period_count: ::core::primitive::u32, - pub extra_reserved: ::core::primitive::u128, - pub total_amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Leased { - const PALLET: &'static str = "Slots"; - const EVENT: &'static str = "Leased"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Amounts held on deposit for each (possibly future) leased parachain."] - #[doc = ""] - #[doc = " The actual amount locked on its behalf by any account at any time is the maximum of the"] - #[doc = " second values of the items in this list whose first value is the account."] - #[doc = ""] - #[doc = " The first item in the list is the amount locked for the current Lease Period. Following"] - #[doc = " items are for the subsequent lease periods."] - #[doc = ""] - #[doc = " The default value (an empty list) implies that the parachain no longer exists (or never"] - #[doc = " existed) as far as this pallet is concerned."] - #[doc = ""] - #[doc = " If a parachain doesn't exist *yet* but is scheduled to exist in the future, then it"] - #[doc = " will be left-padded with one or more `None`s to denote the fact that nothing is held on"] - #[doc = " deposit for the non-existent chain currently, but is held at some point in the future."] - #[doc = ""] - #[doc = " It is illegal for a `None` value to trail in the list."] - pub fn leases_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - ::core::option::Option<( - ::subxt::utils::AccountId32, - ::core::primitive::u128, - )>, - >, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Slots", - "Leases", - vec![], - [ - 233u8, 226u8, 181u8, 160u8, 216u8, 86u8, 238u8, 229u8, 31u8, 67u8, - 200u8, 188u8, 134u8, 22u8, 88u8, 147u8, 204u8, 11u8, 34u8, 244u8, - 234u8, 77u8, 184u8, 171u8, 147u8, 228u8, 254u8, 11u8, 40u8, 162u8, - 177u8, 196u8, - ], - ) - } - #[doc = " Amounts held on deposit for each (possibly future) leased parachain."] - #[doc = ""] - #[doc = " The actual amount locked on its behalf by any account at any time is the maximum of the"] - #[doc = " second values of the items in this list whose first value is the account."] - #[doc = ""] - #[doc = " The first item in the list is the amount locked for the current Lease Period. Following"] - #[doc = " items are for the subsequent lease periods."] - #[doc = ""] - #[doc = " The default value (an empty list) implies that the parachain no longer exists (or never"] - #[doc = " existed) as far as this pallet is concerned."] - #[doc = ""] - #[doc = " If a parachain doesn't exist *yet* but is scheduled to exist in the future, then it"] - #[doc = " will be left-padded with one or more `None`s to denote the fact that nothing is held on"] - #[doc = " deposit for the non-existent chain currently, but is held at some point in the future."] - #[doc = ""] - #[doc = " It is illegal for a `None` value to trail in the list."] - pub fn leases( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec< - ::core::option::Option<( - ::subxt::utils::AccountId32, - ::core::primitive::u128, - )>, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Slots", - "Leases", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 233u8, 226u8, 181u8, 160u8, 216u8, 86u8, 238u8, 229u8, 31u8, 67u8, - 200u8, 188u8, 134u8, 22u8, 88u8, 147u8, 204u8, 11u8, 34u8, 244u8, - 234u8, 77u8, 184u8, 171u8, 147u8, 228u8, 254u8, 11u8, 40u8, 162u8, - 177u8, 196u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The number of blocks over which a single period lasts."] - pub fn lease_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Slots", - "LeasePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of blocks to offset each lease period by."] - pub fn lease_offset(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Slots", - "LeaseOffset", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod auctions { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_common::auctions::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_common::auctions::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct NewAuction { - #[codec(compact)] - pub duration: ::core::primitive::u32, - #[codec(compact)] - pub lease_period_index: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for NewAuction { - const PALLET: &'static str = "Auctions"; - const CALL: &'static str = "new_auction"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bid { - #[codec(compact)] - pub para: runtime_types::polkadot_parachain_primitives::primitives::Id, - #[codec(compact)] - pub auction_index: ::core::primitive::u32, - #[codec(compact)] - pub first_slot: ::core::primitive::u32, - #[codec(compact)] - pub last_slot: ::core::primitive::u32, - #[codec(compact)] - pub amount: ::core::primitive::u128, - } - impl ::subxt::blocks::StaticExtrinsic for Bid { - const PALLET: &'static str = "Auctions"; - const CALL: &'static str = "bid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CancelAuction; - impl ::subxt::blocks::StaticExtrinsic for CancelAuction { - const PALLET: &'static str = "Auctions"; - const CALL: &'static str = "cancel_auction"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::new_auction`]."] - pub fn new_auction( - &self, - duration: ::core::primitive::u32, - lease_period_index: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Auctions", - "new_auction", - types::NewAuction { duration, lease_period_index }, - [ - 116u8, 2u8, 215u8, 191u8, 69u8, 99u8, 218u8, 198u8, 71u8, 228u8, 88u8, - 144u8, 139u8, 206u8, 214u8, 58u8, 106u8, 117u8, 138u8, 115u8, 109u8, - 253u8, 210u8, 135u8, 189u8, 190u8, 86u8, 189u8, 8u8, 168u8, 142u8, - 181u8, - ], - ) - } - #[doc = "See [`Pallet::bid`]."] - pub fn bid( - &self, - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - auction_index: ::core::primitive::u32, - first_slot: ::core::primitive::u32, - last_slot: ::core::primitive::u32, - amount: ::core::primitive::u128, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Auctions", - "bid", - types::Bid { para, auction_index, first_slot, last_slot, amount }, - [ - 203u8, 71u8, 160u8, 55u8, 95u8, 152u8, 111u8, 30u8, 86u8, 113u8, 213u8, - 217u8, 140u8, 9u8, 138u8, 150u8, 90u8, 229u8, 17u8, 95u8, 141u8, 150u8, - 183u8, 171u8, 45u8, 110u8, 47u8, 91u8, 159u8, 91u8, 214u8, 132u8, - ], - ) - } - #[doc = "See [`Pallet::cancel_auction`]."] - pub fn cancel_auction(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Auctions", - "cancel_auction", - types::CancelAuction {}, - [ - 122u8, 231u8, 136u8, 184u8, 194u8, 4u8, 244u8, 62u8, 253u8, 134u8, 9u8, - 240u8, 75u8, 227u8, 74u8, 195u8, 113u8, 247u8, 127u8, 17u8, 90u8, - 228u8, 251u8, 88u8, 4u8, 29u8, 254u8, 71u8, 177u8, 103u8, 66u8, 224u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_common::auctions::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An auction started. Provides its index and the block number where it will begin to"] - #[doc = "close and the first lease period of the quadruplet that is auctioned."] - pub struct AuctionStarted { - pub auction_index: ::core::primitive::u32, - pub lease_period: ::core::primitive::u32, - pub ending: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for AuctionStarted { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "AuctionStarted"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An auction ended. All funds become unreserved."] - pub struct AuctionClosed { - pub auction_index: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for AuctionClosed { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "AuctionClosed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Funds were reserved for a winning bid. First balance is the extra amount reserved."] - #[doc = "Second is the total."] - pub struct Reserved { - pub bidder: ::subxt::utils::AccountId32, - pub extra_reserved: ::core::primitive::u128, - pub total_amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Reserved { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "Reserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Funds were unreserved since bidder is no longer active. `[bidder, amount]`"] - pub struct Unreserved { - pub bidder: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Unreserved { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "Unreserved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Someone attempted to lease the same slot twice for a parachain. The amount is held in"] - #[doc = "reserve but no parachain slot has been leased."] - pub struct ReserveConfiscated { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub leaser: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for ReserveConfiscated { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "ReserveConfiscated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A new bid has been accepted as the current winner."] - pub struct BidAccepted { - pub bidder: ::subxt::utils::AccountId32, - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub amount: ::core::primitive::u128, - pub first_slot: ::core::primitive::u32, - pub last_slot: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for BidAccepted { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "BidAccepted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The winning offset was chosen for an auction. This will map into the `Winning` storage"] - #[doc = "map."] - pub struct WinningOffset { - pub auction_index: ::core::primitive::u32, - pub block_number: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for WinningOffset { - const PALLET: &'static str = "Auctions"; - const EVENT: &'static str = "WinningOffset"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Number of auctions started so far."] - pub fn auction_counter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "AuctionCounter", - vec![], - [ - 110u8, 243u8, 85u8, 4u8, 127u8, 111u8, 101u8, 167u8, 72u8, 129u8, - 201u8, 250u8, 88u8, 9u8, 79u8, 14u8, 152u8, 132u8, 0u8, 204u8, 112u8, - 248u8, 91u8, 254u8, 30u8, 22u8, 62u8, 180u8, 188u8, 204u8, 29u8, 103u8, - ], - ) - } - #[doc = " Information relating to the current auction, if there is one."] - #[doc = ""] - #[doc = " The first item in the tuple is the lease period index that the first of the four"] - #[doc = " contiguous lease periods on auction is for. The second is the block number when the"] - #[doc = " auction will \"begin to end\", i.e. the first block of the Ending Period of the auction."] - pub fn auction_info( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "AuctionInfo", - vec![], - [ - 116u8, 81u8, 223u8, 26u8, 151u8, 103u8, 209u8, 182u8, 169u8, 173u8, - 220u8, 234u8, 88u8, 191u8, 255u8, 75u8, 148u8, 75u8, 167u8, 37u8, 6u8, - 14u8, 224u8, 193u8, 92u8, 82u8, 205u8, 172u8, 209u8, 83u8, 3u8, 77u8, - ], - ) - } - #[doc = " Amounts currently reserved in the accounts of the bidders currently winning"] - #[doc = " (sub-)ranges."] - pub fn reserved_amounts_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "ReservedAmounts", - vec![], - [ - 77u8, 44u8, 116u8, 36u8, 189u8, 213u8, 126u8, 32u8, 42u8, 131u8, 108u8, - 41u8, 147u8, 40u8, 247u8, 245u8, 161u8, 42u8, 152u8, 195u8, 28u8, - 142u8, 231u8, 209u8, 113u8, 11u8, 240u8, 37u8, 112u8, 38u8, 239u8, - 245u8, - ], - ) - } - #[doc = " Amounts currently reserved in the accounts of the bidders currently winning"] - #[doc = " (sub-)ranges."] - pub fn reserved_amounts_iter1( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "ReservedAmounts", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 77u8, 44u8, 116u8, 36u8, 189u8, 213u8, 126u8, 32u8, 42u8, 131u8, 108u8, - 41u8, 147u8, 40u8, 247u8, 245u8, 161u8, 42u8, 152u8, 195u8, 28u8, - 142u8, 231u8, 209u8, 113u8, 11u8, 240u8, 37u8, 112u8, 38u8, 239u8, - 245u8, - ], - ) - } - #[doc = " Amounts currently reserved in the accounts of the bidders currently winning"] - #[doc = " (sub-)ranges."] - pub fn reserved_amounts( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _1: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u128, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "ReservedAmounts", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 77u8, 44u8, 116u8, 36u8, 189u8, 213u8, 126u8, 32u8, 42u8, 131u8, 108u8, - 41u8, 147u8, 40u8, 247u8, 245u8, 161u8, 42u8, 152u8, 195u8, 28u8, - 142u8, 231u8, 209u8, 113u8, 11u8, 240u8, 37u8, 112u8, 38u8, 239u8, - 245u8, - ], - ) - } - #[doc = " The winning bids for each of the 10 ranges at each sample in the final Ending Period of"] - #[doc = " the current auction. The map's key is the 0-based index into the Sample Size. The"] - #[doc = " first sample of the ending period is 0; the last is `Sample Size - 1`."] - pub fn winning_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - [::core::option::Option<( - ::subxt::utils::AccountId32, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u128, - )>; 36usize], - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "Winning", - vec![], - [ - 8u8, 136u8, 174u8, 152u8, 223u8, 1u8, 143u8, 45u8, 213u8, 5u8, 239u8, - 163u8, 152u8, 99u8, 197u8, 109u8, 194u8, 140u8, 246u8, 10u8, 40u8, - 22u8, 0u8, 122u8, 20u8, 132u8, 141u8, 157u8, 56u8, 211u8, 5u8, 104u8, - ], - ) - } - #[doc = " The winning bids for each of the 10 ranges at each sample in the final Ending Period of"] - #[doc = " the current auction. The map's key is the 0-based index into the Sample Size. The"] - #[doc = " first sample of the ending period is 0; the last is `Sample Size - 1`."] - pub fn winning( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - [::core::option::Option<( - ::subxt::utils::AccountId32, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u128, - )>; 36usize], - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Auctions", - "Winning", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 8u8, 136u8, 174u8, 152u8, 223u8, 1u8, 143u8, 45u8, 213u8, 5u8, 239u8, - 163u8, 152u8, 99u8, 197u8, 109u8, 194u8, 140u8, 246u8, 10u8, 40u8, - 22u8, 0u8, 122u8, 20u8, 132u8, 141u8, 157u8, 56u8, 211u8, 5u8, 104u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The number of blocks over which an auction may be retroactively ended."] - pub fn ending_period(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Auctions", - "EndingPeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The length of each sample to take during the ending period."] - #[doc = ""] - #[doc = " `EndingPeriod` / `SampleLength` = Total # of Samples"] - pub fn sample_length(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Auctions", - "SampleLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn slot_range_count( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Auctions", - "SlotRangeCount", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - pub fn lease_periods_per_slot( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Auctions", - "LeasePeriodsPerSlot", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod crowdloan { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_common::crowdloan::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_common::crowdloan::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Create { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - #[codec(compact)] - pub cap: ::core::primitive::u128, - #[codec(compact)] - pub first_period: ::core::primitive::u32, - #[codec(compact)] - pub last_period: ::core::primitive::u32, - #[codec(compact)] - pub end: ::core::primitive::u32, - pub verifier: ::core::option::Option, - } - impl ::subxt::blocks::StaticExtrinsic for Create { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "create"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Contribute { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - #[codec(compact)] - pub value: ::core::primitive::u128, - pub signature: - ::core::option::Option, - } - impl ::subxt::blocks::StaticExtrinsic for Contribute { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "contribute"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Withdraw { - pub who: ::subxt::utils::AccountId32, - #[codec(compact)] - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for Withdraw { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "withdraw"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Refund { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for Refund { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "refund"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Dissolve { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for Dissolve { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "dissolve"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Edit { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - #[codec(compact)] - pub cap: ::core::primitive::u128, - #[codec(compact)] - pub first_period: ::core::primitive::u32, - #[codec(compact)] - pub last_period: ::core::primitive::u32, - #[codec(compact)] - pub end: ::core::primitive::u32, - pub verifier: ::core::option::Option, - } - impl ::subxt::blocks::StaticExtrinsic for Edit { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "edit"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AddMemo { - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub memo: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::blocks::StaticExtrinsic for AddMemo { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "add_memo"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Poke { - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for Poke { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "poke"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ContributeAll { - #[codec(compact)] - pub index: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub signature: - ::core::option::Option, - } - impl ::subxt::blocks::StaticExtrinsic for ContributeAll { - const PALLET: &'static str = "Crowdloan"; - const CALL: &'static str = "contribute_all"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::create`]."] - pub fn create( - &self, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - cap: ::core::primitive::u128, - first_period: ::core::primitive::u32, - last_period: ::core::primitive::u32, - end: ::core::primitive::u32, - verifier: ::core::option::Option, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "create", - types::Create { index, cap, first_period, last_period, end, verifier }, - [ - 236u8, 3u8, 248u8, 168u8, 136u8, 216u8, 20u8, 58u8, 179u8, 13u8, 184u8, - 73u8, 105u8, 35u8, 167u8, 66u8, 117u8, 195u8, 41u8, 41u8, 117u8, 176u8, - 65u8, 18u8, 225u8, 66u8, 2u8, 61u8, 212u8, 92u8, 117u8, 90u8, - ], - ) - } - #[doc = "See [`Pallet::contribute`]."] - pub fn contribute( - &self, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - value: ::core::primitive::u128, - signature: ::core::option::Option, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "contribute", - types::Contribute { index, value, signature }, - [ - 186u8, 247u8, 240u8, 7u8, 12u8, 239u8, 39u8, 191u8, 150u8, 219u8, - 137u8, 122u8, 214u8, 61u8, 62u8, 180u8, 229u8, 181u8, 105u8, 190u8, - 228u8, 55u8, 242u8, 70u8, 91u8, 118u8, 143u8, 233u8, 186u8, 231u8, - 207u8, 106u8, - ], - ) - } - #[doc = "See [`Pallet::withdraw`]."] - pub fn withdraw( - &self, - who: ::subxt::utils::AccountId32, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "withdraw", - types::Withdraw { who, index }, - [ - 148u8, 23u8, 138u8, 161u8, 248u8, 235u8, 138u8, 156u8, 209u8, 236u8, - 235u8, 81u8, 207u8, 212u8, 232u8, 126u8, 221u8, 46u8, 34u8, 39u8, 44u8, - 42u8, 75u8, 134u8, 12u8, 247u8, 84u8, 203u8, 48u8, 133u8, 72u8, 254u8, - ], - ) - } - #[doc = "See [`Pallet::refund`]."] - pub fn refund( - &self, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "refund", - types::Refund { index }, - [ - 245u8, 75u8, 215u8, 28u8, 141u8, 138u8, 201u8, 125u8, 21u8, 214u8, - 57u8, 23u8, 33u8, 41u8, 57u8, 227u8, 119u8, 212u8, 234u8, 227u8, 230u8, - 144u8, 249u8, 100u8, 198u8, 125u8, 106u8, 253u8, 93u8, 177u8, 247u8, - 5u8, - ], - ) - } - #[doc = "See [`Pallet::dissolve`]."] - pub fn dissolve( - &self, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "dissolve", - types::Dissolve { index }, - [ - 60u8, 225u8, 93u8, 234u8, 160u8, 90u8, 185u8, 188u8, 163u8, 72u8, - 241u8, 46u8, 62u8, 176u8, 236u8, 175u8, 147u8, 95u8, 45u8, 235u8, - 253u8, 76u8, 127u8, 190u8, 149u8, 54u8, 108u8, 78u8, 149u8, 161u8, - 39u8, 14u8, - ], - ) - } - #[doc = "See [`Pallet::edit`]."] - pub fn edit( - &self, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - cap: ::core::primitive::u128, - first_period: ::core::primitive::u32, - last_period: ::core::primitive::u32, - end: ::core::primitive::u32, - verifier: ::core::option::Option, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "edit", - types::Edit { index, cap, first_period, last_period, end, verifier }, - [ - 126u8, 29u8, 232u8, 93u8, 94u8, 23u8, 47u8, 217u8, 62u8, 2u8, 161u8, - 31u8, 156u8, 229u8, 109u8, 45u8, 97u8, 101u8, 189u8, 139u8, 40u8, - 238u8, 150u8, 94u8, 145u8, 77u8, 26u8, 153u8, 217u8, 171u8, 48u8, - 195u8, - ], - ) - } - #[doc = "See [`Pallet::add_memo`]."] - pub fn add_memo( - &self, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - memo: ::std::vec::Vec<::core::primitive::u8>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "add_memo", - types::AddMemo { index, memo }, - [ - 190u8, 99u8, 225u8, 54u8, 136u8, 238u8, 210u8, 44u8, 103u8, 198u8, - 225u8, 254u8, 245u8, 12u8, 238u8, 112u8, 143u8, 169u8, 8u8, 193u8, - 29u8, 0u8, 159u8, 25u8, 112u8, 237u8, 194u8, 17u8, 111u8, 192u8, 219u8, - 50u8, - ], - ) - } - #[doc = "See [`Pallet::poke`]."] - pub fn poke( - &self, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "poke", - types::Poke { index }, - [ - 180u8, 81u8, 211u8, 12u8, 54u8, 204u8, 105u8, 118u8, 139u8, 209u8, - 182u8, 227u8, 174u8, 192u8, 64u8, 200u8, 212u8, 101u8, 3u8, 252u8, - 195u8, 110u8, 182u8, 121u8, 218u8, 193u8, 87u8, 38u8, 212u8, 151u8, - 213u8, 56u8, - ], - ) - } - #[doc = "See [`Pallet::contribute_all`]."] - pub fn contribute_all( - &self, - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - signature: ::core::option::Option, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Crowdloan", - "contribute_all", - types::ContributeAll { index, signature }, - [ - 233u8, 62u8, 129u8, 168u8, 161u8, 163u8, 78u8, 92u8, 191u8, 239u8, - 61u8, 2u8, 198u8, 246u8, 246u8, 81u8, 32u8, 131u8, 118u8, 170u8, 72u8, - 87u8, 17u8, 26u8, 55u8, 10u8, 146u8, 184u8, 213u8, 200u8, 252u8, 50u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_common::crowdloan::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Create a new crowdloaning campaign."] - pub struct Created { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for Created { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Created"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contributed to a crowd sale."] - pub struct Contributed { - pub who: ::subxt::utils::AccountId32, - pub fund_index: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Contributed { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Contributed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Withdrew full balance of a contributor."] - pub struct Withdrew { - pub who: ::subxt::utils::AccountId32, - pub fund_index: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Withdrew { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Withdrew"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The loans in a fund have been partially dissolved, i.e. there are some left"] - #[doc = "over child keys that still need to be killed."] - pub struct PartiallyRefunded { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for PartiallyRefunded { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "PartiallyRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "All loans in a fund have been refunded."] - pub struct AllRefunded { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for AllRefunded { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "AllRefunded"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Fund is dissolved."] - pub struct Dissolved { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for Dissolved { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Dissolved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The result of trying to submit a new bid to the Slots pallet."] - pub struct HandleBidResult { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub result: ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for HandleBidResult { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "HandleBidResult"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The configuration to a crowdloan has been edited."] - pub struct Edited { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for Edited { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "Edited"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A memo has been updated."] - pub struct MemoUpdated { - pub who: ::subxt::utils::AccountId32, - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub memo: ::std::vec::Vec<::core::primitive::u8>, - } - impl ::subxt::events::StaticEvent for MemoUpdated { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "MemoUpdated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A parachain has been moved to `NewRaise`"] - pub struct AddedToNewRaise { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::events::StaticEvent for AddedToNewRaise { - const PALLET: &'static str = "Crowdloan"; - const EVENT: &'static str = "AddedToNewRaise"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Info on all of the funds."] - pub fn funds_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::crowdloan::FundInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "Funds", - vec![], - [ - 191u8, 255u8, 37u8, 49u8, 246u8, 246u8, 168u8, 178u8, 73u8, 238u8, - 49u8, 76u8, 66u8, 246u8, 207u8, 12u8, 76u8, 233u8, 31u8, 218u8, 132u8, - 236u8, 237u8, 210u8, 116u8, 159u8, 191u8, 89u8, 212u8, 167u8, 61u8, - 41u8, - ], - ) - } - #[doc = " Info on all of the funds."] - pub fn funds( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::crowdloan::FundInfo< - ::subxt::utils::AccountId32, - ::core::primitive::u128, - ::core::primitive::u32, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "Funds", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 191u8, 255u8, 37u8, 49u8, 246u8, 246u8, 168u8, 178u8, 73u8, 238u8, - 49u8, 76u8, 66u8, 246u8, 207u8, 12u8, 76u8, 233u8, 31u8, 218u8, 132u8, - 236u8, 237u8, 210u8, 116u8, 159u8, 191u8, 89u8, 212u8, 167u8, 61u8, - 41u8, - ], - ) - } - #[doc = " The funds that have had additional contributions during the last block. This is used"] - #[doc = " in order to determine which funds should submit new or updated bids."] - pub fn new_raise( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "NewRaise", - vec![], - [ - 251u8, 31u8, 237u8, 22u8, 90u8, 248u8, 39u8, 66u8, 93u8, 81u8, 209u8, - 209u8, 194u8, 42u8, 109u8, 208u8, 56u8, 75u8, 45u8, 247u8, 253u8, - 165u8, 22u8, 184u8, 49u8, 49u8, 62u8, 126u8, 254u8, 146u8, 190u8, - 174u8, - ], - ) - } - #[doc = " The number of auctions that have entered into their ending period so far."] - pub fn endings_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "EndingsCount", - vec![], - [ - 106u8, 22u8, 229u8, 157u8, 118u8, 195u8, 11u8, 42u8, 5u8, 50u8, 44u8, - 183u8, 72u8, 167u8, 95u8, 243u8, 234u8, 5u8, 200u8, 253u8, 127u8, - 154u8, 23u8, 55u8, 202u8, 221u8, 82u8, 19u8, 201u8, 154u8, 248u8, 29u8, - ], - ) - } - #[doc = " Tracker for the next available fund index"] - pub fn next_fund_index( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Crowdloan", - "NextFundIndex", - vec![], - [ - 192u8, 21u8, 229u8, 234u8, 152u8, 224u8, 149u8, 44u8, 41u8, 9u8, 191u8, - 128u8, 118u8, 11u8, 117u8, 245u8, 170u8, 116u8, 77u8, 216u8, 175u8, - 115u8, 13u8, 85u8, 240u8, 170u8, 156u8, 201u8, 25u8, 96u8, 103u8, - 207u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " `PalletId` for the crowdloan pallet. An appropriate value could be"] - #[doc = " `PalletId(*b\"py/cfund\")`"] - pub fn pallet_id( - &self, - ) -> ::subxt::constants::Address { - ::subxt::constants::Address::new_static( - "Crowdloan", - "PalletId", - [ - 56u8, 243u8, 53u8, 83u8, 154u8, 179u8, 170u8, 80u8, 133u8, 173u8, 61u8, - 161u8, 47u8, 225u8, 146u8, 21u8, 50u8, 229u8, 248u8, 27u8, 104u8, 58u8, - 129u8, 197u8, 102u8, 160u8, 168u8, 205u8, 154u8, 42u8, 217u8, 53u8, - ], - ) - } - #[doc = " The minimum amount that may be contributed into a crowdloan. Should almost certainly be"] - #[doc = " at least `ExistentialDeposit`."] - pub fn min_contribution( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u128> { - ::subxt::constants::Address::new_static( - "Crowdloan", - "MinContribution", - [ - 84u8, 157u8, 140u8, 4u8, 93u8, 57u8, 29u8, 133u8, 105u8, 200u8, 214u8, - 27u8, 144u8, 208u8, 218u8, 160u8, 130u8, 109u8, 101u8, 54u8, 210u8, - 136u8, 71u8, 63u8, 49u8, 237u8, 234u8, 15u8, 178u8, 98u8, 148u8, 156u8, - ], - ) - } - #[doc = " Max number of storage keys to remove per extrinsic call."] - pub fn remove_keys_limit( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Crowdloan", - "RemoveKeysLimit", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod coretime { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_parachains::coretime::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_parachains::coretime::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RequestCoreCount { - pub count: ::core::primitive::u16, - } - impl ::subxt::blocks::StaticExtrinsic for RequestCoreCount { - const PALLET: &'static str = "Coretime"; - const CALL: &'static str = "request_core_count"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssignCore { - pub core: ::core::primitive::u16, - pub begin: ::core::primitive::u32, - pub assignment: ::std::vec::Vec<( - runtime_types::pallet_broker::coretime_interface::CoreAssignment, - runtime_types::polkadot_runtime_parachains::assigner_coretime::PartsOf57600, - )>, - pub end_hint: ::core::option::Option<::core::primitive::u32>, - } - impl ::subxt::blocks::StaticExtrinsic for AssignCore { - const PALLET: &'static str = "Coretime"; - const CALL: &'static str = "assign_core"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::request_core_count`]."] - pub fn request_core_count( - &self, - count: ::core::primitive::u16, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Coretime", - "request_core_count", - types::RequestCoreCount { count }, - [ - 8u8, 225u8, 74u8, 162u8, 188u8, 3u8, 191u8, 45u8, 167u8, 21u8, 227u8, - 200u8, 65u8, 221u8, 49u8, 212u8, 12u8, 229u8, 160u8, 178u8, 136u8, - 13u8, 131u8, 42u8, 220u8, 3u8, 151u8, 241u8, 210u8, 158u8, 218u8, - 217u8, - ], - ) - } - #[doc = "See [`Pallet::assign_core`]."] - pub fn assign_core( - &self, - core: ::core::primitive::u16, - begin: ::core::primitive::u32, - assignment: ::std::vec::Vec<( - runtime_types::pallet_broker::coretime_interface::CoreAssignment, - runtime_types::polkadot_runtime_parachains::assigner_coretime::PartsOf57600, - )>, - end_hint: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Coretime", - "assign_core", - types::AssignCore { core, begin, assignment, end_hint }, - [ - 113u8, 133u8, 153u8, 202u8, 209u8, 53u8, 168u8, 214u8, 153u8, 232u8, - 170u8, 35u8, 63u8, 87u8, 5u8, 108u8, 188u8, 55u8, 111u8, 55u8, 22u8, - 1u8, 190u8, 216u8, 233u8, 185u8, 135u8, 172u8, 15u8, 254u8, 91u8, 92u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_parachains::coretime::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The broker chain has asked for revenue information for a specific block."] - pub struct RevenueInfoRequested { - pub when: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for RevenueInfoRequested { - const PALLET: &'static str = "Coretime"; - const EVENT: &'static str = "RevenueInfoRequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A core has received a new assignment from the broker chain."] - pub struct CoreAssigned { - pub core: runtime_types::polkadot_primitives::v6::CoreIndex, - } - impl ::subxt::events::StaticEvent for CoreAssigned { - const PALLET: &'static str = "Coretime"; - const EVENT: &'static str = "CoreAssigned"; - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The ParaId of the broker system parachain."] - pub fn broker_id(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Coretime", - "BrokerId", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod xcm_pallet { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_xcm::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_xcm::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Send { - pub dest: ::std::boxed::Box, - pub message: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for Send { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "send"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TeleportAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for TeleportAssets { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "teleport_assets"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReserveTransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ReserveTransferAssets { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "reserve_transfer_assets"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Execute { - pub message: ::std::boxed::Box, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for Execute { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "execute"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceXcmVersion { - pub location: - ::std::boxed::Box, - pub version: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for ForceXcmVersion { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "force_xcm_version"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceDefaultXcmVersion { - pub maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - } - impl ::subxt::blocks::StaticExtrinsic for ForceDefaultXcmVersion { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "force_default_xcm_version"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSubscribeVersionNotify { - pub location: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSubscribeVersionNotify { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "force_subscribe_version_notify"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceUnsubscribeVersionNotify { - pub location: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for ForceUnsubscribeVersionNotify { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "force_unsubscribe_version_notify"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LimitedReserveTransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v3::WeightLimit, - } - impl ::subxt::blocks::StaticExtrinsic for LimitedReserveTransferAssets { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "limited_reserve_transfer_assets"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LimitedTeleportAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v3::WeightLimit, - } - impl ::subxt::blocks::StaticExtrinsic for LimitedTeleportAssets { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "limited_teleport_assets"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSuspension { - pub suspended: ::core::primitive::bool, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSuspension { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "force_suspension"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TransferAssets { - pub dest: ::std::boxed::Box, - pub beneficiary: ::std::boxed::Box, - pub assets: ::std::boxed::Box, - pub fee_asset_item: ::core::primitive::u32, - pub weight_limit: runtime_types::xcm::v3::WeightLimit, - } - impl ::subxt::blocks::StaticExtrinsic for TransferAssets { - const PALLET: &'static str = "XcmPallet"; - const CALL: &'static str = "transfer_assets"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::send`]."] - pub fn send( - &self, - dest: runtime_types::xcm::VersionedLocation, - message: runtime_types::xcm::VersionedXcm, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "send", - types::Send { - dest: ::std::boxed::Box::new(dest), - message: ::std::boxed::Box::new(message), - }, - [ - 47u8, 63u8, 128u8, 176u8, 10u8, 137u8, 124u8, 238u8, 155u8, 37u8, - 193u8, 160u8, 83u8, 240u8, 21u8, 179u8, 169u8, 131u8, 27u8, 104u8, - 195u8, 208u8, 123u8, 14u8, 221u8, 12u8, 45u8, 81u8, 148u8, 76u8, 17u8, - 100u8, - ], - ) - } - #[doc = "See [`Pallet::teleport_assets`]."] - pub fn teleport_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "teleport_assets", - types::TeleportAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - }, - [ - 124u8, 191u8, 118u8, 61u8, 45u8, 225u8, 97u8, 83u8, 198u8, 20u8, 139u8, - 117u8, 241u8, 1u8, 19u8, 54u8, 79u8, 181u8, 131u8, 112u8, 11u8, 118u8, - 147u8, 12u8, 89u8, 156u8, 123u8, 123u8, 195u8, 45u8, 50u8, 107u8, - ], - ) - } - #[doc = "See [`Pallet::reserve_transfer_assets`]."] - pub fn reserve_transfer_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "reserve_transfer_assets", - types::ReserveTransferAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - }, - [ - 97u8, 102u8, 230u8, 44u8, 135u8, 197u8, 43u8, 53u8, 182u8, 125u8, - 140u8, 141u8, 229u8, 73u8, 29u8, 55u8, 159u8, 104u8, 197u8, 20u8, - 124u8, 234u8, 250u8, 94u8, 133u8, 253u8, 189u8, 6u8, 216u8, 162u8, - 218u8, 89u8, - ], - ) - } - #[doc = "See [`Pallet::execute`]."] - pub fn execute( - &self, - message: runtime_types::xcm::VersionedXcm2, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "execute", - types::Execute { message: ::std::boxed::Box::new(message), max_weight }, - [ - 71u8, 109u8, 92u8, 110u8, 198u8, 150u8, 140u8, 125u8, 248u8, 236u8, - 177u8, 156u8, 198u8, 223u8, 51u8, 15u8, 52u8, 240u8, 20u8, 200u8, 68u8, - 145u8, 36u8, 156u8, 159u8, 153u8, 125u8, 48u8, 181u8, 61u8, 53u8, - 208u8, - ], - ) - } - #[doc = "See [`Pallet::force_xcm_version`]."] - pub fn force_xcm_version( - &self, - location: runtime_types::staging_xcm::v4::location::Location, - version: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_xcm_version", - types::ForceXcmVersion { - location: ::std::boxed::Box::new(location), - version, - }, - [ - 69u8, 151u8, 198u8, 154u8, 69u8, 181u8, 41u8, 111u8, 145u8, 230u8, - 103u8, 42u8, 237u8, 91u8, 235u8, 6u8, 156u8, 65u8, 187u8, 48u8, 171u8, - 200u8, 49u8, 4u8, 9u8, 210u8, 229u8, 152u8, 187u8, 88u8, 80u8, 246u8, - ], - ) - } - #[doc = "See [`Pallet::force_default_xcm_version`]."] - pub fn force_default_xcm_version( - &self, - maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_default_xcm_version", - types::ForceDefaultXcmVersion { maybe_xcm_version }, - [ - 43u8, 114u8, 102u8, 104u8, 209u8, 234u8, 108u8, 173u8, 109u8, 188u8, - 94u8, 214u8, 136u8, 43u8, 153u8, 75u8, 161u8, 192u8, 76u8, 12u8, 221u8, - 237u8, 158u8, 247u8, 41u8, 193u8, 35u8, 174u8, 183u8, 207u8, 79u8, - 213u8, - ], - ) - } - #[doc = "See [`Pallet::force_subscribe_version_notify`]."] - pub fn force_subscribe_version_notify( - &self, - location: runtime_types::xcm::VersionedLocation, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_subscribe_version_notify", - types::ForceSubscribeVersionNotify { - location: ::std::boxed::Box::new(location), - }, - [ - 203u8, 171u8, 70u8, 130u8, 46u8, 63u8, 76u8, 50u8, 105u8, 23u8, 249u8, - 190u8, 115u8, 74u8, 70u8, 125u8, 132u8, 112u8, 138u8, 60u8, 33u8, 35u8, - 45u8, 29u8, 95u8, 103u8, 187u8, 182u8, 188u8, 196u8, 248u8, 152u8, - ], - ) - } - #[doc = "See [`Pallet::force_unsubscribe_version_notify`]."] - pub fn force_unsubscribe_version_notify( - &self, - location: runtime_types::xcm::VersionedLocation, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_unsubscribe_version_notify", - types::ForceUnsubscribeVersionNotify { - location: ::std::boxed::Box::new(location), - }, - [ - 6u8, 113u8, 168u8, 215u8, 233u8, 202u8, 249u8, 134u8, 131u8, 8u8, - 142u8, 203u8, 142u8, 95u8, 216u8, 70u8, 38u8, 99u8, 166u8, 97u8, 218u8, - 132u8, 247u8, 14u8, 42u8, 99u8, 4u8, 115u8, 200u8, 180u8, 213u8, 50u8, - ], - ) - } - #[doc = "See [`Pallet::limited_reserve_transfer_assets`]."] - pub fn limited_reserve_transfer_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "limited_reserve_transfer_assets", - types::LimitedReserveTransferAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - weight_limit, - }, - [ - 198u8, 66u8, 204u8, 162u8, 222u8, 246u8, 141u8, 165u8, 241u8, 62u8, - 43u8, 236u8, 56u8, 200u8, 54u8, 47u8, 174u8, 83u8, 167u8, 220u8, 174u8, - 111u8, 123u8, 202u8, 248u8, 232u8, 166u8, 80u8, 152u8, 223u8, 86u8, - 141u8, - ], - ) - } - #[doc = "See [`Pallet::limited_teleport_assets`]."] - pub fn limited_teleport_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "limited_teleport_assets", - types::LimitedTeleportAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - weight_limit, - }, - [ - 70u8, 61u8, 32u8, 43u8, 101u8, 104u8, 251u8, 60u8, 212u8, 124u8, 113u8, - 243u8, 241u8, 183u8, 5u8, 231u8, 209u8, 231u8, 136u8, 3u8, 145u8, - 242u8, 179u8, 171u8, 185u8, 185u8, 7u8, 34u8, 5u8, 203u8, 21u8, 210u8, - ], - ) - } - #[doc = "See [`Pallet::force_suspension`]."] - pub fn force_suspension( - &self, - suspended: ::core::primitive::bool, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "force_suspension", - types::ForceSuspension { suspended }, - [ - 78u8, 125u8, 93u8, 55u8, 129u8, 44u8, 36u8, 227u8, 75u8, 46u8, 68u8, - 202u8, 81u8, 127u8, 111u8, 92u8, 149u8, 38u8, 225u8, 185u8, 183u8, - 154u8, 89u8, 159u8, 79u8, 10u8, 229u8, 1u8, 226u8, 243u8, 65u8, 238u8, - ], - ) - } - #[doc = "See [`Pallet::transfer_assets`]."] - pub fn transfer_assets( - &self, - dest: runtime_types::xcm::VersionedLocation, - beneficiary: runtime_types::xcm::VersionedLocation, - assets: runtime_types::xcm::VersionedAssets, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "XcmPallet", - "transfer_assets", - types::TransferAssets { - dest: ::std::boxed::Box::new(dest), - beneficiary: ::std::boxed::Box::new(beneficiary), - assets: ::std::boxed::Box::new(assets), - fee_asset_item, - weight_limit, - }, - [ - 44u8, 155u8, 182u8, 37u8, 123u8, 148u8, 150u8, 191u8, 117u8, 32u8, - 16u8, 238u8, 121u8, 188u8, 217u8, 110u8, 10u8, 236u8, 174u8, 91u8, - 100u8, 201u8, 109u8, 109u8, 60u8, 177u8, 233u8, 66u8, 181u8, 191u8, - 105u8, 37u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_xcm::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Execution of an XCM message was attempted."] - pub struct Attempted { - pub outcome: runtime_types::staging_xcm::v4::traits::Outcome, - } - impl ::subxt::events::StaticEvent for Attempted { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "Attempted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A XCM message was sent."] - pub struct Sent { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub message: runtime_types::staging_xcm::v4::Xcm, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for Sent { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "Sent"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response received which does not match a registered query. This may be because a"] - #[doc = "matching query was never registered, it may be because it is a duplicate response, or"] - #[doc = "because the query timed out."] - pub struct UnexpectedResponse { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for UnexpectedResponse { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "UnexpectedResponse"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] - #[doc = "no registered notification call."] - pub struct ResponseReady { - pub query_id: ::core::primitive::u64, - pub response: runtime_types::staging_xcm::v4::Response, - } - impl ::subxt::events::StaticEvent for ResponseReady { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "ResponseReady"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The registered notification has"] - #[doc = "been dispatched and executed successfully."] - pub struct Notified { - pub query_id: ::core::primitive::u64, - pub pallet_index: ::core::primitive::u8, - pub call_index: ::core::primitive::u8, - } - impl ::subxt::events::StaticEvent for Notified { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "Notified"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The registered notification"] - #[doc = "could not be dispatched because the dispatch weight is greater than the maximum weight"] - #[doc = "originally budgeted by this runtime for the query result."] - pub struct NotifyOverweight { - pub query_id: ::core::primitive::u64, - pub pallet_index: ::core::primitive::u8, - pub call_index: ::core::primitive::u8, - pub actual_weight: runtime_types::sp_weights::weight_v2::Weight, - pub max_budgeted_weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::events::StaticEvent for NotifyOverweight { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyOverweight"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. There was a general error with"] - #[doc = "dispatching the notification call."] - pub struct NotifyDispatchError { - pub query_id: ::core::primitive::u64, - pub pallet_index: ::core::primitive::u8, - pub call_index: ::core::primitive::u8, - } - impl ::subxt::events::StaticEvent for NotifyDispatchError { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyDispatchError"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] - #[doc = "decoded into a `Call`; this might be due to dispatch function having a signature which"] - #[doc = "is not `(origin, QueryId, Response)`."] - pub struct NotifyDecodeFailed { - pub query_id: ::core::primitive::u64, - pub pallet_index: ::core::primitive::u8, - pub call_index: ::core::primitive::u8, - } - impl ::subxt::events::StaticEvent for NotifyDecodeFailed { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyDecodeFailed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the origin location of the response does"] - #[doc = "not match that expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - pub struct InvalidResponder { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - pub expected_location: - ::core::option::Option, - } - impl ::subxt::events::StaticEvent for InvalidResponder { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "InvalidResponder"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the expected origin location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - pub struct InvalidResponderVersion { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for InvalidResponderVersion { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "InvalidResponderVersion"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Received query response has been read and removed."] - pub struct ResponseTaken { - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for ResponseTaken { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "ResponseTaken"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some assets have been placed in an asset trap."] - pub struct AssetsTrapped { - pub hash: ::subxt::utils::H256, - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub assets: runtime_types::xcm::VersionedAssets, - } - impl ::subxt::events::StaticEvent for AssetsTrapped { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "AssetsTrapped"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "An XCM version change notification message has been attempted to be sent."] - #[doc = ""] - #[doc = "The cost of sending it (borne by the chain) is included."] - pub struct VersionChangeNotified { - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub result: ::core::primitive::u32, - pub cost: runtime_types::staging_xcm::v4::asset::Assets, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for VersionChangeNotified { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "VersionChangeNotified"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The supported version of a location has been changed. This might be through an"] - #[doc = "automatic notification or a manual intervention."] - pub struct SupportedVersionChanged { - pub location: runtime_types::staging_xcm::v4::location::Location, - pub version: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for SupportedVersionChanged { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "SupportedVersionChanged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "sending the notification to it."] - pub struct NotifyTargetSendFail { - pub location: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - pub error: runtime_types::xcm::v3::traits::Error, - } - impl ::subxt::events::StaticEvent for NotifyTargetSendFail { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyTargetSendFail"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "migrating the location to our new XCM format."] - pub struct NotifyTargetMigrationFail { - pub location: runtime_types::xcm::VersionedLocation, - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for NotifyTargetMigrationFail { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "NotifyTargetMigrationFail"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the expected querier location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - pub struct InvalidQuerierVersion { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - } - impl ::subxt::events::StaticEvent for InvalidQuerierVersion { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "InvalidQuerierVersion"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Expected query response has been received but the querier location of the response does"] - #[doc = "not match the expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - pub struct InvalidQuerier { - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub query_id: ::core::primitive::u64, - pub expected_querier: runtime_types::staging_xcm::v4::location::Location, - pub maybe_actual_querier: - ::core::option::Option, - } - impl ::subxt::events::StaticEvent for InvalidQuerier { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "InvalidQuerier"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A remote has requested XCM version change notification from us and we have honored it."] - #[doc = "A version information message is sent to them and its cost is included."] - pub struct VersionNotifyStarted { - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub cost: runtime_types::staging_xcm::v4::asset::Assets, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for VersionNotifyStarted { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "VersionNotifyStarted"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "We have requested that a remote chain send us XCM version change notifications."] - pub struct VersionNotifyRequested { - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub cost: runtime_types::staging_xcm::v4::asset::Assets, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for VersionNotifyRequested { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "VersionNotifyRequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "We have requested that a remote chain stops sending us XCM version change"] - #[doc = "notifications."] - pub struct VersionNotifyUnrequested { - pub destination: runtime_types::staging_xcm::v4::location::Location, - pub cost: runtime_types::staging_xcm::v4::asset::Assets, - pub message_id: [::core::primitive::u8; 32usize], - } - impl ::subxt::events::StaticEvent for VersionNotifyUnrequested { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "VersionNotifyUnrequested"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Fees were paid from a location for an operation (often for using `SendXcm`)."] - pub struct FeesPaid { - pub paying: runtime_types::staging_xcm::v4::location::Location, - pub fees: runtime_types::staging_xcm::v4::asset::Assets, - } - impl ::subxt::events::StaticEvent for FeesPaid { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "FeesPaid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some assets have been claimed from an asset trap"] - pub struct AssetsClaimed { - pub hash: ::subxt::utils::H256, - pub origin: runtime_types::staging_xcm::v4::location::Location, - pub assets: runtime_types::xcm::VersionedAssets, - } - impl ::subxt::events::StaticEvent for AssetsClaimed { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "AssetsClaimed"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A XCM version migration finished."] - pub struct VersionMigrationFinished { - pub version: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for VersionMigrationFinished { - const PALLET: &'static str = "XcmPallet"; - const EVENT: &'static str = "VersionMigrationFinished"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The latest available query index."] - pub fn query_counter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "QueryCounter", - vec![], - [ - 216u8, 73u8, 160u8, 232u8, 60u8, 245u8, 218u8, 219u8, 152u8, 68u8, - 146u8, 219u8, 255u8, 7u8, 86u8, 112u8, 83u8, 49u8, 94u8, 173u8, 64u8, - 203u8, 147u8, 226u8, 236u8, 39u8, 129u8, 106u8, 209u8, 113u8, 150u8, - 50u8, - ], - ) - } - #[doc = " The ongoing queries."] - pub fn queries_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "Queries", - vec![], - [ - 246u8, 75u8, 240u8, 129u8, 106u8, 114u8, 99u8, 154u8, 176u8, 188u8, - 146u8, 125u8, 244u8, 103u8, 187u8, 171u8, 60u8, 119u8, 4u8, 90u8, 58u8, - 180u8, 48u8, 165u8, 145u8, 125u8, 227u8, 233u8, 11u8, 142u8, 122u8, - 3u8, - ], - ) - } - #[doc = " The ongoing queries."] - pub fn queries( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::QueryStatus<::core::primitive::u32>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "Queries", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 246u8, 75u8, 240u8, 129u8, 106u8, 114u8, 99u8, 154u8, 176u8, 188u8, - 146u8, 125u8, 244u8, 103u8, 187u8, 171u8, 60u8, 119u8, 4u8, 90u8, 58u8, - 180u8, 48u8, 165u8, 145u8, 125u8, 227u8, 233u8, 11u8, 142u8, 122u8, - 3u8, - ], - ) - } - #[doc = " The existing asset traps."] - #[doc = ""] - #[doc = " Key is the blake2 256 hash of (origin, versioned `Assets`) pair. Value is the number of"] - #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] - pub fn asset_traps_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "AssetTraps", - vec![], - [ - 148u8, 41u8, 254u8, 134u8, 61u8, 172u8, 126u8, 146u8, 78u8, 178u8, - 50u8, 77u8, 226u8, 8u8, 200u8, 78u8, 77u8, 91u8, 26u8, 133u8, 104u8, - 126u8, 28u8, 28u8, 202u8, 62u8, 87u8, 183u8, 231u8, 191u8, 5u8, 181u8, - ], - ) - } - #[doc = " The existing asset traps."] - #[doc = ""] - #[doc = " Key is the blake2 256 hash of (origin, versioned `Assets`) pair. Value is the number of"] - #[doc = " times this pair has been trapped (usually just 1 if it exists at all)."] - pub fn asset_traps( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::H256>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "AssetTraps", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 148u8, 41u8, 254u8, 134u8, 61u8, 172u8, 126u8, 146u8, 78u8, 178u8, - 50u8, 77u8, 226u8, 8u8, 200u8, 78u8, 77u8, 91u8, 26u8, 133u8, 104u8, - 126u8, 28u8, 28u8, 202u8, 62u8, 87u8, 183u8, 231u8, 191u8, 5u8, 181u8, - ], - ) - } - #[doc = " Default version to encode XCM when latest version of destination is unknown. If `None`,"] - #[doc = " then the destinations whose XCM version is unknown are considered unreachable."] - pub fn safe_xcm_version( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "SafeXcmVersion", - vec![], - [ - 187u8, 8u8, 74u8, 126u8, 80u8, 215u8, 177u8, 60u8, 223u8, 123u8, 196u8, - 155u8, 166u8, 66u8, 25u8, 164u8, 191u8, 66u8, 116u8, 131u8, 116u8, - 188u8, 224u8, 122u8, 75u8, 195u8, 246u8, 188u8, 83u8, 134u8, 49u8, - 143u8, - ], - ) - } - #[doc = " The Latest versions that we know various locations support."] - pub fn supported_version_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "SupportedVersion", - vec![], - [ - 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, - 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, - 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, - 202u8, 24u8, - ], - ) - } - #[doc = " The Latest versions that we know various locations support."] - pub fn supported_version_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "SupportedVersion", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, - 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, - 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, - 202u8, 24u8, - ], - ) - } - #[doc = " The Latest versions that we know various locations support."] - pub fn supported_version( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "SupportedVersion", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 144u8, 218u8, 177u8, 254u8, 210u8, 8u8, 84u8, 149u8, 163u8, 162u8, - 238u8, 37u8, 157u8, 28u8, 140u8, 121u8, 201u8, 173u8, 204u8, 92u8, - 133u8, 45u8, 156u8, 38u8, 61u8, 51u8, 153u8, 161u8, 147u8, 146u8, - 202u8, 24u8, - ], - ) - } - #[doc = " All locations that we have requested version notifications from."] - pub fn version_notifiers_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifiers", - vec![], - [ - 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, - 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, - 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, - 201u8, 49u8, - ], - ) - } - #[doc = " All locations that we have requested version notifications from."] - pub fn version_notifiers_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifiers", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, - 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, - 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, - 201u8, 49u8, - ], - ) - } - #[doc = " All locations that we have requested version notifications from."] - pub fn version_notifiers( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifiers", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 175u8, 206u8, 29u8, 14u8, 111u8, 123u8, 211u8, 109u8, 159u8, 131u8, - 80u8, 149u8, 216u8, 196u8, 181u8, 105u8, 117u8, 138u8, 80u8, 69u8, - 237u8, 116u8, 195u8, 66u8, 209u8, 102u8, 42u8, 126u8, 222u8, 176u8, - 201u8, 49u8, - ], - ) - } - #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] - #[doc = " of our versions we informed them of."] - pub fn version_notify_targets_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u64, - runtime_types::sp_weights::weight_v2::Weight, - ::core::primitive::u32, - ), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifyTargets", - vec![], - [ - 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, - 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, - 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, - ], - ) - } - #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] - #[doc = " of our versions we informed them of."] - pub fn version_notify_targets_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u64, - runtime_types::sp_weights::weight_v2::Weight, - ::core::primitive::u32, - ), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifyTargets", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, - 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, - 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, - ], - ) - } - #[doc = " The target locations that are subscribed to our version changes, as well as the most recent"] - #[doc = " of our versions we informed them of."] - pub fn version_notify_targets( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ( - ::core::primitive::u64, - runtime_types::sp_weights::weight_v2::Weight, - ::core::primitive::u32, - ), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionNotifyTargets", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 113u8, 77u8, 150u8, 42u8, 82u8, 49u8, 195u8, 120u8, 96u8, 80u8, 152u8, - 67u8, 27u8, 142u8, 10u8, 74u8, 66u8, 134u8, 35u8, 202u8, 77u8, 187u8, - 174u8, 22u8, 207u8, 199u8, 57u8, 85u8, 53u8, 208u8, 146u8, 81u8, - ], - ) - } - #[doc = " Destinations whose latest XCM version we would like to know. Duplicates not allowed, and"] - #[doc = " the `u32` counter is the number of times that a send to the destination has been attempted,"] - #[doc = " which is used as a prioritization."] - pub fn version_discovery_queue( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - runtime_types::xcm::VersionedLocation, - ::core::primitive::u32, - )>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "VersionDiscoveryQueue", - vec![], - [ - 95u8, 74u8, 97u8, 94u8, 40u8, 140u8, 175u8, 176u8, 224u8, 222u8, 83u8, - 199u8, 170u8, 102u8, 3u8, 77u8, 127u8, 208u8, 155u8, 122u8, 176u8, - 51u8, 15u8, 253u8, 231u8, 245u8, 91u8, 192u8, 60u8, 144u8, 101u8, - 168u8, - ], - ) - } - #[doc = " The current migration's stage, if any."] - pub fn current_migration( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::VersionMigrationStage, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "CurrentMigration", - vec![], - [ - 74u8, 138u8, 181u8, 162u8, 59u8, 251u8, 37u8, 28u8, 232u8, 51u8, 30u8, - 152u8, 252u8, 133u8, 95u8, 195u8, 47u8, 127u8, 21u8, 44u8, 62u8, 143u8, - 170u8, 234u8, 160u8, 37u8, 131u8, 179u8, 57u8, 241u8, 140u8, 124u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on a remote chain."] - pub fn remote_locked_fungibles_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "RemoteLockedFungibles", - vec![], - [ - 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, - 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, - 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, - 201u8, 150u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on a remote chain."] - pub fn remote_locked_fungibles_iter1( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "RemoteLockedFungibles", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, - 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, - 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, - 201u8, 150u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on a remote chain."] - pub fn remote_locked_fungibles_iter2( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "RemoteLockedFungibles", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ], - [ - 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, - 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, - 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, - 201u8, 150u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on a remote chain."] - pub fn remote_locked_fungibles( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u32>, - _1: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - _2: impl ::std::borrow::Borrow, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_xcm::pallet::RemoteLockedFungibleRecord<()>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "RemoteLockedFungibles", - vec![ - ::subxt::storage::address::make_static_storage_map_key(_0.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_1.borrow()), - ::subxt::storage::address::make_static_storage_map_key(_2.borrow()), - ], - [ - 247u8, 124u8, 77u8, 42u8, 208u8, 183u8, 99u8, 196u8, 50u8, 113u8, - 250u8, 221u8, 222u8, 170u8, 10u8, 60u8, 143u8, 172u8, 149u8, 198u8, - 125u8, 154u8, 196u8, 196u8, 145u8, 209u8, 68u8, 28u8, 241u8, 241u8, - 201u8, 150u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on this chain."] - pub fn locked_fungibles_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u128, - runtime_types::xcm::VersionedLocation, - )>, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "LockedFungibles", - vec![], - [ - 254u8, 234u8, 1u8, 27u8, 27u8, 32u8, 217u8, 24u8, 47u8, 30u8, 62u8, - 80u8, 86u8, 125u8, 120u8, 24u8, 143u8, 229u8, 161u8, 153u8, 240u8, - 246u8, 80u8, 15u8, 49u8, 189u8, 20u8, 204u8, 239u8, 198u8, 97u8, 174u8, - ], - ) - } - #[doc = " Fungible assets which we know are locked on this chain."] - pub fn locked_fungibles( - &self, - _0: impl ::std::borrow::Borrow<::subxt::utils::AccountId32>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u128, - runtime_types::xcm::VersionedLocation, - )>, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "LockedFungibles", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 254u8, 234u8, 1u8, 27u8, 27u8, 32u8, 217u8, 24u8, 47u8, 30u8, 62u8, - 80u8, 86u8, 125u8, 120u8, 24u8, 143u8, 229u8, 161u8, 153u8, 240u8, - 246u8, 80u8, 15u8, 49u8, 189u8, 20u8, 204u8, 239u8, 198u8, 97u8, 174u8, - ], - ) - } - #[doc = " Global suspension state of the XCM executor."] - pub fn xcm_execution_suspended( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::bool, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "XcmPallet", - "XcmExecutionSuspended", - vec![], - [ - 182u8, 54u8, 69u8, 68u8, 78u8, 76u8, 103u8, 79u8, 47u8, 136u8, 99u8, - 104u8, 128u8, 129u8, 249u8, 54u8, 214u8, 136u8, 97u8, 48u8, 178u8, - 42u8, 26u8, 27u8, 82u8, 24u8, 33u8, 77u8, 33u8, 27u8, 20u8, 127u8, - ], - ) - } - } - } - } - pub mod beefy { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_beefy::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_beefy::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocation { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_beefy::EquivocationProof< - ::core::primitive::u32, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Signature, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - impl ::subxt::blocks::StaticExtrinsic for ReportEquivocation { - const PALLET: &'static str = "Beefy"; - const CALL: &'static str = "report_equivocation"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReportEquivocationUnsigned { - pub equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_beefy::EquivocationProof< - ::core::primitive::u32, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Signature, - >, - >, - pub key_owner_proof: runtime_types::sp_session::MembershipProof, - } - impl ::subxt::blocks::StaticExtrinsic for ReportEquivocationUnsigned { - const PALLET: &'static str = "Beefy"; - const CALL: &'static str = "report_equivocation_unsigned"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetNewGenesis { - pub delay_in_blocks: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetNewGenesis { - const PALLET: &'static str = "Beefy"; - const CALL: &'static str = "set_new_genesis"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::report_equivocation`]."] - pub fn report_equivocation( - &self, - equivocation_proof: runtime_types::sp_consensus_beefy::EquivocationProof< - ::core::primitive::u32, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Signature, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Beefy", - "report_equivocation", - types::ReportEquivocation { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 156u8, 32u8, 92u8, 179u8, 165u8, 93u8, 216u8, 130u8, 121u8, 225u8, - 33u8, 141u8, 255u8, 12u8, 101u8, 136u8, 177u8, 25u8, 23u8, 239u8, 12u8, - 142u8, 88u8, 228u8, 85u8, 171u8, 218u8, 185u8, 146u8, 245u8, 149u8, - 85u8, - ], - ) - } - #[doc = "See [`Pallet::report_equivocation_unsigned`]."] - pub fn report_equivocation_unsigned( - &self, - equivocation_proof: runtime_types::sp_consensus_beefy::EquivocationProof< - ::core::primitive::u32, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Signature, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Beefy", - "report_equivocation_unsigned", - types::ReportEquivocationUnsigned { - equivocation_proof: ::std::boxed::Box::new(equivocation_proof), - key_owner_proof, - }, - [ - 126u8, 201u8, 236u8, 234u8, 107u8, 52u8, 37u8, 115u8, 228u8, 232u8, - 103u8, 193u8, 143u8, 224u8, 79u8, 192u8, 207u8, 204u8, 161u8, 103u8, - 210u8, 131u8, 64u8, 251u8, 48u8, 196u8, 249u8, 148u8, 2u8, 179u8, - 135u8, 121u8, - ], - ) - } - #[doc = "See [`Pallet::set_new_genesis`]."] - pub fn set_new_genesis( - &self, - delay_in_blocks: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Beefy", - "set_new_genesis", - types::SetNewGenesis { delay_in_blocks }, - [ - 147u8, 6u8, 252u8, 43u8, 77u8, 91u8, 170u8, 45u8, 112u8, 155u8, 158u8, - 79u8, 1u8, 116u8, 162u8, 146u8, 181u8, 9u8, 171u8, 48u8, 198u8, 210u8, - 243u8, 64u8, 229u8, 35u8, 28u8, 177u8, 144u8, 22u8, 165u8, 163u8, - ], - ) - } - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The current authorities set"] - pub fn authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Beefy", - "Authorities", - vec![], - [ - 53u8, 171u8, 94u8, 33u8, 46u8, 83u8, 105u8, 120u8, 123u8, 201u8, 141u8, - 71u8, 131u8, 150u8, 51u8, 121u8, 67u8, 45u8, 249u8, 146u8, 85u8, 113u8, - 23u8, 59u8, 59u8, 41u8, 0u8, 226u8, 98u8, 166u8, 253u8, 59u8, - ], - ) - } - #[doc = " The current validator set id"] - pub fn validator_set_id( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Beefy", - "ValidatorSetId", - vec![], - [ - 168u8, 84u8, 23u8, 134u8, 153u8, 30u8, 183u8, 176u8, 206u8, 100u8, - 109u8, 86u8, 109u8, 126u8, 146u8, 175u8, 173u8, 1u8, 253u8, 42u8, - 122u8, 207u8, 71u8, 4u8, 145u8, 83u8, 148u8, 29u8, 243u8, 52u8, 29u8, - 78u8, - ], - ) - } - #[doc = " Authorities set scheduled to be used with the next session"] - pub fn next_authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Beefy", - "NextAuthorities", - vec![], - [ - 87u8, 180u8, 0u8, 85u8, 209u8, 13u8, 131u8, 103u8, 8u8, 226u8, 42u8, - 72u8, 38u8, 47u8, 190u8, 78u8, 62u8, 4u8, 161u8, 130u8, 87u8, 196u8, - 13u8, 209u8, 205u8, 98u8, 104u8, 91u8, 3u8, 47u8, 82u8, 11u8, - ], - ) - } - #[doc = " A mapping from BEEFY set ID to the index of the *most recent* session for which its"] - #[doc = " members were responsible."] - #[doc = ""] - #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] - #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] - #[doc = " together sessions and BEEFY set ids, i.e. we need to validate that a validator"] - #[doc = " was the owner of a given key on a given session, and what the active set ID was"] - #[doc = " during that session."] - #[doc = ""] - #[doc = " TWOX-NOTE: `ValidatorSetId` is not under user control."] - pub fn set_id_session_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Beefy", - "SetIdSession", - vec![], - [ - 47u8, 0u8, 239u8, 121u8, 187u8, 213u8, 254u8, 50u8, 238u8, 10u8, 162u8, - 65u8, 189u8, 166u8, 37u8, 74u8, 82u8, 81u8, 160u8, 20u8, 180u8, 253u8, - 238u8, 18u8, 209u8, 203u8, 38u8, 148u8, 16u8, 105u8, 72u8, 169u8, - ], - ) - } - #[doc = " A mapping from BEEFY set ID to the index of the *most recent* session for which its"] - #[doc = " members were responsible."] - #[doc = ""] - #[doc = " This is only used for validating equivocation proofs. An equivocation proof must"] - #[doc = " contains a key-ownership proof for a given session, therefore we need a way to tie"] - #[doc = " together sessions and BEEFY set ids, i.e. we need to validate that a validator"] - #[doc = " was the owner of a given key on a given session, and what the active set ID was"] - #[doc = " during that session."] - #[doc = ""] - #[doc = " TWOX-NOTE: `ValidatorSetId` is not under user control."] - pub fn set_id_session( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Beefy", - "SetIdSession", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 47u8, 0u8, 239u8, 121u8, 187u8, 213u8, 254u8, 50u8, 238u8, 10u8, 162u8, - 65u8, 189u8, 166u8, 37u8, 74u8, 82u8, 81u8, 160u8, 20u8, 180u8, 253u8, - 238u8, 18u8, 209u8, 203u8, 38u8, 148u8, 16u8, 105u8, 72u8, 169u8, - ], - ) - } - #[doc = " Block number where BEEFY consensus is enabled/started."] - #[doc = " By changing this (through privileged `set_new_genesis()`), BEEFY consensus is effectively"] - #[doc = " restarted from the newly set block number."] - pub fn genesis_block( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option<::core::primitive::u32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Beefy", - "GenesisBlock", - vec![], - [ - 198u8, 155u8, 11u8, 240u8, 189u8, 245u8, 159u8, 127u8, 55u8, 33u8, - 48u8, 29u8, 209u8, 119u8, 163u8, 24u8, 28u8, 22u8, 163u8, 163u8, 124u8, - 88u8, 126u8, 4u8, 193u8, 158u8, 29u8, 243u8, 212u8, 4u8, 41u8, 22u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The maximum number of authorities that can be added."] - pub fn max_authorities( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Beefy", - "MaxAuthorities", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of nominators for each validator."] - pub fn max_nominators( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "Beefy", - "MaxNominators", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The maximum number of entries to keep in the set id to session index mapping."] - #[doc = ""] - #[doc = " Since the `SetIdSession` map is only used for validating equivocations this"] - #[doc = " value should relate to the bonding duration of whatever staking system is"] - #[doc = " being used (if any). If equivocation handling is not enabled then this value"] - #[doc = " can be zero."] - pub fn max_set_id_session_entries( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u64> { - ::subxt::constants::Address::new_static( - "Beefy", - "MaxSetIdSessionEntries", - [ - 128u8, 214u8, 205u8, 242u8, 181u8, 142u8, 124u8, 231u8, 190u8, 146u8, - 59u8, 226u8, 157u8, 101u8, 103u8, 117u8, 249u8, 65u8, 18u8, 191u8, - 103u8, 119u8, 53u8, 85u8, 81u8, 96u8, 220u8, 42u8, 184u8, 239u8, 42u8, - 246u8, - ], - ) - } - } - } - } - pub mod mmr { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Latest MMR Root hash."] - pub fn root_hash( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Mmr", - "RootHash", - vec![], - [ - 111u8, 206u8, 173u8, 92u8, 67u8, 49u8, 150u8, 113u8, 90u8, 245u8, 38u8, - 254u8, 76u8, 250u8, 167u8, 66u8, 130u8, 129u8, 251u8, 220u8, 172u8, - 229u8, 162u8, 251u8, 36u8, 227u8, 43u8, 189u8, 7u8, 106u8, 23u8, 13u8, - ], - ) - } - #[doc = " Current size of the MMR (number of leaves)."] - pub fn number_of_leaves( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u64, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "Mmr", - "NumberOfLeaves", - vec![], - [ - 123u8, 58u8, 149u8, 174u8, 85u8, 45u8, 20u8, 115u8, 241u8, 0u8, 51u8, - 174u8, 234u8, 60u8, 230u8, 59u8, 237u8, 144u8, 170u8, 32u8, 4u8, 0u8, - 34u8, 163u8, 238u8, 205u8, 93u8, 208u8, 53u8, 38u8, 141u8, 195u8, - ], - ) - } - #[doc = " Hashes of the nodes in the MMR."] - #[doc = ""] - #[doc = " Note this collection only contains MMR peaks, the inner nodes (and leaves)"] - #[doc = " are pruned and only stored in the Offchain DB."] - pub fn nodes_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "Mmr", - "Nodes", - vec![], - [ - 27u8, 84u8, 41u8, 195u8, 146u8, 81u8, 211u8, 189u8, 63u8, 125u8, 173u8, - 206u8, 69u8, 198u8, 202u8, 213u8, 89u8, 31u8, 89u8, 177u8, 76u8, 154u8, - 249u8, 197u8, 133u8, 78u8, 142u8, 71u8, 183u8, 3u8, 132u8, 25u8, - ], - ) - } - #[doc = " Hashes of the nodes in the MMR."] - #[doc = ""] - #[doc = " Note this collection only contains MMR peaks, the inner nodes (and leaves)"] - #[doc = " are pruned and only stored in the Offchain DB."] - pub fn nodes( - &self, - _0: impl ::std::borrow::Borrow<::core::primitive::u64>, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::H256, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Mmr", - "Nodes", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 27u8, 84u8, 41u8, 195u8, 146u8, 81u8, 211u8, 189u8, 63u8, 125u8, 173u8, - 206u8, 69u8, 198u8, 202u8, 213u8, 89u8, 31u8, 89u8, 177u8, 76u8, 154u8, - 249u8, 197u8, 133u8, 78u8, 142u8, 71u8, 183u8, 3u8, 132u8, 25u8, - ], - ) - } - } - } - } - pub mod mmr_leaf { - use super::root_mod; - use super::runtime_types; - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Details of current BEEFY authority set."] - pub fn beefy_authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_beefy::mmr::BeefyAuthoritySet<::subxt::utils::H256>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "MmrLeaf", - "BeefyAuthorities", - vec![], - [ - 128u8, 35u8, 176u8, 79u8, 224u8, 58u8, 214u8, 234u8, 231u8, 71u8, - 227u8, 153u8, 180u8, 189u8, 66u8, 44u8, 47u8, 174u8, 0u8, 83u8, 121u8, - 182u8, 226u8, 44u8, 224u8, 173u8, 237u8, 102u8, 231u8, 146u8, 110u8, - 7u8, - ], - ) - } - #[doc = " Details of next BEEFY authority set."] - #[doc = ""] - #[doc = " This storage entry is used as cache for calls to `update_beefy_next_authority_set`."] - pub fn beefy_next_authorities( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::sp_consensus_beefy::mmr::BeefyAuthoritySet<::subxt::utils::H256>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "MmrLeaf", - "BeefyNextAuthorities", - vec![], - [ - 97u8, 71u8, 52u8, 111u8, 120u8, 251u8, 183u8, 155u8, 177u8, 100u8, - 236u8, 142u8, 204u8, 117u8, 95u8, 40u8, 201u8, 36u8, 32u8, 82u8, 38u8, - 234u8, 135u8, 39u8, 224u8, 69u8, 94u8, 85u8, 12u8, 89u8, 97u8, 218u8, - ], - ) - } - } - } - } - pub mod identity_migrator { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_common::identity_migrator::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReapIdentity { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for ReapIdentity { - const PALLET: &'static str = "IdentityMigrator"; - const CALL: &'static str = "reap_identity"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PokeDeposit { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::blocks::StaticExtrinsic for PokeDeposit { - const PALLET: &'static str = "IdentityMigrator"; - const CALL: &'static str = "poke_deposit"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::reap_identity`]."] - pub fn reap_identity( - &self, - who: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "IdentityMigrator", - "reap_identity", - types::ReapIdentity { who }, - [ - 187u8, 110u8, 202u8, 220u8, 54u8, 240u8, 242u8, 171u8, 5u8, 83u8, - 129u8, 93u8, 213u8, 208u8, 21u8, 236u8, 121u8, 128u8, 127u8, 121u8, - 153u8, 118u8, 232u8, 44u8, 20u8, 124u8, 214u8, 185u8, 249u8, 182u8, - 136u8, 96u8, - ], - ) - } - #[doc = "See [`Pallet::poke_deposit`]."] - pub fn poke_deposit( - &self, - who: ::subxt::utils::AccountId32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "IdentityMigrator", - "poke_deposit", - types::PokeDeposit { who }, - [ - 42u8, 67u8, 168u8, 124u8, 75u8, 32u8, 143u8, 173u8, 14u8, 28u8, 76u8, - 35u8, 196u8, 255u8, 250u8, 33u8, 128u8, 159u8, 132u8, 124u8, 51u8, - 243u8, 166u8, 55u8, 208u8, 101u8, 188u8, 133u8, 36u8, 18u8, 119u8, - 146u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_common::identity_migrator::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The identity and all sub accounts were reaped for `who`."] - pub struct IdentityReaped { - pub who: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for IdentityReaped { - const PALLET: &'static str = "IdentityMigrator"; - const EVENT: &'static str = "IdentityReaped"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The deposits held for `who` were updated. `identity` is the new deposit held for"] - #[doc = "identity info, and `subs` is the new deposit held for the sub-accounts."] - pub struct DepositUpdated { - pub who: ::subxt::utils::AccountId32, - pub identity: ::core::primitive::u128, - pub subs: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for DepositUpdated { - const PALLET: &'static str = "IdentityMigrator"; - const EVENT: &'static str = "DepositUpdated"; - } - } - } - pub mod paras_sudo_wrapper { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_common::paras_sudo_wrapper::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_common::paras_sudo_wrapper::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoScheduleParaInitialize { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub genesis: runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, - } - impl ::subxt::blocks::StaticExtrinsic for SudoScheduleParaInitialize { - const PALLET: &'static str = "ParasSudoWrapper"; - const CALL: &'static str = "sudo_schedule_para_initialize"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoScheduleParaCleanup { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for SudoScheduleParaCleanup { - const PALLET: &'static str = "ParasSudoWrapper"; - const CALL: &'static str = "sudo_schedule_para_cleanup"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoScheduleParathreadUpgrade { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for SudoScheduleParathreadUpgrade { - const PALLET: &'static str = "ParasSudoWrapper"; - const CALL: &'static str = "sudo_schedule_parathread_upgrade"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoScheduleParachainDowngrade { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for SudoScheduleParachainDowngrade { - const PALLET: &'static str = "ParasSudoWrapper"; - const CALL: &'static str = "sudo_schedule_parachain_downgrade"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoQueueDownwardXcm { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub xcm: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for SudoQueueDownwardXcm { - const PALLET: &'static str = "ParasSudoWrapper"; - const CALL: &'static str = "sudo_queue_downward_xcm"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoEstablishHrmpChannel { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub max_capacity: ::core::primitive::u32, - pub max_message_size: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SudoEstablishHrmpChannel { - const PALLET: &'static str = "ParasSudoWrapper"; - const CALL: &'static str = "sudo_establish_hrmp_channel"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::sudo_schedule_para_initialize`]."] - pub fn sudo_schedule_para_initialize( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - genesis: runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasSudoWrapper", - "sudo_schedule_para_initialize", - types::SudoScheduleParaInitialize { id, genesis }, - [ - 91u8, 145u8, 184u8, 83u8, 85u8, 168u8, 43u8, 14u8, 18u8, 86u8, 4u8, - 120u8, 148u8, 107u8, 139u8, 46u8, 145u8, 126u8, 255u8, 61u8, 83u8, - 140u8, 63u8, 233u8, 0u8, 47u8, 227u8, 194u8, 99u8, 7u8, 61u8, 15u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_schedule_para_cleanup`]."] - pub fn sudo_schedule_para_cleanup( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasSudoWrapper", - "sudo_schedule_para_cleanup", - types::SudoScheduleParaCleanup { id }, - [ - 148u8, 0u8, 73u8, 32u8, 33u8, 214u8, 92u8, 82u8, 146u8, 97u8, 39u8, - 220u8, 147u8, 148u8, 83u8, 200u8, 36u8, 197u8, 231u8, 246u8, 159u8, - 175u8, 195u8, 46u8, 68u8, 230u8, 16u8, 240u8, 108u8, 132u8, 0u8, 188u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_schedule_parathread_upgrade`]."] - pub fn sudo_schedule_parathread_upgrade( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasSudoWrapper", - "sudo_schedule_parathread_upgrade", - types::SudoScheduleParathreadUpgrade { id }, - [ - 244u8, 142u8, 128u8, 182u8, 130u8, 88u8, 113u8, 34u8, 92u8, 224u8, - 244u8, 155u8, 83u8, 212u8, 68u8, 87u8, 156u8, 80u8, 26u8, 23u8, 245u8, - 197u8, 167u8, 204u8, 14u8, 198u8, 70u8, 93u8, 227u8, 159u8, 159u8, - 88u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_schedule_parachain_downgrade`]."] - pub fn sudo_schedule_parachain_downgrade( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasSudoWrapper", - "sudo_schedule_parachain_downgrade", - types::SudoScheduleParachainDowngrade { id }, - [ - 152u8, 217u8, 14u8, 138u8, 136u8, 85u8, 79u8, 255u8, 220u8, 85u8, - 248u8, 12u8, 186u8, 250u8, 206u8, 152u8, 115u8, 92u8, 143u8, 8u8, - 171u8, 46u8, 94u8, 232u8, 169u8, 79u8, 150u8, 212u8, 166u8, 191u8, - 188u8, 198u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_queue_downward_xcm`]."] - pub fn sudo_queue_downward_xcm( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - xcm: runtime_types::xcm::VersionedXcm, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasSudoWrapper", - "sudo_queue_downward_xcm", - types::SudoQueueDownwardXcm { id, xcm: ::std::boxed::Box::new(xcm) }, - [ - 35u8, 59u8, 126u8, 248u8, 211u8, 246u8, 239u8, 67u8, 252u8, 100u8, - 231u8, 46u8, 197u8, 83u8, 150u8, 54u8, 215u8, 188u8, 76u8, 193u8, 60u8, - 38u8, 251u8, 162u8, 19u8, 15u8, 214u8, 51u8, 24u8, 2u8, 9u8, 116u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_establish_hrmp_channel`]."] - pub fn sudo_establish_hrmp_channel( - &self, - sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - max_capacity: ::core::primitive::u32, - max_message_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ParasSudoWrapper", - "sudo_establish_hrmp_channel", - types::SudoEstablishHrmpChannel { - sender, - recipient, - max_capacity, - max_message_size, - }, - [ - 236u8, 105u8, 76u8, 213u8, 11u8, 105u8, 119u8, 48u8, 1u8, 103u8, 239u8, - 156u8, 66u8, 63u8, 135u8, 67u8, 226u8, 150u8, 254u8, 24u8, 169u8, 82u8, - 29u8, 75u8, 102u8, 167u8, 59u8, 66u8, 173u8, 148u8, 202u8, 50u8, - ], - ) - } - } - } - } - pub mod assigned_slots { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::polkadot_runtime_common::assigned_slots::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::polkadot_runtime_common::assigned_slots::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssignPermParachainSlot { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for AssignPermParachainSlot { - const PALLET: &'static str = "AssignedSlots"; - const CALL: &'static str = "assign_perm_parachain_slot"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssignTempParachainSlot { pub id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , pub lease_period_start : runtime_types :: polkadot_runtime_common :: assigned_slots :: SlotLeasePeriodStart , } - impl ::subxt::blocks::StaticExtrinsic for AssignTempParachainSlot { - const PALLET: &'static str = "AssignedSlots"; - const CALL: &'static str = "assign_temp_parachain_slot"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UnassignParachainSlot { - pub id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - impl ::subxt::blocks::StaticExtrinsic for UnassignParachainSlot { - const PALLET: &'static str = "AssignedSlots"; - const CALL: &'static str = "unassign_parachain_slot"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxPermanentSlots { - pub slots: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxPermanentSlots { - const PALLET: &'static str = "AssignedSlots"; - const CALL: &'static str = "set_max_permanent_slots"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetMaxTemporarySlots { - pub slots: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for SetMaxTemporarySlots { - const PALLET: &'static str = "AssignedSlots"; - const CALL: &'static str = "set_max_temporary_slots"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::assign_perm_parachain_slot`]."] - pub fn assign_perm_parachain_slot( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "AssignedSlots", - "assign_perm_parachain_slot", - types::AssignPermParachainSlot { id }, - [ - 174u8, 53u8, 0u8, 157u8, 42u8, 160u8, 60u8, 36u8, 68u8, 7u8, 86u8, - 60u8, 126u8, 71u8, 118u8, 95u8, 139u8, 208u8, 57u8, 118u8, 183u8, - 111u8, 59u8, 37u8, 186u8, 193u8, 92u8, 145u8, 39u8, 21u8, 237u8, 31u8, - ], - ) - } - #[doc = "See [`Pallet::assign_temp_parachain_slot`]."] - pub fn assign_temp_parachain_slot( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - lease_period_start : runtime_types :: polkadot_runtime_common :: assigned_slots :: SlotLeasePeriodStart, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "AssignedSlots", - "assign_temp_parachain_slot", - types::AssignTempParachainSlot { id, lease_period_start }, - [ - 226u8, 38u8, 224u8, 199u8, 32u8, 159u8, 245u8, 129u8, 190u8, 103u8, - 103u8, 214u8, 27u8, 215u8, 104u8, 111u8, 132u8, 186u8, 214u8, 25u8, - 110u8, 187u8, 73u8, 179u8, 101u8, 48u8, 60u8, 218u8, 248u8, 28u8, - 202u8, 66u8, - ], - ) - } - #[doc = "See [`Pallet::unassign_parachain_slot`]."] - pub fn unassign_parachain_slot( - &self, - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "AssignedSlots", - "unassign_parachain_slot", - types::UnassignParachainSlot { id }, - [ - 235u8, 6u8, 124u8, 73u8, 72u8, 232u8, 38u8, 233u8, 103u8, 111u8, 249u8, - 235u8, 10u8, 169u8, 92u8, 251u8, 245u8, 151u8, 28u8, 78u8, 125u8, - 113u8, 201u8, 187u8, 24u8, 58u8, 18u8, 177u8, 68u8, 122u8, 167u8, - 143u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_permanent_slots`]."] - pub fn set_max_permanent_slots( - &self, - slots: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "AssignedSlots", - "set_max_permanent_slots", - types::SetMaxPermanentSlots { slots }, - [ - 62u8, 74u8, 80u8, 101u8, 204u8, 21u8, 139u8, 67u8, 178u8, 103u8, 237u8, - 166u8, 58u8, 6u8, 201u8, 30u8, 17u8, 186u8, 220u8, 150u8, 183u8, 174u8, - 72u8, 15u8, 72u8, 166u8, 116u8, 203u8, 132u8, 237u8, 196u8, 230u8, - ], - ) - } - #[doc = "See [`Pallet::set_max_temporary_slots`]."] - pub fn set_max_temporary_slots( - &self, - slots: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "AssignedSlots", - "set_max_temporary_slots", - types::SetMaxTemporarySlots { slots }, - [ - 126u8, 108u8, 55u8, 12u8, 136u8, 207u8, 246u8, 65u8, 251u8, 139u8, - 150u8, 134u8, 10u8, 133u8, 106u8, 161u8, 61u8, 59u8, 15u8, 72u8, 247u8, - 33u8, 191u8, 127u8, 27u8, 89u8, 165u8, 134u8, 148u8, 140u8, 204u8, - 22u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::polkadot_runtime_common::assigned_slots::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A parachain was assigned a permanent parachain slot"] - pub struct PermanentSlotAssigned( - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for PermanentSlotAssigned { - const PALLET: &'static str = "AssignedSlots"; - const EVENT: &'static str = "PermanentSlotAssigned"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A parachain was assigned a temporary parachain slot"] - pub struct TemporarySlotAssigned( - pub runtime_types::polkadot_parachain_primitives::primitives::Id, - ); - impl ::subxt::events::StaticEvent for TemporarySlotAssigned { - const PALLET: &'static str = "AssignedSlots"; - const EVENT: &'static str = "TemporarySlotAssigned"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The maximum number of permanent slots has been changed"] - pub struct MaxPermanentSlotsChanged { - pub slots: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for MaxPermanentSlotsChanged { - const PALLET: &'static str = "AssignedSlots"; - const EVENT: &'static str = "MaxPermanentSlotsChanged"; - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The maximum number of temporary slots has been changed"] - pub struct MaxTemporarySlotsChanged { - pub slots: ::core::primitive::u32, - } - impl ::subxt::events::StaticEvent for MaxTemporarySlotsChanged { - const PALLET: &'static str = "AssignedSlots"; - const EVENT: &'static str = "MaxTemporarySlotsChanged"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Assigned permanent slots, with their start lease period, and duration."] - pub fn permanent_slots_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "PermanentSlots", - vec![], - [ - 133u8, 179u8, 221u8, 222u8, 50u8, 75u8, 158u8, 137u8, 167u8, 190u8, - 19u8, 237u8, 201u8, 44u8, 86u8, 64u8, 57u8, 61u8, 96u8, 112u8, 218u8, - 186u8, 176u8, 58u8, 143u8, 61u8, 105u8, 13u8, 103u8, 162u8, 188u8, - 154u8, - ], - ) - } - #[doc = " Assigned permanent slots, with their start lease period, and duration."] - pub fn permanent_slots( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - (::core::primitive::u32, ::core::primitive::u32), - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "PermanentSlots", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 133u8, 179u8, 221u8, 222u8, 50u8, 75u8, 158u8, 137u8, 167u8, 190u8, - 19u8, 237u8, 201u8, 44u8, 86u8, 64u8, 57u8, 61u8, 96u8, 112u8, 218u8, - 186u8, 176u8, 58u8, 143u8, 61u8, 105u8, 13u8, 103u8, 162u8, 188u8, - 154u8, - ], - ) - } - #[doc = " Number of assigned (and active) permanent slots."] - pub fn permanent_slot_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "PermanentSlotCount", - vec![], - [ - 57u8, 211u8, 19u8, 233u8, 105u8, 201u8, 166u8, 99u8, 53u8, 217u8, 23u8, - 64u8, 216u8, 129u8, 21u8, 36u8, 234u8, 24u8, 57u8, 99u8, 13u8, 205u8, - 201u8, 78u8, 28u8, 96u8, 232u8, 62u8, 91u8, 235u8, 157u8, 213u8, - ], - ) - } - #[doc = " Assigned temporary slots."] - pub fn temporary_slots_iter( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::assigned_slots::ParachainTemporarySlot< - ::subxt::utils::AccountId32, - ::core::primitive::u32, - >, - (), - (), - ::subxt::storage::address::Yes, - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "TemporarySlots", - vec![], - [ - 184u8, 245u8, 181u8, 90u8, 169u8, 232u8, 108u8, 3u8, 153u8, 4u8, 176u8, - 170u8, 230u8, 163u8, 236u8, 111u8, 196u8, 218u8, 154u8, 125u8, 102u8, - 216u8, 195u8, 126u8, 99u8, 90u8, 242u8, 141u8, 214u8, 165u8, 32u8, - 57u8, - ], - ) - } - #[doc = " Assigned temporary slots."] - pub fn temporary_slots( - &self, - _0: impl ::std::borrow::Borrow< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::polkadot_runtime_common::assigned_slots::ParachainTemporarySlot< - ::subxt::utils::AccountId32, - ::core::primitive::u32, - >, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "TemporarySlots", - vec![::subxt::storage::address::make_static_storage_map_key(_0.borrow())], - [ - 184u8, 245u8, 181u8, 90u8, 169u8, 232u8, 108u8, 3u8, 153u8, 4u8, 176u8, - 170u8, 230u8, 163u8, 236u8, 111u8, 196u8, 218u8, 154u8, 125u8, 102u8, - 216u8, 195u8, 126u8, 99u8, 90u8, 242u8, 141u8, 214u8, 165u8, 32u8, - 57u8, - ], - ) - } - #[doc = " Number of assigned temporary slots."] - pub fn temporary_slot_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "TemporarySlotCount", - vec![], - [ - 218u8, 236u8, 69u8, 75u8, 224u8, 60u8, 9u8, 197u8, 217u8, 4u8, 210u8, - 55u8, 125u8, 106u8, 239u8, 208u8, 115u8, 105u8, 94u8, 223u8, 219u8, - 27u8, 175u8, 161u8, 120u8, 168u8, 36u8, 239u8, 136u8, 228u8, 7u8, 15u8, - ], - ) - } - #[doc = " Number of active temporary slots in current slot lease period."] - pub fn active_temporary_slot_count( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "ActiveTemporarySlotCount", - vec![], - [ - 153u8, 99u8, 232u8, 164u8, 137u8, 10u8, 232u8, 172u8, 78u8, 4u8, 69u8, - 178u8, 245u8, 220u8, 56u8, 251u8, 60u8, 238u8, 127u8, 246u8, 60u8, - 11u8, 240u8, 185u8, 2u8, 194u8, 69u8, 212u8, 173u8, 205u8, 205u8, - 198u8, - ], - ) - } - #[doc = " The max number of temporary slots that can be assigned."] - pub fn max_temporary_slots( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "MaxTemporarySlots", - vec![], - [ - 129u8, 130u8, 136u8, 77u8, 149u8, 130u8, 130u8, 195u8, 150u8, 114u8, - 199u8, 133u8, 86u8, 252u8, 149u8, 149u8, 131u8, 248u8, 70u8, 39u8, - 22u8, 101u8, 175u8, 13u8, 32u8, 138u8, 81u8, 20u8, 41u8, 46u8, 238u8, - 187u8, - ], - ) - } - #[doc = " The max number of permanent slots that can be assigned."] - pub fn max_permanent_slots( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::primitive::u32, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "AssignedSlots", - "MaxPermanentSlots", - vec![], - [ - 20u8, 72u8, 203u8, 62u8, 120u8, 21u8, 97u8, 9u8, 138u8, 135u8, 67u8, - 152u8, 131u8, 197u8, 59u8, 80u8, 226u8, 148u8, 159u8, 122u8, 34u8, - 86u8, 162u8, 80u8, 208u8, 151u8, 43u8, 164u8, 120u8, 33u8, 144u8, - 118u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " The number of lease periods a permanent parachain slot lasts."] - pub fn permanent_slot_lease_period_length( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "AssignedSlots", - "PermanentSlotLeasePeriodLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The number of lease periods a temporary parachain slot lasts."] - pub fn temporary_slot_lease_period_length( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "AssignedSlots", - "TemporarySlotLeasePeriodLength", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - #[doc = " The max number of temporary slots to be scheduled per lease periods."] - pub fn max_temporary_slot_per_lease_period( - &self, - ) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "AssignedSlots", - "MaxTemporarySlotPerLeasePeriod", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod validator_manager { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::rococo_runtime::validator_manager::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RegisterValidators { - pub validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - impl ::subxt::blocks::StaticExtrinsic for RegisterValidators { - const PALLET: &'static str = "ValidatorManager"; - const CALL: &'static str = "register_validators"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DeregisterValidators { - pub validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - } - impl ::subxt::blocks::StaticExtrinsic for DeregisterValidators { - const PALLET: &'static str = "ValidatorManager"; - const CALL: &'static str = "deregister_validators"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::register_validators`]."] - pub fn register_validators( - &self, - validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ValidatorManager", - "register_validators", - types::RegisterValidators { validators }, - [ - 181u8, 41u8, 122u8, 3u8, 39u8, 160u8, 138u8, 83u8, 145u8, 147u8, 107u8, - 151u8, 213u8, 31u8, 237u8, 89u8, 119u8, 154u8, 14u8, 23u8, 238u8, - 247u8, 201u8, 92u8, 68u8, 127u8, 56u8, 178u8, 125u8, 152u8, 17u8, - 147u8, - ], - ) - } - #[doc = "See [`Pallet::deregister_validators`]."] - pub fn deregister_validators( - &self, - validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "ValidatorManager", - "deregister_validators", - types::DeregisterValidators { validators }, - [ - 150u8, 134u8, 135u8, 215u8, 121u8, 111u8, 44u8, 52u8, 25u8, 244u8, - 130u8, 47u8, 66u8, 73u8, 243u8, 49u8, 171u8, 143u8, 34u8, 122u8, 55u8, - 234u8, 176u8, 221u8, 106u8, 61u8, 102u8, 234u8, 13u8, 233u8, 211u8, - 214u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::rococo_runtime::validator_manager::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "New validators were added to the set."] - pub struct ValidatorsRegistered(pub ::std::vec::Vec<::subxt::utils::AccountId32>); - impl ::subxt::events::StaticEvent for ValidatorsRegistered { - const PALLET: &'static str = "ValidatorManager"; - const EVENT: &'static str = "ValidatorsRegistered"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Validators were removed from the set."] - pub struct ValidatorsDeregistered(pub ::std::vec::Vec<::subxt::utils::AccountId32>); - impl ::subxt::events::StaticEvent for ValidatorsDeregistered { - const PALLET: &'static str = "ValidatorManager"; - const EVENT: &'static str = "ValidatorsDeregistered"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Validators that should be retired, because their Parachain was deregistered."] - pub fn validators_to_retire( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ValidatorManager", - "ValidatorsToRetire", - vec![], - [ - 137u8, 92u8, 99u8, 157u8, 254u8, 166u8, 190u8, 64u8, 111u8, 212u8, - 37u8, 90u8, 164u8, 0u8, 31u8, 15u8, 83u8, 21u8, 225u8, 7u8, 57u8, - 104u8, 64u8, 192u8, 58u8, 38u8, 36u8, 133u8, 181u8, 229u8, 200u8, 65u8, - ], - ) - } - #[doc = " Validators that should be added."] - pub fn validators_to_add( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::std::vec::Vec<::subxt::utils::AccountId32>, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "ValidatorManager", - "ValidatorsToAdd", - vec![], - [ - 168u8, 209u8, 123u8, 225u8, 168u8, 62u8, 18u8, 174u8, 164u8, 161u8, - 228u8, 179u8, 251u8, 112u8, 210u8, 173u8, 24u8, 177u8, 111u8, 129u8, - 97u8, 230u8, 231u8, 103u8, 72u8, 104u8, 222u8, 156u8, 190u8, 150u8, - 147u8, 68u8, - ], - ) - } - } - } - } - pub mod state_trie_migration { - use super::root_mod; - use super::runtime_types; - #[doc = "The `Error` enum of this pallet."] - pub type Error = runtime_types::pallet_state_trie_migration::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_state_trie_migration::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ControlAutoMigration { - pub maybe_config: ::core::option::Option< - runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - >, - } - impl ::subxt::blocks::StaticExtrinsic for ControlAutoMigration { - const PALLET: &'static str = "StateTrieMigration"; - const CALL: &'static str = "control_auto_migration"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ContinueMigrate { - pub limits: runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - pub real_size_upper: ::core::primitive::u32, - pub witness_task: - runtime_types::pallet_state_trie_migration::pallet::MigrationTask, - } - impl ::subxt::blocks::StaticExtrinsic for ContinueMigrate { - const PALLET: &'static str = "StateTrieMigration"; - const CALL: &'static str = "continue_migrate"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MigrateCustomTop { - pub keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub witness_size: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for MigrateCustomTop { - const PALLET: &'static str = "StateTrieMigration"; - const CALL: &'static str = "migrate_custom_top"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MigrateCustomChild { - pub root: ::std::vec::Vec<::core::primitive::u8>, - pub child_keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub total_size: ::core::primitive::u32, - } - impl ::subxt::blocks::StaticExtrinsic for MigrateCustomChild { - const PALLET: &'static str = "StateTrieMigration"; - const CALL: &'static str = "migrate_custom_child"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetSignedMaxLimits { - pub limits: runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - } - impl ::subxt::blocks::StaticExtrinsic for SetSignedMaxLimits { - const PALLET: &'static str = "StateTrieMigration"; - const CALL: &'static str = "set_signed_max_limits"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ForceSetProgress { - pub progress_top: runtime_types::pallet_state_trie_migration::pallet::Progress, - pub progress_child: - runtime_types::pallet_state_trie_migration::pallet::Progress, - } - impl ::subxt::blocks::StaticExtrinsic for ForceSetProgress { - const PALLET: &'static str = "StateTrieMigration"; - const CALL: &'static str = "force_set_progress"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::control_auto_migration`]."] - pub fn control_auto_migration( - &self, - maybe_config: ::core::option::Option< - runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - >, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "StateTrieMigration", - "control_auto_migration", - types::ControlAutoMigration { maybe_config }, - [ - 41u8, 252u8, 1u8, 4u8, 170u8, 164u8, 45u8, 147u8, 203u8, 58u8, 64u8, - 26u8, 53u8, 231u8, 170u8, 72u8, 23u8, 87u8, 32u8, 93u8, 130u8, 210u8, - 65u8, 200u8, 147u8, 232u8, 32u8, 105u8, 182u8, 213u8, 101u8, 85u8, - ], - ) - } - #[doc = "See [`Pallet::continue_migrate`]."] - pub fn continue_migrate( - &self, - limits: runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - real_size_upper: ::core::primitive::u32, - witness_task: runtime_types::pallet_state_trie_migration::pallet::MigrationTask, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "StateTrieMigration", - "continue_migrate", - types::ContinueMigrate { limits, real_size_upper, witness_task }, - [ - 244u8, 113u8, 101u8, 72u8, 234u8, 245u8, 21u8, 134u8, 132u8, 53u8, - 179u8, 247u8, 210u8, 42u8, 87u8, 131u8, 157u8, 133u8, 108u8, 97u8, - 12u8, 252u8, 69u8, 100u8, 236u8, 171u8, 134u8, 241u8, 68u8, 15u8, - 227u8, 23u8, - ], - ) - } - #[doc = "See [`Pallet::migrate_custom_top`]."] - pub fn migrate_custom_top( - &self, - keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - witness_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "StateTrieMigration", - "migrate_custom_top", - types::MigrateCustomTop { keys, witness_size }, - [ - 167u8, 185u8, 103u8, 14u8, 52u8, 177u8, 104u8, 139u8, 95u8, 195u8, 1u8, - 30u8, 111u8, 205u8, 10u8, 53u8, 116u8, 31u8, 104u8, 135u8, 34u8, 80u8, - 214u8, 3u8, 80u8, 101u8, 21u8, 3u8, 244u8, 62u8, 115u8, 50u8, - ], - ) - } - #[doc = "See [`Pallet::migrate_custom_child`]."] - pub fn migrate_custom_child( - &self, - root: ::std::vec::Vec<::core::primitive::u8>, - child_keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - total_size: ::core::primitive::u32, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "StateTrieMigration", - "migrate_custom_child", - types::MigrateCustomChild { root, child_keys, total_size }, - [ - 160u8, 99u8, 211u8, 111u8, 120u8, 53u8, 188u8, 31u8, 102u8, 86u8, 94u8, - 86u8, 218u8, 181u8, 14u8, 154u8, 243u8, 49u8, 23u8, 65u8, 218u8, 160u8, - 200u8, 97u8, 208u8, 159u8, 40u8, 10u8, 110u8, 134u8, 86u8, 33u8, - ], - ) - } - #[doc = "See [`Pallet::set_signed_max_limits`]."] - pub fn set_signed_max_limits( - &self, - limits: runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "StateTrieMigration", - "set_signed_max_limits", - types::SetSignedMaxLimits { limits }, - [ - 106u8, 43u8, 66u8, 154u8, 114u8, 172u8, 120u8, 79u8, 212u8, 196u8, - 220u8, 112u8, 17u8, 42u8, 131u8, 249u8, 56u8, 91u8, 11u8, 152u8, 80u8, - 120u8, 36u8, 113u8, 51u8, 34u8, 10u8, 35u8, 135u8, 228u8, 216u8, 38u8, - ], - ) - } - #[doc = "See [`Pallet::force_set_progress`]."] - pub fn force_set_progress( - &self, - progress_top: runtime_types::pallet_state_trie_migration::pallet::Progress, - progress_child: runtime_types::pallet_state_trie_migration::pallet::Progress, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "StateTrieMigration", - "force_set_progress", - types::ForceSetProgress { progress_top, progress_child }, - [ - 103u8, 70u8, 170u8, 72u8, 136u8, 4u8, 169u8, 245u8, 254u8, 93u8, 17u8, - 104u8, 19u8, 53u8, 182u8, 35u8, 205u8, 99u8, 116u8, 101u8, 102u8, - 124u8, 253u8, 206u8, 111u8, 140u8, 212u8, 12u8, 218u8, 19u8, 39u8, - 229u8, - ], - ) - } - } - } - #[doc = "Inner events of this pallet."] - pub type Event = runtime_types::pallet_state_trie_migration::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Given number of `(top, child)` keys were migrated respectively, with the given"] - #[doc = "`compute`."] - pub struct Migrated { - pub top: ::core::primitive::u32, - pub child: ::core::primitive::u32, - pub compute: runtime_types::pallet_state_trie_migration::pallet::MigrationCompute, - } - impl ::subxt::events::StaticEvent for Migrated { - const PALLET: &'static str = "StateTrieMigration"; - const EVENT: &'static str = "Migrated"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Some account got slashed by the given amount."] - pub struct Slashed { - pub who: ::subxt::utils::AccountId32, - pub amount: ::core::primitive::u128, - } - impl ::subxt::events::StaticEvent for Slashed { - const PALLET: &'static str = "StateTrieMigration"; - const EVENT: &'static str = "Slashed"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The auto migration task finished."] - pub struct AutoMigrationFinished; - impl ::subxt::events::StaticEvent for AutoMigrationFinished { - const PALLET: &'static str = "StateTrieMigration"; - const EVENT: &'static str = "AutoMigrationFinished"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Migration got halted due to an error or miss-configuration."] - pub struct Halted { - pub error: runtime_types::pallet_state_trie_migration::pallet::Error, - } - impl ::subxt::events::StaticEvent for Halted { - const PALLET: &'static str = "StateTrieMigration"; - const EVENT: &'static str = "Halted"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " Migration progress."] - #[doc = ""] - #[doc = " This stores the snapshot of the last migrated keys. It can be set into motion and move"] - #[doc = " forward by any of the means provided by this pallet."] - pub fn migration_process( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_state_trie_migration::pallet::MigrationTask, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "StateTrieMigration", - "MigrationProcess", - vec![], - [ - 119u8, 172u8, 143u8, 118u8, 90u8, 3u8, 154u8, 185u8, 165u8, 165u8, - 249u8, 230u8, 77u8, 14u8, 221u8, 146u8, 75u8, 243u8, 69u8, 209u8, 79u8, - 253u8, 28u8, 64u8, 243u8, 45u8, 29u8, 1u8, 22u8, 127u8, 0u8, 66u8, - ], - ) - } - #[doc = " The limits that are imposed on automatic migrations."] - #[doc = ""] - #[doc = " If set to None, then no automatic migration happens."] - pub fn auto_limits( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::core::option::Option< - runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - >, - ::subxt::storage::address::Yes, - ::subxt::storage::address::Yes, - (), - > { - ::subxt::storage::address::Address::new_static( - "StateTrieMigration", - "AutoLimits", - vec![], - [ - 225u8, 29u8, 94u8, 66u8, 169u8, 230u8, 106u8, 20u8, 238u8, 81u8, 238u8, - 183u8, 185u8, 74u8, 94u8, 58u8, 107u8, 174u8, 228u8, 10u8, 156u8, - 225u8, 95u8, 75u8, 208u8, 227u8, 58u8, 147u8, 161u8, 68u8, 158u8, 99u8, - ], - ) - } - #[doc = " The maximum limits that the signed migration could use."] - #[doc = ""] - #[doc = " If not set, no signed submission is allowed."] - pub fn signed_migration_max_limits( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "StateTrieMigration", - "SignedMigrationMaxLimits", - vec![], - [ - 121u8, 97u8, 145u8, 237u8, 10u8, 145u8, 206u8, 119u8, 15u8, 12u8, - 200u8, 24u8, 231u8, 140u8, 248u8, 227u8, 202u8, 78u8, 93u8, 134u8, - 144u8, 79u8, 55u8, 136u8, 89u8, 52u8, 49u8, 64u8, 136u8, 249u8, 245u8, - 175u8, - ], - ) - } - } - } - pub mod constants { - use super::runtime_types; - pub struct ConstantsApi; - impl ConstantsApi { - #[doc = " Maximal number of bytes that a key can have."] - #[doc = ""] - #[doc = " FRAME itself does not limit the key length."] - #[doc = " The concrete value must therefore depend on your storage usage."] - #[doc = " A [`frame_support::storage::StorageNMap`] for example can have an arbitrary number of"] - #[doc = " keys which are then hashed and concatenated, resulting in arbitrarily long keys."] - #[doc = ""] - #[doc = " Use the *state migration RPC* to retrieve the length of the longest key in your"] - #[doc = " storage: "] - #[doc = ""] - #[doc = " The migration will halt with a `Halted` event if this value is too small."] - #[doc = " Since there is no real penalty from over-estimating, it is advised to use a large"] - #[doc = " value. The default is 512 byte."] - #[doc = ""] - #[doc = " Some key lengths for reference:"] - #[doc = " - [`frame_support::storage::StorageValue`]: 32 byte"] - #[doc = " - [`frame_support::storage::StorageMap`]: 64 byte"] - #[doc = " - [`frame_support::storage::StorageDoubleMap`]: 96 byte"] - #[doc = ""] - #[doc = " For more info see"] - #[doc = " "] - pub fn max_key_len(&self) -> ::subxt::constants::Address<::core::primitive::u32> { - ::subxt::constants::Address::new_static( - "StateTrieMigration", - "MaxKeyLen", - [ - 98u8, 252u8, 116u8, 72u8, 26u8, 180u8, 225u8, 83u8, 200u8, 157u8, - 125u8, 151u8, 53u8, 76u8, 168u8, 26u8, 10u8, 9u8, 98u8, 68u8, 9u8, - 178u8, 197u8, 113u8, 31u8, 79u8, 200u8, 90u8, 203u8, 100u8, 41u8, - 145u8, - ], - ) - } - } - } - } - pub mod root_testing { - use super::root_mod; - use super::runtime_types; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_root_testing::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FillBlock { - pub ratio: runtime_types::sp_arithmetic::per_things::Perbill, - } - impl ::subxt::blocks::StaticExtrinsic for FillBlock { - const PALLET: &'static str = "RootTesting"; - const CALL: &'static str = "fill_block"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TriggerDefensive; - impl ::subxt::blocks::StaticExtrinsic for TriggerDefensive { - const PALLET: &'static str = "RootTesting"; - const CALL: &'static str = "trigger_defensive"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See `Pallet::fill_block`."] - pub fn fill_block( - &self, - ratio: runtime_types::sp_arithmetic::per_things::Perbill, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "RootTesting", - "fill_block", - types::FillBlock { ratio }, - [ - 164u8, 37u8, 43u8, 91u8, 125u8, 34u8, 208u8, 126u8, 67u8, 94u8, 184u8, - 240u8, 68u8, 208u8, 41u8, 206u8, 172u8, 95u8, 111u8, 115u8, 9u8, 250u8, - 163u8, 66u8, 240u8, 0u8, 237u8, 140u8, 87u8, 57u8, 162u8, 117u8, - ], - ) - } - #[doc = "See `Pallet::trigger_defensive`."] - pub fn trigger_defensive(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "RootTesting", - "trigger_defensive", - types::TriggerDefensive {}, - [ - 170u8, 234u8, 12u8, 158u8, 10u8, 171u8, 161u8, 144u8, 101u8, 67u8, - 150u8, 128u8, 105u8, 234u8, 223u8, 60u8, 241u8, 245u8, 112u8, 21u8, - 80u8, 216u8, 72u8, 147u8, 22u8, 125u8, 19u8, 200u8, 171u8, 153u8, 88u8, - 194u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_root_testing::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Event dispatched when the trigger_defensive extrinsic is called."] - pub struct DefensiveTestCall; - impl ::subxt::events::StaticEvent for DefensiveTestCall { - const PALLET: &'static str = "RootTesting"; - const EVENT: &'static str = "DefensiveTestCall"; - } - } - } - pub mod sudo { - use super::root_mod; - use super::runtime_types; - #[doc = "Error for the Sudo pallet."] - pub type Error = runtime_types::pallet_sudo::pallet::Error; - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub type Call = runtime_types::pallet_sudo::pallet::Call; - pub mod calls { - use super::root_mod; - use super::runtime_types; - type DispatchError = runtime_types::sp_runtime::DispatchError; - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Sudo { - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for Sudo { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "sudo"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoUncheckedWeight { - pub call: ::std::boxed::Box, - pub weight: runtime_types::sp_weights::weight_v2::Weight, - } - impl ::subxt::blocks::StaticExtrinsic for SudoUncheckedWeight { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "sudo_unchecked_weight"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SetKey { - pub new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - } - impl ::subxt::blocks::StaticExtrinsic for SetKey { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "set_key"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SudoAs { - pub who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - pub call: ::std::boxed::Box, - } - impl ::subxt::blocks::StaticExtrinsic for SudoAs { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "sudo_as"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoveKey; - impl ::subxt::blocks::StaticExtrinsic for RemoveKey { - const PALLET: &'static str = "Sudo"; - const CALL: &'static str = "remove_key"; - } - } - pub struct TransactionApi; - impl TransactionApi { - #[doc = "See [`Pallet::sudo`]."] - pub fn sudo( - &self, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "sudo", - types::Sudo { call: ::std::boxed::Box::new(call) }, - [ - 43u8, 182u8, 196u8, 134u8, 180u8, 208u8, 148u8, 64u8, 216u8, 34u8, - 140u8, 90u8, 229u8, 228u8, 203u8, 22u8, 168u8, 119u8, 175u8, 70u8, - 232u8, 116u8, 197u8, 89u8, 212u8, 121u8, 238u8, 161u8, 180u8, 99u8, - 8u8, 144u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_unchecked_weight`]."] - pub fn sudo_unchecked_weight( - &self, - call: runtime_types::rococo_runtime::RuntimeCall, - weight: runtime_types::sp_weights::weight_v2::Weight, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "sudo_unchecked_weight", - types::SudoUncheckedWeight { call: ::std::boxed::Box::new(call), weight }, - [ - 219u8, 250u8, 93u8, 100u8, 201u8, 116u8, 148u8, 14u8, 119u8, 171u8, - 84u8, 252u8, 149u8, 228u8, 129u8, 107u8, 123u8, 120u8, 57u8, 187u8, - 171u8, 2u8, 103u8, 93u8, 178u8, 34u8, 25u8, 238u8, 28u8, 143u8, 23u8, - 252u8, - ], - ) - } - #[doc = "See [`Pallet::set_key`]."] - pub fn set_key( - &self, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "set_key", - types::SetKey { new }, - [ - 9u8, 73u8, 39u8, 205u8, 188u8, 127u8, 143u8, 54u8, 128u8, 94u8, 8u8, - 227u8, 197u8, 44u8, 70u8, 93u8, 228u8, 196u8, 64u8, 165u8, 226u8, - 158u8, 101u8, 192u8, 22u8, 193u8, 102u8, 84u8, 21u8, 35u8, 92u8, 198u8, - ], - ) - } - #[doc = "See [`Pallet::sudo_as`]."] - pub fn sudo_as( - &self, - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call: runtime_types::rococo_runtime::RuntimeCall, - ) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "sudo_as", - types::SudoAs { who, call: ::std::boxed::Box::new(call) }, - [ - 233u8, 95u8, 57u8, 170u8, 94u8, 67u8, 248u8, 43u8, 10u8, 195u8, 202u8, - 3u8, 94u8, 76u8, 107u8, 206u8, 104u8, 235u8, 154u8, 156u8, 23u8, 194u8, - 224u8, 32u8, 17u8, 154u8, 46u8, 123u8, 87u8, 149u8, 0u8, 23u8, - ], - ) - } - #[doc = "See [`Pallet::remove_key`]."] - pub fn remove_key(&self) -> ::subxt::tx::Payload { - ::subxt::tx::Payload::new_static( - "Sudo", - "remove_key", - types::RemoveKey {}, - [ - 133u8, 253u8, 54u8, 175u8, 202u8, 239u8, 5u8, 198u8, 180u8, 138u8, - 25u8, 28u8, 109u8, 40u8, 30u8, 56u8, 126u8, 100u8, 52u8, 205u8, 250u8, - 191u8, 61u8, 195u8, 172u8, 142u8, 184u8, 239u8, 247u8, 10u8, 211u8, - 79u8, - ], - ) - } - } - } - #[doc = "The `Event` enum of this pallet"] - pub type Event = runtime_types::pallet_sudo::pallet::Event; - pub mod events { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A sudo call just took place."] - pub struct Sudid { - pub sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for Sudid { - const PALLET: &'static str = "Sudo"; - const EVENT: &'static str = "Sudid"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The sudo key has been updated."] - pub struct KeyChanged { - pub old: ::core::option::Option<::subxt::utils::AccountId32>, - pub new: ::subxt::utils::AccountId32, - } - impl ::subxt::events::StaticEvent for KeyChanged { - const PALLET: &'static str = "Sudo"; - const EVENT: &'static str = "KeyChanged"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The key was permanently removed."] - pub struct KeyRemoved; - impl ::subxt::events::StaticEvent for KeyRemoved { - const PALLET: &'static str = "Sudo"; - const EVENT: &'static str = "KeyRemoved"; - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "A [sudo_as](Pallet::sudo_as) call just took place."] - pub struct SudoAsDone { - pub sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - } - impl ::subxt::events::StaticEvent for SudoAsDone { - const PALLET: &'static str = "Sudo"; - const EVENT: &'static str = "SudoAsDone"; - } - } - pub mod storage { - use super::runtime_types; - pub struct StorageApi; - impl StorageApi { - #[doc = " The `AccountId` of the sudo key."] - pub fn key( - &self, - ) -> ::subxt::storage::address::Address< - ::subxt::storage::address::StaticStorageMapKey, - ::subxt::utils::AccountId32, - ::subxt::storage::address::Yes, - (), - (), - > { - ::subxt::storage::address::Address::new_static( - "Sudo", - "Key", - vec![], - [ - 72u8, 14u8, 225u8, 162u8, 205u8, 247u8, 227u8, 105u8, 116u8, 57u8, 4u8, - 31u8, 84u8, 137u8, 227u8, 228u8, 133u8, 245u8, 206u8, 227u8, 117u8, - 36u8, 252u8, 151u8, 107u8, 15u8, 180u8, 4u8, 4u8, 152u8, 195u8, 144u8, - ], - ) - } - } - } - } - pub mod runtime_types { - use super::runtime_types; - pub mod bounded_collections { - use super::runtime_types; - pub mod bounded_vec { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BoundedVec<_0>(pub ::std::vec::Vec<_0>); - } - pub mod weak_bounded_vec { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WeakBoundedVec<_0>(pub ::std::vec::Vec<_0>); - } - } - pub mod finality_grandpa { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Equivocation<_0, _1, _2> { - pub round_number: ::core::primitive::u64, - pub identity: _0, - pub first: (_1, _2), - pub second: (_1, _2), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Precommit<_0, _1> { - pub target_hash: _0, - pub target_number: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Prevote<_0, _1> { - pub target_hash: _0, - pub target_number: _1, - } - } - pub mod frame_support { - use super::runtime_types; - pub mod dispatch { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DispatchClass { - #[codec(index = 0)] - Normal, - #[codec(index = 1)] - Operational, - #[codec(index = 2)] - Mandatory, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchInfo { - pub weight: runtime_types::sp_weights::weight_v2::Weight, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub pays_fee: runtime_types::frame_support::dispatch::Pays, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Pays { - #[codec(index = 0)] - Yes, - #[codec(index = 1)] - No, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PerDispatchClass<_0> { - pub normal: _0, - pub operational: _0, - pub mandatory: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PostDispatchInfo { - pub actual_weight: - ::core::option::Option, - pub pays_fee: runtime_types::frame_support::dispatch::Pays, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RawOrigin<_0> { - #[codec(index = 0)] - Root, - #[codec(index = 1)] - Signed(_0), - #[codec(index = 2)] - None, - } - } - pub mod traits { - use super::runtime_types; - pub mod messages { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ProcessMessageError { - #[codec(index = 0)] - BadFormat, - #[codec(index = 1)] - Corrupt, - #[codec(index = 2)] - Unsupported, - #[codec(index = 3)] - Overweight(runtime_types::sp_weights::weight_v2::Weight), - #[codec(index = 4)] - Yield, - } - } - pub mod preimages { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Bounded<_0, _1> { - #[codec(index = 0)] - Legacy { - hash: ::subxt::utils::H256, - }, - #[codec(index = 1)] - Inline( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Lookup { - hash: ::subxt::utils::H256, - len: ::core::primitive::u32, - }, - __Ignore(::core::marker::PhantomData<(_0, _1)>), - } - } - pub mod schedule { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DispatchTime<_0> { - #[codec(index = 0)] - At(_0), - #[codec(index = 1)] - After(_0), - } - } - pub mod tokens { - use super::runtime_types; - pub mod fungible { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HoldConsideration(pub ::core::primitive::u128); - } - pub mod misc { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BalanceStatus { - #[codec(index = 0)] - Free, - #[codec(index = 1)] - Reserved, - } - } - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PalletId(pub [::core::primitive::u8; 8usize]); - } - pub mod frame_system { - use super::runtime_types; - pub mod extensions { - use super::runtime_types; - pub mod check_genesis { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckGenesis; - } - pub mod check_mortality { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckMortality(pub runtime_types::sp_runtime::generic::era::Era); - } - pub mod check_non_zero_sender { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckNonZeroSender; - } - pub mod check_nonce { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckNonce(#[codec(compact)] pub ::core::primitive::u32); - } - pub mod check_spec_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckSpecVersion; - } - pub mod check_tx_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckTxVersion; - } - pub mod check_weight { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckWeight; - } - } - pub mod limits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BlockLength { - pub max: runtime_types::frame_support::dispatch::PerDispatchClass< - ::core::primitive::u32, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BlockWeights { - pub base_block: runtime_types::sp_weights::weight_v2::Weight, - pub max_block: runtime_types::sp_weights::weight_v2::Weight, - pub per_class: runtime_types::frame_support::dispatch::PerDispatchClass< - runtime_types::frame_system::limits::WeightsPerClass, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WeightsPerClass { - pub base_extrinsic: runtime_types::sp_weights::weight_v2::Weight, - pub max_extrinsic: - ::core::option::Option, - pub max_total: - ::core::option::Option, - pub reserved: - ::core::option::Option, - } - } - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::remark`]."] - remark { remark: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 1)] - #[doc = "See [`Pallet::set_heap_pages`]."] - set_heap_pages { pages: ::core::primitive::u64 }, - #[codec(index = 2)] - #[doc = "See [`Pallet::set_code`]."] - set_code { code: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 3)] - #[doc = "See [`Pallet::set_code_without_checks`]."] - set_code_without_checks { code: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 4)] - #[doc = "See [`Pallet::set_storage`]."] - set_storage { - items: ::std::vec::Vec<( - ::std::vec::Vec<::core::primitive::u8>, - ::std::vec::Vec<::core::primitive::u8>, - )>, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::kill_storage`]."] - kill_storage { keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>> }, - #[codec(index = 6)] - #[doc = "See [`Pallet::kill_prefix`]."] - kill_prefix { - prefix: ::std::vec::Vec<::core::primitive::u8>, - subkeys: ::core::primitive::u32, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::remark_with_event`]."] - remark_with_event { remark: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 9)] - #[doc = "See [`Pallet::authorize_upgrade`]."] - authorize_upgrade { code_hash: ::subxt::utils::H256 }, - #[codec(index = 10)] - #[doc = "See [`Pallet::authorize_upgrade_without_checks`]."] - authorize_upgrade_without_checks { code_hash: ::subxt::utils::H256 }, - #[codec(index = 11)] - #[doc = "See [`Pallet::apply_authorized_upgrade`]."] - apply_authorized_upgrade { code: ::std::vec::Vec<::core::primitive::u8> }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the System pallet"] - pub enum Error { - #[codec(index = 0)] - #[doc = "The name of specification does not match between the current runtime"] - #[doc = "and the new runtime."] - InvalidSpecName, - #[codec(index = 1)] - #[doc = "The specification version is not allowed to decrease between the current runtime"] - #[doc = "and the new runtime."] - SpecVersionNeedsToIncrease, - #[codec(index = 2)] - #[doc = "Failed to extract the runtime version from the new runtime."] - #[doc = ""] - #[doc = "Either calling `Core_version` or decoding `RuntimeVersion` failed."] - FailedToExtractRuntimeVersion, - #[codec(index = 3)] - #[doc = "Suicide called when the account has non-default composite data."] - NonDefaultComposite, - #[codec(index = 4)] - #[doc = "There is a non-zero reference count preventing the account from being purged."] - NonZeroRefCount, - #[codec(index = 5)] - #[doc = "The origin filter prevent the call to be dispatched."] - CallFiltered, - #[codec(index = 6)] - #[doc = "No upgrade authorized."] - NothingAuthorized, - #[codec(index = 7)] - #[doc = "The submitted code is not authorized."] - Unauthorized, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Event for the System pallet."] - pub enum Event { - #[codec(index = 0)] - #[doc = "An extrinsic completed successfully."] - ExtrinsicSuccess { - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 1)] - #[doc = "An extrinsic failed."] - ExtrinsicFailed { - dispatch_error: runtime_types::sp_runtime::DispatchError, - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 2)] - #[doc = "`:code` was updated."] - CodeUpdated, - #[codec(index = 3)] - #[doc = "A new account was created."] - NewAccount { account: ::subxt::utils::AccountId32 }, - #[codec(index = 4)] - #[doc = "An account was reaped."] - KilledAccount { account: ::subxt::utils::AccountId32 }, - #[codec(index = 5)] - #[doc = "On on-chain remark happened."] - Remarked { sender: ::subxt::utils::AccountId32, hash: ::subxt::utils::H256 }, - #[codec(index = 6)] - #[doc = "An upgrade was authorized."] - UpgradeAuthorized { - code_hash: ::subxt::utils::H256, - check_version: ::core::primitive::bool, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AccountInfo<_0, _1> { - pub nonce: _0, - pub consumers: ::core::primitive::u32, - pub providers: ::core::primitive::u32, - pub sufficients: ::core::primitive::u32, - pub data: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CodeUpgradeAuthorization { - pub code_hash: ::subxt::utils::H256, - pub check_version: ::core::primitive::bool, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EventRecord<_0, _1> { - pub phase: runtime_types::frame_system::Phase, - pub event: _0, - pub topics: ::std::vec::Vec<_1>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct LastRuntimeUpgradeInfo { - #[codec(compact)] - pub spec_version: ::core::primitive::u32, - pub spec_name: ::std::string::String, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Phase { - #[codec(index = 0)] - ApplyExtrinsic(::core::primitive::u32), - #[codec(index = 1)] - Finalization, - #[codec(index = 2)] - Initialization, - } - } - pub mod pallet_asset_rate { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::create`]."] - create { - asset_kind: ::std::boxed::Box< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - rate: runtime_types::sp_arithmetic::fixed_point::FixedU128, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::update`]."] - update { - asset_kind: ::std::boxed::Box< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - rate: runtime_types::sp_arithmetic::fixed_point::FixedU128, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::remove`]."] - remove { - asset_kind: ::std::boxed::Box< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The given asset ID is unknown."] - UnknownAssetKind, - #[codec(index = 1)] - #[doc = "The given asset ID already has an assigned conversion rate and cannot be re-created."] - AlreadyExists, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - AssetRateCreated { - asset_kind: - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - rate: runtime_types::sp_arithmetic::fixed_point::FixedU128, - }, - #[codec(index = 1)] - AssetRateRemoved { - asset_kind: - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - }, - #[codec(index = 2)] - AssetRateUpdated { - asset_kind: - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - old: runtime_types::sp_arithmetic::fixed_point::FixedU128, - new: runtime_types::sp_arithmetic::fixed_point::FixedU128, - }, - } - } - } - pub mod pallet_babe { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::report_equivocation`]."] - report_equivocation { - equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::report_equivocation_unsigned`]."] - report_equivocation_unsigned { - equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_slots::EquivocationProof< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - runtime_types::sp_consensus_babe::app::Public, - >, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::plan_config_change`]."] - plan_config_change { - config: runtime_types::sp_consensus_babe::digests::NextConfigDescriptor, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "An equivocation proof provided as part of an equivocation report is invalid."] - InvalidEquivocationProof, - #[codec(index = 1)] - #[doc = "A key ownership proof provided as part of an equivocation report is invalid."] - InvalidKeyOwnershipProof, - #[codec(index = 2)] - #[doc = "A given equivocation report is valid but already previously reported."] - DuplicateOffenceReport, - #[codec(index = 3)] - #[doc = "Submitted configuration is invalid."] - InvalidConfiguration, - } - } - } - pub mod pallet_balances { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::transfer_allow_death`]."] - transfer_allow_death { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::force_transfer`]."] - force_transfer { - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::transfer_keep_alive`]."] - transfer_keep_alive { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::transfer_all`]."] - transfer_all { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::force_unreserve`]."] - force_unreserve { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::upgrade_accounts`]."] - upgrade_accounts { who: ::std::vec::Vec<::subxt::utils::AccountId32> }, - #[codec(index = 8)] - #[doc = "See [`Pallet::force_set_balance`]."] - force_set_balance { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - new_free: ::core::primitive::u128, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::force_adjust_total_issuance`]."] - force_adjust_total_issuance { - direction: runtime_types::pallet_balances::types::AdjustmentDirection, - #[codec(compact)] - delta: ::core::primitive::u128, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call2 { - #[codec(index = 0)] - #[doc = "See [`Pallet::transfer_allow_death`]."] - transfer_allow_death { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::force_transfer`]."] - force_transfer { - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::transfer_keep_alive`]."] - transfer_keep_alive { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - value: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::transfer_all`]."] - transfer_all { - dest: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - keep_alive: ::core::primitive::bool, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::force_unreserve`]."] - force_unreserve { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::upgrade_accounts`]."] - upgrade_accounts { who: ::std::vec::Vec<::subxt::utils::AccountId32> }, - #[codec(index = 8)] - #[doc = "See [`Pallet::force_set_balance`]."] - force_set_balance { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - new_free: ::core::primitive::u128, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::force_adjust_total_issuance`]."] - force_adjust_total_issuance { - direction: runtime_types::pallet_balances::types::AdjustmentDirection, - #[codec(compact)] - delta: ::core::primitive::u128, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Vesting balance too high to send value."] - VestingBalance, - #[codec(index = 1)] - #[doc = "Account liquidity restrictions prevent withdrawal."] - LiquidityRestrictions, - #[codec(index = 2)] - #[doc = "Balance too low to send value."] - InsufficientBalance, - #[codec(index = 3)] - #[doc = "Value too low to create account due to existential deposit."] - ExistentialDeposit, - #[codec(index = 4)] - #[doc = "Transfer/payment would kill account."] - Expendability, - #[codec(index = 5)] - #[doc = "A vesting schedule already exists for this account."] - ExistingVestingSchedule, - #[codec(index = 6)] - #[doc = "Beneficiary account must pre-exist."] - DeadAccount, - #[codec(index = 7)] - #[doc = "Number of named reserves exceed `MaxReserves`."] - TooManyReserves, - #[codec(index = 8)] - #[doc = "Number of holds exceed `VariantCountOf`."] - TooManyHolds, - #[codec(index = 9)] - #[doc = "Number of freezes exceed `MaxFreezes`."] - TooManyFreezes, - #[codec(index = 10)] - #[doc = "The issuance cannot be modified since it is already deactivated."] - IssuanceDeactivated, - #[codec(index = 11)] - #[doc = "The delta cannot be zero."] - DeltaZero, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error2 { - #[codec(index = 0)] - #[doc = "Vesting balance too high to send value."] - VestingBalance, - #[codec(index = 1)] - #[doc = "Account liquidity restrictions prevent withdrawal."] - LiquidityRestrictions, - #[codec(index = 2)] - #[doc = "Balance too low to send value."] - InsufficientBalance, - #[codec(index = 3)] - #[doc = "Value too low to create account due to existential deposit."] - ExistentialDeposit, - #[codec(index = 4)] - #[doc = "Transfer/payment would kill account."] - Expendability, - #[codec(index = 5)] - #[doc = "A vesting schedule already exists for this account."] - ExistingVestingSchedule, - #[codec(index = 6)] - #[doc = "Beneficiary account must pre-exist."] - DeadAccount, - #[codec(index = 7)] - #[doc = "Number of named reserves exceed `MaxReserves`."] - TooManyReserves, - #[codec(index = 8)] - #[doc = "Number of holds exceed `VariantCountOf`."] - TooManyHolds, - #[codec(index = 9)] - #[doc = "Number of freezes exceed `MaxFreezes`."] - TooManyFreezes, - #[codec(index = 10)] - #[doc = "The issuance cannot be modified since it is already deactivated."] - IssuanceDeactivated, - #[codec(index = 11)] - #[doc = "The delta cannot be zero."] - DeltaZero, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "An account was created with some free balance."] - Endowed { - account: ::subxt::utils::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] - #[doc = "resulting in an outright loss."] - DustLost { - account: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "Transfer succeeded."] - Transfer { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "A balance was set by root."] - BalanceSet { who: ::subxt::utils::AccountId32, free: ::core::primitive::u128 }, - #[codec(index = 4)] - #[doc = "Some balance was reserved (moved from free to reserved)."] - Reserved { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 5)] - #[doc = "Some balance was unreserved (moved from reserved to free)."] - Unreserved { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 6)] - #[doc = "Some balance was moved from the reserve of the first account to the second account."] - #[doc = "Final argument indicates the destination balance type."] - ReserveRepatriated { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - #[doc = "Some amount was deposited (e.g. for transaction fees)."] - Deposit { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] - Withdraw { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 9)] - #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] - Slashed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - #[doc = "Some amount was minted into an account."] - Minted { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - #[doc = "Some amount was burned from an account."] - Burned { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - #[doc = "Some amount was suspended from an account (it can be restored later)."] - Suspended { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 13)] - #[doc = "Some amount was restored into an account."] - Restored { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 14)] - #[doc = "An account was upgraded."] - Upgraded { who: ::subxt::utils::AccountId32 }, - #[codec(index = 15)] - #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - #[doc = "Some balance was locked."] - Locked { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - #[doc = "Some balance was unlocked."] - Unlocked { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 19)] - #[doc = "Some balance was frozen."] - Frozen { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - #[doc = "Some balance was thawed."] - Thawed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 21)] - #[doc = "The `TotalIssuance` was forcefully changed."] - TotalIssuanceForced { - old: ::core::primitive::u128, - new: ::core::primitive::u128, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event2 { - #[codec(index = 0)] - #[doc = "An account was created with some free balance."] - Endowed { - account: ::subxt::utils::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - #[doc = "An account was removed whose balance was non-zero but below ExistentialDeposit,"] - #[doc = "resulting in an outright loss."] - DustLost { - account: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "Transfer succeeded."] - Transfer { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "A balance was set by root."] - BalanceSet { who: ::subxt::utils::AccountId32, free: ::core::primitive::u128 }, - #[codec(index = 4)] - #[doc = "Some balance was reserved (moved from free to reserved)."] - Reserved { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 5)] - #[doc = "Some balance was unreserved (moved from reserved to free)."] - Unreserved { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 6)] - #[doc = "Some balance was moved from the reserve of the first account to the second account."] - #[doc = "Final argument indicates the destination balance type."] - ReserveRepatriated { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - #[doc = "Some amount was deposited (e.g. for transaction fees)."] - Deposit { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - #[doc = "Some amount was withdrawn from the account (e.g. for transaction fees)."] - Withdraw { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 9)] - #[doc = "Some amount was removed from the account (e.g. for misbehavior)."] - Slashed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - #[doc = "Some amount was minted into an account."] - Minted { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - #[doc = "Some amount was burned from an account."] - Burned { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - #[doc = "Some amount was suspended from an account (it can be restored later)."] - Suspended { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 13)] - #[doc = "Some amount was restored into an account."] - Restored { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 14)] - #[doc = "An account was upgraded."] - Upgraded { who: ::subxt::utils::AccountId32 }, - #[codec(index = 15)] - #[doc = "Total issuance was increased by `amount`, creating a credit to be balanced."] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - #[doc = "Total issuance was decreased by `amount`, creating a debt to be balanced."] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - #[doc = "Some balance was locked."] - Locked { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - #[doc = "Some balance was unlocked."] - Unlocked { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 19)] - #[doc = "Some balance was frozen."] - Frozen { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - #[doc = "Some balance was thawed."] - Thawed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 21)] - #[doc = "The `TotalIssuance` was forcefully changed."] - TotalIssuanceForced { - old: ::core::primitive::u128, - new: ::core::primitive::u128, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AccountData<_0> { - pub free: _0, - pub reserved: _0, - pub frozen: _0, - pub flags: runtime_types::pallet_balances::types::ExtraFlags, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AdjustmentDirection { - #[codec(index = 0)] - Increase, - #[codec(index = 1)] - Decrease, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BalanceLock<_0> { - pub id: [::core::primitive::u8; 8usize], - pub amount: _0, - pub reasons: runtime_types::pallet_balances::types::Reasons, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExtraFlags(pub ::core::primitive::u128); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IdAmount<_0, _1> { - pub id: _0, - pub amount: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Reasons { - #[codec(index = 0)] - Fee, - #[codec(index = 1)] - Misc, - #[codec(index = 2)] - All, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReserveData<_0, _1> { - pub id: _0, - pub amount: _1, - } - } - } - pub mod pallet_beefy { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::report_equivocation`]."] - report_equivocation { - equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_beefy::EquivocationProof< - ::core::primitive::u32, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Signature, - >, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::report_equivocation_unsigned`]."] - report_equivocation_unsigned { - equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_beefy::EquivocationProof< - ::core::primitive::u32, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - runtime_types::sp_consensus_beefy::ecdsa_crypto::Signature, - >, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::set_new_genesis`]."] - set_new_genesis { delay_in_blocks: ::core::primitive::u32 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "A key ownership proof provided as part of an equivocation report is invalid."] - InvalidKeyOwnershipProof, - #[codec(index = 1)] - #[doc = "An equivocation proof provided as part of an equivocation report is invalid."] - InvalidEquivocationProof, - #[codec(index = 2)] - #[doc = "A given equivocation report is valid but already previously reported."] - DuplicateOffenceReport, - #[codec(index = 3)] - #[doc = "Submitted configuration is invalid."] - InvalidConfiguration, - } - } - } - pub mod pallet_bounties { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::propose_bounty`]."] - propose_bounty { - #[codec(compact)] - value: ::core::primitive::u128, - description: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::approve_bounty`]."] - approve_bounty { - #[codec(compact)] - bounty_id: ::core::primitive::u32, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::propose_curator`]."] - propose_curator { - #[codec(compact)] - bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - fee: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::unassign_curator`]."] - unassign_curator { - #[codec(compact)] - bounty_id: ::core::primitive::u32, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::accept_curator`]."] - accept_curator { - #[codec(compact)] - bounty_id: ::core::primitive::u32, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::award_bounty`]."] - award_bounty { - #[codec(compact)] - bounty_id: ::core::primitive::u32, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::claim_bounty`]."] - claim_bounty { - #[codec(compact)] - bounty_id: ::core::primitive::u32, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::close_bounty`]."] - close_bounty { - #[codec(compact)] - bounty_id: ::core::primitive::u32, - }, - #[codec(index = 8)] - #[doc = "See [`Pallet::extend_bounty_expiry`]."] - extend_bounty_expiry { - #[codec(compact)] - bounty_id: ::core::primitive::u32, - remark: ::std::vec::Vec<::core::primitive::u8>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Proposer's balance is too low."] - InsufficientProposersBalance, - #[codec(index = 1)] - #[doc = "No proposal or bounty at that index."] - InvalidIndex, - #[codec(index = 2)] - #[doc = "The reason given is just too big."] - ReasonTooBig, - #[codec(index = 3)] - #[doc = "The bounty status is unexpected."] - UnexpectedStatus, - #[codec(index = 4)] - #[doc = "Require bounty curator."] - RequireCurator, - #[codec(index = 5)] - #[doc = "Invalid bounty value."] - InvalidValue, - #[codec(index = 6)] - #[doc = "Invalid bounty fee."] - InvalidFee, - #[codec(index = 7)] - #[doc = "A bounty payout is pending."] - #[doc = "To cancel the bounty, you must unassign and slash the curator."] - PendingPayout, - #[codec(index = 8)] - #[doc = "The bounties cannot be claimed/closed because it's still in the countdown period."] - Premature, - #[codec(index = 9)] - #[doc = "The bounty cannot be closed because it has active child bounties."] - HasActiveChildBounty, - #[codec(index = 10)] - #[doc = "Too many approvals are already queued."] - TooManyQueued, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "New bounty proposal."] - BountyProposed { index: ::core::primitive::u32 }, - #[codec(index = 1)] - #[doc = "A bounty proposal was rejected; funds were slashed."] - BountyRejected { index: ::core::primitive::u32, bond: ::core::primitive::u128 }, - #[codec(index = 2)] - #[doc = "A bounty proposal is funded and became active."] - BountyBecameActive { index: ::core::primitive::u32 }, - #[codec(index = 3)] - #[doc = "A bounty is awarded to a beneficiary."] - BountyAwarded { - index: ::core::primitive::u32, - beneficiary: ::subxt::utils::AccountId32, - }, - #[codec(index = 4)] - #[doc = "A bounty is claimed by beneficiary."] - BountyClaimed { - index: ::core::primitive::u32, - payout: ::core::primitive::u128, - beneficiary: ::subxt::utils::AccountId32, - }, - #[codec(index = 5)] - #[doc = "A bounty is cancelled."] - BountyCanceled { index: ::core::primitive::u32 }, - #[codec(index = 6)] - #[doc = "A bounty expiry is extended."] - BountyExtended { index: ::core::primitive::u32 }, - #[codec(index = 7)] - #[doc = "A bounty is approved."] - BountyApproved { index: ::core::primitive::u32 }, - #[codec(index = 8)] - #[doc = "A bounty curator is proposed."] - CuratorProposed { - bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::AccountId32, - }, - #[codec(index = 9)] - #[doc = "A bounty curator is unassigned."] - CuratorUnassigned { bounty_id: ::core::primitive::u32 }, - #[codec(index = 10)] - #[doc = "A bounty curator is accepted."] - CuratorAccepted { - bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::AccountId32, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bounty<_0, _1, _2> { - pub proposer: _0, - pub value: _1, - pub fee: _1, - pub curator_deposit: _1, - pub bond: _1, - pub status: runtime_types::pallet_bounties::BountyStatus<_0, _2>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BountyStatus<_0, _1> { - #[codec(index = 0)] - Proposed, - #[codec(index = 1)] - Approved, - #[codec(index = 2)] - Funded, - #[codec(index = 3)] - CuratorProposed { curator: _0 }, - #[codec(index = 4)] - Active { curator: _0, update_due: _1 }, - #[codec(index = 5)] - PendingPayout { curator: _0, beneficiary: _0, unlock_at: _1 }, - } - } - pub mod pallet_broker { - use super::runtime_types; - pub mod coretime_interface { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - Clone, - Eq, - PartialEq, - Ord, - PartialOrd, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum CoreAssignment { - #[codec(index = 0)] - Idle, - #[codec(index = 1)] - Pool, - #[codec(index = 2)] - Task(::core::primitive::u32), - } - } - } - pub mod pallet_child_bounties { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::add_child_bounty`]."] - add_child_bounty { - #[codec(compact)] - parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - value: ::core::primitive::u128, - description: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::propose_curator`]."] - propose_curator { - #[codec(compact)] - parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - child_bounty_id: ::core::primitive::u32, - curator: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - #[codec(compact)] - fee: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::accept_curator`]."] - accept_curator { - #[codec(compact)] - parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - child_bounty_id: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::unassign_curator`]."] - unassign_curator { - #[codec(compact)] - parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - child_bounty_id: ::core::primitive::u32, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::award_child_bounty`]."] - award_child_bounty { - #[codec(compact)] - parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - child_bounty_id: ::core::primitive::u32, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::claim_child_bounty`]."] - claim_child_bounty { - #[codec(compact)] - parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - child_bounty_id: ::core::primitive::u32, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::close_child_bounty`]."] - close_child_bounty { - #[codec(compact)] - parent_bounty_id: ::core::primitive::u32, - #[codec(compact)] - child_bounty_id: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The parent bounty is not in active state."] - ParentBountyNotActive, - #[codec(index = 1)] - #[doc = "The bounty balance is not enough to add new child-bounty."] - InsufficientBountyBalance, - #[codec(index = 2)] - #[doc = "Number of child bounties exceeds limit `MaxActiveChildBountyCount`."] - TooManyChildBounties, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A child-bounty is added."] - Added { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, - #[codec(index = 1)] - #[doc = "A child-bounty is awarded to a beneficiary."] - Awarded { - index: ::core::primitive::u32, - child_index: ::core::primitive::u32, - beneficiary: ::subxt::utils::AccountId32, - }, - #[codec(index = 2)] - #[doc = "A child-bounty is claimed by beneficiary."] - Claimed { - index: ::core::primitive::u32, - child_index: ::core::primitive::u32, - payout: ::core::primitive::u128, - beneficiary: ::subxt::utils::AccountId32, - }, - #[codec(index = 3)] - #[doc = "A child-bounty is cancelled."] - Canceled { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ChildBounty<_0, _1, _2> { - pub parent_bounty: ::core::primitive::u32, - pub value: _1, - pub fee: _1, - pub curator_deposit: _1, - pub status: runtime_types::pallet_child_bounties::ChildBountyStatus<_0, _2>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ChildBountyStatus<_0, _1> { - #[codec(index = 0)] - Added, - #[codec(index = 1)] - CuratorProposed { curator: _0 }, - #[codec(index = 2)] - Active { curator: _0 }, - #[codec(index = 3)] - PendingPayout { curator: _0, beneficiary: _0, unlock_at: _1 }, - } - } - pub mod pallet_conviction_voting { - use super::runtime_types; - pub mod conviction { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Conviction { - #[codec(index = 0)] - None, - #[codec(index = 1)] - Locked1x, - #[codec(index = 2)] - Locked2x, - #[codec(index = 3)] - Locked3x, - #[codec(index = 4)] - Locked4x, - #[codec(index = 5)] - Locked5x, - #[codec(index = 6)] - Locked6x, - } - } - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::vote`]."] - vote { - #[codec(compact)] - poll_index: ::core::primitive::u32, - vote: runtime_types::pallet_conviction_voting::vote::AccountVote< - ::core::primitive::u128, - >, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::delegate`]."] - delegate { - class: ::core::primitive::u16, - to: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, - balance: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::undelegate`]."] - undelegate { class: ::core::primitive::u16 }, - #[codec(index = 3)] - #[doc = "See [`Pallet::unlock`]."] - unlock { - class: ::core::primitive::u16, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::remove_vote`]."] - remove_vote { - class: ::core::option::Option<::core::primitive::u16>, - index: ::core::primitive::u32, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::remove_other_vote`]."] - remove_other_vote { - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - class: ::core::primitive::u16, - index: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Poll is not ongoing."] - NotOngoing, - #[codec(index = 1)] - #[doc = "The given account did not vote on the poll."] - NotVoter, - #[codec(index = 2)] - #[doc = "The actor has no permission to conduct the action."] - NoPermission, - #[codec(index = 3)] - #[doc = "The actor has no permission to conduct the action right now but will do in the future."] - NoPermissionYet, - #[codec(index = 4)] - #[doc = "The account is already delegating."] - AlreadyDelegating, - #[codec(index = 5)] - #[doc = "The account currently has votes attached to it and the operation cannot succeed until"] - #[doc = "these are removed, either through `unvote` or `reap_vote`."] - AlreadyVoting, - #[codec(index = 6)] - #[doc = "Too high a balance was provided that the account cannot afford."] - InsufficientFunds, - #[codec(index = 7)] - #[doc = "The account is not currently delegating."] - NotDelegating, - #[codec(index = 8)] - #[doc = "Delegation to oneself makes no sense."] - Nonsense, - #[codec(index = 9)] - #[doc = "Maximum number of votes reached."] - MaxVotesReached, - #[codec(index = 10)] - #[doc = "The class must be supplied since it is not easily determinable from the state."] - ClassNeeded, - #[codec(index = 11)] - #[doc = "The class ID supplied is invalid."] - BadClass, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "An account has delegated their vote to another account. \\[who, target\\]"] - Delegated(::subxt::utils::AccountId32, ::subxt::utils::AccountId32), - #[codec(index = 1)] - #[doc = "An \\[account\\] has cancelled a previous delegation operation."] - Undelegated(::subxt::utils::AccountId32), - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Delegations<_0> { - pub votes: _0, - pub capital: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Tally<_0> { - pub ayes: _0, - pub nays: _0, - pub support: _0, - } - } - pub mod vote { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AccountVote<_0> { - #[codec(index = 0)] - Standard { - vote: runtime_types::pallet_conviction_voting::vote::Vote, - balance: _0, - }, - #[codec(index = 1)] - Split { aye: _0, nay: _0 }, - #[codec(index = 2)] - SplitAbstain { aye: _0, nay: _0, abstain: _0 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Casting<_0, _1, _2> { - pub votes: runtime_types::bounded_collections::bounded_vec::BoundedVec<( - _1, - runtime_types::pallet_conviction_voting::vote::AccountVote<_0>, - )>, - pub delegations: - runtime_types::pallet_conviction_voting::types::Delegations<_0>, - pub prior: runtime_types::pallet_conviction_voting::vote::PriorLock<_1, _0>, - #[codec(skip)] - pub __subxt_unused_type_params: ::core::marker::PhantomData<_2>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Delegating<_0, _1, _2> { - pub balance: _0, - pub target: _1, - pub conviction: runtime_types::pallet_conviction_voting::conviction::Conviction, - pub delegations: - runtime_types::pallet_conviction_voting::types::Delegations<_0>, - pub prior: runtime_types::pallet_conviction_voting::vote::PriorLock<_2, _0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PriorLock<_0, _1>(pub _0, pub _1); - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote(pub ::core::primitive::u8); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Voting<_0, _1, _2, _3> { - #[codec(index = 0)] - Casting(runtime_types::pallet_conviction_voting::vote::Casting<_0, _2, _2>), - #[codec(index = 1)] - Delegating( - runtime_types::pallet_conviction_voting::vote::Delegating<_0, _1, _2>, - ), - __Ignore(::core::marker::PhantomData<_3>), - } - } - } - pub mod pallet_grandpa { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::report_equivocation`]."] - report_equivocation { - equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::report_equivocation_unsigned`]."] - report_equivocation_unsigned { - equivocation_proof: ::std::boxed::Box< - runtime_types::sp_consensus_grandpa::EquivocationProof< - ::subxt::utils::H256, - ::core::primitive::u32, - >, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::note_stalled`]."] - note_stalled { - delay: ::core::primitive::u32, - best_finalized_block_number: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Attempt to signal GRANDPA pause when the authority set isn't live"] - #[doc = "(either paused or already pending pause)."] - PauseFailed, - #[codec(index = 1)] - #[doc = "Attempt to signal GRANDPA resume when the authority set isn't paused"] - #[doc = "(either live or already pending resume)."] - ResumeFailed, - #[codec(index = 2)] - #[doc = "Attempt to signal GRANDPA change with one already pending."] - ChangePending, - #[codec(index = 3)] - #[doc = "Cannot signal forced change so soon after last."] - TooSoon, - #[codec(index = 4)] - #[doc = "A key ownership proof provided as part of an equivocation report is invalid."] - InvalidKeyOwnershipProof, - #[codec(index = 5)] - #[doc = "An equivocation proof provided as part of an equivocation report is invalid."] - InvalidEquivocationProof, - #[codec(index = 6)] - #[doc = "A given equivocation report is valid but already previously reported."] - DuplicateOffenceReport, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "New authority set has been applied."] - NewAuthorities { - authority_set: ::std::vec::Vec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - }, - #[codec(index = 1)] - #[doc = "Current authority set has been paused."] - Paused, - #[codec(index = 2)] - #[doc = "Current authority set has been resumed."] - Resumed, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct StoredPendingChange<_0> { - pub scheduled_at: _0, - pub delay: _0, - pub next_authorities: - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - pub forced: ::core::option::Option<_0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum StoredState<_0> { - #[codec(index = 0)] - Live, - #[codec(index = 1)] - PendingPause { scheduled_at: _0, delay: _0 }, - #[codec(index = 2)] - Paused, - #[codec(index = 3)] - PendingResume { scheduled_at: _0, delay: _0 }, - } - } - pub mod pallet_identity { - use super::runtime_types; - pub mod legacy { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IdentityInfo { - pub additional: runtime_types::bounded_collections::bounded_vec::BoundedVec<( - runtime_types::pallet_identity::types::Data, - runtime_types::pallet_identity::types::Data, - )>, - pub display: runtime_types::pallet_identity::types::Data, - pub legal: runtime_types::pallet_identity::types::Data, - pub web: runtime_types::pallet_identity::types::Data, - pub riot: runtime_types::pallet_identity::types::Data, - pub email: runtime_types::pallet_identity::types::Data, - pub pgp_fingerprint: ::core::option::Option<[::core::primitive::u8; 20usize]>, - pub image: runtime_types::pallet_identity::types::Data, - pub twitter: runtime_types::pallet_identity::types::Data, - } - } - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Identity pallet declaration."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::add_registrar`]."] - add_registrar { - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::set_identity`]."] - set_identity { - info: - ::std::boxed::Box, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::set_subs`]."] - set_subs { - subs: ::std::vec::Vec<( - ::subxt::utils::AccountId32, - runtime_types::pallet_identity::types::Data, - )>, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::clear_identity`]."] - clear_identity, - #[codec(index = 4)] - #[doc = "See [`Pallet::request_judgement`]."] - request_judgement { - #[codec(compact)] - reg_index: ::core::primitive::u32, - #[codec(compact)] - max_fee: ::core::primitive::u128, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::cancel_request`]."] - cancel_request { reg_index: ::core::primitive::u32 }, - #[codec(index = 6)] - #[doc = "See [`Pallet::set_fee`]."] - set_fee { - #[codec(compact)] - index: ::core::primitive::u32, - #[codec(compact)] - fee: ::core::primitive::u128, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::set_account_id`]."] - set_account_id { - #[codec(compact)] - index: ::core::primitive::u32, - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 8)] - #[doc = "See [`Pallet::set_fields`]."] - set_fields { - #[codec(compact)] - index: ::core::primitive::u32, - fields: ::core::primitive::u64, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::provide_judgement`]."] - provide_judgement { - #[codec(compact)] - reg_index: ::core::primitive::u32, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - judgement: runtime_types::pallet_identity::types::Judgement< - ::core::primitive::u128, - >, - identity: ::subxt::utils::H256, - }, - #[codec(index = 10)] - #[doc = "See [`Pallet::kill_identity`]."] - kill_identity { - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 11)] - #[doc = "See [`Pallet::add_sub`]."] - add_sub { - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - data: runtime_types::pallet_identity::types::Data, - }, - #[codec(index = 12)] - #[doc = "See [`Pallet::rename_sub`]."] - rename_sub { - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - data: runtime_types::pallet_identity::types::Data, - }, - #[codec(index = 13)] - #[doc = "See [`Pallet::remove_sub`]."] - remove_sub { - sub: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 14)] - #[doc = "See [`Pallet::quit_sub`]."] - quit_sub, - #[codec(index = 15)] - #[doc = "See [`Pallet::add_username_authority`]."] - add_username_authority { - authority: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - suffix: ::std::vec::Vec<::core::primitive::u8>, - allocation: ::core::primitive::u32, - }, - #[codec(index = 16)] - #[doc = "See [`Pallet::remove_username_authority`]."] - remove_username_authority { - authority: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 17)] - #[doc = "See [`Pallet::set_username_for`]."] - set_username_for { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - username: ::std::vec::Vec<::core::primitive::u8>, - signature: - ::core::option::Option, - }, - #[codec(index = 18)] - #[doc = "See [`Pallet::accept_username`]."] - accept_username { - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - }, - #[codec(index = 19)] - #[doc = "See [`Pallet::remove_expired_approval`]."] - remove_expired_approval { - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - }, - #[codec(index = 20)] - #[doc = "See [`Pallet::set_primary_username`]."] - set_primary_username { - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - }, - #[codec(index = 21)] - #[doc = "See [`Pallet::remove_dangling_username`]."] - remove_dangling_username { - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Too many subs-accounts."] - TooManySubAccounts, - #[codec(index = 1)] - #[doc = "Account isn't found."] - NotFound, - #[codec(index = 2)] - #[doc = "Account isn't named."] - NotNamed, - #[codec(index = 3)] - #[doc = "Empty index."] - EmptyIndex, - #[codec(index = 4)] - #[doc = "Fee is changed."] - FeeChanged, - #[codec(index = 5)] - #[doc = "No identity found."] - NoIdentity, - #[codec(index = 6)] - #[doc = "Sticky judgement."] - StickyJudgement, - #[codec(index = 7)] - #[doc = "Judgement given."] - JudgementGiven, - #[codec(index = 8)] - #[doc = "Invalid judgement."] - InvalidJudgement, - #[codec(index = 9)] - #[doc = "The index is invalid."] - InvalidIndex, - #[codec(index = 10)] - #[doc = "The target is invalid."] - InvalidTarget, - #[codec(index = 11)] - #[doc = "Maximum amount of registrars reached. Cannot add any more."] - TooManyRegistrars, - #[codec(index = 12)] - #[doc = "Account ID is already named."] - AlreadyClaimed, - #[codec(index = 13)] - #[doc = "Sender is not a sub-account."] - NotSub, - #[codec(index = 14)] - #[doc = "Sub-account isn't owned by sender."] - NotOwned, - #[codec(index = 15)] - #[doc = "The provided judgement was for a different identity."] - JudgementForDifferentIdentity, - #[codec(index = 16)] - #[doc = "Error that occurs when there is an issue paying for judgement."] - JudgementPaymentFailed, - #[codec(index = 17)] - #[doc = "The provided suffix is too long."] - InvalidSuffix, - #[codec(index = 18)] - #[doc = "The sender does not have permission to issue a username."] - NotUsernameAuthority, - #[codec(index = 19)] - #[doc = "The authority cannot allocate any more usernames."] - NoAllocation, - #[codec(index = 20)] - #[doc = "The signature on a username was not valid."] - InvalidSignature, - #[codec(index = 21)] - #[doc = "Setting this username requires a signature, but none was provided."] - RequiresSignature, - #[codec(index = 22)] - #[doc = "The username does not meet the requirements."] - InvalidUsername, - #[codec(index = 23)] - #[doc = "The username is already taken."] - UsernameTaken, - #[codec(index = 24)] - #[doc = "The requested username does not exist."] - NoUsername, - #[codec(index = 25)] - #[doc = "The username cannot be forcefully removed because it can still be accepted."] - NotExpired, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A name was set or reset (which will remove all judgements)."] - IdentitySet { who: ::subxt::utils::AccountId32 }, - #[codec(index = 1)] - #[doc = "A name was cleared, and the given balance returned."] - IdentityCleared { - who: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "A name was removed and the given balance slashed."] - IdentityKilled { - who: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "A judgement was asked from a registrar."] - JudgementRequested { - who: ::subxt::utils::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 4)] - #[doc = "A judgement request was retracted."] - JudgementUnrequested { - who: ::subxt::utils::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 5)] - #[doc = "A judgement was given by a registrar."] - JudgementGiven { - target: ::subxt::utils::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 6)] - #[doc = "A registrar was added."] - RegistrarAdded { registrar_index: ::core::primitive::u32 }, - #[codec(index = 7)] - #[doc = "A sub-identity was added to an identity and the deposit paid."] - SubIdentityAdded { - sub: ::subxt::utils::AccountId32, - main: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 8)] - #[doc = "A sub-identity was removed from an identity and the deposit freed."] - SubIdentityRemoved { - sub: ::subxt::utils::AccountId32, - main: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 9)] - #[doc = "A sub-identity was cleared, and the given deposit repatriated from the"] - #[doc = "main identity account to the sub-identity account."] - SubIdentityRevoked { - sub: ::subxt::utils::AccountId32, - main: ::subxt::utils::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 10)] - #[doc = "A username authority was added."] - AuthorityAdded { authority: ::subxt::utils::AccountId32 }, - #[codec(index = 11)] - #[doc = "A username authority was removed."] - AuthorityRemoved { authority: ::subxt::utils::AccountId32 }, - #[codec(index = 12)] - #[doc = "A username was set for `who`."] - UsernameSet { - who: ::subxt::utils::AccountId32, - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - }, - #[codec(index = 13)] - #[doc = "A username was queued, but `who` must accept it prior to `expiration`."] - UsernameQueued { - who: ::subxt::utils::AccountId32, - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - expiration: ::core::primitive::u32, - }, - #[codec(index = 14)] - #[doc = "A queued username passed its expiration without being claimed and was removed."] - PreapprovalExpired { whose: ::subxt::utils::AccountId32 }, - #[codec(index = 15)] - #[doc = "A username was set as a primary and can be looked up from `who`."] - PrimaryUsernameSet { - who: ::subxt::utils::AccountId32, - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - }, - #[codec(index = 16)] - #[doc = "A dangling username (as in, a username corresponding to an account that has removed its"] - #[doc = "identity) has been removed."] - DanglingUsernameRemoved { - who: ::subxt::utils::AccountId32, - username: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AuthorityProperties<_0> { - pub suffix: _0, - pub allocation: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Data { - #[codec(index = 0)] - None, - #[codec(index = 1)] - Raw0([::core::primitive::u8; 0usize]), - #[codec(index = 2)] - Raw1([::core::primitive::u8; 1usize]), - #[codec(index = 3)] - Raw2([::core::primitive::u8; 2usize]), - #[codec(index = 4)] - Raw3([::core::primitive::u8; 3usize]), - #[codec(index = 5)] - Raw4([::core::primitive::u8; 4usize]), - #[codec(index = 6)] - Raw5([::core::primitive::u8; 5usize]), - #[codec(index = 7)] - Raw6([::core::primitive::u8; 6usize]), - #[codec(index = 8)] - Raw7([::core::primitive::u8; 7usize]), - #[codec(index = 9)] - Raw8([::core::primitive::u8; 8usize]), - #[codec(index = 10)] - Raw9([::core::primitive::u8; 9usize]), - #[codec(index = 11)] - Raw10([::core::primitive::u8; 10usize]), - #[codec(index = 12)] - Raw11([::core::primitive::u8; 11usize]), - #[codec(index = 13)] - Raw12([::core::primitive::u8; 12usize]), - #[codec(index = 14)] - Raw13([::core::primitive::u8; 13usize]), - #[codec(index = 15)] - Raw14([::core::primitive::u8; 14usize]), - #[codec(index = 16)] - Raw15([::core::primitive::u8; 15usize]), - #[codec(index = 17)] - Raw16([::core::primitive::u8; 16usize]), - #[codec(index = 18)] - Raw17([::core::primitive::u8; 17usize]), - #[codec(index = 19)] - Raw18([::core::primitive::u8; 18usize]), - #[codec(index = 20)] - Raw19([::core::primitive::u8; 19usize]), - #[codec(index = 21)] - Raw20([::core::primitive::u8; 20usize]), - #[codec(index = 22)] - Raw21([::core::primitive::u8; 21usize]), - #[codec(index = 23)] - Raw22([::core::primitive::u8; 22usize]), - #[codec(index = 24)] - Raw23([::core::primitive::u8; 23usize]), - #[codec(index = 25)] - Raw24([::core::primitive::u8; 24usize]), - #[codec(index = 26)] - Raw25([::core::primitive::u8; 25usize]), - #[codec(index = 27)] - Raw26([::core::primitive::u8; 26usize]), - #[codec(index = 28)] - Raw27([::core::primitive::u8; 27usize]), - #[codec(index = 29)] - Raw28([::core::primitive::u8; 28usize]), - #[codec(index = 30)] - Raw29([::core::primitive::u8; 29usize]), - #[codec(index = 31)] - Raw30([::core::primitive::u8; 30usize]), - #[codec(index = 32)] - Raw31([::core::primitive::u8; 31usize]), - #[codec(index = 33)] - Raw32([::core::primitive::u8; 32usize]), - #[codec(index = 34)] - BlakeTwo256([::core::primitive::u8; 32usize]), - #[codec(index = 35)] - Sha256([::core::primitive::u8; 32usize]), - #[codec(index = 36)] - Keccak256([::core::primitive::u8; 32usize]), - #[codec(index = 37)] - ShaThree256([::core::primitive::u8; 32usize]), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Judgement<_0> { - #[codec(index = 0)] - Unknown, - #[codec(index = 1)] - FeePaid(_0), - #[codec(index = 2)] - Reasonable, - #[codec(index = 3)] - KnownGood, - #[codec(index = 4)] - OutOfDate, - #[codec(index = 5)] - LowQuality, - #[codec(index = 6)] - Erroneous, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RegistrarInfo<_0, _1, _2> { - pub account: _1, - pub fee: _0, - pub fields: _2, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Registration<_0, _2> { - pub judgements: runtime_types::bounded_collections::bounded_vec::BoundedVec<( - ::core::primitive::u32, - runtime_types::pallet_identity::types::Judgement<_0>, - )>, - pub deposit: _0, - pub info: _2, - } - } - } - pub mod pallet_indices { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::claim`]."] - claim { index: ::core::primitive::u32 }, - #[codec(index = 1)] - #[doc = "See [`Pallet::transfer`]."] - transfer { - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - index: ::core::primitive::u32, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::free`]."] - free { index: ::core::primitive::u32 }, - #[codec(index = 3)] - #[doc = "See [`Pallet::force_transfer`]."] - force_transfer { - new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - index: ::core::primitive::u32, - freeze: ::core::primitive::bool, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::freeze`]."] - freeze { index: ::core::primitive::u32 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The index was not already assigned."] - NotAssigned, - #[codec(index = 1)] - #[doc = "The index is assigned to another account."] - NotOwner, - #[codec(index = 2)] - #[doc = "The index was not available."] - InUse, - #[codec(index = 3)] - #[doc = "The source and destination accounts are identical."] - NotTransfer, - #[codec(index = 4)] - #[doc = "The index is permanent and may not be freed/changed."] - Permanent, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A account index was assigned."] - IndexAssigned { - who: ::subxt::utils::AccountId32, - index: ::core::primitive::u32, - }, - #[codec(index = 1)] - #[doc = "A account index has been freed up (unassigned)."] - IndexFreed { index: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "A account index has been frozen to its current account ID."] - IndexFrozen { index: ::core::primitive::u32, who: ::subxt::utils::AccountId32 }, - } - } - } - pub mod pallet_message_queue { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - # [codec (index = 0)] # [doc = "See [`Pallet::reap_page`]."] reap_page { message_origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , page_index : :: core :: primitive :: u32 , } , # [codec (index = 1)] # [doc = "See [`Pallet::execute_overweight`]."] execute_overweight { message_origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , page : :: core :: primitive :: u32 , index : :: core :: primitive :: u32 , weight_limit : runtime_types :: sp_weights :: weight_v2 :: Weight , } , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Page is not reapable because it has items remaining to be processed and is not old"] - #[doc = "enough."] - NotReapable, - #[codec(index = 1)] - #[doc = "Page to be reaped does not exist."] - NoPage, - #[codec(index = 2)] - #[doc = "The referenced message could not be found."] - NoMessage, - #[codec(index = 3)] - #[doc = "The message was already processed and cannot be processed again."] - AlreadyProcessed, - #[codec(index = 4)] - #[doc = "The message is queued for future execution."] - Queued, - #[codec(index = 5)] - #[doc = "There is temporarily not enough weight to continue servicing messages."] - InsufficientWeight, - #[codec(index = 6)] - #[doc = "This message is temporarily unprocessable."] - #[doc = ""] - #[doc = "Such errors are expected, but not guaranteed, to resolve themselves eventually through"] - #[doc = "retrying."] - TemporarilyUnprocessable, - #[codec(index = 7)] - #[doc = "The queue is paused and no message can be executed from it."] - #[doc = ""] - #[doc = "This can change at any time and may resolve in the future by re-trying."] - QueuePaused, - #[codec(index = 8)] - #[doc = "Another call is in progress and needs to finish before this call can happen."] - RecursiveDisallowed, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - # [codec (index = 0)] # [doc = "Message discarded due to an error in the `MessageProcessor` (usually a format error)."] ProcessingFailed { id : :: subxt :: utils :: H256 , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , error : runtime_types :: frame_support :: traits :: messages :: ProcessMessageError , } , # [codec (index = 1)] # [doc = "Message is processed."] Processed { id : :: subxt :: utils :: H256 , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , weight_used : runtime_types :: sp_weights :: weight_v2 :: Weight , success : :: core :: primitive :: bool , } , # [codec (index = 2)] # [doc = "Message placed in overweight queue."] OverweightEnqueued { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , page_index : :: core :: primitive :: u32 , message_index : :: core :: primitive :: u32 , } , # [codec (index = 3)] # [doc = "This page was reaped."] PageReaped { origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , index : :: core :: primitive :: u32 , } , } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BookState<_0> { - pub begin: ::core::primitive::u32, - pub end: ::core::primitive::u32, - pub count: ::core::primitive::u32, - pub ready_neighbours: - ::core::option::Option>, - pub message_count: ::core::primitive::u64, - pub size: ::core::primitive::u64, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Neighbours<_0> { - pub prev: _0, - pub next: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Page<_0> { - pub remaining: _0, - pub remaining_size: _0, - pub first_index: _0, - pub first: _0, - pub last: _0, - pub heap: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - } - } - pub mod pallet_multisig { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::as_multi_threshold_1`]."] - as_multi_threshold_1 { - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - call: ::std::boxed::Box, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::as_multi`]."] - as_multi { - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call: ::std::boxed::Box, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::approve_as_multi`]."] - approve_as_multi { - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - maybe_timepoint: ::core::option::Option< - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - >, - call_hash: [::core::primitive::u8; 32usize], - max_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::cancel_as_multi`]."] - cancel_as_multi { - threshold: ::core::primitive::u16, - other_signatories: ::std::vec::Vec<::subxt::utils::AccountId32>, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - call_hash: [::core::primitive::u8; 32usize], - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Threshold must be 2 or greater."] - MinimumThreshold, - #[codec(index = 1)] - #[doc = "Call is already approved by this signatory."] - AlreadyApproved, - #[codec(index = 2)] - #[doc = "Call doesn't need any (more) approvals."] - NoApprovalsNeeded, - #[codec(index = 3)] - #[doc = "There are too few signatories in the list."] - TooFewSignatories, - #[codec(index = 4)] - #[doc = "There are too many signatories in the list."] - TooManySignatories, - #[codec(index = 5)] - #[doc = "The signatories were provided out of order; they should be ordered."] - SignatoriesOutOfOrder, - #[codec(index = 6)] - #[doc = "The sender was contained in the other signatories; it shouldn't be."] - SenderInSignatories, - #[codec(index = 7)] - #[doc = "Multisig operation not found when attempting to cancel."] - NotFound, - #[codec(index = 8)] - #[doc = "Only the account that originally created the multisig is able to cancel it."] - NotOwner, - #[codec(index = 9)] - #[doc = "No timepoint was given, yet the multisig operation is already underway."] - NoTimepoint, - #[codec(index = 10)] - #[doc = "A different timepoint was given to the multisig operation that is underway."] - WrongTimepoint, - #[codec(index = 11)] - #[doc = "A timepoint was given, yet no multisig operation is underway."] - UnexpectedTimepoint, - #[codec(index = 12)] - #[doc = "The maximum weight information provided was too low."] - MaxWeightTooLow, - #[codec(index = 13)] - #[doc = "The data to be stored is already stored."] - AlreadyStored, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A new multisig operation has begun."] - NewMultisig { - approving: ::subxt::utils::AccountId32, - multisig: ::subxt::utils::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 1)] - #[doc = "A multisig operation has been approved by someone."] - MultisigApproval { - approving: ::subxt::utils::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::subxt::utils::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - #[doc = "A multisig operation has been executed."] - MultisigExecuted { - approving: ::subxt::utils::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::subxt::utils::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - #[doc = "A multisig operation has been cancelled."] - MultisigCancelled { - cancelling: ::subxt::utils::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::subxt::utils::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Multisig<_0, _1, _2> { - pub when: runtime_types::pallet_multisig::Timepoint<_0>, - pub deposit: _1, - pub depositor: _2, - pub approvals: runtime_types::bounded_collections::bounded_vec::BoundedVec<_2>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Timepoint<_0> { - pub height: _0, - pub index: ::core::primitive::u32, - } - } - pub mod pallet_nis { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bid<_0, _1> { - pub amount: _0, - pub who: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::place_bid`]."] - place_bid { - #[codec(compact)] - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::retract_bid`]."] - retract_bid { - #[codec(compact)] - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::fund_deficit`]."] - fund_deficit, - #[codec(index = 3)] - #[doc = "See [`Pallet::thaw_private`]."] - thaw_private { - #[codec(compact)] - index: ::core::primitive::u32, - maybe_proportion: ::core::option::Option< - runtime_types::sp_arithmetic::per_things::Perquintill, - >, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::thaw_communal`]."] - thaw_communal { - #[codec(compact)] - index: ::core::primitive::u32, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::communify`]."] - communify { - #[codec(compact)] - index: ::core::primitive::u32, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::privatize`]."] - privatize { - #[codec(compact)] - index: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The duration of the bid is less than one."] - DurationTooSmall, - #[codec(index = 1)] - #[doc = "The duration is the bid is greater than the number of queues."] - DurationTooBig, - #[codec(index = 2)] - #[doc = "The amount of the bid is less than the minimum allowed."] - AmountTooSmall, - #[codec(index = 3)] - #[doc = "The queue for the bid's duration is full and the amount bid is too low to get in"] - #[doc = "through replacing an existing bid."] - BidTooLow, - #[codec(index = 4)] - #[doc = "Receipt index is unknown."] - UnknownReceipt, - #[codec(index = 5)] - #[doc = "Not the owner of the receipt."] - NotOwner, - #[codec(index = 6)] - #[doc = "Bond not yet at expiry date."] - NotExpired, - #[codec(index = 7)] - #[doc = "The given bid for retraction is not found."] - UnknownBid, - #[codec(index = 8)] - #[doc = "The portion supplied is beyond the value of the receipt."] - PortionTooBig, - #[codec(index = 9)] - #[doc = "Not enough funds are held to pay out."] - Unfunded, - #[codec(index = 10)] - #[doc = "There are enough funds for what is required."] - AlreadyFunded, - #[codec(index = 11)] - #[doc = "The thaw throttle has been reached for this period."] - Throttled, - #[codec(index = 12)] - #[doc = "The operation would result in a receipt worth an insignficant value."] - MakesDust, - #[codec(index = 13)] - #[doc = "The receipt is already communal."] - AlreadyCommunal, - #[codec(index = 14)] - #[doc = "The receipt is already private."] - AlreadyPrivate, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A bid was successfully placed."] - BidPlaced { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 1)] - #[doc = "A bid was successfully removed (before being accepted)."] - BidRetracted { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 2)] - #[doc = "A bid was dropped from a queue because of another, more substantial, bid was present."] - BidDropped { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "A bid was accepted. The balance may not be released until expiry."] - Issued { - index: ::core::primitive::u32, - expiry: ::core::primitive::u32, - who: ::subxt::utils::AccountId32, - proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "An receipt has been (at least partially) thawed."] - Thawed { - index: ::core::primitive::u32, - who: ::subxt::utils::AccountId32, - proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - amount: ::core::primitive::u128, - dropped: ::core::primitive::bool, - }, - #[codec(index = 5)] - #[doc = "An automatic funding of the deficit was made."] - Funded { deficit: ::core::primitive::u128 }, - #[codec(index = 6)] - #[doc = "A receipt was transfered."] - Transferred { - from: ::subxt::utils::AccountId32, - to: ::subxt::utils::AccountId32, - index: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum HoldReason { - #[codec(index = 0)] - NftReceipt, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReceiptRecord<_0, _1, _2> { - pub proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - pub owner: ::core::option::Option<(_0, _2)>, - pub expiry: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SummaryRecord<_0, _1> { - pub proportion_owed: runtime_types::sp_arithmetic::per_things::Perquintill, - pub index: ::core::primitive::u32, - pub thawed: runtime_types::sp_arithmetic::per_things::Perquintill, - pub last_period: _0, - pub receipts_on_hold: _1, - } - } - } - pub mod pallet_offences { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Events type."] - pub enum Event { - #[codec(index = 0)] - #[doc = "There is an offence reported of the given `kind` happened at the `session_index` and"] - #[doc = "(kind-specific) time slot. This event is not deposited for duplicate slashes."] - #[doc = "\\[kind, timeslot\\]."] - Offence { - kind: [::core::primitive::u8; 16usize], - timeslot: ::std::vec::Vec<::core::primitive::u8>, - }, - } - } - } - pub mod pallet_preimage { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::note_preimage`]."] - note_preimage { bytes: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 1)] - #[doc = "See [`Pallet::unnote_preimage`]."] - unnote_preimage { hash: ::subxt::utils::H256 }, - #[codec(index = 2)] - #[doc = "See [`Pallet::request_preimage`]."] - request_preimage { hash: ::subxt::utils::H256 }, - #[codec(index = 3)] - #[doc = "See [`Pallet::unrequest_preimage`]."] - unrequest_preimage { hash: ::subxt::utils::H256 }, - #[codec(index = 4)] - #[doc = "See [`Pallet::ensure_updated`]."] - ensure_updated { hashes: ::std::vec::Vec<::subxt::utils::H256> }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Preimage is too large to store on-chain."] - TooBig, - #[codec(index = 1)] - #[doc = "Preimage has already been noted on-chain."] - AlreadyNoted, - #[codec(index = 2)] - #[doc = "The user is not authorized to perform this action."] - NotAuthorized, - #[codec(index = 3)] - #[doc = "The preimage cannot be removed since it has not yet been noted."] - NotNoted, - #[codec(index = 4)] - #[doc = "A preimage may not be removed when there are outstanding requests."] - Requested, - #[codec(index = 5)] - #[doc = "The preimage request cannot be removed since no outstanding requests exist."] - NotRequested, - #[codec(index = 6)] - #[doc = "More than `MAX_HASH_UPGRADE_BULK_COUNT` hashes were requested to be upgraded at once."] - TooMany, - #[codec(index = 7)] - #[doc = "Too few hashes were requested to be upgraded (i.e. zero)."] - TooFew, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A preimage has been noted."] - Noted { hash: ::subxt::utils::H256 }, - #[codec(index = 1)] - #[doc = "A preimage has been requested."] - Requested { hash: ::subxt::utils::H256 }, - #[codec(index = 2)] - #[doc = "A preimage has ben cleared."] - Cleared { hash: ::subxt::utils::H256 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum HoldReason { - #[codec(index = 0)] - Preimage, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum OldRequestStatus<_0, _1> { - #[codec(index = 0)] - Unrequested { deposit: (_0, _1), len: ::core::primitive::u32 }, - #[codec(index = 1)] - Requested { - deposit: ::core::option::Option<(_0, _1)>, - count: ::core::primitive::u32, - len: ::core::option::Option<::core::primitive::u32>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RequestStatus<_0, _1> { - #[codec(index = 0)] - Unrequested { ticket: (_0, _1), len: ::core::primitive::u32 }, - #[codec(index = 1)] - Requested { - maybe_ticket: ::core::option::Option<(_0, _1)>, - count: ::core::primitive::u32, - maybe_len: ::core::option::Option<::core::primitive::u32>, - }, - } - } - pub mod pallet_proxy { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::proxy`]."] - proxy { - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - force_proxy_type: - ::core::option::Option, - call: ::std::boxed::Box, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::add_proxy`]."] - add_proxy { - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::remove_proxy`]."] - remove_proxy { - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::remove_proxies`]."] - remove_proxies, - #[codec(index = 4)] - #[doc = "See [`Pallet::create_pure`]."] - create_pure { - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - index: ::core::primitive::u16, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::kill_pure`]."] - kill_pure { - spawner: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - proxy_type: runtime_types::rococo_runtime::ProxyType, - index: ::core::primitive::u16, - #[codec(compact)] - height: ::core::primitive::u32, - #[codec(compact)] - ext_index: ::core::primitive::u32, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::announce`]."] - announce { - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::remove_announcement`]."] - remove_announcement { - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - }, - #[codec(index = 8)] - #[doc = "See [`Pallet::reject_announcement`]."] - reject_announcement { - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call_hash: ::subxt::utils::H256, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::proxy_announced`]."] - proxy_announced { - delegate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - real: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - force_proxy_type: - ::core::option::Option, - call: ::std::boxed::Box, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "There are too many proxies registered or too many announcements pending."] - TooMany, - #[codec(index = 1)] - #[doc = "Proxy registration not found."] - NotFound, - #[codec(index = 2)] - #[doc = "Sender is not a proxy of the account to be proxied."] - NotProxy, - #[codec(index = 3)] - #[doc = "A call which is incompatible with the proxy type's filter was attempted."] - Unproxyable, - #[codec(index = 4)] - #[doc = "Account is already a proxy."] - Duplicate, - #[codec(index = 5)] - #[doc = "Call may not be made by proxy because it may escalate its privileges."] - NoPermission, - #[codec(index = 6)] - #[doc = "Announcement, if made at all, was made too recently."] - Unannounced, - #[codec(index = 7)] - #[doc = "Cannot add self as proxy."] - NoSelfProxy, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A proxy was executed correctly, with the given."] - ProxyExecuted { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - #[doc = "A pure account has been created by new proxy with given"] - #[doc = "disambiguation index and proxy type."] - PureCreated { - pure: ::subxt::utils::AccountId32, - who: ::subxt::utils::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - disambiguation_index: ::core::primitive::u16, - }, - #[codec(index = 2)] - #[doc = "An announcement was placed to make a call in the future."] - Announced { - real: ::subxt::utils::AccountId32, - proxy: ::subxt::utils::AccountId32, - call_hash: ::subxt::utils::H256, - }, - #[codec(index = 3)] - #[doc = "A proxy was added."] - ProxyAdded { - delegator: ::subxt::utils::AccountId32, - delegatee: ::subxt::utils::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - #[codec(index = 4)] - #[doc = "A proxy was removed."] - ProxyRemoved { - delegator: ::subxt::utils::AccountId32, - delegatee: ::subxt::utils::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Announcement<_0, _1, _2> { - pub real: _0, - pub call_hash: _1, - pub height: _2, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ProxyDefinition<_0, _1, _2> { - pub delegate: _0, - pub proxy_type: _1, - pub delay: _2, - } - } - pub mod pallet_ranked_collective { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::add_member`]."] - add_member { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::promote_member`]."] - promote_member { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::demote_member`]."] - demote_member { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::remove_member`]."] - remove_member { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - min_rank: ::core::primitive::u16, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::vote`]."] - vote { poll: ::core::primitive::u32, aye: ::core::primitive::bool }, - #[codec(index = 5)] - #[doc = "See [`Pallet::cleanup_poll`]."] - cleanup_poll { poll_index: ::core::primitive::u32, max: ::core::primitive::u32 }, - #[codec(index = 6)] - #[doc = "See [`Pallet::exchange_member`]."] - exchange_member { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - new_who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Account is already a member."] - AlreadyMember, - #[codec(index = 1)] - #[doc = "Account is not a member."] - NotMember, - #[codec(index = 2)] - #[doc = "The given poll index is unknown or has closed."] - NotPolling, - #[codec(index = 3)] - #[doc = "The given poll is still ongoing."] - Ongoing, - #[codec(index = 4)] - #[doc = "There are no further records to be removed."] - NoneRemaining, - #[codec(index = 5)] - #[doc = "Unexpected error in state."] - Corruption, - #[codec(index = 6)] - #[doc = "The member's rank is too low to vote."] - RankTooLow, - #[codec(index = 7)] - #[doc = "The information provided is incorrect."] - InvalidWitness, - #[codec(index = 8)] - #[doc = "The origin is not sufficiently privileged to do the operation."] - NoPermission, - #[codec(index = 9)] - #[doc = "The new member to exchange is the same as the old member"] - SameMember, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A member `who` has been added."] - MemberAdded { who: ::subxt::utils::AccountId32 }, - #[codec(index = 1)] - #[doc = "The member `who`se rank has been changed to the given `rank`."] - RankChanged { who: ::subxt::utils::AccountId32, rank: ::core::primitive::u16 }, - #[codec(index = 2)] - #[doc = "The member `who` of given `rank` has been removed from the collective."] - MemberRemoved { who: ::subxt::utils::AccountId32, rank: ::core::primitive::u16 }, - #[codec(index = 3)] - #[doc = "The member `who` has voted for the `poll` with the given `vote` leading to an updated"] - #[doc = "`tally`."] - Voted { - who: ::subxt::utils::AccountId32, - poll: ::core::primitive::u32, - vote: runtime_types::pallet_ranked_collective::VoteRecord, - tally: runtime_types::pallet_ranked_collective::Tally, - }, - #[codec(index = 4)] - #[doc = "The member `who` had their `AccountId` changed to `new_who`."] - MemberExchanged { - who: ::subxt::utils::AccountId32, - new_who: ::subxt::utils::AccountId32, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MemberRecord { - pub rank: ::core::primitive::u16, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Tally { - pub bare_ayes: ::core::primitive::u32, - pub ayes: ::core::primitive::u32, - pub nays: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VoteRecord { - #[codec(index = 0)] - Aye(::core::primitive::u32), - #[codec(index = 1)] - Nay(::core::primitive::u32), - } - } - pub mod pallet_recovery { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::as_recovered`]."] - as_recovered { - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call: ::std::boxed::Box, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::set_recovered`]."] - set_recovered { - lost: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::create_recovery`]."] - create_recovery { - friends: ::std::vec::Vec<::subxt::utils::AccountId32>, - threshold: ::core::primitive::u16, - delay_period: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::initiate_recovery`]."] - initiate_recovery { - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::vouch_recovery`]."] - vouch_recovery { - lost: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::claim_recovery`]."] - claim_recovery { - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::close_recovery`]."] - close_recovery { - rescuer: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::remove_recovery`]."] - remove_recovery, - #[codec(index = 8)] - #[doc = "See [`Pallet::cancel_recovered`]."] - cancel_recovered { - account: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "User is not allowed to make a call on behalf of this account"] - NotAllowed, - #[codec(index = 1)] - #[doc = "Threshold must be greater than zero"] - ZeroThreshold, - #[codec(index = 2)] - #[doc = "Friends list must be greater than zero and threshold"] - NotEnoughFriends, - #[codec(index = 3)] - #[doc = "Friends list must be less than max friends"] - MaxFriends, - #[codec(index = 4)] - #[doc = "Friends list must be sorted and free of duplicates"] - NotSorted, - #[codec(index = 5)] - #[doc = "This account is not set up for recovery"] - NotRecoverable, - #[codec(index = 6)] - #[doc = "This account is already set up for recovery"] - AlreadyRecoverable, - #[codec(index = 7)] - #[doc = "A recovery process has already started for this account"] - AlreadyStarted, - #[codec(index = 8)] - #[doc = "A recovery process has not started for this rescuer"] - NotStarted, - #[codec(index = 9)] - #[doc = "This account is not a friend who can vouch"] - NotFriend, - #[codec(index = 10)] - #[doc = "The friend must wait until the delay period to vouch for this recovery"] - DelayPeriod, - #[codec(index = 11)] - #[doc = "This user has already vouched for this recovery"] - AlreadyVouched, - #[codec(index = 12)] - #[doc = "The threshold for recovering this account has not been met"] - Threshold, - #[codec(index = 13)] - #[doc = "There are still active recovery attempts that need to be closed"] - StillActive, - #[codec(index = 14)] - #[doc = "This account is already set up for recovery"] - AlreadyProxy, - #[codec(index = 15)] - #[doc = "Some internal state is broken."] - BadState, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Events type."] - pub enum Event { - #[codec(index = 0)] - #[doc = "A recovery process has been set up for an account."] - RecoveryCreated { account: ::subxt::utils::AccountId32 }, - #[codec(index = 1)] - #[doc = "A recovery process has been initiated for lost account by rescuer account."] - RecoveryInitiated { - lost_account: ::subxt::utils::AccountId32, - rescuer_account: ::subxt::utils::AccountId32, - }, - #[codec(index = 2)] - #[doc = "A recovery process for lost account by rescuer account has been vouched for by sender."] - RecoveryVouched { - lost_account: ::subxt::utils::AccountId32, - rescuer_account: ::subxt::utils::AccountId32, - sender: ::subxt::utils::AccountId32, - }, - #[codec(index = 3)] - #[doc = "A recovery process for lost account by rescuer account has been closed."] - RecoveryClosed { - lost_account: ::subxt::utils::AccountId32, - rescuer_account: ::subxt::utils::AccountId32, - }, - #[codec(index = 4)] - #[doc = "Lost account has been successfully recovered by rescuer account."] - AccountRecovered { - lost_account: ::subxt::utils::AccountId32, - rescuer_account: ::subxt::utils::AccountId32, - }, - #[codec(index = 5)] - #[doc = "A recovery process has been removed for an account."] - RecoveryRemoved { lost_account: ::subxt::utils::AccountId32 }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ActiveRecovery<_0, _1, _2> { - pub created: _0, - pub deposit: _1, - pub friends: _2, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RecoveryConfig<_0, _1, _2> { - pub delay_period: _0, - pub deposit: _1, - pub friends: _2, - pub threshold: ::core::primitive::u16, - } - } - pub mod pallet_referenda { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::submit`]."] - submit { - proposal_origin: - ::std::boxed::Box, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - enactment_moment: - runtime_types::frame_support::traits::schedule::DispatchTime< - ::core::primitive::u32, - >, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::place_decision_deposit`]."] - place_decision_deposit { index: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "See [`Pallet::refund_decision_deposit`]."] - refund_decision_deposit { index: ::core::primitive::u32 }, - #[codec(index = 3)] - #[doc = "See [`Pallet::cancel`]."] - cancel { index: ::core::primitive::u32 }, - #[codec(index = 4)] - #[doc = "See [`Pallet::kill`]."] - kill { index: ::core::primitive::u32 }, - #[codec(index = 5)] - #[doc = "See [`Pallet::nudge_referendum`]."] - nudge_referendum { index: ::core::primitive::u32 }, - #[codec(index = 6)] - #[doc = "See [`Pallet::one_fewer_deciding`]."] - one_fewer_deciding { track: ::core::primitive::u16 }, - #[codec(index = 7)] - #[doc = "See [`Pallet::refund_submission_deposit`]."] - refund_submission_deposit { index: ::core::primitive::u32 }, - #[codec(index = 8)] - #[doc = "See [`Pallet::set_metadata`]."] - set_metadata { - index: ::core::primitive::u32, - maybe_hash: ::core::option::Option<::subxt::utils::H256>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call2 { - #[codec(index = 0)] - #[doc = "See [`Pallet::submit`]."] - submit { - proposal_origin: - ::std::boxed::Box, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - enactment_moment: - runtime_types::frame_support::traits::schedule::DispatchTime< - ::core::primitive::u32, - >, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::place_decision_deposit`]."] - place_decision_deposit { index: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "See [`Pallet::refund_decision_deposit`]."] - refund_decision_deposit { index: ::core::primitive::u32 }, - #[codec(index = 3)] - #[doc = "See [`Pallet::cancel`]."] - cancel { index: ::core::primitive::u32 }, - #[codec(index = 4)] - #[doc = "See [`Pallet::kill`]."] - kill { index: ::core::primitive::u32 }, - #[codec(index = 5)] - #[doc = "See [`Pallet::nudge_referendum`]."] - nudge_referendum { index: ::core::primitive::u32 }, - #[codec(index = 6)] - #[doc = "See [`Pallet::one_fewer_deciding`]."] - one_fewer_deciding { track: ::core::primitive::u16 }, - #[codec(index = 7)] - #[doc = "See [`Pallet::refund_submission_deposit`]."] - refund_submission_deposit { index: ::core::primitive::u32 }, - #[codec(index = 8)] - #[doc = "See [`Pallet::set_metadata`]."] - set_metadata { - index: ::core::primitive::u32, - maybe_hash: ::core::option::Option<::subxt::utils::H256>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Referendum is not ongoing."] - NotOngoing, - #[codec(index = 1)] - #[doc = "Referendum's decision deposit is already paid."] - HasDeposit, - #[codec(index = 2)] - #[doc = "The track identifier given was invalid."] - BadTrack, - #[codec(index = 3)] - #[doc = "There are already a full complement of referenda in progress for this track."] - Full, - #[codec(index = 4)] - #[doc = "The queue of the track is empty."] - QueueEmpty, - #[codec(index = 5)] - #[doc = "The referendum index provided is invalid in this context."] - BadReferendum, - #[codec(index = 6)] - #[doc = "There was nothing to do in the advancement."] - NothingToDo, - #[codec(index = 7)] - #[doc = "No track exists for the proposal origin."] - NoTrack, - #[codec(index = 8)] - #[doc = "Any deposit cannot be refunded until after the decision is over."] - Unfinished, - #[codec(index = 9)] - #[doc = "The deposit refunder is not the depositor."] - NoPermission, - #[codec(index = 10)] - #[doc = "The deposit cannot be refunded since none was made."] - NoDeposit, - #[codec(index = 11)] - #[doc = "The referendum status is invalid for this operation."] - BadStatus, - #[codec(index = 12)] - #[doc = "The preimage does not exist."] - PreimageNotExist, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error2 { - #[codec(index = 0)] - #[doc = "Referendum is not ongoing."] - NotOngoing, - #[codec(index = 1)] - #[doc = "Referendum's decision deposit is already paid."] - HasDeposit, - #[codec(index = 2)] - #[doc = "The track identifier given was invalid."] - BadTrack, - #[codec(index = 3)] - #[doc = "There are already a full complement of referenda in progress for this track."] - Full, - #[codec(index = 4)] - #[doc = "The queue of the track is empty."] - QueueEmpty, - #[codec(index = 5)] - #[doc = "The referendum index provided is invalid in this context."] - BadReferendum, - #[codec(index = 6)] - #[doc = "There was nothing to do in the advancement."] - NothingToDo, - #[codec(index = 7)] - #[doc = "No track exists for the proposal origin."] - NoTrack, - #[codec(index = 8)] - #[doc = "Any deposit cannot be refunded until after the decision is over."] - Unfinished, - #[codec(index = 9)] - #[doc = "The deposit refunder is not the depositor."] - NoPermission, - #[codec(index = 10)] - #[doc = "The deposit cannot be refunded since none was made."] - NoDeposit, - #[codec(index = 11)] - #[doc = "The referendum status is invalid for this operation."] - BadStatus, - #[codec(index = 12)] - #[doc = "The preimage does not exist."] - PreimageNotExist, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A referendum has been submitted."] - Submitted { - index: ::core::primitive::u32, - track: ::core::primitive::u16, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - }, - #[codec(index = 1)] - #[doc = "The decision deposit has been placed."] - DecisionDepositPlaced { - index: ::core::primitive::u32, - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "The decision deposit has been refunded."] - DecisionDepositRefunded { - index: ::core::primitive::u32, - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "A deposit has been slashed."] - DepositSlashed { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "A referendum has moved into the deciding phase."] - DecisionStarted { - index: ::core::primitive::u32, - track: ::core::primitive::u16, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - tally: runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - }, - #[codec(index = 5)] - ConfirmStarted { index: ::core::primitive::u32 }, - #[codec(index = 6)] - ConfirmAborted { index: ::core::primitive::u32 }, - #[codec(index = 7)] - #[doc = "A referendum has ended its confirmation phase and is ready for approval."] - Confirmed { - index: ::core::primitive::u32, - tally: runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - }, - #[codec(index = 8)] - #[doc = "A referendum has been approved and its proposal has been scheduled."] - Approved { index: ::core::primitive::u32 }, - #[codec(index = 9)] - #[doc = "A proposal has been rejected by referendum."] - Rejected { - index: ::core::primitive::u32, - tally: runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - }, - #[codec(index = 10)] - #[doc = "A referendum has been timed out without being decided."] - TimedOut { - index: ::core::primitive::u32, - tally: runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - }, - #[codec(index = 11)] - #[doc = "A referendum has been cancelled."] - Cancelled { - index: ::core::primitive::u32, - tally: runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - }, - #[codec(index = 12)] - #[doc = "A referendum has been killed."] - Killed { - index: ::core::primitive::u32, - tally: runtime_types::pallet_conviction_voting::types::Tally< - ::core::primitive::u128, - >, - }, - #[codec(index = 13)] - #[doc = "The submission deposit has been refunded."] - SubmissionDepositRefunded { - index: ::core::primitive::u32, - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - #[doc = "Metadata for a referendum has been set."] - MetadataSet { index: ::core::primitive::u32, hash: ::subxt::utils::H256 }, - #[codec(index = 15)] - #[doc = "Metadata for a referendum has been cleared."] - MetadataCleared { index: ::core::primitive::u32, hash: ::subxt::utils::H256 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event2 { - #[codec(index = 0)] - #[doc = "A referendum has been submitted."] - Submitted { - index: ::core::primitive::u32, - track: ::core::primitive::u16, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - }, - #[codec(index = 1)] - #[doc = "The decision deposit has been placed."] - DecisionDepositPlaced { - index: ::core::primitive::u32, - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "The decision deposit has been refunded."] - DecisionDepositRefunded { - index: ::core::primitive::u32, - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "A deposit has been slashed."] - DepositSlashed { - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "A referendum has moved into the deciding phase."] - DecisionStarted { - index: ::core::primitive::u32, - track: ::core::primitive::u16, - proposal: runtime_types::frame_support::traits::preimages::Bounded< - runtime_types::rococo_runtime::RuntimeCall, - runtime_types::sp_runtime::traits::BlakeTwo256, - >, - tally: runtime_types::pallet_ranked_collective::Tally, - }, - #[codec(index = 5)] - ConfirmStarted { index: ::core::primitive::u32 }, - #[codec(index = 6)] - ConfirmAborted { index: ::core::primitive::u32 }, - #[codec(index = 7)] - #[doc = "A referendum has ended its confirmation phase and is ready for approval."] - Confirmed { - index: ::core::primitive::u32, - tally: runtime_types::pallet_ranked_collective::Tally, - }, - #[codec(index = 8)] - #[doc = "A referendum has been approved and its proposal has been scheduled."] - Approved { index: ::core::primitive::u32 }, - #[codec(index = 9)] - #[doc = "A proposal has been rejected by referendum."] - Rejected { - index: ::core::primitive::u32, - tally: runtime_types::pallet_ranked_collective::Tally, - }, - #[codec(index = 10)] - #[doc = "A referendum has been timed out without being decided."] - TimedOut { - index: ::core::primitive::u32, - tally: runtime_types::pallet_ranked_collective::Tally, - }, - #[codec(index = 11)] - #[doc = "A referendum has been cancelled."] - Cancelled { - index: ::core::primitive::u32, - tally: runtime_types::pallet_ranked_collective::Tally, - }, - #[codec(index = 12)] - #[doc = "A referendum has been killed."] - Killed { - index: ::core::primitive::u32, - tally: runtime_types::pallet_ranked_collective::Tally, - }, - #[codec(index = 13)] - #[doc = "The submission deposit has been refunded."] - SubmissionDepositRefunded { - index: ::core::primitive::u32, - who: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - #[doc = "Metadata for a referendum has been set."] - MetadataSet { index: ::core::primitive::u32, hash: ::subxt::utils::H256 }, - #[codec(index = 15)] - #[doc = "Metadata for a referendum has been cleared."] - MetadataCleared { index: ::core::primitive::u32, hash: ::subxt::utils::H256 }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Curve { - #[codec(index = 0)] - LinearDecreasing { - length: runtime_types::sp_arithmetic::per_things::Perbill, - floor: runtime_types::sp_arithmetic::per_things::Perbill, - ceil: runtime_types::sp_arithmetic::per_things::Perbill, - }, - #[codec(index = 1)] - SteppedDecreasing { - begin: runtime_types::sp_arithmetic::per_things::Perbill, - end: runtime_types::sp_arithmetic::per_things::Perbill, - step: runtime_types::sp_arithmetic::per_things::Perbill, - period: runtime_types::sp_arithmetic::per_things::Perbill, - }, - #[codec(index = 2)] - Reciprocal { - factor: runtime_types::sp_arithmetic::fixed_point::FixedI64, - x_offset: runtime_types::sp_arithmetic::fixed_point::FixedI64, - y_offset: runtime_types::sp_arithmetic::fixed_point::FixedI64, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DecidingStatus<_0> { - pub since: _0, - pub confirming: ::core::option::Option<_0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Deposit<_0, _1> { - pub who: _0, - pub amount: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ReferendumInfo<_0, _1, _2, _3, _4, _5, _6, _7> { - #[codec(index = 0)] - Ongoing( - runtime_types::pallet_referenda::types::ReferendumStatus< - _0, - _1, - _2, - _3, - _4, - _5, - _6, - _7, - >, - ), - #[codec(index = 1)] - Approved( - _2, - ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - ), - #[codec(index = 2)] - Rejected( - _2, - ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - ), - #[codec(index = 3)] - Cancelled( - _2, - ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - ), - #[codec(index = 4)] - TimedOut( - _2, - ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - ), - #[codec(index = 5)] - Killed(_2), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReferendumStatus<_0, _1, _2, _3, _4, _5, _6, _7> { - pub track: _0, - pub origin: _1, - pub proposal: _3, - pub enactment: runtime_types::frame_support::traits::schedule::DispatchTime<_2>, - pub submitted: _2, - pub submission_deposit: runtime_types::pallet_referenda::types::Deposit<_6, _4>, - pub decision_deposit: ::core::option::Option< - runtime_types::pallet_referenda::types::Deposit<_6, _4>, - >, - pub deciding: ::core::option::Option< - runtime_types::pallet_referenda::types::DecidingStatus<_2>, - >, - pub tally: _5, - pub in_queue: ::core::primitive::bool, - pub alarm: ::core::option::Option<(_2, _7)>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct TrackInfo<_0, _1> { - pub name: ::std::string::String, - pub max_deciding: ::core::primitive::u32, - pub decision_deposit: _0, - pub prepare_period: _1, - pub decision_period: _1, - pub confirm_period: _1, - pub min_enactment_period: _1, - pub min_approval: runtime_types::pallet_referenda::types::Curve, - pub min_support: runtime_types::pallet_referenda::types::Curve, - } - } - } - pub mod pallet_root_testing { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See `Pallet::fill_block`."] - fill_block { ratio: runtime_types::sp_arithmetic::per_things::Perbill }, - #[codec(index = 1)] - #[doc = "See `Pallet::trigger_defensive`."] - trigger_defensive, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Event dispatched when the trigger_defensive extrinsic is called."] - DefensiveTestCall, - } - } - } - pub mod pallet_scheduler { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::schedule`]."] - schedule { - when: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: ::std::boxed::Box, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::cancel`]."] - cancel { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "See [`Pallet::schedule_named`]."] - schedule_named { - id: [::core::primitive::u8; 32usize], - when: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: ::std::boxed::Box, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::cancel_named`]."] - cancel_named { id: [::core::primitive::u8; 32usize] }, - #[codec(index = 4)] - #[doc = "See [`Pallet::schedule_after`]."] - schedule_after { - after: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: ::std::boxed::Box, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::schedule_named_after`]."] - schedule_named_after { - id: [::core::primitive::u8; 32usize], - after: ::core::primitive::u32, - maybe_periodic: ::core::option::Option<( - ::core::primitive::u32, - ::core::primitive::u32, - )>, - priority: ::core::primitive::u8, - call: ::std::boxed::Box, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Failed to schedule a call"] - FailedToSchedule, - #[codec(index = 1)] - #[doc = "Cannot find the scheduled call."] - NotFound, - #[codec(index = 2)] - #[doc = "Given target block number is in the past."] - TargetBlockNumberInPast, - #[codec(index = 3)] - #[doc = "Reschedule failed because it does not change scheduled time."] - RescheduleNoChange, - #[codec(index = 4)] - #[doc = "Attempt to use a non-named function on a named task."] - Named, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Events type."] - pub enum Event { - #[codec(index = 0)] - #[doc = "Scheduled some task."] - Scheduled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 1)] - #[doc = "Canceled some task."] - Canceled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "Dispatched some task."] - Dispatched { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - #[doc = "The call for the provided hash was not found so the task has been aborted."] - CallUnavailable { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 4)] - #[doc = "The given task was unable to be renewed since the agenda is full at that block."] - PeriodicFailed { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 5)] - #[doc = "The given task can never be executed since it is overweight."] - PermanentlyOverweight { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Scheduled<_0, _1, _2, _3, _4> { - pub maybe_id: ::core::option::Option<_0>, - pub priority: ::core::primitive::u8, - pub call: _1, - pub maybe_periodic: ::core::option::Option<(_2, _2)>, - pub origin: _3, - #[codec(skip)] - pub __subxt_unused_type_params: ::core::marker::PhantomData<_4>, - } - } - pub mod pallet_session { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::set_keys`]."] - set_keys { - keys: runtime_types::rococo_runtime::SessionKeys, - proof: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::purge_keys`]."] - purge_keys, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the session pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Invalid ownership proof."] - InvalidProof, - #[codec(index = 1)] - #[doc = "No associated validator ID for account."] - NoAssociatedValidatorId, - #[codec(index = 2)] - #[doc = "Registered duplicate key."] - DuplicatedKey, - #[codec(index = 3)] - #[doc = "No keys are associated with this account."] - NoKeys, - #[codec(index = 4)] - #[doc = "Key setting account is not live, so it's impossible to associate keys."] - NoAccount, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "New session has happened. Note that the argument is the session index, not the"] - #[doc = "block number as the type might suggest."] - NewSession { session_index: ::core::primitive::u32 }, - } - } - } - pub mod pallet_society { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::bid`]."] - bid { value: ::core::primitive::u128 }, - #[codec(index = 1)] - #[doc = "See [`Pallet::unbid`]."] - unbid, - #[codec(index = 2)] - #[doc = "See [`Pallet::vouch`]."] - vouch { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - value: ::core::primitive::u128, - tip: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::unvouch`]."] - unvouch, - #[codec(index = 4)] - #[doc = "See [`Pallet::vote`]."] - vote { - candidate: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - approve: ::core::primitive::bool, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::defender_vote`]."] - defender_vote { approve: ::core::primitive::bool }, - #[codec(index = 6)] - #[doc = "See [`Pallet::payout`]."] - payout, - #[codec(index = 7)] - #[doc = "See [`Pallet::waive_repay`]."] - waive_repay { amount: ::core::primitive::u128 }, - #[codec(index = 8)] - #[doc = "See [`Pallet::found_society`]."] - found_society { - founder: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - max_members: ::core::primitive::u32, - max_intake: ::core::primitive::u32, - max_strikes: ::core::primitive::u32, - candidate_deposit: ::core::primitive::u128, - rules: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::dissolve`]."] - dissolve, - #[codec(index = 10)] - #[doc = "See [`Pallet::judge_suspended_member`]."] - judge_suspended_member { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - forgive: ::core::primitive::bool, - }, - #[codec(index = 11)] - #[doc = "See [`Pallet::set_parameters`]."] - set_parameters { - max_members: ::core::primitive::u32, - max_intake: ::core::primitive::u32, - max_strikes: ::core::primitive::u32, - candidate_deposit: ::core::primitive::u128, - }, - #[codec(index = 12)] - #[doc = "See [`Pallet::punish_skeptic`]."] - punish_skeptic, - #[codec(index = 13)] - #[doc = "See [`Pallet::claim_membership`]."] - claim_membership, - #[codec(index = 14)] - #[doc = "See [`Pallet::bestow_membership`]."] - bestow_membership { candidate: ::subxt::utils::AccountId32 }, - #[codec(index = 15)] - #[doc = "See [`Pallet::kick_candidate`]."] - kick_candidate { candidate: ::subxt::utils::AccountId32 }, - #[codec(index = 16)] - #[doc = "See [`Pallet::resign_candidacy`]."] - resign_candidacy, - #[codec(index = 17)] - #[doc = "See [`Pallet::drop_candidate`]."] - drop_candidate { candidate: ::subxt::utils::AccountId32 }, - #[codec(index = 18)] - #[doc = "See [`Pallet::cleanup_candidacy`]."] - cleanup_candidacy { - candidate: ::subxt::utils::AccountId32, - max: ::core::primitive::u32, - }, - #[codec(index = 19)] - #[doc = "See [`Pallet::cleanup_challenge`]."] - cleanup_challenge { - challenge_round: ::core::primitive::u32, - max: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "User is not a member."] - NotMember, - #[codec(index = 1)] - #[doc = "User is already a member."] - AlreadyMember, - #[codec(index = 2)] - #[doc = "User is suspended."] - Suspended, - #[codec(index = 3)] - #[doc = "User is not suspended."] - NotSuspended, - #[codec(index = 4)] - #[doc = "Nothing to payout."] - NoPayout, - #[codec(index = 5)] - #[doc = "Society already founded."] - AlreadyFounded, - #[codec(index = 6)] - #[doc = "Not enough in pot to accept candidate."] - InsufficientPot, - #[codec(index = 7)] - #[doc = "Member is already vouching or banned from vouching again."] - AlreadyVouching, - #[codec(index = 8)] - #[doc = "Member is not vouching."] - NotVouchingOnBidder, - #[codec(index = 9)] - #[doc = "Cannot remove the head of the chain."] - Head, - #[codec(index = 10)] - #[doc = "Cannot remove the founder."] - Founder, - #[codec(index = 11)] - #[doc = "User has already made a bid."] - AlreadyBid, - #[codec(index = 12)] - #[doc = "User is already a candidate."] - AlreadyCandidate, - #[codec(index = 13)] - #[doc = "User is not a candidate."] - NotCandidate, - #[codec(index = 14)] - #[doc = "Too many members in the society."] - MaxMembers, - #[codec(index = 15)] - #[doc = "The caller is not the founder."] - NotFounder, - #[codec(index = 16)] - #[doc = "The caller is not the head."] - NotHead, - #[codec(index = 17)] - #[doc = "The membership cannot be claimed as the candidate was not clearly approved."] - NotApproved, - #[codec(index = 18)] - #[doc = "The candidate cannot be kicked as the candidate was not clearly rejected."] - NotRejected, - #[codec(index = 19)] - #[doc = "The candidacy cannot be dropped as the candidate was clearly approved."] - Approved, - #[codec(index = 20)] - #[doc = "The candidacy cannot be bestowed as the candidate was clearly rejected."] - Rejected, - #[codec(index = 21)] - #[doc = "The candidacy cannot be concluded as the voting is still in progress."] - InProgress, - #[codec(index = 22)] - #[doc = "The candidacy cannot be pruned until a full additional intake period has passed."] - TooEarly, - #[codec(index = 23)] - #[doc = "The skeptic already voted."] - Voted, - #[codec(index = 24)] - #[doc = "The skeptic need not vote on candidates from expired rounds."] - Expired, - #[codec(index = 25)] - #[doc = "User is not a bidder."] - NotBidder, - #[codec(index = 26)] - #[doc = "There is no defender currently."] - NoDefender, - #[codec(index = 27)] - #[doc = "Group doesn't exist."] - NotGroup, - #[codec(index = 28)] - #[doc = "The member is already elevated to this rank."] - AlreadyElevated, - #[codec(index = 29)] - #[doc = "The skeptic has already been punished for this offence."] - AlreadyPunished, - #[codec(index = 30)] - #[doc = "Funds are insufficient to pay off society debts."] - InsufficientFunds, - #[codec(index = 31)] - #[doc = "The candidate/defender has no stale votes to remove."] - NoVotes, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "The society is founded by the given identity."] - Founded { founder: ::subxt::utils::AccountId32 }, - #[codec(index = 1)] - #[doc = "A membership bid just happened. The given account is the candidate's ID and their offer"] - #[doc = "is the second."] - Bid { - candidate_id: ::subxt::utils::AccountId32, - offer: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "A membership bid just happened by vouching. The given account is the candidate's ID and"] - #[doc = "their offer is the second. The vouching party is the third."] - Vouch { - candidate_id: ::subxt::utils::AccountId32, - offer: ::core::primitive::u128, - vouching: ::subxt::utils::AccountId32, - }, - #[codec(index = 3)] - #[doc = "A candidate was dropped (due to an excess of bids in the system)."] - AutoUnbid { candidate: ::subxt::utils::AccountId32 }, - #[codec(index = 4)] - #[doc = "A candidate was dropped (by their request)."] - Unbid { candidate: ::subxt::utils::AccountId32 }, - #[codec(index = 5)] - #[doc = "A candidate was dropped (by request of who vouched for them)."] - Unvouch { candidate: ::subxt::utils::AccountId32 }, - #[codec(index = 6)] - #[doc = "A group of candidates have been inducted. The batch's primary is the first value, the"] - #[doc = "batch in full is the second."] - Inducted { - primary: ::subxt::utils::AccountId32, - candidates: ::std::vec::Vec<::subxt::utils::AccountId32>, - }, - #[codec(index = 7)] - #[doc = "A suspended member has been judged."] - SuspendedMemberJudgement { - who: ::subxt::utils::AccountId32, - judged: ::core::primitive::bool, - }, - #[codec(index = 8)] - #[doc = "A candidate has been suspended"] - CandidateSuspended { candidate: ::subxt::utils::AccountId32 }, - #[codec(index = 9)] - #[doc = "A member has been suspended"] - MemberSuspended { member: ::subxt::utils::AccountId32 }, - #[codec(index = 10)] - #[doc = "A member has been challenged"] - Challenged { member: ::subxt::utils::AccountId32 }, - #[codec(index = 11)] - #[doc = "A vote has been placed"] - Vote { - candidate: ::subxt::utils::AccountId32, - voter: ::subxt::utils::AccountId32, - vote: ::core::primitive::bool, - }, - #[codec(index = 12)] - #[doc = "A vote has been placed for a defending member"] - DefenderVote { - voter: ::subxt::utils::AccountId32, - vote: ::core::primitive::bool, - }, - #[codec(index = 13)] - #[doc = "A new set of \\[params\\] has been set for the group."] - NewParams { - params: runtime_types::pallet_society::GroupParams<::core::primitive::u128>, - }, - #[codec(index = 14)] - #[doc = "Society is unfounded."] - Unfounded { founder: ::subxt::utils::AccountId32 }, - #[codec(index = 15)] - #[doc = "Some funds were deposited into the society account."] - Deposit { value: ::core::primitive::u128 }, - #[codec(index = 16)] - #[doc = "A \\[member\\] got elevated to \\[rank\\]."] - Elevated { member: ::subxt::utils::AccountId32, rank: ::core::primitive::u32 }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Bid<_0, _1> { - pub who: _0, - pub kind: runtime_types::pallet_society::BidKind<_0, _1>, - pub value: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BidKind<_0, _1> { - #[codec(index = 0)] - Deposit(_1), - #[codec(index = 1)] - Vouch(_0, _1), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Candidacy<_0, _1> { - pub round: ::core::primitive::u32, - pub kind: runtime_types::pallet_society::BidKind<_0, _1>, - pub bid: _1, - pub tally: runtime_types::pallet_society::Tally, - pub skeptic_struck: ::core::primitive::bool, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GroupParams<_0> { - pub max_members: ::core::primitive::u32, - pub max_intake: ::core::primitive::u32, - pub max_strikes: ::core::primitive::u32, - pub candidate_deposit: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IntakeRecord<_0, _1> { - pub who: _0, - pub bid: _1, - pub round: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MemberRecord { - pub rank: ::core::primitive::u32, - pub strikes: ::core::primitive::u32, - pub vouching: ::core::option::Option, - pub index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PayoutRecord<_0, _1> { - pub paid: _0, - pub payouts: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Tally { - pub approvals: ::core::primitive::u32, - pub rejections: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Vote { - pub approve: ::core::primitive::bool, - pub weight: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VouchingStatus { - #[codec(index = 0)] - Vouching, - #[codec(index = 1)] - Banned, - } - } - pub mod pallet_state_trie_migration { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::control_auto_migration`]."] - control_auto_migration { - maybe_config: ::core::option::Option< - runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - >, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::continue_migrate`]."] - continue_migrate { - limits: runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - real_size_upper: ::core::primitive::u32, - witness_task: - runtime_types::pallet_state_trie_migration::pallet::MigrationTask, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::migrate_custom_top`]."] - migrate_custom_top { - keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - witness_size: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::migrate_custom_child`]."] - migrate_custom_child { - root: ::std::vec::Vec<::core::primitive::u8>, - child_keys: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - total_size: ::core::primitive::u32, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::set_signed_max_limits`]."] - set_signed_max_limits { - limits: runtime_types::pallet_state_trie_migration::pallet::MigrationLimits, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::force_set_progress`]."] - force_set_progress { - progress_top: runtime_types::pallet_state_trie_migration::pallet::Progress, - progress_child: - runtime_types::pallet_state_trie_migration::pallet::Progress, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Max signed limits not respected."] - MaxSignedLimits, - #[codec(index = 1)] - #[doc = "A key was longer than the configured maximum."] - #[doc = ""] - #[doc = "This means that the migration halted at the current [`Progress`] and"] - #[doc = "can be resumed with a larger [`crate::Config::MaxKeyLen`] value."] - #[doc = "Retrying with the same [`crate::Config::MaxKeyLen`] value will not work."] - #[doc = "The value should only be increased to avoid a storage migration for the currently"] - #[doc = "stored [`crate::Progress::LastKey`]."] - KeyTooLong, - #[codec(index = 2)] - #[doc = "submitter does not have enough funds."] - NotEnoughFunds, - #[codec(index = 3)] - #[doc = "Bad witness data provided."] - BadWitness, - #[codec(index = 4)] - #[doc = "Signed migration is not allowed because the maximum limit is not set yet."] - SignedMigrationNotAllowed, - #[codec(index = 5)] - #[doc = "Bad child root provided."] - BadChildRoot, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Inner events of this pallet."] - pub enum Event { - #[codec(index = 0)] - #[doc = "Given number of `(top, child)` keys were migrated respectively, with the given"] - #[doc = "`compute`."] - Migrated { - top: ::core::primitive::u32, - child: ::core::primitive::u32, - compute: - runtime_types::pallet_state_trie_migration::pallet::MigrationCompute, - }, - #[codec(index = 1)] - #[doc = "Some account got slashed by the given amount."] - Slashed { who: ::subxt::utils::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 2)] - #[doc = "The auto migration task finished."] - AutoMigrationFinished, - #[codec(index = 3)] - #[doc = "Migration got halted due to an error or miss-configuration."] - Halted { error: runtime_types::pallet_state_trie_migration::pallet::Error }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum HoldReason { - #[codec(index = 0)] - SlashForMigrate, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MigrationCompute { - #[codec(index = 0)] - Signed, - #[codec(index = 1)] - Auto, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MigrationLimits { - pub size: ::core::primitive::u32, - pub item: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MigrationTask { - pub progress_top: runtime_types::pallet_state_trie_migration::pallet::Progress, - pub progress_child: - runtime_types::pallet_state_trie_migration::pallet::Progress, - pub size: ::core::primitive::u32, - pub top_items: ::core::primitive::u32, - pub child_items: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Progress { - #[codec(index = 0)] - ToStart, - #[codec(index = 1)] - LastKey( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Complete, - } - } - } - pub mod pallet_sudo { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::sudo`]."] - sudo { call: ::std::boxed::Box }, - #[codec(index = 1)] - #[doc = "See [`Pallet::sudo_unchecked_weight`]."] - sudo_unchecked_weight { - call: ::std::boxed::Box, - weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::set_key`]."] - set_key { new: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()> }, - #[codec(index = 3)] - #[doc = "See [`Pallet::sudo_as`]."] - sudo_as { - who: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - call: ::std::boxed::Box, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::remove_key`]."] - remove_key, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the Sudo pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Sender must be the Sudo account."] - RequireSudo, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A sudo call just took place."] - Sudid { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - #[doc = "The sudo key has been updated."] - KeyChanged { - old: ::core::option::Option<::subxt::utils::AccountId32>, - new: ::subxt::utils::AccountId32, - }, - #[codec(index = 2)] - #[doc = "The key was permanently removed."] - KeyRemoved, - #[codec(index = 3)] - #[doc = "A [sudo_as](Pallet::sudo_as) call just took place."] - SudoAsDone { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod pallet_timestamp { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::set`]."] - set { - #[codec(compact)] - now: ::core::primitive::u64, - }, - } - } - } - pub mod pallet_transaction_payment { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A transaction fee `actual_fee`, of which `tip` was added to the minimum inclusion fee,"] - #[doc = "has been paid by `who`."] - TransactionFeePaid { - who: ::subxt::utils::AccountId32, - actual_fee: ::core::primitive::u128, - tip: ::core::primitive::u128, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FeeDetails<_0> { - pub inclusion_fee: ::core::option::Option< - runtime_types::pallet_transaction_payment::types::InclusionFee<_0>, - >, - pub tip: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InclusionFee<_0> { - pub base_fee: _0, - pub len_fee: _0, - pub adjusted_weight_fee: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RuntimeDispatchInfo<_0, _1> { - pub weight: _1, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub partial_fee: _0, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ChargeTransactionPayment(#[codec(compact)] pub ::core::primitive::u128); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Releases { - #[codec(index = 0)] - V1Ancient, - #[codec(index = 1)] - V2, - } - } - pub mod pallet_treasury { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::propose_spend`]."] - propose_spend { - #[codec(compact)] - value: ::core::primitive::u128, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::reject_proposal`]."] - reject_proposal { - #[codec(compact)] - proposal_id: ::core::primitive::u32, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::approve_proposal`]."] - approve_proposal { - #[codec(compact)] - proposal_id: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::spend_local`]."] - spend_local { - #[codec(compact)] - amount: ::core::primitive::u128, - beneficiary: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::remove_approval`]."] - remove_approval { - #[codec(compact)] - proposal_id: ::core::primitive::u32, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::spend`]."] - spend { - asset_kind: ::std::boxed::Box< - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - >, - #[codec(compact)] - amount: ::core::primitive::u128, - beneficiary: ::std::boxed::Box, - valid_from: ::core::option::Option<::core::primitive::u32>, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::payout`]."] - payout { index: ::core::primitive::u32 }, - #[codec(index = 7)] - #[doc = "See [`Pallet::check_status`]."] - check_status { index: ::core::primitive::u32 }, - #[codec(index = 8)] - #[doc = "See [`Pallet::void_spend`]."] - void_spend { index: ::core::primitive::u32 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the treasury pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Proposer's balance is too low."] - InsufficientProposersBalance, - #[codec(index = 1)] - #[doc = "No proposal, bounty or spend at that index."] - InvalidIndex, - #[codec(index = 2)] - #[doc = "Too many approvals in the queue."] - TooManyApprovals, - #[codec(index = 3)] - #[doc = "The spend origin is valid but the amount it is allowed to spend is lower than the"] - #[doc = "amount to be spent."] - InsufficientPermission, - #[codec(index = 4)] - #[doc = "Proposal has not been approved."] - ProposalNotApproved, - #[codec(index = 5)] - #[doc = "The balance of the asset kind is not convertible to the balance of the native asset."] - FailedToConvertBalance, - #[codec(index = 6)] - #[doc = "The spend has expired and cannot be claimed."] - SpendExpired, - #[codec(index = 7)] - #[doc = "The spend is not yet eligible for payout."] - EarlyPayout, - #[codec(index = 8)] - #[doc = "The payment has already been attempted."] - AlreadyAttempted, - #[codec(index = 9)] - #[doc = "There was some issue with the mechanism of payment."] - PayoutError, - #[codec(index = 10)] - #[doc = "The payout was not yet attempted/claimed."] - NotAttempted, - #[codec(index = 11)] - #[doc = "The payment has neither failed nor succeeded yet."] - Inconclusive, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "New proposal."] - Proposed { proposal_index: ::core::primitive::u32 }, - #[codec(index = 1)] - #[doc = "We have ended a spend period and will now allocate funds."] - Spending { budget_remaining: ::core::primitive::u128 }, - #[codec(index = 2)] - #[doc = "Some funds have been allocated."] - Awarded { - proposal_index: ::core::primitive::u32, - award: ::core::primitive::u128, - account: ::subxt::utils::AccountId32, - }, - #[codec(index = 3)] - #[doc = "A proposal was rejected; funds were slashed."] - Rejected { - proposal_index: ::core::primitive::u32, - slashed: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "Some of our funds have been burnt."] - Burnt { burnt_funds: ::core::primitive::u128 }, - #[codec(index = 5)] - #[doc = "Spending has finished; this is the amount that rolls over until next spend."] - Rollover { rollover_balance: ::core::primitive::u128 }, - #[codec(index = 6)] - #[doc = "Some funds have been deposited."] - Deposit { value: ::core::primitive::u128 }, - #[codec(index = 7)] - #[doc = "A new spend proposal has been approved."] - SpendApproved { - proposal_index: ::core::primitive::u32, - amount: ::core::primitive::u128, - beneficiary: ::subxt::utils::AccountId32, - }, - #[codec(index = 8)] - #[doc = "The inactive funds of the pallet have been updated."] - UpdatedInactive { - reactivated: ::core::primitive::u128, - deactivated: ::core::primitive::u128, - }, - #[codec(index = 9)] - #[doc = "A new asset spend proposal has been approved."] - AssetSpendApproved { - index: ::core::primitive::u32, - asset_kind: - runtime_types::polkadot_runtime_common::impls::VersionedLocatableAsset, - amount: ::core::primitive::u128, - beneficiary: runtime_types::xcm::VersionedLocation, - valid_from: ::core::primitive::u32, - expire_at: ::core::primitive::u32, - }, - #[codec(index = 10)] - #[doc = "An approved spend was voided."] - AssetSpendVoided { index: ::core::primitive::u32 }, - #[codec(index = 11)] - #[doc = "A payment happened."] - Paid { index: ::core::primitive::u32, payment_id: ::core::primitive::u64 }, - #[codec(index = 12)] - #[doc = "A payment failed and can be retried."] - PaymentFailed { - index: ::core::primitive::u32, - payment_id: ::core::primitive::u64, - }, - #[codec(index = 13)] - #[doc = "A spend was processed and removed from the storage. It might have been successfully"] - #[doc = "paid or it may have expired."] - SpendProcessed { index: ::core::primitive::u32 }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum PaymentState<_0> { - #[codec(index = 0)] - Pending, - #[codec(index = 1)] - Attempted { id: _0 }, - #[codec(index = 2)] - Failed, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Proposal<_0, _1> { - pub proposer: _0, - pub value: _1, - pub beneficiary: _0, - pub bond: _1, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SpendStatus<_0, _1, _2, _3, _4> { - pub asset_kind: _0, - pub amount: _1, - pub beneficiary: _2, - pub valid_from: _3, - pub expire_at: _3, - pub status: runtime_types::pallet_treasury::PaymentState<_4>, - } - } - pub mod pallet_utility { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::batch`]."] - batch { calls: ::std::vec::Vec }, - #[codec(index = 1)] - #[doc = "See [`Pallet::as_derivative`]."] - as_derivative { - index: ::core::primitive::u16, - call: ::std::boxed::Box, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::batch_all`]."] - batch_all { calls: ::std::vec::Vec }, - #[codec(index = 3)] - #[doc = "See [`Pallet::dispatch_as`]."] - dispatch_as { - as_origin: ::std::boxed::Box, - call: ::std::boxed::Box, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::force_batch`]."] - force_batch { - calls: ::std::vec::Vec, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::with_weight`]."] - with_weight { - call: ::std::boxed::Box, - weight: runtime_types::sp_weights::weight_v2::Weight, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Too many calls batched."] - TooManyCalls, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Batch of dispatches did not complete fully. Index of first failing dispatch given, as"] - #[doc = "well as the error."] - BatchInterrupted { - index: ::core::primitive::u32, - error: runtime_types::sp_runtime::DispatchError, - }, - #[codec(index = 1)] - #[doc = "Batch of dispatches completed fully with no error."] - BatchCompleted, - #[codec(index = 2)] - #[doc = "Batch of dispatches completed but has errors."] - BatchCompletedWithErrors, - #[codec(index = 3)] - #[doc = "A single item within a Batch of dispatches has completed with no error."] - ItemCompleted, - #[codec(index = 4)] - #[doc = "A single item within a Batch of dispatches has completed with error."] - ItemFailed { error: runtime_types::sp_runtime::DispatchError }, - #[codec(index = 5)] - #[doc = "A call was dispatched."] - DispatchedAs { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod pallet_vesting { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::vest`]."] - vest, - #[codec(index = 1)] - #[doc = "See [`Pallet::vest_other`]."] - vest_other { - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::vested_transfer`]."] - vested_transfer { - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::force_vested_transfer`]."] - force_vested_transfer { - source: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule: runtime_types::pallet_vesting::vesting_info::VestingInfo< - ::core::primitive::u128, - ::core::primitive::u32, - >, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::merge_schedules`]."] - merge_schedules { - schedule1_index: ::core::primitive::u32, - schedule2_index: ::core::primitive::u32, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::force_remove_vesting_schedule`]."] - force_remove_vesting_schedule { - target: ::subxt::utils::MultiAddress<::subxt::utils::AccountId32, ()>, - schedule_index: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Error for the vesting pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The account given is not vesting."] - NotVesting, - #[codec(index = 1)] - #[doc = "The account already has `MaxVestingSchedules` count of schedules and thus"] - #[doc = "cannot add another one. Consider merging existing schedules in order to add another."] - AtMaxVestingSchedules, - #[codec(index = 2)] - #[doc = "Amount being transferred is too low to create a vesting schedule."] - AmountLow, - #[codec(index = 3)] - #[doc = "An index was out of bounds of the vesting schedules."] - ScheduleIndexOutOfBounds, - #[codec(index = 4)] - #[doc = "Failed to create a new schedule because some parameter was invalid."] - InvalidScheduleParams, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "The amount vested has been updated. This could indicate a change in funds available."] - #[doc = "The balance given is the amount which is left unvested (and thus locked)."] - VestingUpdated { - account: ::subxt::utils::AccountId32, - unvested: ::core::primitive::u128, - }, - #[codec(index = 1)] - #[doc = "An \\[account\\] has become fully vested."] - VestingCompleted { account: ::subxt::utils::AccountId32 }, - } - } - pub mod vesting_info { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VestingInfo<_0, _1> { - pub locked: _0, - pub per_block: _0, - pub starting_block: _1, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Releases { - #[codec(index = 0)] - V0, - #[codec(index = 1)] - V1, - } - } - pub mod pallet_whitelist { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::whitelist_call`]."] - whitelist_call { call_hash: ::subxt::utils::H256 }, - #[codec(index = 1)] - #[doc = "See [`Pallet::remove_whitelisted_call`]."] - remove_whitelisted_call { call_hash: ::subxt::utils::H256 }, - #[codec(index = 2)] - #[doc = "See [`Pallet::dispatch_whitelisted_call`]."] - dispatch_whitelisted_call { - call_hash: ::subxt::utils::H256, - call_encoded_len: ::core::primitive::u32, - call_weight_witness: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::dispatch_whitelisted_call_with_preimage`]."] - dispatch_whitelisted_call_with_preimage { - call: ::std::boxed::Box, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The preimage of the call hash could not be loaded."] - UnavailablePreImage, - #[codec(index = 1)] - #[doc = "The call could not be decoded."] - UndecodableCall, - #[codec(index = 2)] - #[doc = "The weight of the decoded call was higher than the witness."] - InvalidCallWeightWitness, - #[codec(index = 3)] - #[doc = "The call was not whitelisted."] - CallIsNotWhitelisted, - #[codec(index = 4)] - #[doc = "The call was already whitelisted; No-Op."] - CallAlreadyWhitelisted, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - CallWhitelisted { call_hash: ::subxt::utils::H256 }, - #[codec(index = 1)] - WhitelistedCallRemoved { call_hash: ::subxt::utils::H256 }, - #[codec(index = 2)] - WhitelistedCallDispatched { - call_hash: ::subxt::utils::H256, - result: ::core::result::Result< - runtime_types::frame_support::dispatch::PostDispatchInfo, - runtime_types::sp_runtime::DispatchErrorWithPostInfo< - runtime_types::frame_support::dispatch::PostDispatchInfo, - >, - >, - }, - } - } - } - pub mod pallet_xcm { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::send`]."] - send { - dest: ::std::boxed::Box, - message: ::std::boxed::Box, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::teleport_assets`]."] - teleport_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::reserve_transfer_assets`]."] - reserve_transfer_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::execute`]."] - execute { - message: ::std::boxed::Box, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::force_xcm_version`]."] - force_xcm_version { - location: - ::std::boxed::Box, - version: ::core::primitive::u32, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::force_default_xcm_version`]."] - force_default_xcm_version { - maybe_xcm_version: ::core::option::Option<::core::primitive::u32>, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::force_subscribe_version_notify`]."] - force_subscribe_version_notify { - location: ::std::boxed::Box, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::force_unsubscribe_version_notify`]."] - force_unsubscribe_version_notify { - location: ::std::boxed::Box, - }, - #[codec(index = 8)] - #[doc = "See [`Pallet::limited_reserve_transfer_assets`]."] - limited_reserve_transfer_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 9)] - #[doc = "See [`Pallet::limited_teleport_assets`]."] - limited_teleport_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 10)] - #[doc = "See [`Pallet::force_suspension`]."] - force_suspension { suspended: ::core::primitive::bool }, - #[codec(index = 11)] - #[doc = "See [`Pallet::transfer_assets`]."] - transfer_assets { - dest: ::std::boxed::Box, - beneficiary: ::std::boxed::Box, - assets: ::std::boxed::Box, - fee_asset_item: ::core::primitive::u32, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The desired destination was unreachable, generally because there is a no way of routing"] - #[doc = "to it."] - Unreachable, - #[codec(index = 1)] - #[doc = "There was some other issue (i.e. not to do with routing) in sending the message."] - #[doc = "Perhaps a lack of space for buffering the message."] - SendFailure, - #[codec(index = 2)] - #[doc = "The message execution fails the filter."] - Filtered, - #[codec(index = 3)] - #[doc = "The message's weight could not be determined."] - UnweighableMessage, - #[codec(index = 4)] - #[doc = "The destination `Location` provided cannot be inverted."] - DestinationNotInvertible, - #[codec(index = 5)] - #[doc = "The assets to be sent are empty."] - Empty, - #[codec(index = 6)] - #[doc = "Could not re-anchor the assets to declare the fees for the destination chain."] - CannotReanchor, - #[codec(index = 7)] - #[doc = "Too many assets have been attempted for transfer."] - TooManyAssets, - #[codec(index = 8)] - #[doc = "Origin is invalid for sending."] - InvalidOrigin, - #[codec(index = 9)] - #[doc = "The version of the `Versioned` value used is not able to be interpreted."] - BadVersion, - #[codec(index = 10)] - #[doc = "The given location could not be used (e.g. because it cannot be expressed in the"] - #[doc = "desired version of XCM)."] - BadLocation, - #[codec(index = 11)] - #[doc = "The referenced subscription could not be found."] - NoSubscription, - #[codec(index = 12)] - #[doc = "The location is invalid since it already has a subscription from us."] - AlreadySubscribed, - #[codec(index = 13)] - #[doc = "Could not check-out the assets for teleportation to the destination chain."] - CannotCheckOutTeleport, - #[codec(index = 14)] - #[doc = "The owner does not own (all) of the asset that they wish to do the operation on."] - LowBalance, - #[codec(index = 15)] - #[doc = "The asset owner has too many locks on the asset."] - TooManyLocks, - #[codec(index = 16)] - #[doc = "The given account is not an identifiable sovereign account for any location."] - AccountNotSovereign, - #[codec(index = 17)] - #[doc = "The operation required fees to be paid which the initiator could not meet."] - FeesNotMet, - #[codec(index = 18)] - #[doc = "A remote lock with the corresponding data could not be found."] - LockNotFound, - #[codec(index = 19)] - #[doc = "The unlock operation cannot succeed because there are still consumers of the lock."] - InUse, - #[codec(index = 20)] - #[doc = "Invalid non-concrete asset."] - InvalidAssetNotConcrete, - #[codec(index = 21)] - #[doc = "Invalid asset, reserve chain could not be determined for it."] - InvalidAssetUnknownReserve, - #[codec(index = 22)] - #[doc = "Invalid asset, do not support remote asset reserves with different fees reserves."] - InvalidAssetUnsupportedReserve, - #[codec(index = 23)] - #[doc = "Too many assets with different reserve locations have been attempted for transfer."] - TooManyReserves, - #[codec(index = 24)] - #[doc = "Local XCM execution incomplete."] - LocalExecutionIncomplete, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Execution of an XCM message was attempted."] - Attempted { outcome: runtime_types::staging_xcm::v4::traits::Outcome }, - #[codec(index = 1)] - #[doc = "A XCM message was sent."] - Sent { - origin: runtime_types::staging_xcm::v4::location::Location, - destination: runtime_types::staging_xcm::v4::location::Location, - message: runtime_types::staging_xcm::v4::Xcm, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - #[doc = "Query response received which does not match a registered query. This may be because a"] - #[doc = "matching query was never registered, it may be because it is a duplicate response, or"] - #[doc = "because the query timed out."] - UnexpectedResponse { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - }, - #[codec(index = 3)] - #[doc = "Query response has been received and is ready for taking with `take_response`. There is"] - #[doc = "no registered notification call."] - ResponseReady { - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v4::Response, - }, - #[codec(index = 4)] - #[doc = "Query response has been received and query is removed. The registered notification has"] - #[doc = "been dispatched and executed successfully."] - Notified { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 5)] - #[doc = "Query response has been received and query is removed. The registered notification"] - #[doc = "could not be dispatched because the dispatch weight is greater than the maximum weight"] - #[doc = "originally budgeted by this runtime for the query result."] - NotifyOverweight { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - actual_weight: runtime_types::sp_weights::weight_v2::Weight, - max_budgeted_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 6)] - #[doc = "Query response has been received and query is removed. There was a general error with"] - #[doc = "dispatching the notification call."] - NotifyDispatchError { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 7)] - #[doc = "Query response has been received and query is removed. The dispatch was unable to be"] - #[doc = "decoded into a `Call`; this might be due to dispatch function having a signature which"] - #[doc = "is not `(origin, QueryId, Response)`."] - NotifyDecodeFailed { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 8)] - #[doc = "Expected query response has been received but the origin location of the response does"] - #[doc = "not match that expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - InvalidResponder { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - expected_location: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - #[codec(index = 9)] - #[doc = "Expected query response has been received but the expected origin location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - InvalidResponderVersion { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - }, - #[codec(index = 10)] - #[doc = "Received query response has been read and removed."] - ResponseTaken { query_id: ::core::primitive::u64 }, - #[codec(index = 11)] - #[doc = "Some assets have been placed in an asset trap."] - AssetsTrapped { - hash: ::subxt::utils::H256, - origin: runtime_types::staging_xcm::v4::location::Location, - assets: runtime_types::xcm::VersionedAssets, - }, - #[codec(index = 12)] - #[doc = "An XCM version change notification message has been attempted to be sent."] - #[doc = ""] - #[doc = "The cost of sending it (borne by the chain) is included."] - VersionChangeNotified { - destination: runtime_types::staging_xcm::v4::location::Location, - result: ::core::primitive::u32, - cost: runtime_types::staging_xcm::v4::asset::Assets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 13)] - #[doc = "The supported version of a location has been changed. This might be through an"] - #[doc = "automatic notification or a manual intervention."] - SupportedVersionChanged { - location: runtime_types::staging_xcm::v4::location::Location, - version: ::core::primitive::u32, - }, - #[codec(index = 14)] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "sending the notification to it."] - NotifyTargetSendFail { - location: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - error: runtime_types::xcm::v3::traits::Error, - }, - #[codec(index = 15)] - #[doc = "A given location which had a version change subscription was dropped owing to an error"] - #[doc = "migrating the location to our new XCM format."] - NotifyTargetMigrationFail { - location: runtime_types::xcm::VersionedLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 16)] - #[doc = "Expected query response has been received but the expected querier location placed in"] - #[doc = "storage by this runtime previously cannot be decoded. The query remains registered."] - #[doc = ""] - #[doc = "This is unexpected (since a location placed in storage in a previously executing"] - #[doc = "runtime should be readable prior to query timeout) and dangerous since the possibly"] - #[doc = "valid response will be dropped. Manual governance intervention is probably going to be"] - #[doc = "needed."] - InvalidQuerierVersion { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - }, - #[codec(index = 17)] - #[doc = "Expected query response has been received but the querier location of the response does"] - #[doc = "not match the expected. The query remains registered for a later, valid, response to"] - #[doc = "be received and acted upon."] - InvalidQuerier { - origin: runtime_types::staging_xcm::v4::location::Location, - query_id: ::core::primitive::u64, - expected_querier: runtime_types::staging_xcm::v4::location::Location, - maybe_actual_querier: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - #[codec(index = 18)] - #[doc = "A remote has requested XCM version change notification from us and we have honored it."] - #[doc = "A version information message is sent to them and its cost is included."] - VersionNotifyStarted { - destination: runtime_types::staging_xcm::v4::location::Location, - cost: runtime_types::staging_xcm::v4::asset::Assets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 19)] - #[doc = "We have requested that a remote chain send us XCM version change notifications."] - VersionNotifyRequested { - destination: runtime_types::staging_xcm::v4::location::Location, - cost: runtime_types::staging_xcm::v4::asset::Assets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 20)] - #[doc = "We have requested that a remote chain stops sending us XCM version change"] - #[doc = "notifications."] - VersionNotifyUnrequested { - destination: runtime_types::staging_xcm::v4::location::Location, - cost: runtime_types::staging_xcm::v4::asset::Assets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 21)] - #[doc = "Fees were paid from a location for an operation (often for using `SendXcm`)."] - FeesPaid { - paying: runtime_types::staging_xcm::v4::location::Location, - fees: runtime_types::staging_xcm::v4::asset::Assets, - }, - #[codec(index = 22)] - #[doc = "Some assets have been claimed from an asset trap"] - AssetsClaimed { - hash: ::subxt::utils::H256, - origin: runtime_types::staging_xcm::v4::location::Location, - assets: runtime_types::xcm::VersionedAssets, - }, - #[codec(index = 23)] - #[doc = "A XCM version migration finished."] - VersionMigrationFinished { version: ::core::primitive::u32 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Origin { - #[codec(index = 0)] - Xcm(runtime_types::staging_xcm::v4::location::Location), - #[codec(index = 1)] - Response(runtime_types::staging_xcm::v4::location::Location), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum QueryStatus<_0> { - #[codec(index = 0)] - Pending { - responder: runtime_types::xcm::VersionedLocation, - maybe_match_querier: - ::core::option::Option, - maybe_notify: - ::core::option::Option<(::core::primitive::u8, ::core::primitive::u8)>, - timeout: _0, - }, - #[codec(index = 1)] - VersionNotifier { - origin: runtime_types::xcm::VersionedLocation, - is_active: ::core::primitive::bool, - }, - #[codec(index = 2)] - Ready { response: runtime_types::xcm::VersionedResponse, at: _0 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RemoteLockedFungibleRecord<_0> { - pub amount: ::core::primitive::u128, - pub owner: runtime_types::xcm::VersionedLocation, - pub locker: runtime_types::xcm::VersionedLocation, - pub consumers: runtime_types::bounded_collections::bounded_vec::BoundedVec<( - _0, - ::core::primitive::u128, - )>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionMigrationStage { - #[codec(index = 0)] - MigrateSupportedVersion, - #[codec(index = 1)] - MigrateVersionNotifiers, - #[codec(index = 2)] - NotifyCurrentTargets( - ::core::option::Option<::std::vec::Vec<::core::primitive::u8>>, - ), - #[codec(index = 3)] - MigrateAndNotifyOldTargets, - } - } - } - pub mod polkadot_core_primitives { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidateHash(pub ::subxt::utils::H256); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InboundDownwardMessage<_0> { - pub sent_at: _0, - pub msg: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InboundHrmpMessage<_0> { - pub sent_at: _0, - pub data: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OutboundHrmpMessage<_0> { - pub recipient: _0, - pub data: ::std::vec::Vec<::core::primitive::u8>, - } - } - pub mod polkadot_parachain_primitives { - use super::runtime_types; - pub mod primitives { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HeadData(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpChannelId { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Id(pub ::core::primitive::u32); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidationCode(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidationCodeHash(pub ::subxt::utils::H256); - } - } - pub mod polkadot_primitives { - use super::runtime_types; - pub mod v6 { - use super::runtime_types; - pub mod assignment_app { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - } - pub mod async_backing { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AsyncBackingParams { - pub max_candidate_depth: ::core::primitive::u32, - pub allowed_ancestry_len: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BackingState < _0 , _1 > { pub constraints : runtime_types :: polkadot_primitives :: v6 :: async_backing :: Constraints < _1 > , pub pending_availability : :: std :: vec :: Vec < runtime_types :: polkadot_primitives :: v6 :: async_backing :: CandidatePendingAvailability < _0 , _1 > > , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidatePendingAvailability<_0, _1> { - pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - pub descriptor: - runtime_types::polkadot_primitives::v6::CandidateDescriptor<_0>, - pub commitments: - runtime_types::polkadot_primitives::v6::CandidateCommitments<_1>, - pub relay_parent_number: _1, - pub max_pov_size: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Constraints < _0 > { pub min_relay_parent_number : _0 , pub max_pov_size : :: core :: primitive :: u32 , pub max_code_size : :: core :: primitive :: u32 , pub ump_remaining : :: core :: primitive :: u32 , pub ump_remaining_bytes : :: core :: primitive :: u32 , pub max_ump_num_per_candidate : :: core :: primitive :: u32 , pub dmp_remaining_messages : :: std :: vec :: Vec < _0 > , pub hrmp_inbound : runtime_types :: polkadot_primitives :: v6 :: async_backing :: InboundHrmpLimitations < _0 > , pub hrmp_channels_out : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: v6 :: async_backing :: OutboundHrmpChannelLimitations ,) > , pub max_hrmp_num_per_candidate : :: core :: primitive :: u32 , pub required_parent : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub upgrade_restriction : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v6 :: UpgradeRestriction > , pub future_validation_code : :: core :: option :: Option < (_0 , runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash ,) > , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InboundHrmpLimitations<_0> { - pub valid_watermarks: ::std::vec::Vec<_0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OutboundHrmpChannelLimitations { - pub bytes_remaining: ::core::primitive::u32, - pub messages_remaining: ::core::primitive::u32, - } - } - pub mod collator_app { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - } - pub mod executor_params { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ExecutorParam { - #[codec(index = 1)] - MaxMemoryPages(::core::primitive::u32), - #[codec(index = 2)] - StackLogicalMax(::core::primitive::u32), - #[codec(index = 3)] - StackNativeMax(::core::primitive::u32), - #[codec(index = 4)] - PrecheckingMaxMemory(::core::primitive::u64), - #[codec(index = 5)] - PvfPrepTimeout( - runtime_types::polkadot_primitives::v6::PvfPrepKind, - ::core::primitive::u64, - ), - #[codec(index = 6)] - PvfExecTimeout( - runtime_types::polkadot_primitives::v6::PvfExecKind, - ::core::primitive::u64, - ), - #[codec(index = 7)] - WasmExtBulkMemory, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ExecutorParams( - pub ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::executor_params::ExecutorParam, - >, - ); - } - pub mod signed { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct UncheckedSigned<_0, _1> { - pub payload: _0, - pub validator_index: runtime_types::polkadot_primitives::v6::ValidatorIndex, - pub signature: - runtime_types::polkadot_primitives::v6::validator_app::Signature, - #[codec(skip)] - pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, - } - } - pub mod slashing { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DisputeProof { - pub time_slot: - runtime_types::polkadot_primitives::v6::slashing::DisputesTimeSlot, - pub kind: - runtime_types::polkadot_primitives::v6::slashing::SlashingOffenceKind, - pub validator_index: runtime_types::polkadot_primitives::v6::ValidatorIndex, - pub validator_id: - runtime_types::polkadot_primitives::v6::validator_app::Public, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DisputesTimeSlot { - pub session_index: ::core::primitive::u32, - pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaqueKeyOwnershipProof(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PendingSlashes { - pub keys: ::subxt::utils::KeyedVec< - runtime_types::polkadot_primitives::v6::ValidatorIndex, - runtime_types::polkadot_primitives::v6::validator_app::Public, - >, - pub kind: - runtime_types::polkadot_primitives::v6::slashing::SlashingOffenceKind, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum SlashingOffenceKind { - #[codec(index = 0)] - ForInvalid, - #[codec(index = 1)] - AgainstValid, - } - } - pub mod validator_app { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AvailabilityBitfield( - pub ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - ); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BackedCandidate<_0> { - pub candidate: - runtime_types::polkadot_primitives::v6::CommittedCandidateReceipt<_0>, - pub validity_votes: ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::ValidityAttestation, - >, - pub validator_indices: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidateCommitments<_0> { - pub upward_messages: - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::std::vec::Vec<::core::primitive::u8>, - >, - pub horizontal_messages: - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::polkadot_core_primitives::OutboundHrmpMessage< - runtime_types::polkadot_parachain_primitives::primitives::Id, - >, - >, - pub new_validation_code: ::core::option::Option< - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - >, - pub head_data: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub processed_downward_messages: ::core::primitive::u32, - pub hrmp_watermark: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidateDescriptor < _0 > { pub para_id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , pub relay_parent : _0 , pub collator : runtime_types :: polkadot_primitives :: v6 :: collator_app :: Public , pub persisted_validation_data_hash : :: subxt :: utils :: H256 , pub pov_hash : :: subxt :: utils :: H256 , pub erasure_root : :: subxt :: utils :: H256 , pub signature : runtime_types :: polkadot_primitives :: v6 :: collator_app :: Signature , pub para_head : :: subxt :: utils :: H256 , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum CandidateEvent<_0> { - #[codec(index = 0)] - CandidateBacked( - runtime_types::polkadot_primitives::v6::CandidateReceipt<_0>, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v6::CoreIndex, - runtime_types::polkadot_primitives::v6::GroupIndex, - ), - #[codec(index = 1)] - CandidateIncluded( - runtime_types::polkadot_primitives::v6::CandidateReceipt<_0>, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v6::CoreIndex, - runtime_types::polkadot_primitives::v6::GroupIndex, - ), - #[codec(index = 2)] - CandidateTimedOut( - runtime_types::polkadot_primitives::v6::CandidateReceipt<_0>, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v6::CoreIndex, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidateReceipt<_0> { - pub descriptor: runtime_types::polkadot_primitives::v6::CandidateDescriptor<_0>, - pub commitments_hash: ::subxt::utils::H256, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CommittedCandidateReceipt<_0> { - pub descriptor: runtime_types::polkadot_primitives::v6::CandidateDescriptor<_0>, - pub commitments: runtime_types::polkadot_primitives::v6::CandidateCommitments< - ::core::primitive::u32, - >, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CoreIndex(pub ::core::primitive::u32); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum CoreState<_0, _1> { - #[codec(index = 0)] - Occupied(runtime_types::polkadot_primitives::v6::OccupiedCore<_0, _1>), - #[codec(index = 1)] - Scheduled(runtime_types::polkadot_primitives::v6::ScheduledCore), - #[codec(index = 2)] - Free, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DisputeState<_0> { - pub validators_for: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - pub validators_against: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - pub start: _0, - pub concluded_at: ::core::option::Option<_0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DisputeStatement { - #[codec(index = 0)] - Valid(runtime_types::polkadot_primitives::v6::ValidDisputeStatementKind), - #[codec(index = 1)] - Invalid(runtime_types::polkadot_primitives::v6::InvalidDisputeStatementKind), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DisputeStatementSet { - pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - pub session: ::core::primitive::u32, - pub statements: ::std::vec::Vec<( - runtime_types::polkadot_primitives::v6::DisputeStatement, - runtime_types::polkadot_primitives::v6::ValidatorIndex, - runtime_types::polkadot_primitives::v6::validator_app::Signature, - )>, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GroupIndex(pub ::core::primitive::u32); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct GroupRotationInfo<_0> { - pub session_start_block: _0, - pub group_rotation_frequency: _0, - pub now: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct IndexedVec<_0, _1>( - pub ::std::vec::Vec<_1>, - #[codec(skip)] pub ::core::marker::PhantomData<_0>, - ); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InherentData<_0> { - pub bitfields: ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::signed::UncheckedSigned< - runtime_types::polkadot_primitives::v6::AvailabilityBitfield, - runtime_types::polkadot_primitives::v6::AvailabilityBitfield, - >, - >, - pub backed_candidates: ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::BackedCandidate< - ::subxt::utils::H256, - >, - >, - pub disputes: ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::DisputeStatementSet, - >, - pub parent_header: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum InvalidDisputeStatementKind { - #[codec(index = 0)] - Explicit, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OccupiedCore<_0, _1> { - pub next_up_on_available: ::core::option::Option< - runtime_types::polkadot_primitives::v6::ScheduledCore, - >, - pub occupied_since: _1, - pub time_out_at: _1, - pub next_up_on_time_out: ::core::option::Option< - runtime_types::polkadot_primitives::v6::ScheduledCore, - >, - pub availability: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - pub group_responsible: runtime_types::polkadot_primitives::v6::GroupIndex, - pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - pub candidate_descriptor: - runtime_types::polkadot_primitives::v6::CandidateDescriptor<_0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum OccupiedCoreAssumption { - #[codec(index = 0)] - Included, - #[codec(index = 1)] - TimedOut, - #[codec(index = 2)] - Free, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PersistedValidationData<_0, _1> { - pub parent_head: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub relay_parent_number: _1, - pub relay_parent_storage_root: _0, - pub max_pov_size: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PvfCheckStatement { pub accept : :: core :: primitive :: bool , pub subject : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub session_index : :: core :: primitive :: u32 , pub validator_index : runtime_types :: polkadot_primitives :: v6 :: ValidatorIndex , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum PvfExecKind { - #[codec(index = 0)] - Backing, - #[codec(index = 1)] - Approval, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum PvfPrepKind { - #[codec(index = 0)] - Precheck, - #[codec(index = 1)] - Prepare, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScheduledCore { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub collator: ::core::option::Option< - runtime_types::polkadot_primitives::v6::collator_app::Public, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ScrapedOnChainVotes<_0> { - pub session: ::core::primitive::u32, - pub backing_validators_per_candidate: ::std::vec::Vec<( - runtime_types::polkadot_primitives::v6::CandidateReceipt<_0>, - ::std::vec::Vec<( - runtime_types::polkadot_primitives::v6::ValidatorIndex, - runtime_types::polkadot_primitives::v6::ValidityAttestation, - )>, - )>, - pub disputes: ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::DisputeStatementSet, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SessionInfo { - pub active_validator_indices: - ::std::vec::Vec, - pub random_seed: [::core::primitive::u8; 32usize], - pub dispute_period: ::core::primitive::u32, - pub validators: runtime_types::polkadot_primitives::v6::IndexedVec< - runtime_types::polkadot_primitives::v6::ValidatorIndex, - runtime_types::polkadot_primitives::v6::validator_app::Public, - >, - pub discovery_keys: - ::std::vec::Vec, - pub assignment_keys: ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::assignment_app::Public, - >, - pub validator_groups: runtime_types::polkadot_primitives::v6::IndexedVec< - runtime_types::polkadot_primitives::v6::GroupIndex, - ::std::vec::Vec, - >, - pub n_cores: ::core::primitive::u32, - pub zeroth_delay_tranche_width: ::core::primitive::u32, - pub relay_vrf_modulo_samples: ::core::primitive::u32, - pub n_delay_tranches: ::core::primitive::u32, - pub no_show_slots: ::core::primitive::u32, - pub needed_approvals: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum UpgradeGoAhead { - #[codec(index = 0)] - Abort, - #[codec(index = 1)] - GoAhead, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum UpgradeRestriction { - #[codec(index = 0)] - Present, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ValidDisputeStatementKind { - #[codec(index = 0)] - Explicit, - #[codec(index = 1)] - BackingSeconded(::subxt::utils::H256), - #[codec(index = 2)] - BackingValid(::subxt::utils::H256), - #[codec(index = 3)] - ApprovalChecking, - #[codec(index = 4)] - ApprovalCheckingMultipleCandidates( - ::std::vec::Vec, - ), - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidatorIndex(pub ::core::primitive::u32); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ValidityAttestation { - #[codec(index = 1)] - Implicit(runtime_types::polkadot_primitives::v6::validator_app::Signature), - #[codec(index = 2)] - Explicit(runtime_types::polkadot_primitives::v6::validator_app::Signature), - } - } - pub mod vstaging { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ApprovalVotingParams { - pub max_approval_coalesce_count: ::core::primitive::u32, - } - } - } - pub mod polkadot_runtime_common { - use super::runtime_types; - pub mod assigned_slots { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - # [codec (index = 0)] # [doc = "See [`Pallet::assign_perm_parachain_slot`]."] assign_perm_parachain_slot { id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 1)] # [doc = "See [`Pallet::assign_temp_parachain_slot`]."] assign_temp_parachain_slot { id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , lease_period_start : runtime_types :: polkadot_runtime_common :: assigned_slots :: SlotLeasePeriodStart , } , # [codec (index = 2)] # [doc = "See [`Pallet::unassign_parachain_slot`]."] unassign_parachain_slot { id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 3)] # [doc = "See [`Pallet::set_max_permanent_slots`]."] set_max_permanent_slots { slots : :: core :: primitive :: u32 , } , # [codec (index = 4)] # [doc = "See [`Pallet::set_max_temporary_slots`]."] set_max_temporary_slots { slots : :: core :: primitive :: u32 , } , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The specified parachain is not registered."] - ParaDoesntExist, - #[codec(index = 1)] - #[doc = "Not a parathread (on-demand parachain)."] - NotParathread, - #[codec(index = 2)] - #[doc = "Cannot upgrade on-demand parachain to lease holding"] - #[doc = "parachain."] - CannotUpgrade, - #[codec(index = 3)] - #[doc = "Cannot downgrade lease holding parachain to"] - #[doc = "on-demand."] - CannotDowngrade, - #[codec(index = 4)] - #[doc = "Permanent or Temporary slot already assigned."] - SlotAlreadyAssigned, - #[codec(index = 5)] - #[doc = "Permanent or Temporary slot has not been assigned."] - SlotNotAssigned, - #[codec(index = 6)] - #[doc = "An ongoing lease already exists."] - OngoingLeaseExists, - #[codec(index = 7)] - MaxPermanentSlotsExceeded, - #[codec(index = 8)] - MaxTemporarySlotsExceeded, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A parachain was assigned a permanent parachain slot"] - PermanentSlotAssigned( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 1)] - #[doc = "A parachain was assigned a temporary parachain slot"] - TemporarySlotAssigned( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 2)] - #[doc = "The maximum number of permanent slots has been changed"] - MaxPermanentSlotsChanged { slots: ::core::primitive::u32 }, - #[codec(index = 3)] - #[doc = "The maximum number of temporary slots has been changed"] - MaxTemporarySlotsChanged { slots: ::core::primitive::u32 }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ParachainTemporarySlot<_0, _1> { - pub manager: _0, - pub period_begin: _1, - pub period_count: _1, - pub last_lease: ::core::option::Option<_1>, - pub lease_count: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum SlotLeasePeriodStart { - #[codec(index = 0)] - Current, - #[codec(index = 1)] - Next, - } - } - pub mod auctions { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::new_auction`]."] - new_auction { - #[codec(compact)] - duration: ::core::primitive::u32, - #[codec(compact)] - lease_period_index: ::core::primitive::u32, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::bid`]."] - bid { - #[codec(compact)] - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - #[codec(compact)] - auction_index: ::core::primitive::u32, - #[codec(compact)] - first_slot: ::core::primitive::u32, - #[codec(compact)] - last_slot: ::core::primitive::u32, - #[codec(compact)] - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::cancel_auction`]."] - cancel_auction, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "This auction is already in progress."] - AuctionInProgress, - #[codec(index = 1)] - #[doc = "The lease period is in the past."] - LeasePeriodInPast, - #[codec(index = 2)] - #[doc = "Para is not registered"] - ParaNotRegistered, - #[codec(index = 3)] - #[doc = "Not a current auction."] - NotCurrentAuction, - #[codec(index = 4)] - #[doc = "Not an auction."] - NotAuction, - #[codec(index = 5)] - #[doc = "Auction has already ended."] - AuctionEnded, - #[codec(index = 6)] - #[doc = "The para is already leased out for part of this range."] - AlreadyLeasedOut, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "An auction started. Provides its index and the block number where it will begin to"] - #[doc = "close and the first lease period of the quadruplet that is auctioned."] - AuctionStarted { - auction_index: ::core::primitive::u32, - lease_period: ::core::primitive::u32, - ending: ::core::primitive::u32, - }, - #[codec(index = 1)] - #[doc = "An auction ended. All funds become unreserved."] - AuctionClosed { auction_index: ::core::primitive::u32 }, - #[codec(index = 2)] - #[doc = "Funds were reserved for a winning bid. First balance is the extra amount reserved."] - #[doc = "Second is the total."] - Reserved { - bidder: ::subxt::utils::AccountId32, - extra_reserved: ::core::primitive::u128, - total_amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "Funds were unreserved since bidder is no longer active. `[bidder, amount]`"] - Unreserved { - bidder: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - #[doc = "Someone attempted to lease the same slot twice for a parachain. The amount is held in"] - #[doc = "reserve but no parachain slot has been leased."] - ReserveConfiscated { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - #[doc = "A new bid has been accepted as the current winner."] - BidAccepted { - bidder: ::subxt::utils::AccountId32, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - first_slot: ::core::primitive::u32, - last_slot: ::core::primitive::u32, - }, - #[codec(index = 6)] - #[doc = "The winning offset was chosen for an auction. This will map into the `Winning` storage"] - #[doc = "map."] - WinningOffset { - auction_index: ::core::primitive::u32, - block_number: ::core::primitive::u32, - }, - } - } - } - pub mod claims { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::claim`]."] - claim { - dest: ::subxt::utils::AccountId32, - ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::mint_claim`]."] - mint_claim { - who: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - value: ::core::primitive::u128, - vesting_schedule: ::core::option::Option<( - ::core::primitive::u128, - ::core::primitive::u128, - ::core::primitive::u32, - )>, - statement: ::core::option::Option< - runtime_types::polkadot_runtime_common::claims::StatementKind, - >, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::claim_attest`]."] - claim_attest { - dest: ::subxt::utils::AccountId32, - ethereum_signature: - runtime_types::polkadot_runtime_common::claims::EcdsaSignature, - statement: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::attest`]."] - attest { statement: ::std::vec::Vec<::core::primitive::u8> }, - #[codec(index = 4)] - #[doc = "See [`Pallet::move_claim`]."] - move_claim { - old: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - new: runtime_types::polkadot_runtime_common::claims::EthereumAddress, - maybe_preclaim: ::core::option::Option<::subxt::utils::AccountId32>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Invalid Ethereum signature."] - InvalidEthereumSignature, - #[codec(index = 1)] - #[doc = "Ethereum address has no claim."] - SignerHasNoClaim, - #[codec(index = 2)] - #[doc = "Account ID sending transaction has no claim."] - SenderHasNoClaim, - #[codec(index = 3)] - #[doc = "There's not enough in the pot to pay out some unvested amount. Generally implies a"] - #[doc = "logic error."] - PotUnderflow, - #[codec(index = 4)] - #[doc = "A needed statement was not included."] - InvalidStatement, - #[codec(index = 5)] - #[doc = "The account already has a vested balance."] - VestedBalanceExists, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Someone claimed some DOTs."] - Claimed { - who: ::subxt::utils::AccountId32, - ethereum_address: - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - amount: ::core::primitive::u128, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EcdsaSignature(pub [::core::primitive::u8; 65usize]); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EthereumAddress(pub [::core::primitive::u8; 20usize]); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum StatementKind { - #[codec(index = 0)] - Regular, - #[codec(index = 1)] - Saft, - } - } - pub mod crowdloan { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::create`]."] - create { - #[codec(compact)] - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - #[codec(compact)] - cap: ::core::primitive::u128, - #[codec(compact)] - first_period: ::core::primitive::u32, - #[codec(compact)] - last_period: ::core::primitive::u32, - #[codec(compact)] - end: ::core::primitive::u32, - verifier: - ::core::option::Option, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::contribute`]."] - contribute { - #[codec(compact)] - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - #[codec(compact)] - value: ::core::primitive::u128, - signature: - ::core::option::Option, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::withdraw`]."] - withdraw { - who: ::subxt::utils::AccountId32, - #[codec(compact)] - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::refund`]."] - refund { - #[codec(compact)] - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::dissolve`]."] - dissolve { - #[codec(compact)] - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::edit`]."] - edit { - #[codec(compact)] - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - #[codec(compact)] - cap: ::core::primitive::u128, - #[codec(compact)] - first_period: ::core::primitive::u32, - #[codec(compact)] - last_period: ::core::primitive::u32, - #[codec(compact)] - end: ::core::primitive::u32, - verifier: - ::core::option::Option, - }, - #[codec(index = 6)] - #[doc = "See [`Pallet::add_memo`]."] - add_memo { - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - memo: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 7)] - #[doc = "See [`Pallet::poke`]."] - poke { index: runtime_types::polkadot_parachain_primitives::primitives::Id }, - #[codec(index = 8)] - #[doc = "See [`Pallet::contribute_all`]."] - contribute_all { - #[codec(compact)] - index: runtime_types::polkadot_parachain_primitives::primitives::Id, - signature: - ::core::option::Option, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The current lease period is more than the first lease period."] - FirstPeriodInPast, - #[codec(index = 1)] - #[doc = "The first lease period needs to at least be less than 3 `max_value`."] - FirstPeriodTooFarInFuture, - #[codec(index = 2)] - #[doc = "Last lease period must be greater than first lease period."] - LastPeriodBeforeFirstPeriod, - #[codec(index = 3)] - #[doc = "The last lease period cannot be more than 3 periods after the first period."] - LastPeriodTooFarInFuture, - #[codec(index = 4)] - #[doc = "The campaign ends before the current block number. The end must be in the future."] - CannotEndInPast, - #[codec(index = 5)] - #[doc = "The end date for this crowdloan is not sensible."] - EndTooFarInFuture, - #[codec(index = 6)] - #[doc = "There was an overflow."] - Overflow, - #[codec(index = 7)] - #[doc = "The contribution was below the minimum, `MinContribution`."] - ContributionTooSmall, - #[codec(index = 8)] - #[doc = "Invalid fund index."] - InvalidParaId, - #[codec(index = 9)] - #[doc = "Contributions exceed maximum amount."] - CapExceeded, - #[codec(index = 10)] - #[doc = "The contribution period has already ended."] - ContributionPeriodOver, - #[codec(index = 11)] - #[doc = "The origin of this call is invalid."] - InvalidOrigin, - #[codec(index = 12)] - #[doc = "This crowdloan does not correspond to a parachain."] - NotParachain, - #[codec(index = 13)] - #[doc = "This parachain lease is still active and retirement cannot yet begin."] - LeaseActive, - #[codec(index = 14)] - #[doc = "This parachain's bid or lease is still active and withdraw cannot yet begin."] - BidOrLeaseActive, - #[codec(index = 15)] - #[doc = "The crowdloan has not yet ended."] - FundNotEnded, - #[codec(index = 16)] - #[doc = "There are no contributions stored in this crowdloan."] - NoContributions, - #[codec(index = 17)] - #[doc = "The crowdloan is not ready to dissolve. Potentially still has a slot or in retirement"] - #[doc = "period."] - NotReadyToDissolve, - #[codec(index = 18)] - #[doc = "Invalid signature."] - InvalidSignature, - #[codec(index = 19)] - #[doc = "The provided memo is too large."] - MemoTooLarge, - #[codec(index = 20)] - #[doc = "The fund is already in `NewRaise`"] - AlreadyInNewRaise, - #[codec(index = 21)] - #[doc = "No contributions allowed during the VRF delay"] - VrfDelayInProgress, - #[codec(index = 22)] - #[doc = "A lease period has not started yet, due to an offset in the starting block."] - NoLeasePeriod, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "Create a new crowdloaning campaign."] - Created { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 1)] - #[doc = "Contributed to a crowd sale."] - Contributed { - who: ::subxt::utils::AccountId32, - fund_index: - runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - #[doc = "Withdrew full balance of a contributor."] - Withdrew { - who: ::subxt::utils::AccountId32, - fund_index: - runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - #[doc = "The loans in a fund have been partially dissolved, i.e. there are some left"] - #[doc = "over child keys that still need to be killed."] - PartiallyRefunded { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 4)] - #[doc = "All loans in a fund have been refunded."] - AllRefunded { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 5)] - #[doc = "Fund is dissolved."] - Dissolved { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 6)] - #[doc = "The result of trying to submit a new bid to the Slots pallet."] - HandleBidResult { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - result: ::core::result::Result< - (), - runtime_types::sp_runtime::DispatchError, - >, - }, - #[codec(index = 7)] - #[doc = "The configuration to a crowdloan has been edited."] - Edited { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 8)] - #[doc = "A memo has been updated."] - MemoUpdated { - who: ::subxt::utils::AccountId32, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - memo: ::std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 9)] - #[doc = "A parachain has been moved to `NewRaise`"] - AddedToNewRaise { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FundInfo<_0, _1, _2, _3> { - pub depositor: _0, - pub verifier: ::core::option::Option, - pub deposit: _1, - pub raised: _1, - pub end: _2, - pub cap: _1, - pub last_contribution: - runtime_types::polkadot_runtime_common::crowdloan::LastContribution<_2>, - pub first_period: _3, - pub last_period: _3, - pub fund_index: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum LastContribution<_0> { - #[codec(index = 0)] - Never, - #[codec(index = 1)] - PreEnding(::core::primitive::u32), - #[codec(index = 2)] - Ending(_0), - } - } - pub mod identity_migrator { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::reap_identity`]."] - reap_identity { who: ::subxt::utils::AccountId32 }, - #[codec(index = 1)] - #[doc = "See [`Pallet::poke_deposit`]."] - poke_deposit { who: ::subxt::utils::AccountId32 }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "The identity and all sub accounts were reaped for `who`."] - IdentityReaped { who: ::subxt::utils::AccountId32 }, - #[codec(index = 1)] - #[doc = "The deposits held for `who` were updated. `identity` is the new deposit held for"] - #[doc = "identity info, and `subs` is the new deposit held for the sub-accounts."] - DepositUpdated { - who: ::subxt::utils::AccountId32, - identity: ::core::primitive::u128, - subs: ::core::primitive::u128, - }, - } - } - } - pub mod impls { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedLocatableAsset { - #[codec(index = 3)] - V3 { - location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - asset_id: runtime_types::xcm::v3::multiasset::AssetId, - }, - #[codec(index = 4)] - V4 { - location: runtime_types::staging_xcm::v4::location::Location, - asset_id: runtime_types::staging_xcm::v4::asset::AssetId, - }, - } - } - pub mod paras_registrar { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - # [codec (index = 0)] # [doc = "See [`Pallet::register`]."] register { id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , genesis_head : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , validation_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode , } , # [codec (index = 1)] # [doc = "See [`Pallet::force_register`]."] force_register { who : :: subxt :: utils :: AccountId32 , deposit : :: core :: primitive :: u128 , id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , genesis_head : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , validation_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode , } , # [codec (index = 2)] # [doc = "See [`Pallet::deregister`]."] deregister { id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 3)] # [doc = "See [`Pallet::swap`]."] swap { id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , other : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 4)] # [doc = "See [`Pallet::remove_lock`]."] remove_lock { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 5)] # [doc = "See [`Pallet::reserve`]."] reserve , # [codec (index = 6)] # [doc = "See [`Pallet::add_lock`]."] add_lock { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 7)] # [doc = "See [`Pallet::schedule_code_upgrade`]."] schedule_code_upgrade { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , new_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode , } , # [codec (index = 8)] # [doc = "See [`Pallet::set_current_head`]."] set_current_head { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , new_head : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , } , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The ID is not registered."] - NotRegistered, - #[codec(index = 1)] - #[doc = "The ID is already registered."] - AlreadyRegistered, - #[codec(index = 2)] - #[doc = "The caller is not the owner of this Id."] - NotOwner, - #[codec(index = 3)] - #[doc = "Invalid para code size."] - CodeTooLarge, - #[codec(index = 4)] - #[doc = "Invalid para head data size."] - HeadDataTooLarge, - #[codec(index = 5)] - #[doc = "Para is not a Parachain."] - NotParachain, - #[codec(index = 6)] - #[doc = "Para is not a Parathread (on-demand parachain)."] - NotParathread, - #[codec(index = 7)] - #[doc = "Cannot deregister para"] - CannotDeregister, - #[codec(index = 8)] - #[doc = "Cannot schedule downgrade of lease holding parachain to on-demand parachain"] - CannotDowngrade, - #[codec(index = 9)] - #[doc = "Cannot schedule upgrade of on-demand parachain to lease holding parachain"] - CannotUpgrade, - #[codec(index = 10)] - #[doc = "Para is locked from manipulation by the manager. Must use parachain or relay chain"] - #[doc = "governance."] - ParaLocked, - #[codec(index = 11)] - #[doc = "The ID given for registration has not been reserved."] - NotReserved, - #[codec(index = 12)] - #[doc = "Registering parachain with empty code is not allowed."] - EmptyCode, - #[codec(index = 13)] - #[doc = "Cannot perform a parachain slot / lifecycle swap. Check that the state of both paras"] - #[doc = "are correct for the swap to work."] - CannotSwap, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - Registered { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - manager: ::subxt::utils::AccountId32, - }, - #[codec(index = 1)] - Deregistered { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 2)] - Reserved { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - who: ::subxt::utils::AccountId32, - }, - #[codec(index = 3)] - Swapped { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - other_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ParaInfo<_0, _1> { - pub manager: _0, - pub deposit: _1, - pub locked: ::core::option::Option<::core::primitive::bool>, - } - } - pub mod paras_sudo_wrapper { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::sudo_schedule_para_initialize`]."] - sudo_schedule_para_initialize { - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - genesis: - runtime_types::polkadot_runtime_parachains::paras::ParaGenesisArgs, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::sudo_schedule_para_cleanup`]."] - sudo_schedule_para_cleanup { - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::sudo_schedule_parathread_upgrade`]."] - sudo_schedule_parathread_upgrade { - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 3)] - #[doc = "See [`Pallet::sudo_schedule_parachain_downgrade`]."] - sudo_schedule_parachain_downgrade { - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 4)] - #[doc = "See [`Pallet::sudo_queue_downward_xcm`]."] - sudo_queue_downward_xcm { - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - xcm: ::std::boxed::Box, - }, - #[codec(index = 5)] - #[doc = "See [`Pallet::sudo_establish_hrmp_channel`]."] - sudo_establish_hrmp_channel { - sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - max_capacity: ::core::primitive::u32, - max_message_size: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The specified parachain is not registered."] - ParaDoesntExist, - #[codec(index = 1)] - #[doc = "The specified parachain is already registered."] - ParaAlreadyExists, - #[codec(index = 2)] - #[doc = "A DMP message couldn't be sent because it exceeds the maximum size allowed for a"] - #[doc = "downward message."] - ExceedsMaxMessageSize, - #[codec(index = 3)] - #[doc = "Could not schedule para cleanup."] - CouldntCleanup, - #[codec(index = 4)] - #[doc = "Not a parathread (on-demand parachain)."] - NotParathread, - #[codec(index = 5)] - #[doc = "Not a lease holding parachain."] - NotParachain, - #[codec(index = 6)] - #[doc = "Cannot upgrade on-demand parachain to lease holding parachain."] - CannotUpgrade, - #[codec(index = 7)] - #[doc = "Cannot downgrade lease holding parachain to on-demand."] - CannotDowngrade, - #[codec(index = 8)] - #[doc = "There are more cores than supported by the runtime."] - TooManyCores, - } - } - } - pub mod slots { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::force_lease`]."] - force_lease { - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::subxt::utils::AccountId32, - amount: ::core::primitive::u128, - period_begin: ::core::primitive::u32, - period_count: ::core::primitive::u32, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::clear_all_leases`]."] - clear_all_leases { - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 2)] - #[doc = "See [`Pallet::trigger_onboard`]."] - trigger_onboard { - para: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The parachain ID is not onboarding."] - ParaNotOnboarding, - #[codec(index = 1)] - #[doc = "There was an error with the lease."] - LeaseError, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A new `[lease_period]` is beginning."] - NewLeasePeriod { lease_period: ::core::primitive::u32 }, - #[codec(index = 1)] - #[doc = "A para has won the right to a continuous set of lease periods as a parachain."] - #[doc = "First balance is any extra amount reserved on top of the para's existing deposit."] - #[doc = "Second balance is the total amount reserved."] - Leased { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::subxt::utils::AccountId32, - period_begin: ::core::primitive::u32, - period_count: ::core::primitive::u32, - extra_reserved: ::core::primitive::u128, - total_amount: ::core::primitive::u128, - }, - } - } - } - } - pub mod polkadot_runtime_parachains { - use super::runtime_types; - pub mod assigner_coretime { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - AssignmentsEmpty, - #[codec(index = 1)] - #[doc = "Assignments together exceeded 57600."] - OverScheduled, - #[codec(index = 2)] - #[doc = "Assignments together less than 57600"] - UnderScheduled, - #[codec(index = 3)] - #[doc = "assign_core is only allowed to append new assignments at the end of already existing"] - #[doc = "ones."] - DisallowedInsert, - #[codec(index = 4)] - #[doc = "Tried to insert a schedule for the same core and block number as an existing schedule"] - DuplicateInsert, - #[codec(index = 5)] - #[doc = "Tried to add an unsorted set of assignments"] - AssignmentsNotSorted, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssignmentState { - pub ratio: - runtime_types::polkadot_runtime_parachains::assigner_coretime::PartsOf57600, - pub remaining: - runtime_types::polkadot_runtime_parachains::assigner_coretime::PartsOf57600, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CoreDescriptor < _0 > { pub queue : :: core :: option :: Option < runtime_types :: polkadot_runtime_parachains :: assigner_coretime :: QueueDescriptor < _0 > > , pub current_work : :: core :: option :: Option < runtime_types :: polkadot_runtime_parachains :: assigner_coretime :: WorkState < _0 > > , } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PartsOf57600(pub ::core::primitive::u16); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueueDescriptor<_0> { - pub first: _0, - pub last: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Schedule<_0> { - pub assignments: ::std::vec::Vec<( - runtime_types::pallet_broker::coretime_interface::CoreAssignment, - runtime_types::polkadot_runtime_parachains::assigner_coretime::PartsOf57600, - )>, - pub end_hint: ::core::option::Option<_0>, - pub next_schedule: ::core::option::Option<_0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct WorkState < _0 > { pub assignments : :: std :: vec :: Vec < (runtime_types :: pallet_broker :: coretime_interface :: CoreAssignment , runtime_types :: polkadot_runtime_parachains :: assigner_coretime :: AssignmentState ,) > , pub end_hint : :: core :: option :: Option < _0 > , pub pos : :: core :: primitive :: u16 , pub step : runtime_types :: polkadot_runtime_parachains :: assigner_coretime :: PartsOf57600 , } - } - pub mod assigner_on_demand { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::place_order_allow_death`]."] - place_order_allow_death { - max_amount: ::core::primitive::u128, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::place_order_keep_alive`]."] - place_order_keep_alive { - max_amount: ::core::primitive::u128, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The `ParaId` supplied to the `place_order` call is not a valid `ParaThread`, making the"] - #[doc = "call is invalid."] - InvalidParaId, - #[codec(index = 1)] - #[doc = "The order queue is full, `place_order` will not continue."] - QueueFull, - #[codec(index = 2)] - #[doc = "The current spot price is higher than the max amount specified in the `place_order`"] - #[doc = "call, making it invalid."] - SpotPriceHigherThanMaxAmount, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "An order was placed at some spot price amount."] - OnDemandOrderPlaced { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - spot_price: ::core::primitive::u128, - }, - #[codec(index = 1)] - #[doc = "The value of the spot traffic multiplier changed."] - SpotTrafficSet { - traffic: runtime_types::sp_arithmetic::fixed_point::FixedU128, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CoreAffinityCount { - pub core_idx: runtime_types::polkadot_primitives::v6::CoreIndex, - pub count: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EnqueuedOrder { - pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - } - pub mod configuration { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - # [codec (index = 0)] # [doc = "See [`Pallet::set_validation_upgrade_cooldown`]."] set_validation_upgrade_cooldown { new : :: core :: primitive :: u32 , } , # [codec (index = 1)] # [doc = "See [`Pallet::set_validation_upgrade_delay`]."] set_validation_upgrade_delay { new : :: core :: primitive :: u32 , } , # [codec (index = 2)] # [doc = "See [`Pallet::set_code_retention_period`]."] set_code_retention_period { new : :: core :: primitive :: u32 , } , # [codec (index = 3)] # [doc = "See [`Pallet::set_max_code_size`]."] set_max_code_size { new : :: core :: primitive :: u32 , } , # [codec (index = 4)] # [doc = "See [`Pallet::set_max_pov_size`]."] set_max_pov_size { new : :: core :: primitive :: u32 , } , # [codec (index = 5)] # [doc = "See [`Pallet::set_max_head_data_size`]."] set_max_head_data_size { new : :: core :: primitive :: u32 , } , # [codec (index = 6)] # [doc = "See [`Pallet::set_coretime_cores`]."] set_coretime_cores { new : :: core :: primitive :: u32 , } , # [codec (index = 7)] # [doc = "See [`Pallet::set_on_demand_retries`]."] set_on_demand_retries { new : :: core :: primitive :: u32 , } , # [codec (index = 8)] # [doc = "See [`Pallet::set_group_rotation_frequency`]."] set_group_rotation_frequency { new : :: core :: primitive :: u32 , } , # [codec (index = 9)] # [doc = "See [`Pallet::set_paras_availability_period`]."] set_paras_availability_period { new : :: core :: primitive :: u32 , } , # [codec (index = 11)] # [doc = "See [`Pallet::set_scheduling_lookahead`]."] set_scheduling_lookahead { new : :: core :: primitive :: u32 , } , # [codec (index = 12)] # [doc = "See [`Pallet::set_max_validators_per_core`]."] set_max_validators_per_core { new : :: core :: option :: Option < :: core :: primitive :: u32 > , } , # [codec (index = 13)] # [doc = "See [`Pallet::set_max_validators`]."] set_max_validators { new : :: core :: option :: Option < :: core :: primitive :: u32 > , } , # [codec (index = 14)] # [doc = "See [`Pallet::set_dispute_period`]."] set_dispute_period { new : :: core :: primitive :: u32 , } , # [codec (index = 15)] # [doc = "See [`Pallet::set_dispute_post_conclusion_acceptance_period`]."] set_dispute_post_conclusion_acceptance_period { new : :: core :: primitive :: u32 , } , # [codec (index = 18)] # [doc = "See [`Pallet::set_no_show_slots`]."] set_no_show_slots { new : :: core :: primitive :: u32 , } , # [codec (index = 19)] # [doc = "See [`Pallet::set_n_delay_tranches`]."] set_n_delay_tranches { new : :: core :: primitive :: u32 , } , # [codec (index = 20)] # [doc = "See [`Pallet::set_zeroth_delay_tranche_width`]."] set_zeroth_delay_tranche_width { new : :: core :: primitive :: u32 , } , # [codec (index = 21)] # [doc = "See [`Pallet::set_needed_approvals`]."] set_needed_approvals { new : :: core :: primitive :: u32 , } , # [codec (index = 22)] # [doc = "See [`Pallet::set_relay_vrf_modulo_samples`]."] set_relay_vrf_modulo_samples { new : :: core :: primitive :: u32 , } , # [codec (index = 23)] # [doc = "See [`Pallet::set_max_upward_queue_count`]."] set_max_upward_queue_count { new : :: core :: primitive :: u32 , } , # [codec (index = 24)] # [doc = "See [`Pallet::set_max_upward_queue_size`]."] set_max_upward_queue_size { new : :: core :: primitive :: u32 , } , # [codec (index = 25)] # [doc = "See [`Pallet::set_max_downward_message_size`]."] set_max_downward_message_size { new : :: core :: primitive :: u32 , } , # [codec (index = 27)] # [doc = "See [`Pallet::set_max_upward_message_size`]."] set_max_upward_message_size { new : :: core :: primitive :: u32 , } , # [codec (index = 28)] # [doc = "See [`Pallet::set_max_upward_message_num_per_candidate`]."] set_max_upward_message_num_per_candidate { new : :: core :: primitive :: u32 , } , # [codec (index = 29)] # [doc = "See [`Pallet::set_hrmp_open_request_ttl`]."] set_hrmp_open_request_ttl { new : :: core :: primitive :: u32 , } , # [codec (index = 30)] # [doc = "See [`Pallet::set_hrmp_sender_deposit`]."] set_hrmp_sender_deposit { new : :: core :: primitive :: u128 , } , # [codec (index = 31)] # [doc = "See [`Pallet::set_hrmp_recipient_deposit`]."] set_hrmp_recipient_deposit { new : :: core :: primitive :: u128 , } , # [codec (index = 32)] # [doc = "See [`Pallet::set_hrmp_channel_max_capacity`]."] set_hrmp_channel_max_capacity { new : :: core :: primitive :: u32 , } , # [codec (index = 33)] # [doc = "See [`Pallet::set_hrmp_channel_max_total_size`]."] set_hrmp_channel_max_total_size { new : :: core :: primitive :: u32 , } , # [codec (index = 34)] # [doc = "See [`Pallet::set_hrmp_max_parachain_inbound_channels`]."] set_hrmp_max_parachain_inbound_channels { new : :: core :: primitive :: u32 , } , # [codec (index = 36)] # [doc = "See [`Pallet::set_hrmp_channel_max_message_size`]."] set_hrmp_channel_max_message_size { new : :: core :: primitive :: u32 , } , # [codec (index = 37)] # [doc = "See [`Pallet::set_hrmp_max_parachain_outbound_channels`]."] set_hrmp_max_parachain_outbound_channels { new : :: core :: primitive :: u32 , } , # [codec (index = 39)] # [doc = "See [`Pallet::set_hrmp_max_message_num_per_candidate`]."] set_hrmp_max_message_num_per_candidate { new : :: core :: primitive :: u32 , } , # [codec (index = 42)] # [doc = "See [`Pallet::set_pvf_voting_ttl`]."] set_pvf_voting_ttl { new : :: core :: primitive :: u32 , } , # [codec (index = 43)] # [doc = "See [`Pallet::set_minimum_validation_upgrade_delay`]."] set_minimum_validation_upgrade_delay { new : :: core :: primitive :: u32 , } , # [codec (index = 44)] # [doc = "See [`Pallet::set_bypass_consistency_check`]."] set_bypass_consistency_check { new : :: core :: primitive :: bool , } , # [codec (index = 45)] # [doc = "See [`Pallet::set_async_backing_params`]."] set_async_backing_params { new : runtime_types :: polkadot_primitives :: v6 :: async_backing :: AsyncBackingParams , } , # [codec (index = 46)] # [doc = "See [`Pallet::set_executor_params`]."] set_executor_params { new : runtime_types :: polkadot_primitives :: v6 :: executor_params :: ExecutorParams , } , # [codec (index = 47)] # [doc = "See [`Pallet::set_on_demand_base_fee`]."] set_on_demand_base_fee { new : :: core :: primitive :: u128 , } , # [codec (index = 48)] # [doc = "See [`Pallet::set_on_demand_fee_variability`]."] set_on_demand_fee_variability { new : runtime_types :: sp_arithmetic :: per_things :: Perbill , } , # [codec (index = 49)] # [doc = "See [`Pallet::set_on_demand_queue_max_size`]."] set_on_demand_queue_max_size { new : :: core :: primitive :: u32 , } , # [codec (index = 50)] # [doc = "See [`Pallet::set_on_demand_target_queue_utilization`]."] set_on_demand_target_queue_utilization { new : runtime_types :: sp_arithmetic :: per_things :: Perbill , } , # [codec (index = 51)] # [doc = "See [`Pallet::set_on_demand_ttl`]."] set_on_demand_ttl { new : :: core :: primitive :: u32 , } , # [codec (index = 52)] # [doc = "See [`Pallet::set_minimum_backing_votes`]."] set_minimum_backing_votes { new : :: core :: primitive :: u32 , } , # [codec (index = 53)] # [doc = "See [`Pallet::set_node_feature`]."] set_node_feature { index : :: core :: primitive :: u8 , value : :: core :: primitive :: bool , } , # [codec (index = 54)] # [doc = "See [`Pallet::set_approval_voting_params`]."] set_approval_voting_params { new : runtime_types :: polkadot_primitives :: vstaging :: ApprovalVotingParams , } , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The new value for a configuration parameter is invalid."] - InvalidNewValue, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HostConfiguration<_0> { - pub max_code_size: ::core::primitive::u32, - pub max_head_data_size: ::core::primitive::u32, - pub max_upward_queue_count: ::core::primitive::u32, - pub max_upward_queue_size: ::core::primitive::u32, - pub max_upward_message_size: ::core::primitive::u32, - pub max_upward_message_num_per_candidate: ::core::primitive::u32, - pub hrmp_max_message_num_per_candidate: ::core::primitive::u32, - pub validation_upgrade_cooldown: _0, - pub validation_upgrade_delay: _0, - pub async_backing_params: - runtime_types::polkadot_primitives::v6::async_backing::AsyncBackingParams, - pub max_pov_size: ::core::primitive::u32, - pub max_downward_message_size: ::core::primitive::u32, - pub hrmp_max_parachain_outbound_channels: ::core::primitive::u32, - pub hrmp_sender_deposit: ::core::primitive::u128, - pub hrmp_recipient_deposit: ::core::primitive::u128, - pub hrmp_channel_max_capacity: ::core::primitive::u32, - pub hrmp_channel_max_total_size: ::core::primitive::u32, - pub hrmp_max_parachain_inbound_channels: ::core::primitive::u32, - pub hrmp_channel_max_message_size: ::core::primitive::u32, - pub executor_params: - runtime_types::polkadot_primitives::v6::executor_params::ExecutorParams, - pub code_retention_period: _0, - pub coretime_cores: ::core::primitive::u32, - pub on_demand_retries: ::core::primitive::u32, - pub on_demand_queue_max_size: ::core::primitive::u32, - pub on_demand_target_queue_utilization: - runtime_types::sp_arithmetic::per_things::Perbill, - pub on_demand_fee_variability: - runtime_types::sp_arithmetic::per_things::Perbill, - pub on_demand_base_fee: ::core::primitive::u128, - pub on_demand_ttl: _0, - pub group_rotation_frequency: _0, - pub paras_availability_period: _0, - pub scheduling_lookahead: ::core::primitive::u32, - pub max_validators_per_core: ::core::option::Option<_0>, - pub max_validators: ::core::option::Option<_0>, - pub dispute_period: ::core::primitive::u32, - pub dispute_post_conclusion_acceptance_period: _0, - pub no_show_slots: ::core::primitive::u32, - pub n_delay_tranches: ::core::primitive::u32, - pub zeroth_delay_tranche_width: ::core::primitive::u32, - pub needed_approvals: ::core::primitive::u32, - pub relay_vrf_modulo_samples: ::core::primitive::u32, - pub pvf_voting_ttl: ::core::primitive::u32, - pub minimum_validation_upgrade_delay: _0, - pub minimum_backing_votes: ::core::primitive::u32, - pub node_features: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - pub approval_voting_params: - runtime_types::polkadot_primitives::vstaging::ApprovalVotingParams, - } - } - pub mod coretime { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - # [codec (index = 1)] # [doc = "See [`Pallet::request_core_count`]."] request_core_count { count : :: core :: primitive :: u16 , } , # [codec (index = 4)] # [doc = "See [`Pallet::assign_core`]."] assign_core { core : :: core :: primitive :: u16 , begin : :: core :: primitive :: u32 , assignment : :: std :: vec :: Vec < (runtime_types :: pallet_broker :: coretime_interface :: CoreAssignment , runtime_types :: polkadot_runtime_parachains :: assigner_coretime :: PartsOf57600 ,) > , end_hint : :: core :: option :: Option < :: core :: primitive :: u32 > , } , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The paraid making the call is not the coretime brokerage system parachain."] - NotBroker, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "The broker chain has asked for revenue information for a specific block."] - RevenueInfoRequested { when: ::core::primitive::u32 }, - #[codec(index = 1)] - #[doc = "A core has received a new assignment from the broker chain."] - CoreAssigned { core: runtime_types::polkadot_primitives::v6::CoreIndex }, - } - } - } - pub mod disputes { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::force_unfreeze`]."] - force_unfreeze, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Duplicate dispute statement sets provided."] - DuplicateDisputeStatementSets, - #[codec(index = 1)] - #[doc = "Ancient dispute statement provided."] - AncientDisputeStatement, - #[codec(index = 2)] - #[doc = "Validator index on statement is out of bounds for session."] - ValidatorIndexOutOfBounds, - #[codec(index = 3)] - #[doc = "Invalid signature on statement."] - InvalidSignature, - #[codec(index = 4)] - #[doc = "Validator vote submitted more than once to dispute."] - DuplicateStatement, - #[codec(index = 5)] - #[doc = "A dispute where there are only votes on one side."] - SingleSidedDispute, - #[codec(index = 6)] - #[doc = "A dispute vote from a malicious backer."] - MaliciousBacker, - #[codec(index = 7)] - #[doc = "No backing votes were provides along dispute statements."] - MissingBackingVotes, - #[codec(index = 8)] - #[doc = "Unconfirmed dispute statement sets provided."] - UnconfirmedDispute, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A dispute has been initiated. \\[candidate hash, dispute location\\]"] - DisputeInitiated( - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, - ), - #[codec(index = 1)] - #[doc = "A dispute has concluded for or against a candidate."] - #[doc = "`\\[para id, candidate hash, dispute result\\]`"] - DisputeConcluded( - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, - ), - #[codec(index = 2)] - #[doc = "A dispute has concluded with supermajority against a candidate."] - #[doc = "Block authors should no longer build on top of this head and should"] - #[doc = "instead revert the block at the given height. This should be the"] - #[doc = "number of the child of the last known valid block in the chain."] - Revert(::core::primitive::u32), - } - } - pub mod slashing { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::report_dispute_lost_unsigned`]."] - report_dispute_lost_unsigned { - dispute_proof: ::std::boxed::Box< - runtime_types::polkadot_primitives::v6::slashing::DisputeProof, - >, - key_owner_proof: runtime_types::sp_session::MembershipProof, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The key ownership proof is invalid."] - InvalidKeyOwnershipProof, - #[codec(index = 1)] - #[doc = "The session index is too old or invalid."] - InvalidSessionIndex, - #[codec(index = 2)] - #[doc = "The candidate hash is invalid."] - InvalidCandidateHash, - #[codec(index = 3)] - #[doc = "There is no pending slash for the given validator index and time"] - #[doc = "slot."] - InvalidValidatorIndex, - #[codec(index = 4)] - #[doc = "The validator index does not match the validator id."] - ValidatorIndexIdMismatch, - #[codec(index = 5)] - #[doc = "The given slashing report is valid but already previously reported."] - DuplicateSlashingReport, - } - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DisputeLocation { - #[codec(index = 0)] - Local, - #[codec(index = 1)] - Remote, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DisputeResult { - #[codec(index = 0)] - Valid, - #[codec(index = 1)] - Invalid, - } - } - pub mod hrmp { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - # [codec (index = 0)] # [doc = "See [`Pallet::hrmp_init_open_channel`]."] hrmp_init_open_channel { recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , proposed_max_capacity : :: core :: primitive :: u32 , proposed_max_message_size : :: core :: primitive :: u32 , } , # [codec (index = 1)] # [doc = "See [`Pallet::hrmp_accept_open_channel`]."] hrmp_accept_open_channel { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 2)] # [doc = "See [`Pallet::hrmp_close_channel`]."] hrmp_close_channel { channel_id : runtime_types :: polkadot_parachain_primitives :: primitives :: HrmpChannelId , } , # [codec (index = 3)] # [doc = "See [`Pallet::force_clean_hrmp`]."] force_clean_hrmp { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , num_inbound : :: core :: primitive :: u32 , num_outbound : :: core :: primitive :: u32 , } , # [codec (index = 4)] # [doc = "See [`Pallet::force_process_hrmp_open`]."] force_process_hrmp_open { channels : :: core :: primitive :: u32 , } , # [codec (index = 5)] # [doc = "See [`Pallet::force_process_hrmp_close`]."] force_process_hrmp_close { channels : :: core :: primitive :: u32 , } , # [codec (index = 6)] # [doc = "See [`Pallet::hrmp_cancel_open_request`]."] hrmp_cancel_open_request { channel_id : runtime_types :: polkadot_parachain_primitives :: primitives :: HrmpChannelId , open_requests : :: core :: primitive :: u32 , } , # [codec (index = 7)] # [doc = "See [`Pallet::force_open_hrmp_channel`]."] force_open_hrmp_channel { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , max_capacity : :: core :: primitive :: u32 , max_message_size : :: core :: primitive :: u32 , } , # [codec (index = 8)] # [doc = "See [`Pallet::establish_system_channel`]."] establish_system_channel { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 9)] # [doc = "See [`Pallet::poke_channel_deposits`]."] poke_channel_deposits { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "The sender tried to open a channel to themselves."] - OpenHrmpChannelToSelf, - #[codec(index = 1)] - #[doc = "The recipient is not a valid para."] - OpenHrmpChannelInvalidRecipient, - #[codec(index = 2)] - #[doc = "The requested capacity is zero."] - OpenHrmpChannelZeroCapacity, - #[codec(index = 3)] - #[doc = "The requested capacity exceeds the global limit."] - OpenHrmpChannelCapacityExceedsLimit, - #[codec(index = 4)] - #[doc = "The requested maximum message size is 0."] - OpenHrmpChannelZeroMessageSize, - #[codec(index = 5)] - #[doc = "The open request requested the message size that exceeds the global limit."] - OpenHrmpChannelMessageSizeExceedsLimit, - #[codec(index = 6)] - #[doc = "The channel already exists"] - OpenHrmpChannelAlreadyExists, - #[codec(index = 7)] - #[doc = "There is already a request to open the same channel."] - OpenHrmpChannelAlreadyRequested, - #[codec(index = 8)] - #[doc = "The sender already has the maximum number of allowed outbound channels."] - OpenHrmpChannelLimitExceeded, - #[codec(index = 9)] - #[doc = "The channel from the sender to the origin doesn't exist."] - AcceptHrmpChannelDoesntExist, - #[codec(index = 10)] - #[doc = "The channel is already confirmed."] - AcceptHrmpChannelAlreadyConfirmed, - #[codec(index = 11)] - #[doc = "The recipient already has the maximum number of allowed inbound channels."] - AcceptHrmpChannelLimitExceeded, - #[codec(index = 12)] - #[doc = "The origin tries to close a channel where it is neither the sender nor the recipient."] - CloseHrmpChannelUnauthorized, - #[codec(index = 13)] - #[doc = "The channel to be closed doesn't exist."] - CloseHrmpChannelDoesntExist, - #[codec(index = 14)] - #[doc = "The channel close request is already requested."] - CloseHrmpChannelAlreadyUnderway, - #[codec(index = 15)] - #[doc = "Canceling is requested by neither the sender nor recipient of the open channel request."] - CancelHrmpOpenChannelUnauthorized, - #[codec(index = 16)] - #[doc = "The open request doesn't exist."] - OpenHrmpChannelDoesntExist, - #[codec(index = 17)] - #[doc = "Cannot cancel an HRMP open channel request because it is already confirmed."] - OpenHrmpChannelAlreadyConfirmed, - #[codec(index = 18)] - #[doc = "The provided witness data is wrong."] - WrongWitness, - #[codec(index = 19)] - #[doc = "The channel between these two chains cannot be authorized."] - ChannelCreationNotAuthorized, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - # [codec (index = 0)] # [doc = "Open HRMP channel requested."] OpenChannelRequested { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , proposed_max_capacity : :: core :: primitive :: u32 , proposed_max_message_size : :: core :: primitive :: u32 , } , # [codec (index = 1)] # [doc = "An HRMP channel request sent by the receiver was canceled by either party."] OpenChannelCanceled { by_parachain : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , channel_id : runtime_types :: polkadot_parachain_primitives :: primitives :: HrmpChannelId , } , # [codec (index = 2)] # [doc = "Open HRMP channel accepted."] OpenChannelAccepted { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 3)] # [doc = "HRMP channel closed."] ChannelClosed { by_parachain : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , channel_id : runtime_types :: polkadot_parachain_primitives :: primitives :: HrmpChannelId , } , # [codec (index = 4)] # [doc = "An HRMP channel was opened via Root origin."] HrmpChannelForceOpened { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , proposed_max_capacity : :: core :: primitive :: u32 , proposed_max_message_size : :: core :: primitive :: u32 , } , # [codec (index = 5)] # [doc = "An HRMP channel was opened between two system chains."] HrmpSystemChannelOpened { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , proposed_max_capacity : :: core :: primitive :: u32 , proposed_max_message_size : :: core :: primitive :: u32 , } , # [codec (index = 6)] # [doc = "An HRMP channel's deposits were updated."] OpenChannelDepositsUpdated { sender : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , recipient : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpChannel { - pub max_capacity: ::core::primitive::u32, - pub max_total_size: ::core::primitive::u32, - pub max_message_size: ::core::primitive::u32, - pub msg_count: ::core::primitive::u32, - pub total_size: ::core::primitive::u32, - pub mqc_head: ::core::option::Option<::subxt::utils::H256>, - pub sender_deposit: ::core::primitive::u128, - pub recipient_deposit: ::core::primitive::u128, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct HrmpOpenChannelRequest { - pub confirmed: ::core::primitive::bool, - pub _age: ::core::primitive::u32, - pub sender_deposit: ::core::primitive::u128, - pub max_message_size: ::core::primitive::u32, - pub max_capacity: ::core::primitive::u32, - pub max_total_size: ::core::primitive::u32, - } - } - pub mod inclusion { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call {} - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Validator indices are out of order or contains duplicates."] - UnsortedOrDuplicateValidatorIndices, - #[codec(index = 1)] - #[doc = "Dispute statement sets are out of order or contain duplicates."] - UnsortedOrDuplicateDisputeStatementSet, - #[codec(index = 2)] - #[doc = "Backed candidates are out of order (core index) or contain duplicates."] - UnsortedOrDuplicateBackedCandidates, - #[codec(index = 3)] - #[doc = "A different relay parent was provided compared to the on-chain stored one."] - UnexpectedRelayParent, - #[codec(index = 4)] - #[doc = "Availability bitfield has unexpected size."] - WrongBitfieldSize, - #[codec(index = 5)] - #[doc = "Bitfield consists of zeros only."] - BitfieldAllZeros, - #[codec(index = 6)] - #[doc = "Multiple bitfields submitted by same validator or validators out of order by index."] - BitfieldDuplicateOrUnordered, - #[codec(index = 7)] - #[doc = "Validator index out of bounds."] - ValidatorIndexOutOfBounds, - #[codec(index = 8)] - #[doc = "Invalid signature"] - InvalidBitfieldSignature, - #[codec(index = 9)] - #[doc = "Candidate submitted but para not scheduled."] - UnscheduledCandidate, - #[codec(index = 10)] - #[doc = "Candidate scheduled despite pending candidate already existing for the para."] - CandidateScheduledBeforeParaFree, - #[codec(index = 11)] - #[doc = "Scheduled cores out of order."] - ScheduledOutOfOrder, - #[codec(index = 12)] - #[doc = "Head data exceeds the configured maximum."] - HeadDataTooLarge, - #[codec(index = 13)] - #[doc = "Code upgrade prematurely."] - PrematureCodeUpgrade, - #[codec(index = 14)] - #[doc = "Output code is too large"] - NewCodeTooLarge, - #[codec(index = 15)] - #[doc = "The candidate's relay-parent was not allowed. Either it was"] - #[doc = "not recent enough or it didn't advance based on the last parachain block."] - DisallowedRelayParent, - #[codec(index = 16)] - #[doc = "Failed to compute group index for the core: either it's out of bounds"] - #[doc = "or the relay parent doesn't belong to the current session."] - InvalidAssignment, - #[codec(index = 17)] - #[doc = "Invalid group index in core assignment."] - InvalidGroupIndex, - #[codec(index = 18)] - #[doc = "Insufficient (non-majority) backing."] - InsufficientBacking, - #[codec(index = 19)] - #[doc = "Invalid (bad signature, unknown validator, etc.) backing."] - InvalidBacking, - #[codec(index = 20)] - #[doc = "Collator did not sign PoV."] - NotCollatorSigned, - #[codec(index = 21)] - #[doc = "The validation data hash does not match expected."] - ValidationDataHashMismatch, - #[codec(index = 22)] - #[doc = "The downward message queue is not processed correctly."] - IncorrectDownwardMessageHandling, - #[codec(index = 23)] - #[doc = "At least one upward message sent does not pass the acceptance criteria."] - InvalidUpwardMessages, - #[codec(index = 24)] - #[doc = "The candidate didn't follow the rules of HRMP watermark advancement."] - HrmpWatermarkMishandling, - #[codec(index = 25)] - #[doc = "The HRMP messages sent by the candidate is not valid."] - InvalidOutboundHrmp, - #[codec(index = 26)] - #[doc = "The validation code hash of the candidate is not valid."] - InvalidValidationCodeHash, - #[codec(index = 27)] - #[doc = "The `para_head` hash in the candidate descriptor doesn't match the hash of the actual"] - #[doc = "para head in the commitments."] - ParaHeadMismatch, - #[codec(index = 28)] - #[doc = "A bitfield that references a freed core,"] - #[doc = "either intentionally or as part of a concluded"] - #[doc = "invalid dispute."] - BitfieldReferencesFreedCore, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "A candidate was backed. `[candidate, head_data]`"] - CandidateBacked( - runtime_types::polkadot_primitives::v6::CandidateReceipt< - ::subxt::utils::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v6::CoreIndex, - runtime_types::polkadot_primitives::v6::GroupIndex, - ), - #[codec(index = 1)] - #[doc = "A candidate was included. `[candidate, head_data]`"] - CandidateIncluded( - runtime_types::polkadot_primitives::v6::CandidateReceipt< - ::subxt::utils::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v6::CoreIndex, - runtime_types::polkadot_primitives::v6::GroupIndex, - ), - #[codec(index = 2)] - #[doc = "A candidate timed out. `[candidate, head_data]`"] - CandidateTimedOut( - runtime_types::polkadot_primitives::v6::CandidateReceipt< - ::subxt::utils::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v6::CoreIndex, - ), - #[codec(index = 3)] - #[doc = "Some upward messages have been received and will be processed."] - UpwardMessagesReceived { - from: runtime_types::polkadot_parachain_primitives::primitives::Id, - count: ::core::primitive::u32, - }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AggregateMessageOrigin { - #[codec(index = 0)] - Ump(runtime_types::polkadot_runtime_parachains::inclusion::UmpQueueId), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AvailabilityBitfieldRecord<_0> { - pub bitfield: runtime_types::polkadot_primitives::v6::AvailabilityBitfield, - pub submitted_at: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CandidatePendingAvailability<_0, _1> { - pub core: runtime_types::polkadot_primitives::v6::CoreIndex, - pub hash: runtime_types::polkadot_core_primitives::CandidateHash, - pub descriptor: runtime_types::polkadot_primitives::v6::CandidateDescriptor<_0>, - pub availability_votes: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - pub backers: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - pub relay_parent_number: _1, - pub backed_in_number: _1, - pub backing_group: runtime_types::polkadot_primitives::v6::GroupIndex, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum UmpQueueId { - #[codec(index = 0)] - Para(runtime_types::polkadot_parachain_primitives::primitives::Id), - } - } - pub mod initializer { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::force_approve`]."] - force_approve { up_to: ::core::primitive::u32 }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BufferedSessionChange { - pub validators: ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::validator_app::Public, - >, - pub queued: ::std::vec::Vec< - runtime_types::polkadot_primitives::v6::validator_app::Public, - >, - pub session_index: ::core::primitive::u32, - } - } - pub mod origin { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Origin { - #[codec(index = 0)] - Parachain(runtime_types::polkadot_parachain_primitives::primitives::Id), - } - } - } - pub mod paras { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - # [codec (index = 0)] # [doc = "See [`Pallet::force_set_current_code`]."] force_set_current_code { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , new_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode , } , # [codec (index = 1)] # [doc = "See [`Pallet::force_set_current_head`]."] force_set_current_head { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , new_head : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , } , # [codec (index = 2)] # [doc = "See [`Pallet::force_schedule_code_upgrade`]."] force_schedule_code_upgrade { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , new_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode , relay_parent_number : :: core :: primitive :: u32 , } , # [codec (index = 3)] # [doc = "See [`Pallet::force_note_new_head`]."] force_note_new_head { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , new_head : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , } , # [codec (index = 4)] # [doc = "See [`Pallet::force_queue_action`]."] force_queue_action { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , } , # [codec (index = 5)] # [doc = "See [`Pallet::add_trusted_validation_code`]."] add_trusted_validation_code { validation_code : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCode , } , # [codec (index = 6)] # [doc = "See [`Pallet::poke_unused_validation_code`]."] poke_unused_validation_code { validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } , # [codec (index = 7)] # [doc = "See [`Pallet::include_pvf_check_statement`]."] include_pvf_check_statement { stmt : runtime_types :: polkadot_primitives :: v6 :: PvfCheckStatement , signature : runtime_types :: polkadot_primitives :: v6 :: validator_app :: Signature , } , # [codec (index = 8)] # [doc = "See [`Pallet::force_set_most_recent_context`]."] force_set_most_recent_context { para : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , context : :: core :: primitive :: u32 , } , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Para is not registered in our system."] - NotRegistered, - #[codec(index = 1)] - #[doc = "Para cannot be onboarded because it is already tracked by our system."] - CannotOnboard, - #[codec(index = 2)] - #[doc = "Para cannot be offboarded at this time."] - CannotOffboard, - #[codec(index = 3)] - #[doc = "Para cannot be upgraded to a lease holding parachain."] - CannotUpgrade, - #[codec(index = 4)] - #[doc = "Para cannot be downgraded to an on-demand parachain."] - CannotDowngrade, - #[codec(index = 5)] - #[doc = "The statement for PVF pre-checking is stale."] - PvfCheckStatementStale, - #[codec(index = 6)] - #[doc = "The statement for PVF pre-checking is for a future session."] - PvfCheckStatementFuture, - #[codec(index = 7)] - #[doc = "Claimed validator index is out of bounds."] - PvfCheckValidatorIndexOutOfBounds, - #[codec(index = 8)] - #[doc = "The signature for the PVF pre-checking is invalid."] - PvfCheckInvalidSignature, - #[codec(index = 9)] - #[doc = "The given validator already has cast a vote."] - PvfCheckDoubleVote, - #[codec(index = 10)] - #[doc = "The given PVF does not exist at the moment of process a vote."] - PvfCheckSubjectInvalid, - #[codec(index = 11)] - #[doc = "Parachain cannot currently schedule a code upgrade."] - CannotUpgradeCode, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - # [codec (index = 0)] # [doc = "Current code has been updated for a Para. `para_id`"] CurrentCodeUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 1)] # [doc = "Current head has been updated for a Para. `para_id`"] CurrentHeadUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 2)] # [doc = "A code upgrade has been scheduled for a Para. `para_id`"] CodeUpgradeScheduled (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 3)] # [doc = "A new head has been noted for a Para. `para_id`"] NewHeadNoted (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 4)] # [doc = "A para has been queued to execute pending actions. `para_id`"] ActionQueued (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , :: core :: primitive :: u32 ,) , # [codec (index = 5)] # [doc = "The given para either initiated or subscribed to a PVF check for the given validation"] # [doc = "code. `code_hash` `para_id`"] PvfCheckStarted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 6)] # [doc = "The given validation code was accepted by the PVF pre-checking vote."] # [doc = "`code_hash` `para_id`"] PvfCheckAccepted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 7)] # [doc = "The given validation code was rejected by the PVF pre-checking vote."] # [doc = "`code_hash` `para_id`"] PvfCheckRejected (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ParaGenesisArgs { - pub genesis_head: - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - pub validation_code: - runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - pub para_kind: ::core::primitive::bool, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ParaLifecycle { - #[codec(index = 0)] - Onboarding, - #[codec(index = 1)] - Parathread, - #[codec(index = 2)] - Parachain, - #[codec(index = 3)] - UpgradingParathread, - #[codec(index = 4)] - DowngradingParachain, - #[codec(index = 5)] - OffboardingParathread, - #[codec(index = 6)] - OffboardingParachain, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ParaPastCodeMeta<_0> { - pub upgrade_times: ::std::vec::Vec< - runtime_types::polkadot_runtime_parachains::paras::ReplacementTimes<_0>, - >, - pub last_pruned: ::core::option::Option<_0>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PvfCheckActiveVoteState<_0> { - pub votes_accept: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - pub votes_reject: ::subxt::utils::bits::DecodedBits< - ::core::primitive::u8, - ::subxt::utils::bits::Lsb0, - >, - pub age: ::core::primitive::u32, - pub created_at: _0, - pub causes: ::std::vec::Vec< - runtime_types::polkadot_runtime_parachains::paras::PvfCheckCause<_0>, - >, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum PvfCheckCause<_0> { - #[codec(index = 0)] - Onboarding(runtime_types::polkadot_parachain_primitives::primitives::Id), - #[codec(index = 1)] - Upgrade { - id: runtime_types::polkadot_parachain_primitives::primitives::Id, - included_at: _0, - set_go_ahead: runtime_types::polkadot_runtime_parachains::paras::SetGoAhead, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ReplacementTimes<_0> { - pub expected_at: _0, - pub activated_at: _0, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum SetGoAhead { - #[codec(index = 0)] - Yes, - #[codec(index = 1)] - No, - } - } - pub mod paras_inherent { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::enter`]."] - enter { - data: runtime_types::polkadot_primitives::v6::InherentData< - runtime_types::sp_runtime::generic::header::Header< - ::core::primitive::u32, - >, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Error` enum of this pallet."] - pub enum Error { - #[codec(index = 0)] - #[doc = "Inclusion inherent called more than once per block."] - TooManyInclusionInherents, - #[codec(index = 1)] - #[doc = "The hash of the submitted parent header doesn't correspond to the saved block hash of"] - #[doc = "the parent."] - InvalidParentHeader, - #[codec(index = 2)] - #[doc = "Disputed candidate that was concluded invalid."] - CandidateConcludedInvalid, - #[codec(index = 3)] - #[doc = "The data given to the inherent will result in an overweight block."] - InherentOverweight, - #[codec(index = 4)] - #[doc = "The ordering of dispute statements was invalid."] - DisputeStatementsUnsortedOrDuplicates, - #[codec(index = 5)] - #[doc = "A dispute statement was invalid."] - DisputeInvalid, - #[codec(index = 6)] - #[doc = "A candidate was backed by a disabled validator"] - BackedByDisabled, - } - } - } - pub mod scheduler { - use super::runtime_types; - pub mod common { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Assignment { - #[codec(index = 0)] - Pool { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - core_index: runtime_types::polkadot_primitives::v6::CoreIndex, - }, - #[codec(index = 1)] - Bulk(runtime_types::polkadot_parachain_primitives::primitives::Id), - } - } - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum CoreOccupied<_0> { - # [codec (index = 0)] Free , # [codec (index = 1)] Paras (runtime_types :: polkadot_runtime_parachains :: scheduler :: pallet :: ParasEntry < _0 > ,) , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ParasEntry < _0 > { pub assignment : runtime_types :: polkadot_runtime_parachains :: scheduler :: common :: Assignment , pub availability_timeouts : :: core :: primitive :: u32 , pub ttl : _0 , } - } - } - pub mod shared { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call {} - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AllowedRelayParentsTracker<_0, _1> { - pub buffer: ::std::vec::Vec<(_0, _0)>, - pub latest_number: _1, - } - } - } - pub mod rococo_runtime { - use super::runtime_types; - pub mod governance { - use super::runtime_types; - pub mod origins { - use super::runtime_types; - pub mod pallet_custom_origins { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Origin { - #[codec(index = 0)] - StakingAdmin, - #[codec(index = 1)] - Treasurer, - #[codec(index = 2)] - FellowshipAdmin, - #[codec(index = 3)] - GeneralAdmin, - #[codec(index = 4)] - AuctionAdmin, - #[codec(index = 5)] - LeaseAdmin, - #[codec(index = 6)] - ReferendumCanceller, - #[codec(index = 7)] - ReferendumKiller, - #[codec(index = 8)] - SmallTipper, - #[codec(index = 9)] - BigTipper, - #[codec(index = 10)] - SmallSpender, - #[codec(index = 11)] - MediumSpender, - #[codec(index = 12)] - BigSpender, - #[codec(index = 13)] - WhitelistedCaller, - #[codec(index = 14)] - FellowshipInitiates, - #[codec(index = 15)] - Fellows, - #[codec(index = 16)] - FellowshipExperts, - #[codec(index = 17)] - FellowshipMasters, - #[codec(index = 18)] - Fellowship1Dan, - #[codec(index = 19)] - Fellowship2Dan, - #[codec(index = 20)] - Fellowship3Dan, - #[codec(index = 21)] - Fellowship4Dan, - #[codec(index = 22)] - Fellowship5Dan, - #[codec(index = 23)] - Fellowship6Dan, - #[codec(index = 24)] - Fellowship7Dan, - #[codec(index = 25)] - Fellowship8Dan, - #[codec(index = 26)] - Fellowship9Dan, - } - } - } - } - pub mod validator_manager { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "Contains a variant per dispatchable extrinsic that this pallet has."] - pub enum Call { - #[codec(index = 0)] - #[doc = "See [`Pallet::register_validators`]."] - register_validators { - validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - }, - #[codec(index = 1)] - #[doc = "See [`Pallet::deregister_validators`]."] - deregister_validators { - validators: ::std::vec::Vec<::subxt::utils::AccountId32>, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - #[doc = "The `Event` enum of this pallet"] - pub enum Event { - #[codec(index = 0)] - #[doc = "New validators were added to the set."] - ValidatorsRegistered(::std::vec::Vec<::subxt::utils::AccountId32>), - #[codec(index = 1)] - #[doc = "Validators were removed from the set."] - ValidatorsDeregistered(::std::vec::Vec<::subxt::utils::AccountId32>), - } - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum OriginCaller { - # [codec (index = 0)] system (runtime_types :: frame_support :: dispatch :: RawOrigin < :: subxt :: utils :: AccountId32 > ,) , # [codec (index = 43)] Origins (runtime_types :: rococo_runtime :: governance :: origins :: pallet_custom_origins :: Origin ,) , # [codec (index = 50)] ParachainsOrigin (runtime_types :: polkadot_runtime_parachains :: origin :: pallet :: Origin ,) , # [codec (index = 99)] XcmPallet (runtime_types :: pallet_xcm :: pallet :: Origin ,) , # [codec (index = 4)] Void (runtime_types :: sp_core :: Void ,) , } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ProxyType { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - NonTransfer, - #[codec(index = 2)] - Governance, - #[codec(index = 3)] - IdentityJudgement, - #[codec(index = 4)] - CancelProxy, - #[codec(index = 5)] - Auction, - #[codec(index = 6)] - Society, - #[codec(index = 7)] - OnDemandOrdering, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Runtime; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RuntimeCall { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Call), - #[codec(index = 1)] - Babe(runtime_types::pallet_babe::pallet::Call), - #[codec(index = 2)] - Timestamp(runtime_types::pallet_timestamp::pallet::Call), - #[codec(index = 3)] - Indices(runtime_types::pallet_indices::pallet::Call), - #[codec(index = 4)] - Balances(runtime_types::pallet_balances::pallet::Call), - #[codec(index = 8)] - Session(runtime_types::pallet_session::pallet::Call), - #[codec(index = 10)] - Grandpa(runtime_types::pallet_grandpa::pallet::Call), - #[codec(index = 18)] - Treasury(runtime_types::pallet_treasury::pallet::Call), - #[codec(index = 20)] - ConvictionVoting(runtime_types::pallet_conviction_voting::pallet::Call), - #[codec(index = 21)] - Referenda(runtime_types::pallet_referenda::pallet::Call), - #[codec(index = 22)] - FellowshipCollective(runtime_types::pallet_ranked_collective::pallet::Call), - #[codec(index = 23)] - FellowshipReferenda(runtime_types::pallet_referenda::pallet::Call2), - #[codec(index = 44)] - Whitelist(runtime_types::pallet_whitelist::pallet::Call), - #[codec(index = 19)] - Claims(runtime_types::polkadot_runtime_common::claims::pallet::Call), - #[codec(index = 24)] - Utility(runtime_types::pallet_utility::pallet::Call), - #[codec(index = 25)] - Identity(runtime_types::pallet_identity::pallet::Call), - #[codec(index = 26)] - Society(runtime_types::pallet_society::pallet::Call), - #[codec(index = 27)] - Recovery(runtime_types::pallet_recovery::pallet::Call), - #[codec(index = 28)] - Vesting(runtime_types::pallet_vesting::pallet::Call), - #[codec(index = 29)] - Scheduler(runtime_types::pallet_scheduler::pallet::Call), - #[codec(index = 30)] - Proxy(runtime_types::pallet_proxy::pallet::Call), - #[codec(index = 31)] - Multisig(runtime_types::pallet_multisig::pallet::Call), - #[codec(index = 32)] - Preimage(runtime_types::pallet_preimage::pallet::Call), - #[codec(index = 39)] - AssetRate(runtime_types::pallet_asset_rate::pallet::Call), - #[codec(index = 35)] - Bounties(runtime_types::pallet_bounties::pallet::Call), - #[codec(index = 40)] - ChildBounties(runtime_types::pallet_child_bounties::pallet::Call), - #[codec(index = 38)] - Nis(runtime_types::pallet_nis::pallet::Call), - #[codec(index = 45)] - NisCounterpartBalances(runtime_types::pallet_balances::pallet::Call2), - #[codec(index = 51)] - Configuration( - runtime_types::polkadot_runtime_parachains::configuration::pallet::Call, - ), - #[codec(index = 52)] - ParasShared(runtime_types::polkadot_runtime_parachains::shared::pallet::Call), - #[codec(index = 53)] - ParaInclusion(runtime_types::polkadot_runtime_parachains::inclusion::pallet::Call), - #[codec(index = 54)] - ParaInherent( - runtime_types::polkadot_runtime_parachains::paras_inherent::pallet::Call, - ), - #[codec(index = 56)] - Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Call), - #[codec(index = 57)] - Initializer(runtime_types::polkadot_runtime_parachains::initializer::pallet::Call), - #[codec(index = 60)] - Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Call), - #[codec(index = 62)] - ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Call), - #[codec(index = 63)] - ParasSlashing( - runtime_types::polkadot_runtime_parachains::disputes::slashing::pallet::Call, - ), - #[codec(index = 64)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Call), - #[codec(index = 66)] - OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Call, - ), - #[codec(index = 70)] - Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Call), - #[codec(index = 71)] - Slots(runtime_types::polkadot_runtime_common::slots::pallet::Call), - #[codec(index = 72)] - Auctions(runtime_types::polkadot_runtime_common::auctions::pallet::Call), - #[codec(index = 73)] - Crowdloan(runtime_types::polkadot_runtime_common::crowdloan::pallet::Call), - #[codec(index = 74)] - Coretime(runtime_types::polkadot_runtime_parachains::coretime::pallet::Call), - #[codec(index = 99)] - XcmPallet(runtime_types::pallet_xcm::pallet::Call), - #[codec(index = 240)] - Beefy(runtime_types::pallet_beefy::pallet::Call), - #[codec(index = 248)] - IdentityMigrator( - runtime_types::polkadot_runtime_common::identity_migrator::pallet::Call, - ), - #[codec(index = 250)] - ParasSudoWrapper( - runtime_types::polkadot_runtime_common::paras_sudo_wrapper::pallet::Call, - ), - #[codec(index = 251)] - AssignedSlots(runtime_types::polkadot_runtime_common::assigned_slots::pallet::Call), - #[codec(index = 252)] - ValidatorManager(runtime_types::rococo_runtime::validator_manager::pallet::Call), - #[codec(index = 254)] - StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::Call), - #[codec(index = 249)] - RootTesting(runtime_types::pallet_root_testing::pallet::Call), - #[codec(index = 255)] - Sudo(runtime_types::pallet_sudo::pallet::Call), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RuntimeError { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Error), - #[codec(index = 1)] - Babe(runtime_types::pallet_babe::pallet::Error), - #[codec(index = 3)] - Indices(runtime_types::pallet_indices::pallet::Error), - #[codec(index = 4)] - Balances(runtime_types::pallet_balances::pallet::Error), - #[codec(index = 8)] - Session(runtime_types::pallet_session::pallet::Error), - #[codec(index = 10)] - Grandpa(runtime_types::pallet_grandpa::pallet::Error), - #[codec(index = 18)] - Treasury(runtime_types::pallet_treasury::pallet::Error), - #[codec(index = 20)] - ConvictionVoting(runtime_types::pallet_conviction_voting::pallet::Error), - #[codec(index = 21)] - Referenda(runtime_types::pallet_referenda::pallet::Error), - #[codec(index = 22)] - FellowshipCollective(runtime_types::pallet_ranked_collective::pallet::Error), - #[codec(index = 23)] - FellowshipReferenda(runtime_types::pallet_referenda::pallet::Error2), - #[codec(index = 44)] - Whitelist(runtime_types::pallet_whitelist::pallet::Error), - #[codec(index = 19)] - Claims(runtime_types::polkadot_runtime_common::claims::pallet::Error), - #[codec(index = 24)] - Utility(runtime_types::pallet_utility::pallet::Error), - #[codec(index = 25)] - Identity(runtime_types::pallet_identity::pallet::Error), - #[codec(index = 26)] - Society(runtime_types::pallet_society::pallet::Error), - #[codec(index = 27)] - Recovery(runtime_types::pallet_recovery::pallet::Error), - #[codec(index = 28)] - Vesting(runtime_types::pallet_vesting::pallet::Error), - #[codec(index = 29)] - Scheduler(runtime_types::pallet_scheduler::pallet::Error), - #[codec(index = 30)] - Proxy(runtime_types::pallet_proxy::pallet::Error), - #[codec(index = 31)] - Multisig(runtime_types::pallet_multisig::pallet::Error), - #[codec(index = 32)] - Preimage(runtime_types::pallet_preimage::pallet::Error), - #[codec(index = 39)] - AssetRate(runtime_types::pallet_asset_rate::pallet::Error), - #[codec(index = 35)] - Bounties(runtime_types::pallet_bounties::pallet::Error), - #[codec(index = 40)] - ChildBounties(runtime_types::pallet_child_bounties::pallet::Error), - #[codec(index = 38)] - Nis(runtime_types::pallet_nis::pallet::Error), - #[codec(index = 45)] - NisCounterpartBalances(runtime_types::pallet_balances::pallet::Error2), - #[codec(index = 51)] - Configuration( - runtime_types::polkadot_runtime_parachains::configuration::pallet::Error, - ), - #[codec(index = 53)] - ParaInclusion(runtime_types::polkadot_runtime_parachains::inclusion::pallet::Error), - #[codec(index = 54)] - ParaInherent( - runtime_types::polkadot_runtime_parachains::paras_inherent::pallet::Error, - ), - #[codec(index = 56)] - Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Error), - #[codec(index = 60)] - Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Error), - #[codec(index = 62)] - ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Error), - #[codec(index = 63)] - ParasSlashing( - runtime_types::polkadot_runtime_parachains::disputes::slashing::pallet::Error, - ), - #[codec(index = 64)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Error), - #[codec(index = 66)] - OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Error, - ), - #[codec(index = 68)] - CoretimeAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_coretime::pallet::Error, - ), - #[codec(index = 70)] - Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Error), - #[codec(index = 71)] - Slots(runtime_types::polkadot_runtime_common::slots::pallet::Error), - #[codec(index = 72)] - Auctions(runtime_types::polkadot_runtime_common::auctions::pallet::Error), - #[codec(index = 73)] - Crowdloan(runtime_types::polkadot_runtime_common::crowdloan::pallet::Error), - #[codec(index = 74)] - Coretime(runtime_types::polkadot_runtime_parachains::coretime::pallet::Error), - #[codec(index = 99)] - XcmPallet(runtime_types::pallet_xcm::pallet::Error), - #[codec(index = 240)] - Beefy(runtime_types::pallet_beefy::pallet::Error), - #[codec(index = 250)] - ParasSudoWrapper( - runtime_types::polkadot_runtime_common::paras_sudo_wrapper::pallet::Error, - ), - #[codec(index = 251)] - AssignedSlots( - runtime_types::polkadot_runtime_common::assigned_slots::pallet::Error, - ), - #[codec(index = 254)] - StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::Error), - #[codec(index = 255)] - Sudo(runtime_types::pallet_sudo::pallet::Error), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RuntimeEvent { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Event), - #[codec(index = 3)] - Indices(runtime_types::pallet_indices::pallet::Event), - #[codec(index = 4)] - Balances(runtime_types::pallet_balances::pallet::Event), - #[codec(index = 33)] - TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), - #[codec(index = 7)] - Offences(runtime_types::pallet_offences::pallet::Event), - #[codec(index = 8)] - Session(runtime_types::pallet_session::pallet::Event), - #[codec(index = 10)] - Grandpa(runtime_types::pallet_grandpa::pallet::Event), - #[codec(index = 18)] - Treasury(runtime_types::pallet_treasury::pallet::Event), - #[codec(index = 20)] - ConvictionVoting(runtime_types::pallet_conviction_voting::pallet::Event), - #[codec(index = 21)] - Referenda(runtime_types::pallet_referenda::pallet::Event), - #[codec(index = 22)] - FellowshipCollective(runtime_types::pallet_ranked_collective::pallet::Event), - #[codec(index = 23)] - FellowshipReferenda(runtime_types::pallet_referenda::pallet::Event2), - #[codec(index = 44)] - Whitelist(runtime_types::pallet_whitelist::pallet::Event), - #[codec(index = 19)] - Claims(runtime_types::polkadot_runtime_common::claims::pallet::Event), - #[codec(index = 24)] - Utility(runtime_types::pallet_utility::pallet::Event), - #[codec(index = 25)] - Identity(runtime_types::pallet_identity::pallet::Event), - #[codec(index = 26)] - Society(runtime_types::pallet_society::pallet::Event), - #[codec(index = 27)] - Recovery(runtime_types::pallet_recovery::pallet::Event), - #[codec(index = 28)] - Vesting(runtime_types::pallet_vesting::pallet::Event), - #[codec(index = 29)] - Scheduler(runtime_types::pallet_scheduler::pallet::Event), - #[codec(index = 30)] - Proxy(runtime_types::pallet_proxy::pallet::Event), - #[codec(index = 31)] - Multisig(runtime_types::pallet_multisig::pallet::Event), - #[codec(index = 32)] - Preimage(runtime_types::pallet_preimage::pallet::Event), - #[codec(index = 39)] - AssetRate(runtime_types::pallet_asset_rate::pallet::Event), - #[codec(index = 35)] - Bounties(runtime_types::pallet_bounties::pallet::Event), - #[codec(index = 40)] - ChildBounties(runtime_types::pallet_child_bounties::pallet::Event), - #[codec(index = 38)] - Nis(runtime_types::pallet_nis::pallet::Event), - #[codec(index = 45)] - NisCounterpartBalances(runtime_types::pallet_balances::pallet::Event2), - #[codec(index = 53)] - ParaInclusion(runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event), - #[codec(index = 56)] - Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Event), - #[codec(index = 60)] - Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event), - #[codec(index = 62)] - ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Event), - #[codec(index = 64)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Event), - #[codec(index = 66)] - OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event, - ), - #[codec(index = 70)] - Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event), - #[codec(index = 71)] - Slots(runtime_types::polkadot_runtime_common::slots::pallet::Event), - #[codec(index = 72)] - Auctions(runtime_types::polkadot_runtime_common::auctions::pallet::Event), - #[codec(index = 73)] - Crowdloan(runtime_types::polkadot_runtime_common::crowdloan::pallet::Event), - #[codec(index = 74)] - Coretime(runtime_types::polkadot_runtime_parachains::coretime::pallet::Event), - #[codec(index = 99)] - XcmPallet(runtime_types::pallet_xcm::pallet::Event), - #[codec(index = 248)] - IdentityMigrator( - runtime_types::polkadot_runtime_common::identity_migrator::pallet::Event, - ), - #[codec(index = 251)] - AssignedSlots( - runtime_types::polkadot_runtime_common::assigned_slots::pallet::Event, - ), - #[codec(index = 252)] - ValidatorManager(runtime_types::rococo_runtime::validator_manager::pallet::Event), - #[codec(index = 254)] - StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::Event), - #[codec(index = 249)] - RootTesting(runtime_types::pallet_root_testing::pallet::Event), - #[codec(index = 255)] - Sudo(runtime_types::pallet_sudo::pallet::Event), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum RuntimeHoldReason { - #[codec(index = 32)] - Preimage(runtime_types::pallet_preimage::pallet::HoldReason), - #[codec(index = 38)] - Nis(runtime_types::pallet_nis::pallet::HoldReason), - #[codec(index = 254)] - StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::HoldReason), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SessionKeys { - pub grandpa: runtime_types::sp_consensus_grandpa::app::Public, - pub babe: runtime_types::sp_consensus_babe::app::Public, - pub para_validator: runtime_types::polkadot_primitives::v6::validator_app::Public, - pub para_assignment: runtime_types::polkadot_primitives::v6::assignment_app::Public, - pub authority_discovery: runtime_types::sp_authority_discovery::app::Public, - pub beefy: runtime_types::sp_consensus_beefy::ecdsa_crypto::Public, - } - } - pub mod sp_arithmetic { - use super::runtime_types; - pub mod fixed_point { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FixedI64(pub ::core::primitive::i64); - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct FixedU128(pub ::core::primitive::u128); - } - pub mod per_things { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Perbill(pub ::core::primitive::u32); - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Permill(pub ::core::primitive::u32); - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Perquintill(pub ::core::primitive::u64); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum ArithmeticError { - #[codec(index = 0)] - Underflow, - #[codec(index = 1)] - Overflow, - #[codec(index = 2)] - DivisionByZero, - } - } - pub mod sp_authority_discovery { - use super::runtime_types; - pub mod app { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - } - } - pub mod sp_consensus_babe { - use super::runtime_types; - pub mod app { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - } - pub mod digests { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum NextConfigDescriptor { - #[codec(index = 1)] - V1 { - c: (::core::primitive::u64, ::core::primitive::u64), - allowed_slots: runtime_types::sp_consensus_babe::AllowedSlots, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum PreDigest { - #[codec(index = 1)] - Primary(runtime_types::sp_consensus_babe::digests::PrimaryPreDigest), - #[codec(index = 2)] - SecondaryPlain( - runtime_types::sp_consensus_babe::digests::SecondaryPlainPreDigest, - ), - #[codec(index = 3)] - SecondaryVRF(runtime_types::sp_consensus_babe::digests::SecondaryVRFPreDigest), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PrimaryPreDigest { - pub authority_index: ::core::primitive::u32, - pub slot: runtime_types::sp_consensus_slots::Slot, - pub vrf_signature: runtime_types::sp_core::sr25519::vrf::VrfSignature, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SecondaryPlainPreDigest { - pub authority_index: ::core::primitive::u32, - pub slot: runtime_types::sp_consensus_slots::Slot, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct SecondaryVRFPreDigest { - pub authority_index: ::core::primitive::u32, - pub slot: runtime_types::sp_consensus_slots::Slot, - pub vrf_signature: runtime_types::sp_core::sr25519::vrf::VrfSignature, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AllowedSlots { - #[codec(index = 0)] - PrimarySlots, - #[codec(index = 1)] - PrimaryAndSecondaryPlainSlots, - #[codec(index = 2)] - PrimaryAndSecondaryVRFSlots, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BabeConfiguration { - pub slot_duration: ::core::primitive::u64, - pub epoch_length: ::core::primitive::u64, - pub c: (::core::primitive::u64, ::core::primitive::u64), - pub authorities: ::std::vec::Vec<( - runtime_types::sp_consensus_babe::app::Public, - ::core::primitive::u64, - )>, - pub randomness: [::core::primitive::u8; 32usize], - pub allowed_slots: runtime_types::sp_consensus_babe::AllowedSlots, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BabeEpochConfiguration { - pub c: (::core::primitive::u64, ::core::primitive::u64), - pub allowed_slots: runtime_types::sp_consensus_babe::AllowedSlots, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Epoch { - pub epoch_index: ::core::primitive::u64, - pub start_slot: runtime_types::sp_consensus_slots::Slot, - pub duration: ::core::primitive::u64, - pub authorities: ::std::vec::Vec<( - runtime_types::sp_consensus_babe::app::Public, - ::core::primitive::u64, - )>, - pub randomness: [::core::primitive::u8; 32usize], - pub config: runtime_types::sp_consensus_babe::BabeEpochConfiguration, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaqueKeyOwnershipProof(pub ::std::vec::Vec<::core::primitive::u8>); - } - pub mod sp_consensus_beefy { - use super::runtime_types; - pub mod commitment { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Commitment<_0> { - pub payload: runtime_types::sp_consensus_beefy::payload::Payload, - pub block_number: _0, - pub validator_set_id: ::core::primitive::u64, - } - } - pub mod ecdsa_crypto { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::ecdsa::Public); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub runtime_types::sp_core::ecdsa::Signature); - } - pub mod mmr { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BeefyAuthoritySet<_0> { - pub id: ::core::primitive::u64, - pub len: ::core::primitive::u32, - pub keyset_commitment: _0, - } - } - pub mod payload { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Payload( - pub ::std::vec::Vec<( - [::core::primitive::u8; 2usize], - ::std::vec::Vec<::core::primitive::u8>, - )>, - ); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EquivocationProof<_0, _1, _2> { - pub first: runtime_types::sp_consensus_beefy::VoteMessage<_0, _1, _2>, - pub second: runtime_types::sp_consensus_beefy::VoteMessage<_0, _1, _2>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaqueKeyOwnershipProof(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidatorSet<_0> { - pub validators: ::std::vec::Vec<_0>, - pub id: ::core::primitive::u64, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VoteMessage<_0, _1, _2> { - pub commitment: runtime_types::sp_consensus_beefy::commitment::Commitment<_0>, - pub id: _1, - pub signature: _2, - } - } - pub mod sp_consensus_grandpa { - use super::runtime_types; - pub mod app { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub runtime_types::sp_core::ed25519::Public); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Equivocation<_0, _1> { - #[codec(index = 0)] - Prevote( - runtime_types::finality_grandpa::Equivocation< - runtime_types::sp_consensus_grandpa::app::Public, - runtime_types::finality_grandpa::Prevote<_0, _1>, - runtime_types::sp_consensus_grandpa::app::Signature, - >, - ), - #[codec(index = 1)] - Precommit( - runtime_types::finality_grandpa::Equivocation< - runtime_types::sp_consensus_grandpa::app::Public, - runtime_types::finality_grandpa::Precommit<_0, _1>, - runtime_types::sp_consensus_grandpa::app::Signature, - >, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EquivocationProof<_0, _1> { - pub set_id: ::core::primitive::u64, - pub equivocation: runtime_types::sp_consensus_grandpa::Equivocation<_0, _1>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaqueKeyOwnershipProof(pub ::std::vec::Vec<::core::primitive::u8>); - } - pub mod sp_consensus_slots { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EquivocationProof<_0, _1> { - pub offender: _1, - pub slot: runtime_types::sp_consensus_slots::Slot, - pub first_header: _0, - pub second_header: _0, - } - #[derive( - :: subxt :: ext :: codec :: CompactAs, - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Slot(pub ::core::primitive::u64); - } - pub mod sp_core { - use super::runtime_types; - pub mod crypto { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); - } - pub mod ecdsa { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub [::core::primitive::u8; 33usize]); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub [::core::primitive::u8; 65usize]); - } - pub mod ed25519 { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - pub mod sr25519 { - use super::runtime_types; - pub mod vrf { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct VrfSignature { - pub pre_output: [::core::primitive::u8; 32usize], - pub proof: [::core::primitive::u8; 64usize], - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OpaqueMetadata(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Void {} - } - pub mod sp_inherents { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct CheckInherentsResult { - pub okay: ::core::primitive::bool, - pub fatal_error: ::core::primitive::bool, - pub errors: runtime_types::sp_inherents::InherentData, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct InherentData { - pub data: ::subxt::utils::KeyedVec< - [::core::primitive::u8; 8usize], - ::std::vec::Vec<::core::primitive::u8>, - >, - } - } - pub mod sp_mmr_primitives { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct EncodableOpaqueLeaf(pub ::std::vec::Vec<::core::primitive::u8>); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Error { - #[codec(index = 0)] - InvalidNumericOp, - #[codec(index = 1)] - Push, - #[codec(index = 2)] - GetRoot, - #[codec(index = 3)] - Commit, - #[codec(index = 4)] - GenerateProof, - #[codec(index = 5)] - Verify, - #[codec(index = 6)] - LeafNotFound, - #[codec(index = 7)] - PalletNotIncluded, - #[codec(index = 8)] - InvalidLeafIndex, - #[codec(index = 9)] - InvalidBestKnownBlock, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Proof<_0> { - pub leaf_indices: ::std::vec::Vec<::core::primitive::u64>, - pub leaf_count: ::core::primitive::u64, - pub items: ::std::vec::Vec<_0>, - } - } - pub mod sp_runtime { - use super::runtime_types; - pub mod generic { - use super::runtime_types; - pub mod block { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Block<_0, _1> { - pub header: _0, - pub extrinsics: ::std::vec::Vec<_1>, - } - } - pub mod digest { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Digest { - pub logs: - ::std::vec::Vec, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DigestItem { - #[codec(index = 6)] - PreRuntime( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 4)] - Consensus( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 5)] - Seal( - [::core::primitive::u8; 4usize], - ::std::vec::Vec<::core::primitive::u8>, - ), - #[codec(index = 0)] - Other(::std::vec::Vec<::core::primitive::u8>), - #[codec(index = 8)] - RuntimeEnvironmentUpdated, - } - } - pub mod era { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Era { - #[codec(index = 0)] - Immortal, - #[codec(index = 1)] - Mortal1(::core::primitive::u8), - #[codec(index = 2)] - Mortal2(::core::primitive::u8), - #[codec(index = 3)] - Mortal3(::core::primitive::u8), - #[codec(index = 4)] - Mortal4(::core::primitive::u8), - #[codec(index = 5)] - Mortal5(::core::primitive::u8), - #[codec(index = 6)] - Mortal6(::core::primitive::u8), - #[codec(index = 7)] - Mortal7(::core::primitive::u8), - #[codec(index = 8)] - Mortal8(::core::primitive::u8), - #[codec(index = 9)] - Mortal9(::core::primitive::u8), - #[codec(index = 10)] - Mortal10(::core::primitive::u8), - #[codec(index = 11)] - Mortal11(::core::primitive::u8), - #[codec(index = 12)] - Mortal12(::core::primitive::u8), - #[codec(index = 13)] - Mortal13(::core::primitive::u8), - #[codec(index = 14)] - Mortal14(::core::primitive::u8), - #[codec(index = 15)] - Mortal15(::core::primitive::u8), - #[codec(index = 16)] - Mortal16(::core::primitive::u8), - #[codec(index = 17)] - Mortal17(::core::primitive::u8), - #[codec(index = 18)] - Mortal18(::core::primitive::u8), - #[codec(index = 19)] - Mortal19(::core::primitive::u8), - #[codec(index = 20)] - Mortal20(::core::primitive::u8), - #[codec(index = 21)] - Mortal21(::core::primitive::u8), - #[codec(index = 22)] - Mortal22(::core::primitive::u8), - #[codec(index = 23)] - Mortal23(::core::primitive::u8), - #[codec(index = 24)] - Mortal24(::core::primitive::u8), - #[codec(index = 25)] - Mortal25(::core::primitive::u8), - #[codec(index = 26)] - Mortal26(::core::primitive::u8), - #[codec(index = 27)] - Mortal27(::core::primitive::u8), - #[codec(index = 28)] - Mortal28(::core::primitive::u8), - #[codec(index = 29)] - Mortal29(::core::primitive::u8), - #[codec(index = 30)] - Mortal30(::core::primitive::u8), - #[codec(index = 31)] - Mortal31(::core::primitive::u8), - #[codec(index = 32)] - Mortal32(::core::primitive::u8), - #[codec(index = 33)] - Mortal33(::core::primitive::u8), - #[codec(index = 34)] - Mortal34(::core::primitive::u8), - #[codec(index = 35)] - Mortal35(::core::primitive::u8), - #[codec(index = 36)] - Mortal36(::core::primitive::u8), - #[codec(index = 37)] - Mortal37(::core::primitive::u8), - #[codec(index = 38)] - Mortal38(::core::primitive::u8), - #[codec(index = 39)] - Mortal39(::core::primitive::u8), - #[codec(index = 40)] - Mortal40(::core::primitive::u8), - #[codec(index = 41)] - Mortal41(::core::primitive::u8), - #[codec(index = 42)] - Mortal42(::core::primitive::u8), - #[codec(index = 43)] - Mortal43(::core::primitive::u8), - #[codec(index = 44)] - Mortal44(::core::primitive::u8), - #[codec(index = 45)] - Mortal45(::core::primitive::u8), - #[codec(index = 46)] - Mortal46(::core::primitive::u8), - #[codec(index = 47)] - Mortal47(::core::primitive::u8), - #[codec(index = 48)] - Mortal48(::core::primitive::u8), - #[codec(index = 49)] - Mortal49(::core::primitive::u8), - #[codec(index = 50)] - Mortal50(::core::primitive::u8), - #[codec(index = 51)] - Mortal51(::core::primitive::u8), - #[codec(index = 52)] - Mortal52(::core::primitive::u8), - #[codec(index = 53)] - Mortal53(::core::primitive::u8), - #[codec(index = 54)] - Mortal54(::core::primitive::u8), - #[codec(index = 55)] - Mortal55(::core::primitive::u8), - #[codec(index = 56)] - Mortal56(::core::primitive::u8), - #[codec(index = 57)] - Mortal57(::core::primitive::u8), - #[codec(index = 58)] - Mortal58(::core::primitive::u8), - #[codec(index = 59)] - Mortal59(::core::primitive::u8), - #[codec(index = 60)] - Mortal60(::core::primitive::u8), - #[codec(index = 61)] - Mortal61(::core::primitive::u8), - #[codec(index = 62)] - Mortal62(::core::primitive::u8), - #[codec(index = 63)] - Mortal63(::core::primitive::u8), - #[codec(index = 64)] - Mortal64(::core::primitive::u8), - #[codec(index = 65)] - Mortal65(::core::primitive::u8), - #[codec(index = 66)] - Mortal66(::core::primitive::u8), - #[codec(index = 67)] - Mortal67(::core::primitive::u8), - #[codec(index = 68)] - Mortal68(::core::primitive::u8), - #[codec(index = 69)] - Mortal69(::core::primitive::u8), - #[codec(index = 70)] - Mortal70(::core::primitive::u8), - #[codec(index = 71)] - Mortal71(::core::primitive::u8), - #[codec(index = 72)] - Mortal72(::core::primitive::u8), - #[codec(index = 73)] - Mortal73(::core::primitive::u8), - #[codec(index = 74)] - Mortal74(::core::primitive::u8), - #[codec(index = 75)] - Mortal75(::core::primitive::u8), - #[codec(index = 76)] - Mortal76(::core::primitive::u8), - #[codec(index = 77)] - Mortal77(::core::primitive::u8), - #[codec(index = 78)] - Mortal78(::core::primitive::u8), - #[codec(index = 79)] - Mortal79(::core::primitive::u8), - #[codec(index = 80)] - Mortal80(::core::primitive::u8), - #[codec(index = 81)] - Mortal81(::core::primitive::u8), - #[codec(index = 82)] - Mortal82(::core::primitive::u8), - #[codec(index = 83)] - Mortal83(::core::primitive::u8), - #[codec(index = 84)] - Mortal84(::core::primitive::u8), - #[codec(index = 85)] - Mortal85(::core::primitive::u8), - #[codec(index = 86)] - Mortal86(::core::primitive::u8), - #[codec(index = 87)] - Mortal87(::core::primitive::u8), - #[codec(index = 88)] - Mortal88(::core::primitive::u8), - #[codec(index = 89)] - Mortal89(::core::primitive::u8), - #[codec(index = 90)] - Mortal90(::core::primitive::u8), - #[codec(index = 91)] - Mortal91(::core::primitive::u8), - #[codec(index = 92)] - Mortal92(::core::primitive::u8), - #[codec(index = 93)] - Mortal93(::core::primitive::u8), - #[codec(index = 94)] - Mortal94(::core::primitive::u8), - #[codec(index = 95)] - Mortal95(::core::primitive::u8), - #[codec(index = 96)] - Mortal96(::core::primitive::u8), - #[codec(index = 97)] - Mortal97(::core::primitive::u8), - #[codec(index = 98)] - Mortal98(::core::primitive::u8), - #[codec(index = 99)] - Mortal99(::core::primitive::u8), - #[codec(index = 100)] - Mortal100(::core::primitive::u8), - #[codec(index = 101)] - Mortal101(::core::primitive::u8), - #[codec(index = 102)] - Mortal102(::core::primitive::u8), - #[codec(index = 103)] - Mortal103(::core::primitive::u8), - #[codec(index = 104)] - Mortal104(::core::primitive::u8), - #[codec(index = 105)] - Mortal105(::core::primitive::u8), - #[codec(index = 106)] - Mortal106(::core::primitive::u8), - #[codec(index = 107)] - Mortal107(::core::primitive::u8), - #[codec(index = 108)] - Mortal108(::core::primitive::u8), - #[codec(index = 109)] - Mortal109(::core::primitive::u8), - #[codec(index = 110)] - Mortal110(::core::primitive::u8), - #[codec(index = 111)] - Mortal111(::core::primitive::u8), - #[codec(index = 112)] - Mortal112(::core::primitive::u8), - #[codec(index = 113)] - Mortal113(::core::primitive::u8), - #[codec(index = 114)] - Mortal114(::core::primitive::u8), - #[codec(index = 115)] - Mortal115(::core::primitive::u8), - #[codec(index = 116)] - Mortal116(::core::primitive::u8), - #[codec(index = 117)] - Mortal117(::core::primitive::u8), - #[codec(index = 118)] - Mortal118(::core::primitive::u8), - #[codec(index = 119)] - Mortal119(::core::primitive::u8), - #[codec(index = 120)] - Mortal120(::core::primitive::u8), - #[codec(index = 121)] - Mortal121(::core::primitive::u8), - #[codec(index = 122)] - Mortal122(::core::primitive::u8), - #[codec(index = 123)] - Mortal123(::core::primitive::u8), - #[codec(index = 124)] - Mortal124(::core::primitive::u8), - #[codec(index = 125)] - Mortal125(::core::primitive::u8), - #[codec(index = 126)] - Mortal126(::core::primitive::u8), - #[codec(index = 127)] - Mortal127(::core::primitive::u8), - #[codec(index = 128)] - Mortal128(::core::primitive::u8), - #[codec(index = 129)] - Mortal129(::core::primitive::u8), - #[codec(index = 130)] - Mortal130(::core::primitive::u8), - #[codec(index = 131)] - Mortal131(::core::primitive::u8), - #[codec(index = 132)] - Mortal132(::core::primitive::u8), - #[codec(index = 133)] - Mortal133(::core::primitive::u8), - #[codec(index = 134)] - Mortal134(::core::primitive::u8), - #[codec(index = 135)] - Mortal135(::core::primitive::u8), - #[codec(index = 136)] - Mortal136(::core::primitive::u8), - #[codec(index = 137)] - Mortal137(::core::primitive::u8), - #[codec(index = 138)] - Mortal138(::core::primitive::u8), - #[codec(index = 139)] - Mortal139(::core::primitive::u8), - #[codec(index = 140)] - Mortal140(::core::primitive::u8), - #[codec(index = 141)] - Mortal141(::core::primitive::u8), - #[codec(index = 142)] - Mortal142(::core::primitive::u8), - #[codec(index = 143)] - Mortal143(::core::primitive::u8), - #[codec(index = 144)] - Mortal144(::core::primitive::u8), - #[codec(index = 145)] - Mortal145(::core::primitive::u8), - #[codec(index = 146)] - Mortal146(::core::primitive::u8), - #[codec(index = 147)] - Mortal147(::core::primitive::u8), - #[codec(index = 148)] - Mortal148(::core::primitive::u8), - #[codec(index = 149)] - Mortal149(::core::primitive::u8), - #[codec(index = 150)] - Mortal150(::core::primitive::u8), - #[codec(index = 151)] - Mortal151(::core::primitive::u8), - #[codec(index = 152)] - Mortal152(::core::primitive::u8), - #[codec(index = 153)] - Mortal153(::core::primitive::u8), - #[codec(index = 154)] - Mortal154(::core::primitive::u8), - #[codec(index = 155)] - Mortal155(::core::primitive::u8), - #[codec(index = 156)] - Mortal156(::core::primitive::u8), - #[codec(index = 157)] - Mortal157(::core::primitive::u8), - #[codec(index = 158)] - Mortal158(::core::primitive::u8), - #[codec(index = 159)] - Mortal159(::core::primitive::u8), - #[codec(index = 160)] - Mortal160(::core::primitive::u8), - #[codec(index = 161)] - Mortal161(::core::primitive::u8), - #[codec(index = 162)] - Mortal162(::core::primitive::u8), - #[codec(index = 163)] - Mortal163(::core::primitive::u8), - #[codec(index = 164)] - Mortal164(::core::primitive::u8), - #[codec(index = 165)] - Mortal165(::core::primitive::u8), - #[codec(index = 166)] - Mortal166(::core::primitive::u8), - #[codec(index = 167)] - Mortal167(::core::primitive::u8), - #[codec(index = 168)] - Mortal168(::core::primitive::u8), - #[codec(index = 169)] - Mortal169(::core::primitive::u8), - #[codec(index = 170)] - Mortal170(::core::primitive::u8), - #[codec(index = 171)] - Mortal171(::core::primitive::u8), - #[codec(index = 172)] - Mortal172(::core::primitive::u8), - #[codec(index = 173)] - Mortal173(::core::primitive::u8), - #[codec(index = 174)] - Mortal174(::core::primitive::u8), - #[codec(index = 175)] - Mortal175(::core::primitive::u8), - #[codec(index = 176)] - Mortal176(::core::primitive::u8), - #[codec(index = 177)] - Mortal177(::core::primitive::u8), - #[codec(index = 178)] - Mortal178(::core::primitive::u8), - #[codec(index = 179)] - Mortal179(::core::primitive::u8), - #[codec(index = 180)] - Mortal180(::core::primitive::u8), - #[codec(index = 181)] - Mortal181(::core::primitive::u8), - #[codec(index = 182)] - Mortal182(::core::primitive::u8), - #[codec(index = 183)] - Mortal183(::core::primitive::u8), - #[codec(index = 184)] - Mortal184(::core::primitive::u8), - #[codec(index = 185)] - Mortal185(::core::primitive::u8), - #[codec(index = 186)] - Mortal186(::core::primitive::u8), - #[codec(index = 187)] - Mortal187(::core::primitive::u8), - #[codec(index = 188)] - Mortal188(::core::primitive::u8), - #[codec(index = 189)] - Mortal189(::core::primitive::u8), - #[codec(index = 190)] - Mortal190(::core::primitive::u8), - #[codec(index = 191)] - Mortal191(::core::primitive::u8), - #[codec(index = 192)] - Mortal192(::core::primitive::u8), - #[codec(index = 193)] - Mortal193(::core::primitive::u8), - #[codec(index = 194)] - Mortal194(::core::primitive::u8), - #[codec(index = 195)] - Mortal195(::core::primitive::u8), - #[codec(index = 196)] - Mortal196(::core::primitive::u8), - #[codec(index = 197)] - Mortal197(::core::primitive::u8), - #[codec(index = 198)] - Mortal198(::core::primitive::u8), - #[codec(index = 199)] - Mortal199(::core::primitive::u8), - #[codec(index = 200)] - Mortal200(::core::primitive::u8), - #[codec(index = 201)] - Mortal201(::core::primitive::u8), - #[codec(index = 202)] - Mortal202(::core::primitive::u8), - #[codec(index = 203)] - Mortal203(::core::primitive::u8), - #[codec(index = 204)] - Mortal204(::core::primitive::u8), - #[codec(index = 205)] - Mortal205(::core::primitive::u8), - #[codec(index = 206)] - Mortal206(::core::primitive::u8), - #[codec(index = 207)] - Mortal207(::core::primitive::u8), - #[codec(index = 208)] - Mortal208(::core::primitive::u8), - #[codec(index = 209)] - Mortal209(::core::primitive::u8), - #[codec(index = 210)] - Mortal210(::core::primitive::u8), - #[codec(index = 211)] - Mortal211(::core::primitive::u8), - #[codec(index = 212)] - Mortal212(::core::primitive::u8), - #[codec(index = 213)] - Mortal213(::core::primitive::u8), - #[codec(index = 214)] - Mortal214(::core::primitive::u8), - #[codec(index = 215)] - Mortal215(::core::primitive::u8), - #[codec(index = 216)] - Mortal216(::core::primitive::u8), - #[codec(index = 217)] - Mortal217(::core::primitive::u8), - #[codec(index = 218)] - Mortal218(::core::primitive::u8), - #[codec(index = 219)] - Mortal219(::core::primitive::u8), - #[codec(index = 220)] - Mortal220(::core::primitive::u8), - #[codec(index = 221)] - Mortal221(::core::primitive::u8), - #[codec(index = 222)] - Mortal222(::core::primitive::u8), - #[codec(index = 223)] - Mortal223(::core::primitive::u8), - #[codec(index = 224)] - Mortal224(::core::primitive::u8), - #[codec(index = 225)] - Mortal225(::core::primitive::u8), - #[codec(index = 226)] - Mortal226(::core::primitive::u8), - #[codec(index = 227)] - Mortal227(::core::primitive::u8), - #[codec(index = 228)] - Mortal228(::core::primitive::u8), - #[codec(index = 229)] - Mortal229(::core::primitive::u8), - #[codec(index = 230)] - Mortal230(::core::primitive::u8), - #[codec(index = 231)] - Mortal231(::core::primitive::u8), - #[codec(index = 232)] - Mortal232(::core::primitive::u8), - #[codec(index = 233)] - Mortal233(::core::primitive::u8), - #[codec(index = 234)] - Mortal234(::core::primitive::u8), - #[codec(index = 235)] - Mortal235(::core::primitive::u8), - #[codec(index = 236)] - Mortal236(::core::primitive::u8), - #[codec(index = 237)] - Mortal237(::core::primitive::u8), - #[codec(index = 238)] - Mortal238(::core::primitive::u8), - #[codec(index = 239)] - Mortal239(::core::primitive::u8), - #[codec(index = 240)] - Mortal240(::core::primitive::u8), - #[codec(index = 241)] - Mortal241(::core::primitive::u8), - #[codec(index = 242)] - Mortal242(::core::primitive::u8), - #[codec(index = 243)] - Mortal243(::core::primitive::u8), - #[codec(index = 244)] - Mortal244(::core::primitive::u8), - #[codec(index = 245)] - Mortal245(::core::primitive::u8), - #[codec(index = 246)] - Mortal246(::core::primitive::u8), - #[codec(index = 247)] - Mortal247(::core::primitive::u8), - #[codec(index = 248)] - Mortal248(::core::primitive::u8), - #[codec(index = 249)] - Mortal249(::core::primitive::u8), - #[codec(index = 250)] - Mortal250(::core::primitive::u8), - #[codec(index = 251)] - Mortal251(::core::primitive::u8), - #[codec(index = 252)] - Mortal252(::core::primitive::u8), - #[codec(index = 253)] - Mortal253(::core::primitive::u8), - #[codec(index = 254)] - Mortal254(::core::primitive::u8), - #[codec(index = 255)] - Mortal255(::core::primitive::u8), - } - } - pub mod header { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Header<_0> { - pub parent_hash: ::subxt::utils::H256, - #[codec(compact)] - pub number: _0, - pub state_root: ::subxt::utils::H256, - pub extrinsics_root: ::subxt::utils::H256, - pub digest: runtime_types::sp_runtime::generic::digest::Digest, - } - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct BlakeTwo256; - } - pub mod transaction_validity { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum InvalidTransaction { - #[codec(index = 0)] - Call, - #[codec(index = 1)] - Payment, - #[codec(index = 2)] - Future, - #[codec(index = 3)] - Stale, - #[codec(index = 4)] - BadProof, - #[codec(index = 5)] - AncientBirthBlock, - #[codec(index = 6)] - ExhaustsResources, - #[codec(index = 7)] - Custom(::core::primitive::u8), - #[codec(index = 8)] - BadMandatory, - #[codec(index = 9)] - MandatoryValidation, - #[codec(index = 10)] - BadSigner, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TransactionSource { - #[codec(index = 0)] - InBlock, - #[codec(index = 1)] - Local, - #[codec(index = 2)] - External, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TransactionValidityError { - #[codec(index = 0)] - Invalid(runtime_types::sp_runtime::transaction_validity::InvalidTransaction), - #[codec(index = 1)] - Unknown(runtime_types::sp_runtime::transaction_validity::UnknownTransaction), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum UnknownTransaction { - #[codec(index = 0)] - CannotLookup, - #[codec(index = 1)] - NoUnsignedValidator, - #[codec(index = 2)] - Custom(::core::primitive::u8), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ValidTransaction { - pub priority: ::core::primitive::u64, - pub requires: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub provides: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub longevity: ::core::primitive::u64, - pub propagate: ::core::primitive::bool, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum DispatchError { - #[codec(index = 0)] - Other, - #[codec(index = 1)] - CannotLookup, - #[codec(index = 2)] - BadOrigin, - #[codec(index = 3)] - Module(runtime_types::sp_runtime::ModuleError), - #[codec(index = 4)] - ConsumerRemaining, - #[codec(index = 5)] - NoProviders, - #[codec(index = 6)] - TooManyConsumers, - #[codec(index = 7)] - Token(runtime_types::sp_runtime::TokenError), - #[codec(index = 8)] - Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), - #[codec(index = 9)] - Transactional(runtime_types::sp_runtime::TransactionalError), - #[codec(index = 10)] - Exhausted, - #[codec(index = 11)] - Corruption, - #[codec(index = 12)] - Unavailable, - #[codec(index = 13)] - RootNotAllowed, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DispatchErrorWithPostInfo<_0> { - pub post_info: _0, - pub error: runtime_types::sp_runtime::DispatchError, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct ModuleError { - pub index: ::core::primitive::u8, - pub error: [::core::primitive::u8; 4usize], - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiSignature { - #[codec(index = 0)] - Ed25519(runtime_types::sp_core::ed25519::Signature), - #[codec(index = 1)] - Sr25519(runtime_types::sp_core::sr25519::Signature), - #[codec(index = 2)] - Ecdsa(runtime_types::sp_core::ecdsa::Signature), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiSigner { - #[codec(index = 0)] - Ed25519(runtime_types::sp_core::ed25519::Public), - #[codec(index = 1)] - Sr25519(runtime_types::sp_core::sr25519::Public), - #[codec(index = 2)] - Ecdsa(runtime_types::sp_core::ecdsa::Public), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TokenError { - #[codec(index = 0)] - FundsUnavailable, - #[codec(index = 1)] - OnlyProvider, - #[codec(index = 2)] - BelowMinimum, - #[codec(index = 3)] - CannotCreate, - #[codec(index = 4)] - UnknownAsset, - #[codec(index = 5)] - Frozen, - #[codec(index = 6)] - Unsupported, - #[codec(index = 7)] - CannotCreateHold, - #[codec(index = 8)] - NotExpendable, - #[codec(index = 9)] - Blocked, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum TransactionalError { - #[codec(index = 0)] - LimitReached, - #[codec(index = 1)] - NoLayer, - } - } - pub mod sp_session { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MembershipProof { - pub session: ::core::primitive::u32, - pub trie_nodes: ::std::vec::Vec<::std::vec::Vec<::core::primitive::u8>>, - pub validator_count: ::core::primitive::u32, - } - } - pub mod sp_staking { - use super::runtime_types; - pub mod offence { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct OffenceDetails<_0, _1> { - pub offender: _1, - pub reporters: ::std::vec::Vec<_0>, - } - } - } - pub mod sp_version { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RuntimeVersion { - pub spec_name: ::std::string::String, - pub impl_name: ::std::string::String, - pub authoring_version: ::core::primitive::u32, - pub spec_version: ::core::primitive::u32, - pub impl_version: ::core::primitive::u32, - pub apis: - ::std::vec::Vec<([::core::primitive::u8; 8usize], ::core::primitive::u32)>, - pub transaction_version: ::core::primitive::u32, - pub state_version: ::core::primitive::u8, - } - } - pub mod sp_weights { - use super::runtime_types; - pub mod weight_v2 { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Weight { - #[codec(compact)] - pub ref_time: ::core::primitive::u64, - #[codec(compact)] - pub proof_size: ::core::primitive::u64, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct RuntimeDbWeight { - pub read: ::core::primitive::u64, - pub write: ::core::primitive::u64, - } - } - pub mod staging_xcm { - use super::runtime_types; - pub mod v3 { - use super::runtime_types; - pub mod multilocation { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::xcm::v3::junctions::Junctions, - } - } - } - pub mod v4 { - use super::runtime_types; - pub mod asset { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Asset { - pub id: runtime_types::staging_xcm::v4::asset::AssetId, - pub fun: runtime_types::staging_xcm::v4::asset::Fungibility, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetFilter { - #[codec(index = 0)] - Definite(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 1)] - Wild(runtime_types::staging_xcm::v4::asset::WildAsset), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct AssetId(pub runtime_types::staging_xcm::v4::location::Location); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Assets( - pub ::std::vec::Vec, - ); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::staging_xcm::v4::asset::AssetInstance), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::staging_xcm::v4::asset::AssetId, - fun: runtime_types::staging_xcm::v4::asset::WildFungibility, - }, - #[codec(index = 2)] - AllCounted(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - AllOfCounted { - id: runtime_types::staging_xcm::v4::asset::AssetId, - fun: runtime_types::staging_xcm::v4::asset::WildFungibility, - #[codec(compact)] - count: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - } - pub mod junction { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: ::core::option::Option< - runtime_types::staging_xcm::v4::junction::NetworkId, - >, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: ::core::option::Option< - runtime_types::staging_xcm::v4::junction::NetworkId, - >, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: ::core::option::Option< - runtime_types::staging_xcm::v4::junction::NetworkId, - >, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey { - length: ::core::primitive::u8, - data: [::core::primitive::u8; 32usize], - }, - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v3::junction::BodyId, - part: runtime_types::xcm::v3::junction::BodyPart, - }, - #[codec(index = 9)] - GlobalConsensus(runtime_types::staging_xcm::v4::junction::NetworkId), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum NetworkId { - #[codec(index = 0)] - ByGenesis([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - ByFork { - block_number: ::core::primitive::u64, - block_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - #[codec(index = 4)] - Westend, - #[codec(index = 5)] - Rococo, - #[codec(index = 6)] - Wococo, - #[codec(index = 7)] - Ethereum { - #[codec(compact)] - chain_id: ::core::primitive::u64, - }, - #[codec(index = 8)] - BitcoinCore, - #[codec(index = 9)] - BitcoinCash, - #[codec(index = 10)] - PolkadotBulletin, - } - } - pub mod junctions { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1([runtime_types::staging_xcm::v4::junction::Junction; 1usize]), - #[codec(index = 2)] - X2([runtime_types::staging_xcm::v4::junction::Junction; 2usize]), - #[codec(index = 3)] - X3([runtime_types::staging_xcm::v4::junction::Junction; 3usize]), - #[codec(index = 4)] - X4([runtime_types::staging_xcm::v4::junction::Junction; 4usize]), - #[codec(index = 5)] - X5([runtime_types::staging_xcm::v4::junction::Junction; 5usize]), - #[codec(index = 6)] - X6([runtime_types::staging_xcm::v4::junction::Junction; 6usize]), - #[codec(index = 7)] - X7([runtime_types::staging_xcm::v4::junction::Junction; 7usize]), - #[codec(index = 8)] - X8([runtime_types::staging_xcm::v4::junction::Junction; 8usize]), - } - } - pub mod location { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Location { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::staging_xcm::v4::junctions::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Outcome { - #[codec(index = 0)] - Complete { used: runtime_types::sp_weights::weight_v2::Weight }, - #[codec(index = 1)] - Incomplete { - used: runtime_types::sp_weights::weight_v2::Weight, - error: runtime_types::xcm::v3::traits::Error, - }, - #[codec(index = 2)] - Error { error: runtime_types::xcm::v3::traits::Error }, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v4::Response, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - beneficiary: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v4::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::staging_xcm::v4::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - beneficiary: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v4::asset::AssetFilter, - want: runtime_types::staging_xcm::v4::asset::Assets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - reserve: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v4::asset::Asset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v4::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v4::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - ticket: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 29)] - ExpectAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::staging_xcm::v4::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::staging_xcm::v4::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::staging_xcm::v4::junction::NetworkId, - destination: runtime_types::staging_xcm::v4::junctions::Junctions, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::staging_xcm::v4::asset::Asset, - unlocker: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::staging_xcm::v4::asset::Asset, - target: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::staging_xcm::v4::asset::Asset, - owner: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::staging_xcm::v4::asset::Asset, - locker: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v4::location::Location), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v4::Response, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - beneficiary: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v4::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::staging_xcm::v4::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - beneficiary: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v4::asset::AssetFilter, - want: runtime_types::staging_xcm::v4::asset::Assets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - reserve: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - dest: runtime_types::staging_xcm::v4::location::Location, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, - assets: runtime_types::staging_xcm::v4::asset::AssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v4::asset::Asset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v4::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v4::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v4::asset::Assets, - ticket: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 29)] - ExpectAsset(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::staging_xcm::v4::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::staging_xcm::v4::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::staging_xcm::v4::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::staging_xcm::v4::junction::NetworkId, - destination: runtime_types::staging_xcm::v4::junctions::Junctions, - xcm: runtime_types::staging_xcm::v4::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::staging_xcm::v4::asset::Asset, - unlocker: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::staging_xcm::v4::asset::Asset, - target: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::staging_xcm::v4::asset::Asset, - owner: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::staging_xcm::v4::asset::Asset, - locker: runtime_types::staging_xcm::v4::location::Location, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v4::location::Location), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v4::location::Location, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PalletInfo { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - #[codec(compact)] - pub major: ::core::primitive::u32, - #[codec(compact)] - pub minor: ::core::primitive::u32, - #[codec(compact)] - pub patch: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryResponseInfo { - pub destination: runtime_types::staging_xcm::v4::location::Location, - #[codec(compact)] - pub query_id: ::core::primitive::u64, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::staging_xcm::v4::asset::Assets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - #[codec(index = 4)] - PalletsInfo( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::staging_xcm::v4::PalletInfo, - >, - ), - #[codec(index = 5)] - DispatchResult(runtime_types::xcm::v3::MaybeErrorCode), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm(pub ::std::vec::Vec); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm2(pub ::std::vec::Vec); - } - } - pub mod xcm { - use super::runtime_types; - pub mod double_encoded { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DoubleEncoded { - pub encoded: ::std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct DoubleEncoded2 { - pub encoded: ::std::vec::Vec<::core::primitive::u8>, - } - } - pub mod v2 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: runtime_types::xcm::v2::NetworkId, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: runtime_types::xcm::v2::NetworkId, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: runtime_types::xcm::v2::NetworkId, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v2::BodyId, - part: runtime_types::xcm::v2::BodyPart, - }, - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::xcm::v2::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract(::std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - #[codec(index = 6)] - Blob(::std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::xcm::v2::multiasset::AssetInstance), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiAsset { - pub id: runtime_types::xcm::v2::multiasset::AssetId, - pub fun: runtime_types::xcm::v2::multiasset::Fungibility, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::xcm::v2::multiasset::WildMultiAsset), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiAssets( - pub ::std::vec::Vec, - ); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::xcm::v2::multiasset::AssetId, - fun: runtime_types::xcm::v2::multiasset::WildFungibility, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::xcm::v2::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - runtime_types::xcm::v2::junction::Junction, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::xcm::v2::multilocation::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - MultiLocationFull, - #[codec(index = 5)] - MultiLocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - UnhandledXcmVersion, - #[codec(index = 23)] - WeightLimitReached(::core::primitive::u64), - #[codec(index = 24)] - Barrier, - #[codec(index = 25)] - WeightNotComputable, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v2::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v2::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::xcm::v2::multilocation::MultiLocation, - assets: runtime_types::xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v2::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v2::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum NetworkId { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum OriginKind { - #[codec(index = 0)] - Native, - #[codec(index = 1)] - SovereignAccount, - #[codec(index = 2)] - Superuser, - #[codec(index = 3)] - Xcm, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v2::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(#[codec(compact)] ::core::primitive::u64), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm(pub ::std::vec::Vec); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm2(pub ::std::vec::Vec); - } - pub mod v3 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Moniker([::core::primitive::u8; 4usize]), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: - ::core::option::Option, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: - ::core::option::Option, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: - ::core::option::Option, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey { - length: ::core::primitive::u8, - data: [::core::primitive::u8; 32usize], - }, - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::xcm::v3::junction::BodyId, - part: runtime_types::xcm::v3::junction::BodyPart, - }, - #[codec(index = 9)] - GlobalConsensus(runtime_types::xcm::v3::junction::NetworkId), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum NetworkId { - #[codec(index = 0)] - ByGenesis([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - ByFork { - block_number: ::core::primitive::u64, - block_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - #[codec(index = 4)] - Westend, - #[codec(index = 5)] - Rococo, - #[codec(index = 6)] - Wococo, - #[codec(index = 7)] - Ethereum { - #[codec(compact)] - chain_id: ::core::primitive::u64, - }, - #[codec(index = 8)] - BitcoinCore, - #[codec(index = 9)] - BitcoinCash, - #[codec(index = 10)] - PolkadotBulletin, - } - } - pub mod junctions { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::xcm::v3::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - runtime_types::xcm::v3::junction::Junction, - ), - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract([::core::primitive::u8; 32usize]), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::xcm::v3::multiasset::AssetInstance), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiAsset { - pub id: runtime_types::xcm::v3::multiasset::AssetId, - pub fun: runtime_types::xcm::v3::multiasset::Fungibility, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::xcm::v3::multiasset::WildMultiAsset), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct MultiAssets( - pub ::std::vec::Vec, - ); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::xcm::v3::multiasset::AssetId, - fun: runtime_types::xcm::v3::multiasset::WildFungibility, - }, - #[codec(index = 2)] - AllCounted(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - AllOfCounted { - id: runtime_types::xcm::v3::multiasset::AssetId, - fun: runtime_types::xcm::v3::multiasset::WildFungibility, - #[codec(compact)] - count: ::core::primitive::u32, - }, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - LocationFull, - #[codec(index = 5)] - LocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - ExpectationFalse, - #[codec(index = 23)] - PalletNotFound, - #[codec(index = 24)] - NameMismatch, - #[codec(index = 25)] - VersionIncompatible, - #[codec(index = 26)] - HoldingWouldOverflow, - #[codec(index = 27)] - ExportError, - #[codec(index = 28)] - ReanchorFailed, - #[codec(index = 29)] - NoDeal, - #[codec(index = 30)] - FeesNotMet, - #[codec(index = 31)] - LockError, - #[codec(index = 32)] - NoPermission, - #[codec(index = 33)] - Unanchored, - #[codec(index = 34)] - NotDepositable, - #[codec(index = 35)] - UnhandledXcmVersion, - #[codec(index = 36)] - WeightLimitReached(runtime_types::sp_weights::weight_v2::Weight), - #[codec(index = 37)] - Barrier, - #[codec(index = 38)] - WeightNotComputable, - #[codec(index = 39)] - ExceedsStackLimit, - } - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v3::Response, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v3::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - want: runtime_types::xcm::v3::multiasset::MultiAssets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::xcm::v3::QueryResponseInfo, - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v3::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v3::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v3::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 29)] - ExpectAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::xcm::v3::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::xcm::v3::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::xcm::v3::junction::NetworkId, - destination: runtime_types::xcm::v3::junctions::Junctions, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::xcm::v3::Response, - max_weight: runtime_types::sp_weights::weight_v2::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::xcm::v2::OriginKind, - require_weight_at_most: runtime_types::sp_weights::weight_v2::Weight, - call: runtime_types::xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::xcm::v3::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - want: runtime_types::xcm::v3::multiasset::MultiAssets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::xcm::v3::QueryResponseInfo, - assets: runtime_types::xcm::v3::multiasset::MultiAssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::xcm::v3::multiasset::MultiAsset, - weight_limit: runtime_types::xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::xcm::v3::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::xcm::v3::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::xcm::v3::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: runtime_types::sp_weights::weight_v2::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 29)] - ExpectAsset(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::xcm::v3::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::std::vec::Vec<::core::primitive::u8>, - module_name: ::std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::xcm::v3::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::xcm::v3::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::xcm::v3::junction::NetworkId, - destination: runtime_types::xcm::v3::junctions::Junctions, - xcm: runtime_types::xcm::v3::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::xcm::v3::multiasset::MultiAsset, - locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum MaybeErrorCode { - #[codec(index = 0)] - Success, - #[codec(index = 1)] - Error( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - TruncatedError( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct PalletInfo { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - #[codec(compact)] - pub major: ::core::primitive::u32, - #[codec(compact)] - pub minor: ::core::primitive::u32, - #[codec(compact)] - pub patch: ::core::primitive::u32, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct QueryResponseInfo { - pub destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - #[codec(compact)] - pub query_id: ::core::primitive::u64, - pub max_weight: runtime_types::sp_weights::weight_v2::Weight, - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::xcm::v3::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - #[codec(index = 4)] - PalletsInfo( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::xcm::v3::PalletInfo, - >, - ), - #[codec(index = 5)] - DispatchResult(runtime_types::xcm::v3::MaybeErrorCode), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(runtime_types::sp_weights::weight_v2::Weight), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm(pub ::std::vec::Vec); - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub struct Xcm2(pub ::std::vec::Vec); - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedAssetId { - #[codec(index = 3)] - V3(runtime_types::xcm::v3::multiasset::AssetId), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::asset::AssetId), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedAssets { - #[codec(index = 1)] - V2(runtime_types::xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::multiasset::MultiAssets), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::asset::Assets), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedLocation { - #[codec(index = 1)] - V2(runtime_types::xcm::v2::multilocation::MultiLocation), - #[codec(index = 3)] - V3(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::location::Location), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedResponse { - #[codec(index = 2)] - V2(runtime_types::xcm::v2::Response), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::Response), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::Response), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedXcm { - #[codec(index = 2)] - V2(runtime_types::xcm::v2::Xcm), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::Xcm), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::Xcm), - } - #[derive( - :: subxt :: ext :: codec :: Decode, - :: subxt :: ext :: codec :: Encode, - :: subxt :: ext :: scale_decode :: DecodeAsType, - :: subxt :: ext :: scale_encode :: EncodeAsType, - Debug, - )] - # [codec (crate = :: subxt :: ext :: codec)] - #[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] - #[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] - pub enum VersionedXcm2 { - #[codec(index = 2)] - V2(runtime_types::xcm::v2::Xcm2), - #[codec(index = 3)] - V3(runtime_types::xcm::v3::Xcm2), - #[codec(index = 4)] - V4(runtime_types::staging_xcm::v4::Xcm2), - } - } - } + "place_order_keep_alive", + PlaceOrderKeepAlive { max_amount, para_id }, + [ + 112u8, 56u8, 202u8, 218u8, 85u8, 138u8, 45u8, 213u8, 119u8, 36u8, 62u8, 138u8, 217u8, + 95u8, 25u8, 86u8, 119u8, 192u8, 57u8, 245u8, 34u8, 225u8, 247u8, 116u8, 114u8, 230u8, + 130u8, 180u8, 163u8, 190u8, 106u8, 5u8, + ], + ) } diff --git a/client/coretime/on-demand/src/submit_order.rs b/client/coretime/on-demand/src/submit_order.rs index eb639e4..af49da7 100644 --- a/client/coretime/on-demand/src/submit_order.rs +++ b/client/coretime/on-demand/src/submit_order.rs @@ -18,6 +18,7 @@ //! //! Subxt is used here to construct and submit the transaction. //! + use crate::metadata; use cumulus_primitives_core::{ relay_chain::BlockId, relay_chain::BlockNumber as RelayBlockNumber, ParaId, @@ -126,10 +127,7 @@ pub async fn build_rpc_for_submit_order( .await .map_err(|_e| SubmitOrderError::RPCConnectError)?; - let place_order = metadata::api::tx().on_demand_assignment_provider().place_order_allow_death( - max_amount, - metadata::api::runtime_types::polkadot_parachain_primitives::primitives::Id(para_id.into()), - ); + let place_order = metadata::place_order_allow_death(max_amount, metadata::Id(para_id.into())); let signer_keystore = SignerKeystore::::new(keystore.clone()); From 96910b578497b6624b1e586398e4e2561d63a6b8 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sat, 6 Jul 2024 13:57:56 +0800 Subject: [PATCH 24/44] remove on demand runtime useless metadata of relaychain --- client/coretime/on-demand/src/metadata.rs | 3 - pallets/on-demand/src/lib.rs | 22 +- primitives/coretime/on-demand/src/metadata.rs | 5372 +---------------- 3 files changed, 35 insertions(+), 5362 deletions(-) diff --git a/client/coretime/on-demand/src/metadata.rs b/client/coretime/on-demand/src/metadata.rs index 78e6d44..3da3849 100644 --- a/client/coretime/on-demand/src/metadata.rs +++ b/client/coretime/on-demand/src/metadata.rs @@ -140,7 +140,6 @@ pub struct PlaceOrderAllowDeath { pub para_id: Id, } - impl ::subxt::blocks::StaticExtrinsic for PlaceOrderAllowDeath { const PALLET: &'static str = "OnDemandAssignmentProvider"; const CALL: &'static str = "place_order_allow_death"; @@ -177,13 +176,11 @@ pub struct PlaceOrderKeepAlive { pub para_id: Id, } - impl ::subxt::blocks::StaticExtrinsic for PlaceOrderKeepAlive { const PALLET: &'static str = "OnDemandAssignmentProvider"; const CALL: &'static str = "place_order_keep_alive"; } - #[warn(dead_code)] pub fn place_order_keep_alive( max_amount: u128, diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs index dc8722d..93691d4 100644 --- a/pallets/on-demand/src/lib.rs +++ b/pallets/on-demand/src/lib.rs @@ -37,7 +37,7 @@ use frame_support::{ use frame_system::pallet_prelude::*; use frame_system::{self, EventRecord}; use mp_coretime_on_demand::{ - metadata::api::{runtime_types, runtime_types::rococo_runtime as polakdot_runtime}, + metadata::{BalancesEvent, OnDemandEvent, RelaychainRuntimeEvent}, well_known_keys::SYSTEM_EVENTS, }; pub use pallet::*; @@ -350,7 +350,7 @@ impl Pallet { RelayChainStateProof::new(para_id, relay_storage_root, relay_storage_proof) .expect("Invalid relay chain state proof"); let head_data = relay_storage_rooted_proof - .read_entry::>>>( + .read_entry::>>>( SYSTEM_EVENTS, None, ) @@ -358,11 +358,9 @@ impl Pallet { let v_price: Vec = head_data .iter() .filter_map(|item| { - if let polakdot_runtime::RuntimeEvent::OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event::OnDemandOrderPlaced{ - para_id: pid, - spot_price: sprice, - }) = &item.event + if let RelaychainRuntimeEvent::OnDemandAssignmentProvider( + OnDemandEvent::OnDemandOrderPlaced { para_id: pid, spot_price: sprice }, + ) = &item.event { if pid.encode() == para_id.encode() { Some(*sprice) @@ -381,12 +379,10 @@ impl Pallet { let _: Vec<_> = head_data .iter() .filter_map(|event| { - if let polakdot_runtime::RuntimeEvent::Balances( - runtime_types::pallet_balances::pallet::Event::Withdraw { - who: ref order, - amount: eprice, - }, - ) = event.event + if let RelaychainRuntimeEvent::Balances(BalancesEvent::Withdraw { + who: ref order, + amount: eprice, + }) = event.event { if eprice == *item { orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { diff --git a/primitives/coretime/on-demand/src/metadata.rs b/primitives/coretime/on-demand/src/metadata.rs index cfbd9bc..82af83c 100644 --- a/primitives/coretime/on-demand/src/metadata.rs +++ b/primitives/coretime/on-demand/src/metadata.rs @@ -1,5350 +1,30 @@ -#[allow(dead_code, unused_imports, non_camel_case_types)] -#[allow(clippy::all)] -#[allow(rustdoc::broken_intra_doc_links)] -pub mod api { - #[allow(unused_imports)] - mod root_mod { - pub use super::*; - } - pub mod runtime_types { - use super::runtime_types; - pub mod rococo_runtime { - use super::runtime_types; - pub mod validator_manager { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ValidatorsRegistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), - #[codec(index = 1)] - ValidatorsDeregistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), - } - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ProxyType { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - NonTransfer, - #[codec(index = 2)] - Governance, - #[codec(index = 3)] - IdentityJudgement, - #[codec(index = 4)] - CancelProxy, - #[codec(index = 5)] - Auction, - #[codec(index = 6)] - Society, - #[codec(index = 7)] - OnDemandOrdering, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum RuntimeEvent { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Event), - #[codec(index = 3)] - Indices(runtime_types::pallet_indices::pallet::Event), - #[codec(index = 4)] - Balances(runtime_types::pallet_balances::pallet::Event), - #[codec(index = 33)] - TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), - #[codec(index = 7)] - Offences(runtime_types::pallet_offences::pallet::Event), - #[codec(index = 8)] - Session(runtime_types::pallet_session::pallet::Event), - #[codec(index = 10)] - Grandpa(runtime_types::pallet_grandpa::pallet::Event), - #[codec(index = 11)] - ImOnline(runtime_types::pallet_im_online::pallet::Event), - #[codec(index = 13)] - Democracy(runtime_types::pallet_democracy::pallet::Event), - #[codec(index = 14)] - Council(runtime_types::pallet_collective::pallet::Event), - #[codec(index = 15)] - TechnicalCommittee(runtime_types::pallet_collective::pallet::Event2), - #[codec(index = 16)] - PhragmenElection(runtime_types::pallet_elections_phragmen::pallet::Event), - #[codec(index = 17)] - TechnicalMembership(runtime_types::pallet_membership::pallet::Event), - #[codec(index = 18)] - Treasury(runtime_types::pallet_treasury::pallet::Event), - #[codec(index = 19)] - Claims(runtime_types::polkadot_runtime_common::claims::pallet::Event), - #[codec(index = 24)] - Utility(runtime_types::pallet_utility::pallet::Event), - #[codec(index = 25)] - Identity(runtime_types::pallet_identity::pallet::Event), - #[codec(index = 26)] - Society(runtime_types::pallet_society::pallet::Event), - #[codec(index = 27)] - Recovery(runtime_types::pallet_recovery::pallet::Event), - #[codec(index = 28)] - Vesting(runtime_types::pallet_vesting::pallet::Event), - #[codec(index = 29)] - Scheduler(runtime_types::pallet_scheduler::pallet::Event), - #[codec(index = 30)] - Proxy(runtime_types::pallet_proxy::pallet::Event), - #[codec(index = 31)] - Multisig(runtime_types::pallet_multisig::pallet::Event), - #[codec(index = 32)] - Preimage(runtime_types::pallet_preimage::pallet::Event), - #[codec(index = 35)] - Bounties(runtime_types::pallet_bounties::pallet::Event), - #[codec(index = 40)] - ChildBounties(runtime_types::pallet_child_bounties::pallet::Event), - #[codec(index = 36)] - Tips(runtime_types::pallet_tips::pallet::Event), - #[codec(index = 38)] - Nis(runtime_types::pallet_nis::pallet::Event), - #[codec(index = 45)] - NisCounterpartBalances(runtime_types::pallet_balances::pallet::Event2), - #[codec(index = 53)] - ParaInclusion(runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event), - #[codec(index = 56)] - Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Event), - #[codec(index = 60)] - Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event), - #[codec(index = 62)] - ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Event), - #[codec(index = 64)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Event), - #[codec(index = 66)] - OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event, - ), - #[codec(index = 70)] - Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event), - #[codec(index = 71)] - Slots(runtime_types::polkadot_runtime_common::slots::pallet::Event), - #[codec(index = 72)] - Auctions(runtime_types::polkadot_runtime_common::auctions::pallet::Event), - #[codec(index = 73)] - Crowdloan(runtime_types::polkadot_runtime_common::crowdloan::pallet::Event), - #[codec(index = 99)] - XcmPallet(runtime_types::pallet_xcm::pallet::Event), - #[codec(index = 251)] - AssignedSlots( - runtime_types::polkadot_runtime_common::assigned_slots::pallet::Event, - ), - #[codec(index = 252)] - ValidatorManager(runtime_types::rococo_runtime::validator_manager::pallet::Event), - #[codec(index = 254)] - StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::Event), - #[codec(index = 255)] - Sudo(runtime_types::pallet_sudo::pallet::Event), - } - } - pub mod pallet_indices { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - IndexAssigned { - who: ::sp_core::crypto::AccountId32, - index: ::core::primitive::u32, - }, - #[codec(index = 1)] - IndexFreed { index: ::core::primitive::u32 }, - #[codec(index = 2)] - IndexFrozen { - index: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - }, - } - } - } - pub mod pallet_transaction_payment { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - TransactionFeePaid { - who: ::sp_core::crypto::AccountId32, - actual_fee: ::core::primitive::u128, - tip: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_offences { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Offence { - kind: [::core::primitive::u8; 16usize], - timeslot: ::sp_std::vec::Vec<::core::primitive::u8>, - }, - } - } - } - pub mod pallet_session { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewSession { session_index: ::core::primitive::u32 }, - } - } - } - pub mod sp_consensus_grandpa { - use super::runtime_types; - pub mod app { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::ed25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); - } - } - pub mod pallet_grandpa { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewAuthorities { - authority_set: ::sp_std::vec::Vec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - }, - #[codec(index = 1)] - Paused, - #[codec(index = 2)] - Resumed, - } - } - } - pub mod pallet_im_online { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - HeartbeatReceived { - authority_id: runtime_types::pallet_im_online::sr25519::app_sr25519::Public, - }, - #[codec(index = 1)] - AllGood, - #[codec(index = 2)] - SomeOffline { - offline: ::sp_std::vec::Vec<(::sp_core::crypto::AccountId32, ())>, - }, - } - } - pub mod sr25519 { - use super::runtime_types; - pub mod app_sr25519 { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - } - } - } - pub mod pallet_democracy { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { - proposal_index: ::core::primitive::u32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 1)] - Tabled { - proposal_index: ::core::primitive::u32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 2)] - ExternalTabled, - #[codec(index = 3)] - Started { - ref_index: ::core::primitive::u32, - threshold: runtime_types::pallet_democracy::vote_threshold::VoteThreshold, - }, - #[codec(index = 4)] - Passed { ref_index: ::core::primitive::u32 }, - #[codec(index = 5)] - NotPassed { ref_index: ::core::primitive::u32 }, - #[codec(index = 6)] - Cancelled { ref_index: ::core::primitive::u32 }, - #[codec(index = 7)] - Delegated { - who: ::sp_core::crypto::AccountId32, - target: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 8)] - Undelegated { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 9)] - Vetoed { - who: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - until: ::core::primitive::u32, - }, - #[codec(index = 10)] - Blacklisted { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 11)] - Voted { - voter: ::sp_core::crypto::AccountId32, - ref_index: ::core::primitive::u32, - vote: runtime_types::pallet_democracy::vote::AccountVote< - ::core::primitive::u128, - >, - }, - #[codec(index = 12)] - Seconded { - seconder: ::sp_core::crypto::AccountId32, - prop_index: ::core::primitive::u32, - }, - #[codec(index = 13)] - ProposalCanceled { prop_index: ::core::primitive::u32 }, - #[codec(index = 14)] - MetadataSet { - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 15)] - MetadataCleared { - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 16)] - MetadataTransferred { - prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MetadataOwner { - #[codec(index = 0)] - External, - #[codec(index = 1)] - Proposal(::core::primitive::u32), - #[codec(index = 2)] - Referendum(::core::primitive::u32), - } - } - pub mod vote { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AccountVote<_0> { - #[codec(index = 0)] - Standard { vote: runtime_types::pallet_democracy::vote::Vote, balance: _0 }, - #[codec(index = 1)] - Split { aye: _0, nay: _0 }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Vote(pub ::core::primitive::u8); - } - pub mod vote_threshold { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VoteThreshold { - #[codec(index = 0)] - SuperMajorityApprove, - #[codec(index = 1)] - SuperMajorityAgainst, - #[codec(index = 2)] - SimpleMajority, - } - } - } - pub mod pallet_collective { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { - account: ::sp_core::crypto::AccountId32, - proposal_index: ::core::primitive::u32, - proposal_hash: runtime_types::primitive_types::H256, - threshold: ::core::primitive::u32, - }, - #[codec(index = 1)] - Voted { - account: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - voted: ::core::primitive::bool, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - #[codec(index = 2)] - Approved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 3)] - Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - Executed { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 5)] - MemberExecuted { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 6)] - Closed { - proposal_hash: runtime_types::primitive_types::H256, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event2 { - #[codec(index = 0)] - Proposed { - account: ::sp_core::crypto::AccountId32, - proposal_index: ::core::primitive::u32, - proposal_hash: runtime_types::primitive_types::H256, - threshold: ::core::primitive::u32, - }, - #[codec(index = 1)] - Voted { - account: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - voted: ::core::primitive::bool, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - #[codec(index = 2)] - Approved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 3)] - Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - Executed { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 5)] - MemberExecuted { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 6)] - Closed { - proposal_hash: runtime_types::primitive_types::H256, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - } - } - } - pub mod pallet_elections_phragmen { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewTerm { - new_members: ::sp_std::vec::Vec<( - ::sp_core::crypto::AccountId32, - ::core::primitive::u128, - )>, - }, - #[codec(index = 1)] - EmptyTerm, - #[codec(index = 2)] - ElectionError, - #[codec(index = 3)] - MemberKicked { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - Renounced { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - CandidateSlashed { - candidate: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - SeatHolderSlashed { - seat_holder: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_membership { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - MemberAdded, - #[codec(index = 1)] - MemberRemoved, - #[codec(index = 2)] - MembersSwapped, - #[codec(index = 3)] - MembersReset, - #[codec(index = 4)] - KeyChanged, - #[codec(index = 5)] - Dummy, - } - } - } - pub mod pallet_treasury { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { proposal_index: ::core::primitive::u32 }, - #[codec(index = 1)] - Spending { budget_remaining: ::core::primitive::u128 }, - #[codec(index = 2)] - Awarded { - proposal_index: ::core::primitive::u32, - award: ::core::primitive::u128, - account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Rejected { - proposal_index: ::core::primitive::u32, - slashed: ::core::primitive::u128, - }, - #[codec(index = 4)] - Burnt { burnt_funds: ::core::primitive::u128 }, - #[codec(index = 5)] - Rollover { rollover_balance: ::core::primitive::u128 }, - #[codec(index = 6)] - Deposit { value: ::core::primitive::u128 }, - #[codec(index = 7)] - SpendApproved { - proposal_index: ::core::primitive::u32, - amount: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 8)] - UpdatedInactive { - reactivated: ::core::primitive::u128, - deactivated: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_identity { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - IdentitySet { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - IdentityCleared { - who: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 2)] - IdentityKilled { - who: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 3)] - JudgementRequested { - who: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 4)] - JudgementUnrequested { - who: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 5)] - JudgementGiven { - target: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 6)] - RegistrarAdded { registrar_index: ::core::primitive::u32 }, - #[codec(index = 7)] - SubIdentityAdded { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 8)] - SubIdentityRemoved { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 9)] - SubIdentityRevoked { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_society { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Founded { founder: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - Bid { - candidate_id: ::sp_core::crypto::AccountId32, - offer: ::core::primitive::u128, - }, - #[codec(index = 2)] - Vouch { - candidate_id: ::sp_core::crypto::AccountId32, - offer: ::core::primitive::u128, - vouching: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - AutoUnbid { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - Unbid { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - Unvouch { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 6)] - Inducted { - primary: ::sp_core::crypto::AccountId32, - candidates: ::sp_std::vec::Vec<::sp_core::crypto::AccountId32>, - }, - #[codec(index = 7)] - SuspendedMemberJudgement { - who: ::sp_core::crypto::AccountId32, - judged: ::core::primitive::bool, - }, - #[codec(index = 8)] - CandidateSuspended { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 9)] - MemberSuspended { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 10)] - Challenged { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 11)] - Vote { - candidate: ::sp_core::crypto::AccountId32, - voter: ::sp_core::crypto::AccountId32, - vote: ::core::primitive::bool, - }, - #[codec(index = 12)] - DefenderVote { - voter: ::sp_core::crypto::AccountId32, - vote: ::core::primitive::bool, - }, - #[codec(index = 13)] - NewParams { - params: runtime_types::pallet_society::GroupParams<::core::primitive::u128>, - }, - #[codec(index = 14)] - Unfounded { founder: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Deposit { value: ::core::primitive::u128 }, - #[codec(index = 16)] - Elevated { - member: ::sp_core::crypto::AccountId32, - rank: ::core::primitive::u32, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct GroupParams<_0> { - pub max_members: ::core::primitive::u32, - pub max_intake: ::core::primitive::u32, - pub max_strikes: ::core::primitive::u32, - pub candidate_deposit: _0, - } - } - pub mod pallet_recovery { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - RecoveryCreated { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - RecoveryInitiated { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 2)] - RecoveryVouched { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - sender: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - RecoveryClosed { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 4)] - AccountRecovered { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 5)] - RecoveryRemoved { lost_account: ::sp_core::crypto::AccountId32 }, - } - } - } - pub mod pallet_utility { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BatchInterrupted { - index: ::core::primitive::u32, - error: runtime_types::sp_runtime::DispatchError, - }, - #[codec(index = 1)] - BatchCompleted, - #[codec(index = 2)] - BatchCompletedWithErrors, - #[codec(index = 3)] - ItemCompleted, - #[codec(index = 4)] - ItemFailed { error: runtime_types::sp_runtime::DispatchError }, - #[codec(index = 5)] - DispatchedAs { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod pallet_vesting { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - VestingUpdated { - account: ::sp_core::crypto::AccountId32, - unvested: ::core::primitive::u128, - }, - #[codec(index = 1)] - VestingCompleted { account: ::sp_core::crypto::AccountId32 }, - } - } - } - pub mod pallet_scheduler { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Scheduled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 1)] - Canceled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 2)] - Dispatched { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - CallUnavailable { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 4)] - PeriodicFailed { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 5)] - PermanentlyOverweight { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - } - } - } - pub mod pallet_proxy { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ProxyExecuted { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - PureCreated { - pure: ::sp_core::crypto::AccountId32, - who: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - disambiguation_index: ::core::primitive::u16, - }, - #[codec(index = 2)] - Announced { - real: ::sp_core::crypto::AccountId32, - proxy: ::sp_core::crypto::AccountId32, - call_hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 3)] - ProxyAdded { - delegator: ::sp_core::crypto::AccountId32, - delegatee: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - #[codec(index = 4)] - ProxyRemoved { - delegator: ::sp_core::crypto::AccountId32, - delegatee: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - } - } - } - pub mod pallet_multisig { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewMultisig { - approving: ::sp_core::crypto::AccountId32, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 1)] - MultisigApproval { - approving: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - MultisigExecuted { - approving: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - MultisigCancelled { - cancelling: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Timepoint<_0> { - pub height: _0, - pub index: ::core::primitive::u32, - } - } - pub mod pallet_preimage { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Noted { hash: runtime_types::primitive_types::H256 }, - #[codec(index = 1)] - Requested { hash: runtime_types::primitive_types::H256 }, - #[codec(index = 2)] - Cleared { hash: runtime_types::primitive_types::H256 }, - } - } - } - pub mod pallet_bounties { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BountyProposed { index: ::core::primitive::u32 }, - #[codec(index = 1)] - BountyRejected { index: ::core::primitive::u32, bond: ::core::primitive::u128 }, - #[codec(index = 2)] - BountyBecameActive { index: ::core::primitive::u32 }, - #[codec(index = 3)] - BountyAwarded { - index: ::core::primitive::u32, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 4)] - BountyClaimed { - index: ::core::primitive::u32, - payout: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 5)] - BountyCanceled { index: ::core::primitive::u32 }, - #[codec(index = 6)] - BountyExtended { index: ::core::primitive::u32 }, - } - } - } - pub mod pallet_child_bounties { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Added { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, - #[codec(index = 1)] - Awarded { - index: ::core::primitive::u32, - child_index: ::core::primitive::u32, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 2)] - Claimed { - index: ::core::primitive::u32, - child_index: ::core::primitive::u32, - payout: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Canceled { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, - } - } - } - pub mod pallet_tips { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewTip { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 1)] - TipClosing { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 2)] - TipClosed { - tip_hash: runtime_types::primitive_types::H256, - who: ::sp_core::crypto::AccountId32, - payout: ::core::primitive::u128, - }, - #[codec(index = 3)] - TipRetracted { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - TipSlashed { - tip_hash: runtime_types::primitive_types::H256, - finder: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_nis { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BidPlaced { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 1)] - BidRetracted { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 2)] - BidDropped { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 3)] - Issued { - index: ::core::primitive::u32, - expiry: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - Thawed { - index: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - amount: ::core::primitive::u128, - dropped: ::core::primitive::bool, - }, - #[codec(index = 5)] - Funded { deficit: ::core::primitive::u128 }, - #[codec(index = 6)] - Transferred { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - index: ::core::primitive::u32, - }, - } - } - } - pub mod polkadot_core_primitives { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateHash(pub runtime_types::primitive_types::H256); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct InboundDownwardMessage<_0> { - pub sent_at: _0, - pub msg: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct InboundHrmpMessage<_0> { - pub sent_at: _0, - pub data: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct OutboundHrmpMessage<_0> { - pub recipient: _0, - pub data: ::sp_std::vec::Vec<::core::primitive::u8>, - } - } - pub mod polkadot_primitives { - use super::runtime_types; - pub mod v5 { - use super::runtime_types; - // pub mod assignment_app { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Public(pub runtime_types::sp_core::sr25519::Public); - // } - pub mod collator_app { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - } - // pub mod executor_params { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ExecutorParam { - // #[codec(index = 1)] - // MaxMemoryPages(::core::primitive::u32), - // #[codec(index = 2)] - // StackLogicalMax(::core::primitive::u32), - // #[codec(index = 3)] - // StackNativeMax(::core::primitive::u32), - // #[codec(index = 4)] - // PrecheckingMaxMemory(::core::primitive::u64), - // #[codec(index = 5)] - // PvfPrepTimeout( - // runtime_types::polkadot_primitives::v5::PvfPrepTimeoutKind, - // ::core::primitive::u64, - // ), - // #[codec(index = 6)] - // PvfExecTimeout( - // runtime_types::polkadot_primitives::v5::PvfExecTimeoutKind, - // ::core::primitive::u64, - // ), - // #[codec(index = 7)] - // WasmExtBulkMemory, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ExecutorParams( - // pub ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::executor_params::ExecutorParam, - // >, - // ); - // } - // pub mod signed { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct UncheckedSigned<_0, _1> { - // pub payload: _0, - // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, - // pub signature: - // runtime_types::polkadot_primitives::v5::validator_app::Signature, - // #[codec(skip)] - // pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, - // } - // } - // pub mod slashing { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeProof { - // pub time_slot: - // runtime_types::polkadot_primitives::v5::slashing::DisputesTimeSlot, - // pub kind: - // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, - // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, - // pub validator_id: - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputesTimeSlot { - // pub session_index: ::core::primitive::u32, - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OpaqueKeyOwnershipProof(pub ::sp_std::vec::Vec<::core::primitive::u8>); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PendingSlashes { - // pub keys: ::subxt::utils::KeyedVec< - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // >, - // pub kind: - // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum SlashingOffenceKind { - // #[codec(index = 0)] - // ForInvalid, - // #[codec(index = 1)] - // AgainstValid, - // } - // } - // pub mod validator_app { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Public(pub runtime_types::sp_core::sr25519::Public); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Assignment { - // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AvailabilityBitfield( - // pub ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // ); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct BackedCandidate<_0> { - // pub candidate: - // runtime_types::polkadot_primitives::v5::CommittedCandidateReceipt<_0>, - // pub validity_votes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::ValidityAttestation, - // >, - // pub validator_indices: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidateCommitments<_0> { - // pub upward_messages: - // runtime_types::bounded_collections::bounded_vec::BoundedVec< - // ::sp_std::vec::Vec<::core::primitive::u8>, - // >, - // pub horizontal_messages: - // runtime_types::bounded_collections::bounded_vec::BoundedVec< - // runtime_types::polkadot_core_primitives::OutboundHrmpMessage< - // runtime_types::polkadot_parachain_primitives::primitives::Id, - // >, - // >, - // pub new_validation_code: ::core::option::Option< - // runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - // >, - // pub head_data: - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // pub processed_downward_messages: ::core::primitive::u32, - // pub hrmp_watermark: _0, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateDescriptor < _0 > { pub para_id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , pub relay_parent : _0 , pub collator : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Public , pub persisted_validation_data_hash : runtime_types::primitive_types::H256 , pub pov_hash : runtime_types::primitive_types::H256 , pub erasure_root : runtime_types::primitive_types::H256 , pub signature : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Signature , pub para_head : runtime_types::primitive_types::H256 , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CandidateEvent<_0> { - // #[codec(index = 0)] - // CandidateBacked( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ), - // #[codec(index = 1)] - // CandidateIncluded( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ), - // #[codec(index = 2)] - // CandidateTimedOut( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // ), - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateReceipt<_0> { - pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - pub commitments_hash: runtime_types::primitive_types::H256, - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CommittedCandidateReceipt<_0> { - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub commitments: runtime_types::polkadot_primitives::v5::CandidateCommitments< - // ::core::primitive::u32, - // >, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CoreIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CoreOccupied<_0> { - // #[codec(index = 0)] - // Free, - // #[codec(index = 1)] - // Paras(runtime_types::polkadot_primitives::v5::ParasEntry<_0>), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CoreState<_0, _1> { - // #[codec(index = 0)] - // Occupied(runtime_types::polkadot_primitives::v5::OccupiedCore<_0, _1>), - // #[codec(index = 1)] - // Scheduled(runtime_types::polkadot_primitives::v5::ScheduledCore), - // #[codec(index = 2)] - // Free, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeState<_0> { - // pub validators_for: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub validators_against: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub start: _0, - // pub concluded_at: ::core::option::Option<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum DisputeStatement { - // #[codec(index = 0)] - // Valid(runtime_types::polkadot_primitives::v5::ValidDisputeStatementKind), - // #[codec(index = 1)] - // Invalid(runtime_types::polkadot_primitives::v5::InvalidDisputeStatementKind), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeStatementSet { - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub session: ::core::primitive::u32, - // pub statements: ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::DisputeStatement, - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Signature, - // )>, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct GroupIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct GroupRotationInfo<_0> { - // pub session_start_block: _0, - // pub group_rotation_frequency: _0, - // pub now: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct IndexedVec<_0, _1>( - // pub ::sp_std::vec::Vec<_1>, - // #[codec(skip)] pub ::core::marker::PhantomData<_0>, - // ); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct InherentData<_0> { - // pub bitfields: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::signed::UncheckedSigned< - // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // >, - // >, - // pub backed_candidates: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::BackedCandidate< - // ::subxt::utils::H256, - // >, - // >, - // pub disputes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::DisputeStatementSet, - // >, - // pub parent_header: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum InvalidDisputeStatementKind { - // #[codec(index = 0)] - // Explicit, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OccupiedCore<_0, _1> { - // pub next_up_on_available: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::ScheduledCore, - // >, - // pub occupied_since: _1, - // pub time_out_at: _1, - // pub next_up_on_time_out: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::ScheduledCore, - // >, - // pub availability: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub group_responsible: runtime_types::polkadot_primitives::v5::GroupIndex, - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub candidate_descriptor: - // runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum OccupiedCoreAssumption { - // #[codec(index = 0)] - // Included, - // #[codec(index = 1)] - // TimedOut, - // #[codec(index = 2)] - // Free, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ParasEntry<_0> { - // pub assignment: runtime_types::polkadot_primitives::v5::Assignment, - // pub availability_timeouts: ::core::primitive::u32, - // pub ttl: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PersistedValidationData<_0, _1> { - // pub parent_head: - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // pub relay_parent_number: _1, - // pub relay_parent_storage_root: _0, - // pub max_pov_size: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PvfCheckStatement { pub accept : :: core :: primitive :: bool , pub subject : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub session_index : :: core :: primitive :: u32 , pub validator_index : runtime_types :: polkadot_primitives :: v5 :: ValidatorIndex , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum PvfExecTimeoutKind { - // #[codec(index = 0)] - // Backing, - // #[codec(index = 1)] - // Approval, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum PvfPrepTimeoutKind { - // #[codec(index = 0)] - // Precheck, - // #[codec(index = 1)] - // Lenient, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ScheduledCore { - // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - // pub collator: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::collator_app::Public, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ScrapedOnChainVotes<_0> { - // pub session: ::core::primitive::u32, - // pub backing_validators_per_candidate: ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::ValidityAttestation, - // )>, - // )>, - // pub disputes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::DisputeStatementSet, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct SessionInfo { - // pub active_validator_indices: - // ::sp_std::vec::Vec, - // pub random_seed: [::core::primitive::u8; 32usize], - // pub dispute_period: ::core::primitive::u32, - // pub validators: runtime_types::polkadot_primitives::v5::IndexedVec< - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // >, - // pub discovery_keys: - // ::sp_std::vec::Vec, - // pub assignment_keys: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::assignment_app::Public, - // >, - // pub validator_groups: runtime_types::polkadot_primitives::v5::IndexedVec< - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ::sp_std::vec::Vec, - // >, - // pub n_cores: ::core::primitive::u32, - // pub zeroth_delay_tranche_width: ::core::primitive::u32, - // pub relay_vrf_modulo_samples: ::core::primitive::u32, - // pub n_delay_tranches: ::core::primitive::u32, - // pub no_show_slots: ::core::primitive::u32, - // pub needed_approvals: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum UpgradeGoAhead { - // #[codec(index = 0)] - // Abort, - // #[codec(index = 1)] - // GoAhead, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum UpgradeRestriction { - // #[codec(index = 0)] - // Present, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ValidDisputeStatementKind { - // #[codec(index = 0)] - // Explicit, - // #[codec(index = 1)] - // BackingSeconded(::subxt::utils::H256), - // #[codec(index = 2)] - // BackingValid(::subxt::utils::H256), - // #[codec(index = 3)] - // ApprovalChecking, - // } - // #[derive( - // :: codec :: Decode, - // :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - // Clone, - // Debug, - // PartialEq, - // )] - // pub struct ValidatorIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ValidityAttestation { - // #[codec(index = 1)] - // Implicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), - // #[codec(index = 2)] - // Explicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), - // } - // } - // pub mod vstaging { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AsyncBackingParams { - // pub max_candidate_depth: ::core::primitive::u32, - // pub allowed_ancestry_len: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct BackingState<_0, _1> { - // pub constraints: runtime_types::polkadot_primitives::vstaging::Constraints<_1>, - // pub pending_availability: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::vstaging::CandidatePendingAvailability< - // _0, - // _1, - // >, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidatePendingAvailability<_0, _1> { - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub commitments: - // runtime_types::polkadot_primitives::v5::CandidateCommitments<_1>, - // pub relay_parent_number: _1, - // pub max_pov_size: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Constraints < _0 > { pub min_relay_parent_number : _0 , pub max_pov_size : :: core :: primitive :: u32 , pub max_code_size : :: core :: primitive :: u32 , pub ump_remaining : :: core :: primitive :: u32 , pub ump_remaining_bytes : :: core :: primitive :: u32 , pub max_ump_num_per_candidate : :: core :: primitive :: u32 , pub dmp_remaining_messages : :: std :: vec :: Vec < _0 > , pub hrmp_inbound : runtime_types :: polkadot_primitives :: vstaging :: InboundHrmpLimitations < _0 > , pub hrmp_channels_out : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: vstaging :: OutboundHrmpChannelLimitations ,) > , pub max_hrmp_num_per_candidate : :: core :: primitive :: u32 , pub required_parent : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub upgrade_restriction : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v5 :: UpgradeRestriction > , pub future_validation_code : :: core :: option :: Option < (_0 , runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash ,) > , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct InboundHrmpLimitations<_0> { - // pub valid_watermarks: ::sp_std::vec::Vec<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OutboundHrmpChannelLimitations { - // pub bytes_remaining: ::core::primitive::u32, - // pub messages_remaining: ::core::primitive::u32, - // } - } - } - pub mod sp_core { - use super::runtime_types; - pub mod crypto { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); - } - pub mod ecdsa { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 33usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 65usize]); - } - pub mod ed25519 { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - pub mod sr25519 { - use super::runtime_types; - pub mod vrf { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct VrfSignature { - pub output: [::core::primitive::u8; 32usize], - pub proof: [::core::primitive::u8; 64usize], - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct OpaqueMetadata(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Void {} - } - pub mod pallet_message_queue { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - # [codec (index = 0)] ProcessingFailed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , error : runtime_types :: frame_support :: traits :: messages :: ProcessMessageError , } , # [codec (index = 1)] Processed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , weight_used : :: sp_weights :: Weight , success : :: core :: primitive :: bool , } , # [codec (index = 2)] OverweightEnqueued { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , page_index : :: core :: primitive :: u32 , message_index : :: core :: primitive :: u32 , } , # [codec (index = 3)] PageReaped { origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , index : :: core :: primitive :: u32 , } , } - } - } - pub mod pallet_xcm { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Attempted { outcome: runtime_types::staging_xcm::v3::traits::Outcome }, - #[codec(index = 1)] - Sent { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - message: runtime_types::staging_xcm::v3::Xcm, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - UnexpectedResponse { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 3)] - ResponseReady { - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v3::Response, - }, - #[codec(index = 4)] - Notified { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 5)] - NotifyOverweight { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - actual_weight: ::sp_weights::Weight, - max_budgeted_weight: ::sp_weights::Weight, - }, - #[codec(index = 6)] - NotifyDispatchError { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 7)] - NotifyDecodeFailed { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 8)] - InvalidResponder { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - expected_location: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 9)] - InvalidResponderVersion { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 10)] - ResponseTaken { query_id: ::core::primitive::u64 }, - #[codec(index = 11)] - AssetsTrapped { - hash: runtime_types::primitive_types::H256, - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::VersionedMultiAssets, - }, - #[codec(index = 12)] - VersionChangeNotified { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - result: ::core::primitive::u32, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 13)] - SupportedVersionChanged { - location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - version: ::core::primitive::u32, - }, - #[codec(index = 14)] - NotifyTargetSendFail { - location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - error: runtime_types::staging_xcm::v3::traits::Error, - }, - #[codec(index = 15)] - NotifyTargetMigrationFail { - location: runtime_types::staging_xcm::VersionedMultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 16)] - InvalidQuerierVersion { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 17)] - InvalidQuerier { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - expected_querier: - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - maybe_actual_querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 18)] - VersionNotifyStarted { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 19)] - VersionNotifyRequested { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 20)] - VersionNotifyUnrequested { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 21)] - FeesPaid { - paying: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - fees: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - }, - #[codec(index = 22)] - AssetsClaimed { - hash: runtime_types::primitive_types::H256, - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::VersionedMultiAssets, - }, - } - } - } - pub mod staging_xcm { - use super::runtime_types; - pub mod double_encoded { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DoubleEncoded { - pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DoubleEncoded2 { - pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, - } - } - pub mod v2 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: runtime_types::staging_xcm::v2::NetworkId, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: runtime_types::staging_xcm::v2::NetworkId, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: runtime_types::staging_xcm::v2::NetworkId, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::staging_xcm::v2::BodyId, - part: runtime_types::staging_xcm::v2::BodyPart, - }, - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::staging_xcm::v2::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract(::sp_std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - #[codec(index = 6)] - Blob(::sp_std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::staging_xcm::v2::multiasset::AssetInstance), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAsset { - pub id: runtime_types::staging_xcm::v2::multiasset::AssetId, - pub fun: runtime_types::staging_xcm::v2::multiasset::Fungibility, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::staging_xcm::v2::multiasset::WildMultiAsset), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAssets( - pub ::sp_std::vec::Vec< - runtime_types::staging_xcm::v2::multiasset::MultiAsset, - >, - ); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::staging_xcm::v2::multiasset::AssetId, - fun: runtime_types::staging_xcm::v2::multiasset::WildFungibility, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::staging_xcm::v2::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::staging_xcm::v2::multilocation::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - MultiLocationFull, - #[codec(index = 5)] - MultiLocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - UnhandledXcmVersion, - #[codec(index = 23)] - WeightLimitReached(::core::primitive::u64), - #[codec(index = 24)] - Barrier, - #[codec(index = 25)] - WeightNotComputable, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::staging_xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v2::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v2::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::staging_xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v2::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v2::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum NetworkId { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum OriginKind { - #[codec(index = 0)] - Native, - #[codec(index = 1)] - SovereignAccount, - #[codec(index = 2)] - Superuser, - #[codec(index = 3)] - Xcm, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v2::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(#[codec(compact)] ::core::primitive::u64), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm(pub ::sp_std::vec::Vec); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm2( - pub ::sp_std::vec::Vec, - ); - } - pub mod v3 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Moniker([::core::primitive::u8; 4usize]), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey { - length: ::core::primitive::u8, - data: [::core::primitive::u8; 32usize], - }, - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::staging_xcm::v3::junction::BodyId, - part: runtime_types::staging_xcm::v3::junction::BodyPart, - }, - #[codec(index = 9)] - GlobalConsensus(runtime_types::staging_xcm::v3::junction::NetworkId), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum NetworkId { - #[codec(index = 0)] - ByGenesis([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - ByFork { - block_number: ::core::primitive::u64, - block_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - #[codec(index = 4)] - Westend, - #[codec(index = 5)] - Rococo, - #[codec(index = 6)] - Wococo, - #[codec(index = 7)] - Ethereum { - #[codec(compact)] - chain_id: ::core::primitive::u64, - }, - #[codec(index = 8)] - BitcoinCore, - #[codec(index = 9)] - BitcoinCash, - } - } - pub mod junctions { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::staging_xcm::v3::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract([::core::primitive::u8; 32usize]), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::staging_xcm::v3::multiasset::AssetInstance), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAsset { - pub id: runtime_types::staging_xcm::v3::multiasset::AssetId, - pub fun: runtime_types::staging_xcm::v3::multiasset::Fungibility, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::staging_xcm::v3::multiasset::WildMultiAsset), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAssets( - pub ::sp_std::vec::Vec< - runtime_types::staging_xcm::v3::multiasset::MultiAsset, - >, - ); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::staging_xcm::v3::multiasset::AssetId, - fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, - }, - #[codec(index = 2)] - AllCounted(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - AllOfCounted { - id: runtime_types::staging_xcm::v3::multiasset::AssetId, - fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, - #[codec(compact)] - count: ::core::primitive::u32, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::staging_xcm::v3::junctions::Junctions, - } - } +#[derive( + :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, +)] +pub struct Id(pub u32); - pub mod traits { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - LocationFull, - #[codec(index = 5)] - LocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - ExpectationFalse, - #[codec(index = 23)] - PalletNotFound, - #[codec(index = 24)] - NameMismatch, - #[codec(index = 25)] - VersionIncompatible, - #[codec(index = 26)] - HoldingWouldOverflow, - #[codec(index = 27)] - ExportError, - #[codec(index = 28)] - ReanchorFailed, - #[codec(index = 29)] - NoDeal, - #[codec(index = 30)] - FeesNotMet, - #[codec(index = 31)] - LockError, - #[codec(index = 32)] - NoPermission, - #[codec(index = 33)] - Unanchored, - #[codec(index = 34)] - NotDepositable, - #[codec(index = 35)] - UnhandledXcmVersion, - #[codec(index = 36)] - WeightLimitReached(::sp_weights::Weight), - #[codec(index = 37)] - Barrier, - #[codec(index = 38)] - WeightNotComputable, - #[codec(index = 39)] - ExceedsStackLimit, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Outcome { - #[codec(index = 0)] - Complete(::sp_weights::Weight), - #[codec(index = 1)] - Incomplete( - ::sp_weights::Weight, - runtime_types::staging_xcm::v3::traits::Error, - ), - #[codec(index = 2)] - Error(runtime_types::staging_xcm::v3::traits::Error), - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v3::Response, - max_weight: ::sp_weights::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::staging_xcm::v2::OriginKind, - require_weight_at_most: ::sp_weights::Weight, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v3::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v3::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: ::sp_weights::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 29)] - ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::sp_std::vec::Vec<::core::primitive::u8>, - module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::staging_xcm::v3::junction::NetworkId, - destination: runtime_types::staging_xcm::v3::junctions::Junctions, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum Instruction2 { - // #[codec(index = 0)] - // WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 1)] - // ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 2)] - // ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 3)] - // QueryResponse { - // #[codec(compact)] - // query_id: ::core::primitive::u64, - // response: runtime_types::staging_xcm::v3::Response, - // max_weight: ::sp_weights::Weight, - // querier: ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // }, - // #[codec(index = 4)] - // TransferAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 5)] - // TransferReserveAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 6)] - // Transact { - // origin_kind: runtime_types::staging_xcm::v2::OriginKind, - // require_weight_at_most: ::sp_weights::Weight, - // call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, - // }, - // #[codec(index = 7)] - // HrmpNewChannelOpenRequest { - // #[codec(compact)] - // sender: ::core::primitive::u32, - // #[codec(compact)] - // max_message_size: ::core::primitive::u32, - // #[codec(compact)] - // max_capacity: ::core::primitive::u32, - // }, - // #[codec(index = 8)] - // HrmpChannelAccepted { - // #[codec(compact)] - // recipient: ::core::primitive::u32, - // }, - // #[codec(index = 9)] - // HrmpChannelClosing { - // #[codec(compact)] - // initiator: ::core::primitive::u32, - // #[codec(compact)] - // sender: ::core::primitive::u32, - // #[codec(compact)] - // recipient: ::core::primitive::u32, - // }, - // #[codec(index = 10)] - // ClearOrigin, - // #[codec(index = 11)] - // DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), - // #[codec(index = 12)] - // ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), - // #[codec(index = 13)] - // DepositAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 14)] - // DepositReserveAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 15)] - // ExchangeAsset { - // give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // maximal: ::core::primitive::bool, - // }, - // #[codec(index = 16)] - // InitiateReserveWithdraw { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 17)] - // InitiateTeleport { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 18)] - // ReportHolding { - // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // }, - // #[codec(index = 19)] - // BuyExecution { - // fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - // }, - // #[codec(index = 20)] - // RefundSurplus, - // #[codec(index = 21)] - // SetErrorHandler(runtime_types::staging_xcm::v3::Xcm2), - // #[codec(index = 22)] - // SetAppendix(runtime_types::staging_xcm::v3::Xcm2), - // #[codec(index = 23)] - // ClearError, - // #[codec(index = 24)] - // ClaimAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 25)] - // Trap(#[codec(compact)] ::core::primitive::u64), - // #[codec(index = 26)] - // SubscribeVersion { - // #[codec(compact)] - // query_id: ::core::primitive::u64, - // max_response_weight: ::sp_weights::Weight, - // }, - // #[codec(index = 27)] - // UnsubscribeVersion, - // #[codec(index = 28)] - // BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 29)] - // ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 30)] - // ExpectOrigin( - // ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // ), - // #[codec(index = 31)] - // ExpectError( - // ::core::option::Option<( - // ::core::primitive::u32, - // runtime_types::staging_xcm::v3::traits::Error, - // )>, - // ), - // #[codec(index = 32)] - // ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), - // #[codec(index = 33)] - // QueryPallet { - // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - // }, - // #[codec(index = 34)] - // ExpectPallet { - // #[codec(compact)] - // index: ::core::primitive::u32, - // name: ::sp_std::vec::Vec<::core::primitive::u8>, - // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - // #[codec(compact)] - // crate_major: ::core::primitive::u32, - // #[codec(compact)] - // min_crate_minor: ::core::primitive::u32, - // }, - // #[codec(index = 35)] - // ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), - // #[codec(index = 36)] - // ClearTransactStatus, - // #[codec(index = 37)] - // UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), - // #[codec(index = 38)] - // ExportMessage { - // network: runtime_types::staging_xcm::v3::junction::NetworkId, - // destination: runtime_types::staging_xcm::v3::junctions::Junctions, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 39)] - // LockAsset { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 40)] - // UnlockAsset { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 41)] - // NoteUnlockable { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 42)] - // RequestUnlock { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 43)] - // SetFeesMode { jit_withdraw: ::core::primitive::bool }, - // #[codec(index = 44)] - // SetTopic([::core::primitive::u8; 32usize]), - // #[codec(index = 45)] - // ClearTopic, - // #[codec(index = 46)] - // AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - // #[codec(index = 47)] - // UnpaidExecution { - // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - // check_origin: ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // }, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MaybeErrorCode { - #[codec(index = 0)] - Success, - #[codec(index = 1)] - Error( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - TruncatedError( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct PalletInfo { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - #[codec(compact)] - pub major: ::core::primitive::u32, - #[codec(compact)] - pub minor: ::core::primitive::u32, - #[codec(compact)] - pub patch: ::core::primitive::u32, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct QueryResponseInfo { - pub destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - #[codec(compact)] - pub query_id: ::core::primitive::u64, - pub max_weight: ::sp_weights::Weight, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v3::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - #[codec(index = 4)] - PalletsInfo( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::staging_xcm::v3::PalletInfo, - >, - ), - #[codec(index = 5)] - DispatchResult(runtime_types::staging_xcm::v3::MaybeErrorCode), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(::sp_weights::Weight), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm(pub ::sp_std::vec::Vec); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Xcm2(pub ::sp_std::vec::Vec); - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedAssetId { - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::multiasset::AssetId), - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VersionedMultiAssets { - #[codec(index = 1)] - V2(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - V3(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VersionedMultiLocation { - #[codec(index = 1)] - V2(runtime_types::staging_xcm::v2::multilocation::MultiLocation), - #[codec(index = 3)] - V3(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedResponse { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Response), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Response), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedXcm { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Xcm), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Xcm), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedXcm2 { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Xcm2), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Xcm2), - // } - } +#[derive( + :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, +)] +pub enum OnDemandEvent { + #[codec(index = 0)] + OnDemandOrderPlaced { para_id: Id, spot_price: u128 }, +} - pub mod polkadot_runtime_common { - use super::runtime_types; - pub mod assigned_slots { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - PermanentSlotAssigned( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 1)] - TemporarySlotAssigned( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 2)] - MaxPermanentSlotsChanged { slots: ::core::primitive::u32 }, - #[codec(index = 3)] - MaxTemporarySlotsChanged { slots: ::core::primitive::u32 }, - } - } - } - pub mod auctions { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - AuctionStarted { - auction_index: ::core::primitive::u32, - lease_period: ::core::primitive::u32, - ending: ::core::primitive::u32, - }, - #[codec(index = 1)] - AuctionClosed { auction_index: ::core::primitive::u32 }, - #[codec(index = 2)] - Reserved { - bidder: ::sp_core::crypto::AccountId32, - extra_reserved: ::core::primitive::u128, - total_amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - Unreserved { - bidder: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - ReserveConfiscated { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - BidAccepted { - bidder: ::sp_core::crypto::AccountId32, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - first_slot: ::core::primitive::u32, - last_slot: ::core::primitive::u32, - }, - #[codec(index = 6)] - WinningOffset { - auction_index: ::core::primitive::u32, - block_number: ::core::primitive::u32, - }, - } - } - } - pub mod claims { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Claimed { - who: ::sp_core::crypto::AccountId32, - ethereum_address: - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - amount: ::core::primitive::u128, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct EthereumAddress(pub [::core::primitive::u8; 20usize]); - } - pub mod crowdloan { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Created { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 1)] - Contributed { - who: ::sp_core::crypto::AccountId32, - fund_index: - runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Withdrew { - who: ::sp_core::crypto::AccountId32, - fund_index: - runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - PartiallyRefunded { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 4)] - AllRefunded { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 5)] - Dissolved { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 6)] - HandleBidResult { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - result: ::core::result::Result< - (), - runtime_types::sp_runtime::DispatchError, - >, - }, - #[codec(index = 7)] - Edited { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 8)] - MemoUpdated { - who: ::sp_core::crypto::AccountId32, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - memo: ::sp_std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 9)] - AddedToNewRaise { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - } - } - pub mod paras_registrar { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Registered { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - manager: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 1)] - Deregistered { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 2)] - Reserved { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - who: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Swapped { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - other_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - } - } - pub mod slots { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewLeasePeriod { lease_period: ::core::primitive::u32 }, - #[codec(index = 1)] - Leased { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::sp_core::crypto::AccountId32, - period_begin: ::core::primitive::u32, - period_count: ::core::primitive::u32, - extra_reserved: ::core::primitive::u128, - total_amount: ::core::primitive::u128, - }, - } - } - } - } +#[derive( + :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, +)] +pub enum BalancesEvent { + #[codec(index = 8)] + Withdraw { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, +} - pub mod pallet_state_trie_migration { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - MaxSignedLimits, - #[codec(index = 1)] - KeyTooLong, - #[codec(index = 2)] - NotEnoughFunds, - #[codec(index = 3)] - BadWitness, - #[codec(index = 4)] - SignedMigrationNotAllowed, - #[codec(index = 5)] - BadChildRoot, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Migrated { - top: ::core::primitive::u32, - child: ::core::primitive::u32, - compute: - runtime_types::pallet_state_trie_migration::pallet::MigrationCompute, - }, - #[codec(index = 1)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 2)] - AutoMigrationFinished, - #[codec(index = 3)] - Halted { error: runtime_types::pallet_state_trie_migration::pallet::Error }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MigrationCompute { - #[codec(index = 0)] - Signed, - #[codec(index = 1)] - Auto, - } - } - } - pub mod bounded_collections { - use super::runtime_types; - pub mod bounded_vec { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct BoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); - } - pub mod weak_bounded_vec { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct WeakBoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); - } - } - pub mod primitive_types { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct H256(pub [::core::primitive::u8; 32usize]); - } - pub mod frame_system { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ExtrinsicSuccess { - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 1)] - ExtrinsicFailed { - dispatch_error: runtime_types::sp_runtime::DispatchError, - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 2)] - CodeUpdated, - #[codec(index = 3)] - NewAccount { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - KilledAccount { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - Remarked { - sender: ::sp_core::crypto::AccountId32, - hash: runtime_types::primitive_types::H256, - }, - } - } - } - pub mod frame_support { - use super::runtime_types; - pub mod dispatch { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DispatchClass { - #[codec(index = 0)] - Normal, - #[codec(index = 1)] - Operational, - #[codec(index = 2)] - Mandatory, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DispatchInfo { - pub weight: ::sp_weights::Weight, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub pays_fee: runtime_types::frame_support::dispatch::Pays, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Pays { - #[codec(index = 0)] - Yes, - #[codec(index = 1)] - No, - } - } - pub mod traits { - use super::runtime_types; - pub mod messages { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ProcessMessageError { - #[codec(index = 0)] - BadFormat, - #[codec(index = 1)] - Corrupt, - #[codec(index = 2)] - Unsupported, - #[codec(index = 3)] - Overweight(::sp_weights::Weight), - #[codec(index = 4)] - Yield, - } - } - pub mod tokens { - use super::runtime_types; - pub mod misc { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BalanceStatus { - #[codec(index = 0)] - Free, - #[codec(index = 1)] - Reserved, - } - } - } - } - } - pub mod pallet_balances { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Endowed { - account: ::sp_core::crypto::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - DustLost { - account: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Transfer { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - BalanceSet { - who: ::sp_core::crypto::AccountId32, - free: ::core::primitive::u128, - }, - #[codec(index = 4)] - Reserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - Unreserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - ReserveRepatriated { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - Withdraw { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - Suspended { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 13)] - Restored { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - Upgraded { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - Unlocked { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 19)] - Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event2 { - #[codec(index = 0)] - Endowed { - account: ::sp_core::crypto::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - DustLost { - account: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Transfer { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - BalanceSet { - who: ::sp_core::crypto::AccountId32, - free: ::core::primitive::u128, - }, - #[codec(index = 4)] - Reserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - Unreserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - ReserveRepatriated { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - Withdraw { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - Suspended { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 13)] - Restored { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - Upgraded { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - Unlocked { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 19)] - Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - } - } - } - pub mod polkadot_runtime_parachains { - use super::runtime_types; - pub mod assigner_on_demand { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - OnDemandOrderPlaced { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - spot_price: ::core::primitive::u128, - }, - #[codec(index = 1)] - SpotTrafficSet { - traffic: runtime_types::sp_arithmetic::fixed_point::FixedU128, - }, - } - } - } - pub mod inclusion { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - CandidateBacked( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - runtime_types::polkadot_primitives::v5::GroupIndex, - ), - #[codec(index = 1)] - CandidateIncluded( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - runtime_types::polkadot_primitives::v5::GroupIndex, - ), - #[codec(index = 2)] - CandidateTimedOut( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - ), - #[codec(index = 3)] - UpwardMessagesReceived { - from: runtime_types::polkadot_parachain_primitives::primitives::Id, - count: ::core::primitive::u32, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AggregateMessageOrigin { - #[codec(index = 0)] - Ump(runtime_types::polkadot_runtime_parachains::inclusion::UmpQueueId), - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AvailabilityBitfieldRecord<_0> { - // pub bitfield: runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // pub submitted_at: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidatePendingAvailability<_0, _1> { - // pub core: runtime_types::polkadot_primitives::v5::CoreIndex, - // pub hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub availability_votes: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub backers: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub relay_parent_number: _1, - // pub backed_in_number: _1, - // pub backing_group: runtime_types::polkadot_primitives::v5::GroupIndex, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum UmpQueueId { - #[codec(index = 0)] - Para(runtime_types::polkadot_parachain_primitives::primitives::Id), - } - } - pub mod paras { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - # [codec (index = 0)] CurrentCodeUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 1)] CurrentHeadUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 2)] CodeUpgradeScheduled (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 3)] NewHeadNoted (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 4)] ActionQueued (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , :: core :: primitive :: u32 ,) , # [codec (index = 5)] PvfCheckStarted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 6)] PvfCheckAccepted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 7)] PvfCheckRejected (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , } - } - } - pub mod hrmp { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - OpenChannelRequested( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - ::core::primitive::u32, - ), - #[codec(index = 1)] - OpenChannelCanceled( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - ), - #[codec(index = 2)] - OpenChannelAccepted( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 3)] - ChannelClosed( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - ), - #[codec(index = 4)] - HrmpChannelForceOpened( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - ::core::primitive::u32, - ), - } - } - } - pub mod disputes { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - DisputeInitiated( - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, - ), - #[codec(index = 1)] - DisputeConcluded( - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, - ), - #[codec(index = 2)] - Revert(::core::primitive::u32), - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DisputeLocation { - #[codec(index = 0)] - Local, - #[codec(index = 1)] - Remote, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DisputeResult { - #[codec(index = 0)] - Valid, - #[codec(index = 1)] - Invalid, - } - } - } - pub mod polkadot_parachain_primitives { - use super::runtime_types; - pub mod primitives { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct HeadData(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct HrmpChannelId { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Id(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ValidationCode(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ValidationCodeHash(pub runtime_types::primitive_types::H256); - } - } - pub mod pallet_sudo { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Sudid { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - KeyChanged { - old_sudoer: ::core::option::Option<::sp_core::crypto::AccountId32>, - }, - #[codec(index = 2)] - SudoAsDone { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod sp_arithmetic { - use super::runtime_types; - pub mod fixed_point { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct FixedU128(pub ::core::primitive::u128); - } - pub mod per_things { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Perbill(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Percent(pub ::core::primitive::u8); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Permill(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Perquintill(pub ::core::primitive::u64); - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ArithmeticError { - #[codec(index = 0)] - Underflow, - #[codec(index = 1)] - Overflow, - #[codec(index = 2)] - DivisionByZero, - } - } - pub mod sp_runtime { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DispatchError { - #[codec(index = 0)] - Other, - #[codec(index = 1)] - CannotLookup, - #[codec(index = 2)] - BadOrigin, - #[codec(index = 3)] - Module(runtime_types::sp_runtime::ModuleError), - #[codec(index = 4)] - ConsumerRemaining, - #[codec(index = 5)] - NoProviders, - #[codec(index = 6)] - TooManyConsumers, - #[codec(index = 7)] - Token(runtime_types::sp_runtime::TokenError), - #[codec(index = 8)] - Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), - #[codec(index = 9)] - Transactional(runtime_types::sp_runtime::TransactionalError), - #[codec(index = 10)] - Exhausted, - #[codec(index = 11)] - Corruption, - #[codec(index = 12)] - Unavailable, - #[codec(index = 13)] - RootNotAllowed, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ModuleError { - pub index: ::core::primitive::u8, - pub error: [::core::primitive::u8; 4usize], - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum TokenError { - #[codec(index = 0)] - FundsUnavailable, - #[codec(index = 1)] - OnlyProvider, - #[codec(index = 2)] - BelowMinimum, - #[codec(index = 3)] - CannotCreate, - #[codec(index = 4)] - UnknownAsset, - #[codec(index = 5)] - Frozen, - #[codec(index = 6)] - Unsupported, - #[codec(index = 7)] - CannotCreateHold, - #[codec(index = 8)] - NotExpendable, - #[codec(index = 9)] - Blocked, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum TransactionalError { - #[codec(index = 0)] - LimitReached, - #[codec(index = 1)] - NoLayer, - } - } - } +#[derive( + :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, +)] +pub enum RelaychainRuntimeEvent { + #[codec(index = 4)] + Balances(BalancesEvent), + #[codec(index = 66)] + OnDemandAssignmentProvider(OnDemandEvent), } From 43555745d48afc7a9de94596dd60506d2a2f028e Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sat, 6 Jul 2024 17:23:12 +0800 Subject: [PATCH 25/44] Restore the ondemand mode code so that it can run normally --- node/src/service.rs | 57 ++++++++++++--------- pallets/on-demand/src/lib.rs | 97 ++++++++++++++++-------------------- runtime/src/lib.rs | 11 ++-- 3 files changed, 82 insertions(+), 83 deletions(-) diff --git a/node/src/service.rs b/node/src/service.rs index e7e83c4..ab1cb9a 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -512,7 +512,7 @@ async fn start_node_impl( collator_key.expect("Command line arguments do not allow this. qed"), overseer_handle, announce_block, - // order_record, + order_record, bulk_mem_record, )?; } @@ -569,7 +569,7 @@ fn start_consensus( collator_key: CollatorPair, overseer_handle: OverseerHandle, announce_block: Arc>) + Send + Sync>, - // order_record: Arc>>, + order_record: Arc>>, bulk_mem_record: Arc>, ) -> Result<(), sc_service::Error> { use cumulus_client_consensus_aura::collators::lookahead::{self as aura, Params as AuraParams}; @@ -638,30 +638,11 @@ fn start_consensus( // Ok(order_inherent) // } // }, - - // block_import, - // para_client: client.clone(), - // para_backend: backend.clone(), - // relay_client: relay_chain_interface_clone, - // code_hash_provider: move |block_hash| { - // client.code_at(block_hash).ok().map(|c| ValidationCode::from(c).hash()) - // }, - // sync_oracle, - // keystore, - // collator_key, - // para_id, - // overseer_handle, - // slot_duration, - // relay_chain_slot_duration, - // proposer, - // collator_service, - // // Very limited proposal time. - // authoring_duration: Duration::from_millis(1500), - // reinitialize: false, - // }; let params = AuraParams { create_inherent_data_providers: move |_, ()| { let bulk_mem_record_clone = bulk_mem_record.clone(); + let relay_chain_interface = relay_chain_interface.clone(); + let order_record_clone = order_record.clone(); async move { let mut bulk_mem_record_clone_local = bulk_mem_record_clone.lock().await; let record_items = &mut bulk_mem_record_clone_local.items; @@ -706,7 +687,35 @@ fn start_consensus( "Failed to create bulk inherent", ) })?; - Ok(bulk_inherent) + let parent_hash = relay_chain_interface.best_block_hash().await?; + let (relay_parent, validation_data, sequence_number, author_pub) = { + let order_record_local = order_record_clone.lock().await; + if order_record_local.validation_data.is_none() { + (parent_hash, None, order_record_local.sequence_number, None) + } else { + ( + order_record_local.relay_parent.expect("can not get relay_parent hash"), + order_record_local.validation_data.clone(), + order_record_local.sequence_number, + order_record_local.author_pub.clone(), + ) + } + }; + let order_inherent = mp_coretime_on_demand::OrderInherentData::create_at( + relay_parent, + &relay_chain_interface, + &validation_data, + para_id, + sequence_number, + &author_pub, + ) + .await; + let order_inherent = order_inherent.ok_or_else(|| { + Box::::from( + "Failed to create order inherent", + ) + })?; + Ok((bulk_inherent, order_inherent)) } }, diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs index 93691d4..4848c4d 100644 --- a/pallets/on-demand/src/lib.rs +++ b/pallets/on-demand/src/lib.rs @@ -191,53 +191,52 @@ pub mod pallet { /// Called at the end of each block to check whether an order has been placed. /// If so, modify the execution status and increase the sequencer number. fn on_finalize(block_number: BlockNumberFor) { - // let old_sequence_number = SequenceNumber::::get(); - // let order = OrderMap::::get(old_sequence_number); - // if let Some(t_order) = order { - // let orderer = t_order.orderer; - // OrderMap::::remove(old_sequence_number); - // OrderMap::::insert( - // old_sequence_number, - // Order:: { - // sequence_number: old_sequence_number, - // orderer: orderer.clone(), - // price: t_order.price, - // executed: true, - // }, - // ); - // SequenceNumber::::set(old_sequence_number + 1); - // Block2Sequence::::insert(block_number, old_sequence_number); - // Self::deposit_event(Event::OrderCreate { - // sequence_number: old_sequence_number, - // orderer, - // }); - // } + let old_sequence_number = SequenceNumber::::get(); + let order = OrderMap::::get(old_sequence_number); + if let Some(t_order) = order { + let orderer = t_order.orderer; + OrderMap::::remove(old_sequence_number); + OrderMap::::insert( + old_sequence_number, + Order:: { + sequence_number: old_sequence_number, + orderer: orderer.clone(), + price: t_order.price, + executed: true, + }, + ); + SequenceNumber::::set(old_sequence_number + 1); + Block2Sequence::::insert(block_number, old_sequence_number); + Self::deposit_event(Event::OrderCreate { + sequence_number: old_sequence_number, + orderer, + }); + } } } - // #[pallet::inherent] - // impl ProvideInherent for Pallet { - // type Call = Call; - // type Error = MakeFatalError<()>; - - // const INHERENT_IDENTIFIER: InherentIdentifier = - // magnet_primitives_order::INHERENT_IDENTIFIER; - // fn create_inherent(data: &InherentData) -> Option { - // let data: magnet_primitives_order::OrderInherentData = data - // .get_data(&magnet_primitives_order::INHERENT_IDENTIFIER) - // .ok() - // .flatten() - // .expect("there is not data to be posted; qed"); - // if data.validation_data.is_some() { - // Some(Call::create_order { data }) - // } else { - // None - // } - // } - // fn is_inherent(call: &Self::Call) -> bool { - // matches!(call, Call::create_order { .. }) - // } - // } + #[pallet::inherent] + impl ProvideInherent for Pallet { + type Call = Call; + type Error = MakeFatalError<()>; + + const INHERENT_IDENTIFIER: InherentIdentifier = mp_coretime_on_demand::INHERENT_IDENTIFIER; + fn create_inherent(data: &InherentData) -> Option { + let data: mp_coretime_on_demand::OrderInherentData = data + .get_data(&mp_coretime_on_demand::INHERENT_IDENTIFIER) + .ok() + .flatten() + .expect("there is not data to be posted; qed"); + if data.validation_data.is_some() { + Some(Call::create_order { data }) + } else { + None + } + } + fn is_inherent(call: &Self::Call) -> bool { + matches!(call, Call::create_order { .. }) + } + } #[pallet::call] impl Pallet { @@ -473,13 +472,3 @@ impl Pallet { } } } - -pub trait OrderGasCost { - /// Gas consumed by placing an order in a certain block. - /// - /// Parameters: - /// - `block_number`: The block number of para chain. - fn gas_cost( - block_number: BlockNumberFor, - ) -> Result, DispatchError>; -} diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index a6d867b..62af949 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -91,7 +91,8 @@ use weights::{BlockExecutionWeight, ExtrinsicBaseWeight}; // XCM Imports use cumulus_primitives_core::{AggregateMessageOrigin, ParaId, PersistedValidationData}; pub use pallet_bulk::{self, BulkGasCost}; -pub use pallet_on_demand::{self, OrderGasCost}; +pub use pallet_on_demand; +use pallet_liquidation::OrderGasCost; use xcm::latest::prelude::{ Asset as MultiAsset, BodyId, InteriorLocation as InteriorMultiLocation, Junction::PalletInstance, Location as MultiLocation, @@ -373,13 +374,13 @@ const NORMAL_DISPATCH_RATIO: Perbill = Perbill::from_percent(75); /// We allow for 2 seconds of compute with a 6 second average block time. const MAXIMUM_BLOCK_WEIGHT: Weight = Weight::from_parts( - WEIGHT_REF_TIME_PER_SECOND.saturating_mul(2), + WEIGHT_REF_TIME_PER_SECOND.saturating_div(2), cumulus_primitives_core::relay_chain::MAX_POV_SIZE as u64, ); /// Maximum number of blocks simultaneously accepted by the Runtime, not yet included /// into the relay chain. -const UNINCLUDED_SEGMENT_CAPACITY: u32 = 3; +const UNINCLUDED_SEGMENT_CAPACITY: u32 = 1; /// How many parachain blocks are processed by the relay chain per parent. Limits the /// number of blocks authored per slot. const BLOCK_PROCESSING_VELOCITY: u32 = 1; @@ -666,7 +667,7 @@ impl pallet_aura::Config for Runtime { type AuthorityId = AuraId; type DisabledValidators = (); type MaxAuthorities = ConstU32<100_000>; - type AllowMultipleBlocksPerSlot = ConstBool; + type AllowMultipleBlocksPerSlot = ConstBool; #[cfg(feature = "experimental")] type SlotDuration = ConstU64; } @@ -1021,7 +1022,7 @@ impl pallet_liquidation::Config for Runtime { type Currency = Balances; type XcmSender = xcm_config::XcmRouter; type WeightToFee = WeightToFee; - type OrderGasCost = (); + type OrderGasCost = OrderGasCostHandler; type SystemRatio = SystemRatio; type TreasuryRatio = TreasuryRatio; type OperationRatio = OperationRatio; From 38ce8a725a6ad8dc57146b47a594896ca591eb3c Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sun, 7 Jul 2024 10:02:21 +0800 Subject: [PATCH 26/44] merge multisig,proxy code, resolved conflicts --- Cargo.lock | 2 ++ Cargo.toml | 3 ++ runtime/Cargo.toml | 8 +++++ runtime/src/lib.rs | 82 +++++++++++++++++++++++++++++++++++++++++++--- 4 files changed, 90 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 210e390..0caa1bb 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -9670,11 +9670,13 @@ dependencies = [ "pallet-liquidation", "pallet-message-queue", "pallet-move", + "pallet-multisig", "pallet-pot", "pallet-pot-runtime-api", "pallet-precompile-substrate-utils", "pallet-precompile-transfer-to-magnet", "pallet-preimage", + "pallet-proxy", "pallet-ranked-collective", "pallet-referenda", "pallet-scheduler", diff --git a/Cargo.toml b/Cargo.toml index ce9001a..e57486f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -150,6 +150,9 @@ pallet-transaction-payment-rpc = { git = "https://github.com/paritytech/polkadot pallet-transaction-payment-rpc-runtime-api = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } pallet-utility = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } pallet-whitelist = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false} +pallet-multisig = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false} +pallet-proxy = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false} + # Substrate Utility substrate-prometheus-endpoint = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0" } substrate-build-script-utils = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0" } diff --git a/runtime/Cargo.toml b/runtime/Cargo.toml index 4df2a13..05c9f7d 100644 --- a/runtime/Cargo.toml +++ b/runtime/Cargo.toml @@ -78,6 +78,8 @@ pallet-scheduler = { workspace = true, default-features = false} pallet-insecure-randomness-collective-flip = { workspace = true, default-features = false} pallet-contracts = { workspace = true, default-features = false} pallet-message-queue = { workspace = true, default-features = false } +pallet-multisig = { workspace = true, default-features = false } +pallet-proxy = { workspace = true, default-features = false } # Polkadot pallet-xcm = { workspace = true, default-features = false} @@ -212,6 +214,8 @@ std = [ "pallet-contracts/std", "cumulus-primitives-aura/std", "pallet-move/std", + "pallet-multisig/std", + "pallet-proxy/std", "pallet-bulk/std", "mp-coretime-bulk/std", ] @@ -256,6 +260,8 @@ runtime-benchmarks = [ "pallet-scheduler/runtime-benchmarks", "pallet-contracts/runtime-benchmarks", "pallet-move/runtime-benchmarks", + "pallet-multisig/runtime-benchmarks", + "pallet-proxy/runtime-benchmarks", "pallet-bulk/runtime-benchmarks", ] @@ -310,6 +316,8 @@ try-runtime = [ "pallet-insecure-randomness-collective-flip/try-runtime", "pallet-contracts/try-runtime", "pallet-move/try-runtime", + "pallet-multisig/try-runtime", + "pallet-proxy/try-runtime", ] experimental = [ "pallet-aura/experimental" ] diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index e8859a0..96e3242 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -13,7 +13,7 @@ pub mod xcms; use core::ops::Div; -use codec::{Decode, Encode}; +use codec::{Decode, Encode, MaxEncodedLen}; use cumulus_pallet_parachain_system::RelayNumberMonotonicallyIncreases; use cumulus_pallet_parachain_system::RelayNumberStrictlyIncreases; @@ -30,7 +30,7 @@ use sp_runtime::{ IdentifyAccount, PostDispatchInfoOf, Saturating, UniqueSaturatedInto, Verify, }, transaction_validity::{TransactionSource, TransactionValidity, TransactionValidityError}, - ApplyExtrinsicResult, ConsensusEngineId, DispatchError, MultiSignature, Percent, + ApplyExtrinsicResult, ConsensusEngineId, DispatchError, MultiSignature, Percent, RuntimeDebug, }; use scale_info::prelude::string::String; @@ -54,7 +54,8 @@ use frame_support::{ traits::{ fungible::HoldConsideration, AsEnsureOriginWithArg, ConstBool, ConstU128, ConstU32, ConstU64, ConstU8, Currency, EitherOf, EitherOfDiverse, Everything, FindAuthor, Imbalance, - LinearStoragePrice, OnFinalize, OnUnbalanced, PrivilegeCmp, TransformOrigin, + InstanceFilter, LinearStoragePrice, OnFinalize, OnUnbalanced, PrivilegeCmp, + TransformOrigin, }, weights::{ constants::WEIGHT_REF_TIME_PER_SECOND, ConstantMultiplier, Weight, WeightToFeeCoefficient, @@ -1173,6 +1174,72 @@ impl pallet_move::Config for Runtime { type WeightInfo = pallet_move::weights::SubstrateWeight; } +impl pallet_multisig::Config for Runtime { + type RuntimeEvent = RuntimeEvent; + type RuntimeCall = RuntimeCall; + type Currency = Balances; + type DepositBase = ConstU128<228_000_000_000_000>; + type DepositFactor = ConstU128<32_000_000_000_000>; + type MaxSignatories = ConstU32<20>; + type WeightInfo = pallet_multisig::weights::SubstrateWeight; +} + +#[derive( + Copy, + Clone, + Eq, + PartialEq, + Ord, + PartialOrd, + Encode, + Decode, + RuntimeDebug, + MaxEncodedLen, + scale_info::TypeInfo, +)] +pub enum ProxyType { + Any, + JustTransfer, + JustUtility, +} +impl Default for ProxyType { + fn default() -> Self { + Self::Any + } +} +impl InstanceFilter for ProxyType { + fn filter(&self, c: &RuntimeCall) -> bool { + match self { + ProxyType::Any => true, + ProxyType::JustTransfer => { + matches!( + c, + RuntimeCall::Balances(pallet_balances::Call::transfer_allow_death { .. }) + ) + }, + ProxyType::JustUtility => matches!(c, RuntimeCall::Utility { .. }), + } + } + fn is_superset(&self, o: &Self) -> bool { + self == &ProxyType::Any || self == o + } +} + +impl pallet_proxy::Config for Runtime { + type RuntimeEvent = RuntimeEvent; + type RuntimeCall = RuntimeCall; + type Currency = Balances; + type ProxyType = ProxyType; + type ProxyDepositBase = ConstU128<160_000_000_000_000>; + type ProxyDepositFactor = ConstU128<33_000_000_000_000>; + type MaxProxies = ConstU32<100>; + type CallHasher = BlakeTwo256; + type MaxPending = ConstU32<1000>; + type AnnouncementDepositBase = ConstU128<16_000_000_000_000>; + type AnnouncementDepositFactor = ConstU128<64_000_000_000_000>; + type WeightInfo = pallet_proxy::weights::SubstrateWeight; +} + // Create the runtime by composing the FRAME pallets that were previously configured. construct_runtime!( pub enum Runtime @@ -1237,14 +1304,17 @@ construct_runtime!( Pot: pallet_pot = 61, Assurance: pallet_assurance = 62, Liquidation: pallet_liquidation = 63, - + BulkPallet: pallet_bulk = 64, //Contracts RandomnessCollectiveFlip: pallet_insecure_randomness_collective_flip = 70, Contracts: pallet_contracts = 71, //Move-vm MoveModule: pallet_move = 80, - BulkPallet: pallet_bulk = 72, + + //call util + Multisig: pallet_multisig = 90, + Proxy: pallet_proxy = 91, } ); @@ -1261,6 +1331,8 @@ mod benches { [pallet_bulk, BulkPallet] // [pallet_order, OrderPallet] [pallet_move, MoveModule] + [pallet_multisig, Multisig] + [pallet_proxy, Proxy] ); } From 870755f913ca218035c8972f96d7af6625ed3b8c Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sun, 7 Jul 2024 10:11:53 +0800 Subject: [PATCH 27/44] fix cargo fmt error --- runtime/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index 2bc2b6e..e68f052 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -11,8 +11,8 @@ mod weights; pub mod xcm_config; pub mod xcms; -use core::ops::Div; use codec::{Decode, Encode, MaxEncodedLen}; +use core::ops::Div; use cumulus_pallet_parachain_system::RelayNumberMonotonicallyIncreases; use cumulus_pallet_parachain_system::RelayNumberStrictlyIncreases; From 2098cbc803c860675233f9c636ede56a9eeaf1ce Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Mon, 8 Jul 2024 20:45:25 +0800 Subject: [PATCH 28/44] fix cargo fmt bug --- Cargo.lock | 2 +- runtime/src/lib.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 7764177..81c2681 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -9675,8 +9675,8 @@ dependencies = [ "pallet-liquidation", "pallet-message-queue", "pallet-move", - "pallet-on-demand", "pallet-multisig", + "pallet-on-demand", "pallet-pot", "pallet-pot-runtime-api", "pallet-precompile-substrate-utils", diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index 6d66e1c..9c6d071 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -91,8 +91,8 @@ use weights::{BlockExecutionWeight, ExtrinsicBaseWeight}; // XCM Imports use cumulus_primitives_core::{AggregateMessageOrigin, ParaId, PersistedValidationData}; pub use pallet_bulk::{self, BulkGasCost}; -pub use pallet_on_demand; use pallet_liquidation::OrderGasCost; +pub use pallet_on_demand; use xcm::latest::prelude::{ Asset as MultiAsset, BodyId, InteriorLocation as InteriorMultiLocation, Junction::PalletInstance, Location as MultiLocation, From 2b3b3841852b5955a4518a5a86b3a399e1e560a2 Mon Sep 17 00:00:00 2001 From: toints Date: Tue, 9 Jul 2024 18:52:29 +0800 Subject: [PATCH 29/44] feat: To distribute profits with configurable distribution addresses --- node/src/chain_spec.rs | 16 ++++++- pallets/liquidation/src/lib.rs | 78 ++++++++++++++++++-------------- pallets/liquidation/src/mock.rs | 10 ++-- pallets/liquidation/src/tests.rs | 22 ++++++++- runtime/src/lib.rs | 2 +- 5 files changed, 86 insertions(+), 42 deletions(-) diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index 208ce0f..fa77c5c 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -3,8 +3,9 @@ use parachain_magnet_runtime::{AccountId, AuraId, Signature, EXISTENTIAL_DEPOSIT use sc_chain_spec::{ChainSpecExtension, ChainSpecGroup}; use sc_service::ChainType; use serde::{Deserialize, Serialize}; -use sp_core::{sr25519, Pair, Public, H160, U256}; +use sp_core::{crypto::Ss58Codec, sr25519, Pair, Public, H160, U256}; use sp_runtime::traits::{IdentifyAccount, Verify}; +use sp_runtime::AccountId32; use sp_std::marker::PhantomData; use std::{collections::BTreeMap, str::FromStr}; @@ -166,6 +167,9 @@ pub fn local_testnet_config() -> ChainSpec { .build() } +fn get_account_id_from_address(address: &str) -> AccountId32 { + AccountId32::from_ss58check(address).expect("Invalid address") +} fn testnet_genesis( invulnerables: Vec<(AccountId, AuraId)>, endowed_accounts: Vec, @@ -175,6 +179,11 @@ fn testnet_genesis( let alice = get_from_seed::("Alice"); let bob = get_from_seed::("Bob"); + let op_account1 = + get_account_id_from_address("5GP7etLvS2VLLfUar7Q2TkQkaxHweYnDvrhh3s5hhf8eorPW"); + let op_account2 = + get_account_id_from_address("5CFuj7WxZAyinLxoqAJ8NH4yEEVXUUSHi9LRhodC3HyzHvN4"); + let evm_accounts = { let mut map = BTreeMap::new(); map.insert( @@ -295,7 +304,10 @@ fn testnet_genesis( "adminKey": Some(root.clone()), "systemRatio": 20_000_0000, "treasuryRatio": 33_000_0000, - "operationRatio": 25_000_0000, + "operationRatio": vec![ + (op_account1.clone(), 15_000_0000), + (op_account2.clone(), 10_000_0000) + ], "collatorRatio": 22_000_0000, "minLiquidationThreshold": 20_000_000_000_000_000u128, "profitDistributionCycle": 10, diff --git a/pallets/liquidation/src/lib.rs b/pallets/liquidation/src/lib.rs index 99ce8a3..c03edcf 100644 --- a/pallets/liquidation/src/lib.rs +++ b/pallets/liquidation/src/lib.rs @@ -137,8 +137,9 @@ pub mod pallet { pub type TreasuryRatio = StorageValue<_, u32, ValueQuery>; #[pallet::storage] - #[pallet::getter(fn operation_ratio)] - pub type OperationRatio = StorageValue<_, u32, ValueQuery>; + #[pallet::getter(fn operation_ratios)] + pub type OperationRatios = + StorageMap<_, Twox64Concat, T::AccountId, u32, ValueQuery>; #[pallet::storage] #[pallet::getter(fn collator_ratio)] @@ -164,7 +165,7 @@ pub mod pallet { pub admin_key: Option, pub system_ratio: u32, pub treasury_ratio: u32, - pub operation_ratio: u32, + pub operation_ratios: Vec<(T::AccountId, u32)>, pub collator_ratio: u32, pub min_liquidation_threshold: Balance, pub profit_distribution_cycle: BlockNumberFor, @@ -176,7 +177,7 @@ pub mod pallet { assert!( self.system_ratio + self.treasury_ratio - + self.operation_ratio + + self.operation_ratios.iter().map(|(_, r)| *r).sum::() + self.collator_ratio <= 100 * (PERCENT_UNIT as u32), "Ratio sum must be <= 100%" @@ -195,10 +196,12 @@ pub mod pallet { } SystemRatio::::put(self.system_ratio); TreasuryRatio::::put(self.treasury_ratio); - OperationRatio::::put(self.operation_ratio); CollatorRatio::::put(self.collator_ratio); MinLiquidationThreshold::::put(self.min_liquidation_threshold); ProfitDistributionCycle::::put(self.profit_distribution_cycle); + for (account, ratio) in &self.operation_ratios { + OperationRatios::::insert(account, ratio); + } } } @@ -233,8 +236,8 @@ pub mod pallet { /// Set treasury ratio TreasuryRatioSet(u32), - /// Set operation ratio - OperationRatioSet(u32), + /// Set operation ratio for a specific account + OperationRatioSet(T::AccountId, u32), ///Set collator ratio CollatorRatioSet(u32), @@ -475,6 +478,7 @@ pub mod pallet { Error::::GetPotAccountError })?; + /* let operation_account = pallet_pot::Pallet::::ensure_pot( T::OperationAccountName::get(), ) @@ -482,17 +486,18 @@ pub mod pallet { log::error!("get maintenance account err:{:?}", err); Error::::GetPotAccountError })?; + */ - let system_ratio = SystemRatio::::get(); + //let system_ratio = SystemRatio::::get(); let treasury_ratio = TreasuryRatio::::get(); - let operation_ratio = OperationRatio::::get(); + let collators_ratio = CollatorRatio::::get(); + //let total_operation_ratio: u32 = OperationRatios::::iter().map(|(_, r)| r).sum(); let treasury_amount = (treasury_ratio as u128) / PERCENT_UNIT * total_profit / PARACHAIN_TO_RELAYCHAIN_UNIT; - let operation_amount = (operation_ratio as u128) / PERCENT_UNIT * total_profit; - let system_amount = (system_ratio as u128) / PERCENT_UNIT * total_profit; - let total_collators_profit = - total_profit.saturating_sub(treasury_amount + operation_amount + system_amount); + //let operation_amount = (operation_ratio as u128) / PERCENT_UNIT * total_profit; + //let system_amount = (system_ratio as u128) / PERCENT_UNIT * total_profit; + let total_collators_profit = (collators_ratio as u128) / PERCENT_UNIT * total_profit; let origin: OriginFor = frame_system::RawOrigin::Signed(treasury_account.clone()).into(); @@ -510,9 +515,12 @@ pub mod pallet { transfers.push((treasury_account, treasury_account_profit)); */ - let operation_account_profit = - operation_amount.try_into().unwrap_or_else(|_| Zero::zero()); - transfers.push((operation_account, operation_account_profit)); + for (operation_account, ratio) in OperationRatios::::iter() { + let operation_amount = (ratio as u128) / PERCENT_UNIT * total_profit; + let operation_account_profit = + operation_amount.try_into().unwrap_or_else(|_| Zero::zero()); + transfers.push((operation_account, operation_account_profit)); + } for (collator, collator_cost) in CollatorRealGasCosts::::iter() { let collator_ratio = Percent::from_rational(collator_cost, total_cost); @@ -612,7 +620,7 @@ pub mod pallet { ensure_root_or_admin::(origin)?; let treasury_ratio = TreasuryRatio::::get(); - let operation_ratio = OperationRatio::::get(); + let operation_ratio = OperationRatios::::iter().map(|(_, r)| r).sum(); let collator_ratio = CollatorRatio::::get(); let total_ratio = treasury_ratio + ratio + operation_ratio + collator_ratio; @@ -636,7 +644,7 @@ pub mod pallet { ensure_root_or_admin::(origin)?; let system_ratio = SystemRatio::::get(); - let operation_ratio = OperationRatio::::get(); + let operation_ratio = OperationRatios::::iter().map(|(_, r)| r).sum(); let collator_ratio = CollatorRatio::::get(); let total_ratio = system_ratio + ratio + operation_ratio + collator_ratio; @@ -657,25 +665,29 @@ pub mod pallet { #[pallet::call_index(3)] #[pallet::weight(Weight::from_parts(10_000, 0) + T::DbWeight::get().writes(1))] - pub fn set_operation_ratio(origin: OriginFor, ratio: u32) -> DispatchResultWithPostInfo { + pub fn set_operation_ratio( + origin: OriginFor, + operation_account: T::AccountId, + ratio: u32, + ) -> DispatchResultWithPostInfo { ensure_root_or_admin::(origin)?; let system_ratio = SystemRatio::::get(); let treasury_ratio = TreasuryRatio::::get(); let collator_ratio = CollatorRatio::::get(); - - let total_ratio = system_ratio + treasury_ratio + ratio + collator_ratio; - log::info!("3 -+-+-+-+-+ set operation ratio, total ratio:{:?}, system_ratio:{:?}, treasury_ratio:{:?}, collator_ratio:{:?}, operation_ratio:{:?}", - total_ratio, system_ratio, treasury_ratio, collator_ratio, ratio); - ensure_total_ratio_not_exceed_one::( - system_ratio, - treasury_ratio, - ratio, - collator_ratio, - )?; - - OperationRatio::::put(ratio); - Self::deposit_event(Event::OperationRatioSet(ratio)); + let total_existing_operation_ratio: u32 = + OperationRatios::::iter().map(|(_, r)| r).sum(); + let total_ratio = system_ratio + + treasury_ratio + collator_ratio + + total_existing_operation_ratio + + ratio; + log::info!("3 -+-+-+-+-+ set operation ratio, total ratio:{:?}, system_ratio:{:?}, treasury_ratio:{:?}, collator_ratio:{:?}, operation account:{:?}, op_ratio:{:?}", + total_ratio, system_ratio, treasury_ratio, collator_ratio, operation_account, ratio); + + ensure!((total_ratio as u128) <= 100 * PERCENT_UNIT, Error::::InvalidRatio); + + OperationRatios::::insert(operation_account.clone(), ratio); + Self::deposit_event(Event::OperationRatioSet(operation_account, ratio)); Ok(Pays::No.into()) } @@ -686,7 +698,7 @@ pub mod pallet { let system_ratio = SystemRatio::::get(); let treasury_ratio = TreasuryRatio::::get(); - let operation_ratio = OperationRatio::::get(); + let operation_ratio = OperationRatios::::iter().map(|(_, r)| r).sum(); let total_ratio = system_ratio + treasury_ratio + ratio + operation_ratio; log::info!("4. *********** set collator ratio, total ratio:{:?}, system_ratio:{:?}, treasury_ratio:{:?}, operation_ratio:{:?}, collator_ratio:{:?}", diff --git a/pallets/liquidation/src/mock.rs b/pallets/liquidation/src/mock.rs index 3f8dfb1..f1edee8 100644 --- a/pallets/liquidation/src/mock.rs +++ b/pallets/liquidation/src/mock.rs @@ -310,7 +310,7 @@ pub struct ExtBuilder { existential_deposit: u128, system_ratio: u32, treasury_ratio: u32, - operation_ratio: u32, + operation_ratios: Vec<(AccountId, u32)>, collator_ratio: u32, min_liquidation_threshold: Balance, profit_distribution_cycle: u64, @@ -322,7 +322,7 @@ impl Default for ExtBuilder { existential_deposit: 1, system_ratio: 20_000_0000, treasury_ratio: 33_000_0000, - operation_ratio: 25_000_0000, + operation_ratios: vec![(AccountId32::new([1u8; 32]), 25_000_000)], collator_ratio: 22_000_0000, min_liquidation_threshold: MILLIUNIT * 20, profit_distribution_cycle: 10, @@ -346,8 +346,8 @@ impl ExtBuilder { self } - pub fn operation_ratio(mut self, ratio: u32) -> Self { - self.operation_ratio = ratio; + pub fn operation_ratio(mut self, ratio: Vec<(AccountId, u32)>) -> Self { + self.operation_ratios = ratio; self } @@ -378,7 +378,7 @@ impl ExtBuilder { admin_key: Some(SYSTEM_ACCOUNT), system_ratio: self.system_ratio, treasury_ratio: self.treasury_ratio, - operation_ratio: self.operation_ratio, + operation_ratio: self.operation_ratios.clone(), collator_ratio: self.collator_ratio, min_liquidation_threshold: self.min_liquidation_threshold, profit_distribution_cycle: self.profit_distribution_cycle, diff --git a/pallets/liquidation/src/tests.rs b/pallets/liquidation/src/tests.rs index 9e5b1c8..90e50e3 100644 --- a/pallets/liquidation/src/tests.rs +++ b/pallets/liquidation/src/tests.rs @@ -9,7 +9,7 @@ fn distribute_profit_should_work() { .existential_deposit(100) .system_ratio(20_000_0000) .treasury_ratio(33_000_0000) - .operation_ratio(25_000_0000) + .operation_ratio(vec![(AccountId32::new([1u8; 32]), 25_000_0000)]) .collator_ratio(22_000_0000) .min_liquidation_threshold(20_000_000_000) .profit_distribution_cycle(10) @@ -38,3 +38,23 @@ fn distribute_profit_should_work() { assert!(>::iter().next().is_none()); }); } + +#[test] +fn set_operation_ratios_should_work() { + ExtBuilder::default().build().execute_with(|| { + let new_ratios = vec![ + (AccountId32::new([3u8; 32]), 30_000_0000), + (AccountId32::new([4u8; 32]), 10_000_0000), + ]; + assert_ok!(Liquidation::set_operation_ratios(RuntimeOrigin::root(), new_ratios.clone())); + for (account, ratio) in new_ratios { + assert_eq!(OperationRatios::::get(account), ratio); + } + + let total_ratio = SystemRatio::::get() + + TreasuryRatio::::get() + + CollatorRatio::::get() + + OperationRatios::::iter().map(|(_, r)| r).sum::(); + assert!(total_ratio <= 100 * PERCENT_UNIT as u32); + }); +} diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index c3d178e..d1613e6 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -1007,7 +1007,7 @@ impl pallet_utility::Config for Runtime { parameter_types! { pub const SystemRatio: Perbill = Perbill::from_percent(20); // 20% for system pub const TreasuryRatio: Perbill = Perbill::from_percent(33); // 33% for treasury - pub const OperationRatio: Perbill = Perbill::from_percent(25); // 25% for maintenance + //pub const OperationRatio: Perbill = Perbill::from_percent(25); // 25% for maintenance pub const ProfitDistributionCycle: BlockNumber = 10; pub const ExistDeposit: Balance = EXISTENTIAL_DEPOSIT; pub const MinLiquidationThreshold: Balance = MILLIUNIT * 20; From 92f3810d0f2d0730cc79e84e60a7bebfde9b9add Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Tue, 9 Jul 2024 21:24:18 +0800 Subject: [PATCH 30/44] Add configuration parameters --- client/coretime/on-demand/src/lib.rs | 44 ++++++++---------- node/src/chain_spec.rs | 5 ++ node/src/service.rs | 42 ----------------- pallets/on-demand/src/lib.rs | 58 +++++++++++------------- primitives/coretime/on-demand/src/lib.rs | 2 +- runtime/src/lib.rs | 13 +----- 6 files changed, 52 insertions(+), 112 deletions(-) diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index 63dccc7..20ec540 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -31,6 +31,7 @@ use cumulus_primitives_core::{ }; use cumulus_relay_chain_interface::{RelayChainInterface, RelayChainResult}; use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; +use mc_coretime_common::is_parathread; use metadata::{CoreAssignment, CoreDescriptor}; use mp_coretime_common::well_known_keys::paras_para_lifecycles; use mp_coretime_on_demand::{ @@ -188,6 +189,7 @@ async fn reach_txpool_threshold( transaction_pool: Arc, height: RelayBlockNumber, snap_txs: Vec, + core_price: Balance, ) -> Option<(bool, OrderType)> where Block: BlockT, @@ -206,6 +208,7 @@ where let mut all_gas_value = Balance::from(0u32); let block_hash = parachain.usage_info().chain.best_hash; let mut back_txs: Vec = vec![]; + loop { let pending_tx = if let Some(pending_tx) = pending_iterator.next() { pending_tx } else { break }; @@ -217,8 +220,10 @@ where .ok()?; all_gas_value = query_fee.final_fee().add(all_gas_value); if transaction_pool.status().ready != 0 { - is_place_order = - parachain.runtime_api().reach_txpool_threshold(block_hash, all_gas_value).ok()?; + is_place_order = parachain + .runtime_api() + .reach_txpool_threshold(block_hash, all_gas_value, core_price) + .ok()?; } log::info!( "tx_fee:{:?},all_fee:{:?},can_order:{:?},status:{:?}", @@ -313,21 +318,7 @@ where PB::Signature: TryFrom> + Member + Codec, ExPool: MaintainedTransactionPool::Hash> + 'static, { - let para_lifecycles_storage = relay_chain - .get_storage_by_key(p_hash, paras_para_lifecycles(para_id).as_slice()) - .await?; - let para_lifecycles = para_lifecycles_storage - .map(|raw| ::decode(&mut &raw[..])) - .transpose()?; - let is_parathread = match para_lifecycles { - Some(lifecycles) => matches!( - lifecycles, - ParaLifecycle::Parathread - | ParaLifecycle::UpgradingParathread - | ParaLifecycle::OffboardingParathread - ), - None => false, - }; + let is_parathread = is_parathread(&relay_chain, p_hash, para_id).await?; if !is_parathread { //parachain mode let mut order_record_local = order_record.lock().await; @@ -400,11 +391,21 @@ where let mut order_record_local = order_record.lock().await; if collator_public.is_some() { //your turn + // get on demand core price + let max_amount = parachain.runtime_api().order_max_amount(hash)?; + let p_spot_price = get_spot_price::(relay_chain.clone(), p_hash).await; + let spot_price; + if p_spot_price.is_some() { + spot_price = p_spot_price.unwrap(); + } else { + spot_price = max_amount; + } let reached = reach_txpool_threshold::<_, _, _, _, PB>( parachain, transaction_pool, height, order_record_local.txs.clone(), + spot_price, ) .await; let mut can_order = false; @@ -442,15 +443,6 @@ where if can_order { if height - order_record_local.relay_height > slot_block { if order_record_local.order_status == OrderStatus::Init { - let max_amount = parachain.runtime_api().order_max_amount(hash)?; - let p_spot_price = - get_spot_price::(relay_chain.clone(), p_hash).await; - let spot_price; - if p_spot_price.is_some() { - spot_price = p_spot_price.unwrap(); - } else { - spot_price = max_amount; - } match order_type { OrderType::Normal => { log::info!( diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index 208ce0f..bd14c8f 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -291,6 +291,11 @@ fn testnet_genesis( "rpcUrl": b"ws://127.0.0.1:8855".to_vec(), "genesisHash": U256::from_str("0x4ea18c8f295ba903acbbed39c70ea0569cf1705fa954a537ffa3b8b7125eaf58").expect("internal U256 is valid; qed") }, + "orderPallet": { + "slotWidth": 2, + "priceLimit": 200000000, + "priceThreshold": 10, + }, "liquidation":{ "adminKey": Some(root.clone()), "systemRatio": 20_000_0000, diff --git a/node/src/service.rs b/node/src/service.rs index ab1cb9a..4378f16 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -573,12 +573,6 @@ fn start_consensus( bulk_mem_record: Arc>, ) -> Result<(), sc_service::Error> { use cumulus_client_consensus_aura::collators::lookahead::{self as aura, Params as AuraParams}; - // use cumulus_client_consensus_aura::collators::basic::{ - // self as basic_aura, Params as BasicAuraParams, - // }; - // use magnet_client_consensus_aura::collators::on_demand::{ - // self as on_demand_aura, Params as BasicAuraParams, - // }; // NOTE: because we use Aura here explicitly, we can use `CollatorSybilResistance::Resistant` // when starting the network. @@ -602,42 +596,6 @@ fn start_consensus( client.clone(), ); let relay_chain_interface_clone = relay_chain_interface.clone(); - // let params = AuraParams { - // create_inherent_data_providers: move |_, ()| { - // let relay_chain_interface = relay_chain_interface.clone(); - // let order_record_clone = order_record.clone(); - // async move { - // let parent_hash = relay_chain_interface.best_block_hash().await?; - // let (relay_parent, validation_data, sequence_number, author_pub) = { - // let order_record_local = order_record_clone.lock().await; - // if order_record_local.validation_data.is_none() { - // (parent_hash, None, order_record_local.sequence_number, None) - // } else { - // ( - // order_record_local.relay_parent.expect("can not get relay_parent hash"), - // order_record_local.validation_data.clone(), - // order_record_local.sequence_number, - // order_record_local.author_pub.clone(), - // ) - // } - // }; - // let order_inherent = magnet_primitives_order::OrderInherentData::create_at( - // relay_parent, - // &relay_chain_interface, - // &validation_data, - // para_id, - // sequence_number, - // &author_pub, - // ) - // .await; - // let order_inherent = order_inherent.ok_or_else(|| { - // Box::::from( - // "Failed to create order inherent", - // ) - // })?; - // Ok(order_inherent) - // } - // }, let params = AuraParams { create_inherent_data_providers: move |_, ()| { let bulk_mem_record_clone = bulk_mem_record.clone(); diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs index 4848c4d..5615a12 100644 --- a/pallets/on-demand/src/lib.rs +++ b/pallets/on-demand/src/lib.rs @@ -47,6 +47,7 @@ use sp_runtime::sp_std::{prelude::*, vec}; use sp_runtime::{traits::Member, RuntimeAppPublic}; pub mod weights; use sp_core::crypto::ByteArray; +use sp_runtime::Perbill; use weights::WeightInfo; #[cfg(test)] mod mock; @@ -77,6 +78,8 @@ pub struct Order { } #[frame_support::pallet] pub mod pallet { + use sp_runtime::Percent; + use super::*; /// Configure the pallet by specifying the parameters and types on which it depends. @@ -97,17 +100,6 @@ pub mod pallet { type UpdateOrigin: EnsureOrigin; type WeightInfo: WeightInfo; - /// The default value of w. - #[pallet::constant] - type SlotWidth: Get; - - /// The max value of place order. - #[pallet::constant] - type OrderMaxAmount: Get>; - - /// The gas threshold required to place an order. - #[pallet::constant] - type TxPoolThreshold: Get>; } #[pallet::pallet] @@ -123,35 +115,20 @@ pub mod pallet { #[pallet::getter(fn current_relay_height)] pub type CurrentRelayHeight = StorageValue<_, u32, ValueQuery>; - #[pallet::type_value] - pub fn SlotWidthOnEmpty() -> u32 { - T::SlotWidth::get() - } - #[pallet::type_value] - pub fn OrderMaxAmountOnEmpty() -> BalanceOf { - T::OrderMaxAmount::get() - } - #[pallet::type_value] - pub fn TxPoolThresholdOnEmpty() -> BalanceOf { - T::TxPoolThreshold::get() - } - /// The order interval is 2^slotwidth. #[pallet::storage] #[pallet::getter(fn slot_width)] - pub(super) type SlotWidth = StorageValue<_, u32, ValueQuery, SlotWidthOnEmpty>; + pub(super) type SlotWidth = StorageValue<_, u32, ValueQuery>; /// The maximum price the user is willing to pay when placing an order. #[pallet::storage] #[pallet::getter(fn order_max_amount)] - pub(super) type OrderMaxAmount = - StorageValue<_, BalanceOf, ValueQuery, OrderMaxAmountOnEmpty>; + pub(super) type OrderMaxAmount = StorageValue<_, BalanceOf, ValueQuery>; /// Gas threshold that triggers order placement. #[pallet::storage] #[pallet::getter(fn txpool_threshold)] - pub(super) type TxPoolThreshold = - StorageValue<_, BalanceOf, ValueQuery, TxPoolThresholdOnEmpty>; + pub(super) type TxPoolThreshold = StorageValue<_, Perbill, ValueQuery>; /// Order Information Map. #[pallet::storage] @@ -165,6 +142,23 @@ pub mod pallet { pub type Block2Sequence = StorageMap<_, Twox64Concat, BlockNumberFor, u64, OptionQuery>; + #[pallet::genesis_config] + #[derive(frame_support::DefaultNoBound)] + pub struct GenesisConfig { + pub slot_width: u32, + pub price_limit: BalanceOf, + pub price_threshold: Perbill, + } + + #[pallet::genesis_build] + impl BuildGenesisConfig for GenesisConfig { + fn build(&self) { + SlotWidth::::put(&self.slot_width); + OrderMaxAmount::::put(&self.price_limit); + TxPoolThreshold::::put(&self.price_threshold); + } + } + #[pallet::event] #[pallet::generate_deposit(pub(super) fn deposit_event)] pub enum Event { @@ -314,7 +308,7 @@ pub mod pallet { origin: OriginFor, slot_width: Option, order_max_amount: Option>, - tx_pool_threshold: Option>, + tx_pool_threshold: Option, ) -> DispatchResultWithPostInfo { T::UpdateOrigin::ensure_origin(origin)?; @@ -455,9 +449,9 @@ impl Pallet { /// /// Parameters: /// - `gas_balance`: The total gas. - pub fn reach_txpool_threshold(gas_balance: BalanceOf) -> bool { + pub fn reach_txpool_threshold(gas_balance: BalanceOf, core_price: BalanceOf) -> bool { let txpool_threshold = TxPoolThreshold::::get(); - gas_balance > txpool_threshold + gas_balance > txpool_threshold * core_price } /// Whether the order with the specified sequence number is executed. diff --git a/primitives/coretime/on-demand/src/lib.rs b/primitives/coretime/on-demand/src/lib.rs index c8d6dfe..70fe44d 100644 --- a/primitives/coretime/on-demand/src/lib.rs +++ b/primitives/coretime/on-demand/src/lib.rs @@ -104,7 +104,7 @@ sp_api::decl_runtime_apis! { para_id:ParaId, )-> Option; - fn reach_txpool_threshold(gas_balance:Balance) -> bool; + fn reach_txpool_threshold(gas_balance:Balance, core_price:Balance) -> bool; fn order_executed(sequence_number:u64) -> bool ; } diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index 9c6d071..1d53888 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -727,12 +727,6 @@ where } } -parameter_types! { - pub const SlotWidth: u32 = 2; - pub const OrderMaxAmount:Balance = 200000000; - pub const TxPoolThreshold:Balance = 3000000000; -} - type EnsureRootOrHalf = EitherOfDiverse< EnsureRoot, pallet_collective::EnsureProportionMoreThan, @@ -743,9 +737,6 @@ impl pallet_on_demand::Config for Runtime { type AuthorityId = AuraId; type Currency = Balances; type UpdateOrigin = EnsureRootOrHalf; - type OrderMaxAmount = OrderMaxAmount; - type SlotWidth = SlotWidth; - type TxPoolThreshold = TxPoolThreshold; type WeightInfo = pallet_on_demand::weights::SubstrateWeight; } pub struct BulkGasCostHandler(); @@ -1707,8 +1698,8 @@ impl_runtime_apis! { OrderPallet::order_placed(relay_storage_proof, validation_data, para_id) } - fn reach_txpool_threshold(gas_balance:Balance) -> bool { - OrderPallet::reach_txpool_threshold(gas_balance) + fn reach_txpool_threshold(gas_balance:Balance, core_price:Balance) -> bool { + OrderPallet::reach_txpool_threshold(gas_balance, core_price) } From 040531670bb9baa3a8b4224a280fd97ae1994272 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Wed, 10 Jul 2024 16:40:03 +0800 Subject: [PATCH 31/44] Refactoring on demand client code --- client/coretime/on-demand/src/lib.rs | 46 ++++++++++--------- node/src/service.rs | 27 +++-------- primitives/coretime/on-demand/src/lib.rs | 28 +++++++++++ .../coretime/on-demand/src/well_known_keys.rs | 11 ++--- 4 files changed, 64 insertions(+), 48 deletions(-) diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index 20ec540..d65533f 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -33,7 +33,6 @@ use cumulus_relay_chain_interface::{RelayChainInterface, RelayChainResult}; use futures::{lock::Mutex, pin_mut, select, FutureExt, Stream, StreamExt}; use mc_coretime_common::is_parathread; use metadata::{CoreAssignment, CoreDescriptor}; -use mp_coretime_common::well_known_keys::paras_para_lifecycles; use mp_coretime_on_demand::{ self, well_known_keys::paras_core_descriptors, @@ -43,7 +42,7 @@ use mp_coretime_on_demand::{ use mp_system::OnRelayChainApi; pub use pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi; use polkadot_primitives::OccupiedCoreAssumption; -use runtime_parachains::{configuration::HostConfiguration, paras::ParaLifecycle}; +use runtime_parachains::configuration::HostConfiguration; use sc_client_api::UsageProvider; use sc_service::TaskManager; use sc_transaction_pool_api::{InPoolTransaction, MaintainedTransactionPool}; @@ -60,7 +59,7 @@ use sp_runtime::{ }, FixedPointNumber, FixedU128, }; -use std::cmp::Ordering; +use std::{cmp::Ordering, net::SocketAddr}; use std::{convert::TryFrom, error::Error, fmt::Debug, sync::Arc}; use submit_order::{build_rpc_for_submit_order, SubmitOrderError}; @@ -117,13 +116,15 @@ async fn start_on_demand( para_id: ParaId, ) -> Option { let active_config_storage = relay_chain.get_storage_by_key(hash, ACTIVE_CONFIG).await.ok()?; + // Get config let p_active_config = active_config_storage .map(|raw| >::decode(&mut &raw[..])) .transpose() .ok()?; - if p_active_config.is_some() { + if let Some(active_config) = p_active_config { let mut result = false; - let cores = p_active_config.unwrap().coretime_cores; + // Get the number of cores. + let cores = active_config.coretime_cores; for core in 0..cores { let key = paras_core_descriptors(polkadot_primitives::CoreIndex(core)); let core_descriptors_storage = @@ -132,14 +133,14 @@ async fn start_on_demand( .map(|raw| >::decode(&mut &raw[..])) .transpose() .ok()?; - if p_core_descriptors.is_some() { - let p_current_work = p_core_descriptors?.current_work; - if p_current_work.is_some() { - let current_work = p_current_work?; + if let Some(core_descriptors) = p_core_descriptors { + let p_current_work = core_descriptors.current_work; + if let Some(current_work) = p_current_work { for (assign, _) in current_work.assignments { if assign == CoreAssignment::Task(para_id.into()) { - return Some(false); + return Some(false); // para chain bulk mode. } else if assign == CoreAssignment::Pool { + // find on demand core result = true } } @@ -148,7 +149,8 @@ async fn start_on_demand( } Some(result) } else { - None + // get config failed + Some(false) } } @@ -286,7 +288,7 @@ where } /// The main processing logic of purchasing core. -async fn handle_new_best_parachain_head( +async fn handle_relaychain_stream( validation_data: PersistedValidationData, height: RelayBlockNumber, parachain: &P, @@ -319,19 +321,18 @@ where ExPool: MaintainedTransactionPool::Hash> + 'static, { let is_parathread = is_parathread(&relay_chain, p_hash, para_id).await?; + if !is_parathread { - //parachain mode + //parachain mode, clear all data. let mut order_record_local = order_record.lock().await; - order_record_local.validation_data = None; - order_record_local.author_pub = None; - order_record_local.relay_parent = None; + order_record_local.reset(); return Ok(()); } else { //parathread let p_on_demand = start_on_demand(relay_chain.clone(), p_hash, para_id).await; - if p_on_demand.is_some() { - let on_demand = p_on_demand.unwrap(); + if let Some(on_demand) = p_on_demand { if !on_demand { + // bulk mode return Ok(()); } } @@ -345,7 +346,7 @@ where Ok(header) => header, Err(err) => return Err(format!("get parachain head error:{:?}", err).into()), }; - + // parachain hash let hash = parachain_head.hash(); let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; let slot_width = parachain.runtime_api().slot_width(hash)?; @@ -548,7 +549,7 @@ async fn relay_chain_notification( h = new_best_heads.next() => { match h { Some((height, head, hash)) => { - let _ = handle_new_best_parachain_head::<_,_,PB,_,_>(head,height, &*parachain,keystore.clone(), relay_chain.clone(), hash, para_id, order_record.clone(),transaction_pool.clone(), url.clone()).await; + let _ = handle_relaychain_stream::<_,_,PB,_,_>(head,height, &*parachain,keystore.clone(), relay_chain.clone(), hash, para_id, order_record.clone(),transaction_pool.clone(), url.clone()).await; }, None => { return; @@ -610,7 +611,7 @@ pub fn spawn_on_demand_order( task_manager: &TaskManager, keystore: KeystorePtr, order_record: Arc>>, - url: String, + relay_rpc: Option, ) -> sc_service::error::Result<()> where Block: BlockT, @@ -634,6 +635,9 @@ where PB::Public: AppPublic + Member + Codec, PB::Signature: TryFrom> + Member + Codec, { + let mut url = String::from("ws://"); + url.push_str(&relay_rpc.expect("Should set rpc address for submit order extrinic").to_string()); + let on_demand_order_task = run_on_demand_task::<_, _, _, PB, _, _>( para_id, parachain.clone(), diff --git a/node/src/service.rs b/node/src/service.rs index 4378f16..7bc5c12 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -243,13 +243,8 @@ async fn start_node_impl( let client = params.client.clone(); let backend = params.backend.clone(); let mut task_manager = params.task_manager; - let mut rpc_address = String::from("ws://"); - rpc_address.push_str( - &polkadot_config - .rpc_addr - .expect("Should set rpc address for submit order extrinic") - .to_string(), - ); + let relay_rpc = polkadot_config.rpc_addr; + let (relay_chain_interface, collator_key) = build_relay_chain_interface( polkadot_config, ¶chain_config, @@ -464,19 +459,9 @@ async fn start_node_impl( sync_service: sync_service.clone(), })?; if validator { - let order_record = - Arc::new(Mutex::new(OrderRecord:: { - relay_parent: None, - relay_height: 0, - relay_base: Default::default(), - relay_base_height: 0, - order_status: OrderStatus::Init, - validation_data: None, - para_id, - sequence_number: 0, - author_pub: None, - txs: vec![], - })); + let order_record = Arc::new(Mutex::new(OrderRecord::< + sp_consensus_aura::sr25519::AuthorityId, + >::new(para_id))); spawn_on_demand_order::<_, _, _, _, sp_consensus_aura::sr25519::AuthorityPair, _>( client.clone(), para_id, @@ -485,7 +470,7 @@ async fn start_node_impl( &task_manager, params.keystore_container.keystore(), order_record.clone(), - rpc_address, + relay_rpc, )?; let bulk_mem_record = Arc::new(Mutex::new(BulkMemRecord { coretime_para_height: 0, items: Vec::new() })); diff --git a/primitives/coretime/on-demand/src/lib.rs b/primitives/coretime/on-demand/src/lib.rs index 70fe44d..b9bf03d 100644 --- a/primitives/coretime/on-demand/src/lib.rs +++ b/primitives/coretime/on-demand/src/lib.rs @@ -83,6 +83,34 @@ pub struct OrderRecord { pub txs: Vec, } +impl OrderRecord { + pub fn new(para_id: ParaId) -> OrderRecord { + OrderRecord { + relay_parent: None, + relay_height: 0, + relay_base: Default::default(), + relay_base_height: 0, + order_status: OrderStatus::Init, + validation_data: None, + para_id, + sequence_number: 0, + author_pub: None, + txs: vec![], + } + } + pub fn reset(&mut self) { + self.relay_parent = None; + self.relay_height = 0; + self.relay_base = Default::default(); + self.relay_base_height = 0; + self.order_status = OrderStatus::Init; + self.validation_data = None; + self.sequence_number = 0; + self.author_pub = None; + self.txs = vec![]; + } +} + sp_api::decl_runtime_apis! { #[api_version(2)] pub trait OrderRuntimeApi where diff --git a/primitives/coretime/on-demand/src/well_known_keys.rs b/primitives/coretime/on-demand/src/well_known_keys.rs index 07cc8be..46804de 100644 --- a/primitives/coretime/on-demand/src/well_known_keys.rs +++ b/primitives/coretime/on-demand/src/well_known_keys.rs @@ -18,12 +18,7 @@ #![cfg_attr(not(feature = "std"), no_std)] use cumulus_primitives_core::relay_chain::CoreIndex; -use { - cumulus_primitives_core::ParaId, - sp_core::Encode, - sp_io::hashing::{twox_256, twox_64}, - sp_std::vec::Vec, -}; +use {sp_core::Encode, sp_io::hashing::twox_256, sp_std::vec::Vec}; pub const SYSTEM_ACCOUNT: &[u8] = &hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da9"]; @@ -52,3 +47,7 @@ pub fn paras_core_descriptors(core_index: CoreIndex) -> Vec { CORE_DESCRIPTORS.iter().chain(twox_256(core_index).iter()).cloned().collect() }) } + +// ParaScheduler AvailabilityCores +pub const AVAILABILITY_CORES: &[u8] = + &hex_literal::hex!["94eadf0156a8ad5156507773d0471e4ab8ebad86f546c7e0b135a4212aace339"]; From f60f2db022ed2c7c8f97196103b3153e878f93c1 Mon Sep 17 00:00:00 2001 From: toints Date: Wed, 10 Jul 2024 16:48:35 +0800 Subject: [PATCH 32/44] fixed: fixed mock run failed --- node/src/chain_spec.rs | 2 +- pallets/liquidation/Cargo.toml | 1 + pallets/liquidation/src/mock.rs | 2 +- pallets/liquidation/src/tests.rs | 9 +++++---- 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index fa77c5c..f3a18e0 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -304,7 +304,7 @@ fn testnet_genesis( "adminKey": Some(root.clone()), "systemRatio": 20_000_0000, "treasuryRatio": 33_000_0000, - "operationRatio": vec![ + "operationRatios": vec![ (op_account1.clone(), 15_000_0000), (op_account2.clone(), 10_000_0000) ], diff --git a/pallets/liquidation/Cargo.toml b/pallets/liquidation/Cargo.toml index f43018b..daecbdb 100644 --- a/pallets/liquidation/Cargo.toml +++ b/pallets/liquidation/Cargo.toml @@ -68,6 +68,7 @@ std = [ "xcm-builder/std", "cumulus-pallet-xcmp-queue/std", "xcm-executor/std", + "sp-consensus-aura/std", ] try-runtime = [ "frame-support/try-runtime", diff --git a/pallets/liquidation/src/mock.rs b/pallets/liquidation/src/mock.rs index f1edee8..a99ef2a 100644 --- a/pallets/liquidation/src/mock.rs +++ b/pallets/liquidation/src/mock.rs @@ -378,7 +378,7 @@ impl ExtBuilder { admin_key: Some(SYSTEM_ACCOUNT), system_ratio: self.system_ratio, treasury_ratio: self.treasury_ratio, - operation_ratio: self.operation_ratios.clone(), + operation_ratios: self.operation_ratios.clone(), collator_ratio: self.collator_ratio, min_liquidation_threshold: self.min_liquidation_threshold, profit_distribution_cycle: self.profit_distribution_cycle, diff --git a/pallets/liquidation/src/tests.rs b/pallets/liquidation/src/tests.rs index 90e50e3..b696985 100644 --- a/pallets/liquidation/src/tests.rs +++ b/pallets/liquidation/src/tests.rs @@ -43,11 +43,12 @@ fn distribute_profit_should_work() { fn set_operation_ratios_should_work() { ExtBuilder::default().build().execute_with(|| { let new_ratios = vec![ - (AccountId32::new([3u8; 32]), 30_000_0000), - (AccountId32::new([4u8; 32]), 10_000_0000), + (AccountId32::new([1u8; 32]), 15_000_0000), + (AccountId32::new([2u8; 32]), 10_000_0000), ]; - assert_ok!(Liquidation::set_operation_ratios(RuntimeOrigin::root(), new_ratios.clone())); - for (account, ratio) in new_ratios { + + for (account, ratio) in new_ratios.clone() { + assert_ok!(Liquidation::set_operation_ratio(RuntimeOrigin::root(), account.clone(), ratio)); assert_eq!(OperationRatios::::get(account), ratio); } From 9f2cb459203370d7586cfeb211705d971c044b86 Mon Sep 17 00:00:00 2001 From: toints Date: Wed, 10 Jul 2024 17:01:37 +0800 Subject: [PATCH 33/44] style: format tests.rs --- pallets/liquidation/src/tests.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pallets/liquidation/src/tests.rs b/pallets/liquidation/src/tests.rs index b696985..6003241 100644 --- a/pallets/liquidation/src/tests.rs +++ b/pallets/liquidation/src/tests.rs @@ -48,7 +48,11 @@ fn set_operation_ratios_should_work() { ]; for (account, ratio) in new_ratios.clone() { - assert_ok!(Liquidation::set_operation_ratio(RuntimeOrigin::root(), account.clone(), ratio)); + assert_ok!(Liquidation::set_operation_ratio( + RuntimeOrigin::root(), + account.clone(), + ratio + )); assert_eq!(OperationRatios::::get(account), ratio); } From a06cb66b9908d7bc2211812caa721d3fd451163a Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Wed, 10 Jul 2024 17:35:53 +0800 Subject: [PATCH 34/44] fix build --- client/coretime/on-demand/src/lib.rs | 3 +++ primitives/coretime/on-demand/src/lib.rs | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index d65533f..b037978 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -351,9 +351,12 @@ where let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; let slot_width = parachain.runtime_api().slot_width(hash)?; let auth_len = authorities.len() as u32; + // The larger the slot width, the longer the rotation time. let idx = (height >> slot_width) % auth_len; + // Randomly select a collator to place an order. let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; let base = 2 as u32; + // Minimum interval for placing an order,calculated in one relaychain block time. let slot_block = base.pow(slot_width); if height % slot_block == 0 { let mut order_record_local = order_record.lock().await; diff --git a/primitives/coretime/on-demand/src/lib.rs b/primitives/coretime/on-demand/src/lib.rs index b9bf03d..1258682 100644 --- a/primitives/coretime/on-demand/src/lib.rs +++ b/primitives/coretime/on-demand/src/lib.rs @@ -95,7 +95,7 @@ impl OrderRecord { para_id, sequence_number: 0, author_pub: None, - txs: vec![], + txs: Vec::new(), } } pub fn reset(&mut self) { @@ -107,7 +107,7 @@ impl OrderRecord { self.validation_data = None; self.sequence_number = 0; self.author_pub = None; - self.txs = vec![]; + self.txs = Vec::new(); } } From aae15dbd14ef07c9789c9dd1899de233a50be743 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Wed, 10 Jul 2024 21:42:18 +0800 Subject: [PATCH 35/44] Refactoring the handle_relaychain_stream method of the on demand client --- client/coretime/on-demand/src/lib.rs | 207 ++++++++++++--------------- 1 file changed, 93 insertions(+), 114 deletions(-) diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index b037978..7c218fa 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -70,7 +70,7 @@ struct EnqueuedOrder { } /// Order type -#[derive(Clone, PartialEq)] +#[derive(Clone, PartialEq, Debug)] pub enum OrderType { /// The mem pool gas reaches the threshold. Normal, @@ -336,10 +336,10 @@ where return Ok(()); } } - let order_record_local = order_record.lock().await; - if order_record_local.relay_height == height { - return Ok(()); - } + // let order_record_local = order_record.lock().await; + // if order_record_local.relay_height == height { + // return Ok(()); + // } } let head = validation_data.clone().parent_head.0; let parachain_head = match <::Header>::decode(&mut &head[..]) { @@ -374,119 +374,98 @@ where validation_data.clone(), para_id, )?; - match order_placed { - Some(author) => { - let mut order_record_local = order_record.lock().await; - order_record_local.relay_parent = Some(p_hash); - order_record_local.relay_height = height; - order_record_local.validation_data = Some(validation_data); - order_record_local.author_pub = Some(author); - order_record_local.para_id = para_id; - let sequence_number = parachain.runtime_api().sequence_number(hash)?; - order_record_local.sequence_number = sequence_number; - order_record_local.txs = get_txs(transaction_pool.clone()).await; - }, - None => { - let sequence_number = parachain.runtime_api().sequence_number(hash)?; - let order_executed = parachain.runtime_api().order_executed(hash, sequence_number)?; - if order_executed { - return Ok(()); + let sequence_number = parachain.runtime_api().sequence_number(hash)?; + // Get information about the OnDemandOrderPlaced event. + if let Some(author) = order_placed { + // Get the event and the account who placed the order + let mut order_record_local = order_record.lock().await; + order_record_local.relay_parent = Some(p_hash); + order_record_local.relay_height = height; + order_record_local.validation_data = Some(validation_data); + order_record_local.author_pub = Some(author); + order_record_local.para_id = para_id; + order_record_local.sequence_number = sequence_number; + order_record_local.txs = get_txs(transaction_pool.clone()).await; + return Ok(()); + } + // Check whether the conditions for placing an order are met, and if so, place the order + + // Check if it is in the ondemand queue, if so, do not place a order. + // key = OnDemandAssignmentProvider OnDemandQueue + let mut exist_order = false; + let on_demand_queue_storage = relay_chain.get_storage_by_key(p_hash, ON_DEMAND_QUEUE).await?; + let on_demand_queue = on_demand_queue_storage + .map(|raw| >::decode(&mut &raw[..])) + .transpose()?; + if let Some(vvs) = on_demand_queue.clone() { + for vv in vvs.into_iter() { + if vv.para_id == para_id { + exist_order = true; + break; } - let mut order_record_local = order_record.lock().await; - if collator_public.is_some() { - //your turn - // get on demand core price - let max_amount = parachain.runtime_api().order_max_amount(hash)?; - let p_spot_price = get_spot_price::(relay_chain.clone(), p_hash).await; - let spot_price; - if p_spot_price.is_some() { - spot_price = p_spot_price.unwrap(); - } else { - spot_price = max_amount; - } - let reached = reach_txpool_threshold::<_, _, _, _, PB>( - parachain, - transaction_pool, - height, - order_record_local.txs.clone(), - spot_price, - ) - .await; - let mut can_order = false; - let mut order_type = OrderType::Normal; - if let Some((reach, o_t)) = reached { - if reach { - order_type = o_t; - let mut exist_order = false; - // key = OnDemandAssignmentProvider OnDemandQueue - let on_demand_queue_storage = - relay_chain.get_storage_by_key(p_hash, ON_DEMAND_QUEUE).await?; - let on_demand_queue = on_demand_queue_storage - .map(|raw| >::decode(&mut &raw[..])) - .transpose()?; - if let Some(vvs) = on_demand_queue.clone() { - for vv in vvs.into_iter() { - if vv.para_id == para_id { - exist_order = true; - break; - } - } - } - if !exist_order { - can_order = true; - } - } else { - let trig_xcm_event = - relay_chain_xcm_event(relay_chain.clone(), para_id, p_hash).await; - if let Some((trig_flag, o_t)) = trig_xcm_event { - can_order = trig_flag; - order_type = o_t; - } - } - } - if can_order { - if height - order_record_local.relay_height > slot_block { - if order_record_local.order_status == OrderStatus::Init { - match order_type { - OrderType::Normal => { - log::info!( - "============normal place order======================" - ); - }, - OrderType::Force => { - log::info!( - "============force place order======================" - ); - }, - OrderType::XCMEvent => { - log::info!("============xcm place order======================"); - }, - } - let order_result = try_place_order::( - order_record_local.relay_base, - keystore, - para_id, - url, - spot_price, - slot_block, - height, - relay_chain.clone(), - order_record_local.relay_base_height, - ) - .await; - log::info!("===========place order completed==============",); - order_record_local.order_status = OrderStatus::Order; - if order_result.is_err() { - log::info!( - "===========place_order error:=============={:?}", - order_result - ); - } - } + } + } + if exist_order { + return Ok(()); + } + // get on demand core price + let max_amount = parachain.runtime_api().order_max_amount(hash)?; + let p_spot_price = get_spot_price::(relay_chain.clone(), p_hash).await; + let spot_price = if let Some(pot_price) = p_spot_price { pot_price } else { max_amount }; + // Check whether the gas of the transaction pool has reached the spot price threshold. + let mut order_record_local = order_record.lock().await; + + let reached = reach_txpool_threshold::<_, _, _, _, PB>( + parachain, + transaction_pool, + height, + order_record_local.txs.clone(), + spot_price, + ) + .await; + let mut can_order = false; + let mut order_type = OrderType::Normal; + if let Some((reach, o_t)) = reached { + if reach { + order_type = o_t; + can_order = true; + } else { + let trig_xcm_event = relay_chain_xcm_event(relay_chain.clone(), para_id, p_hash).await; + if let Some((trig_flag, o_t)) = trig_xcm_event { + can_order = trig_flag; + order_type = o_t; + } + } + } + if collator_public.is_some() { + //your turn + if can_order { + if height - order_record_local.relay_height > slot_block { + if order_record_local.order_status == OrderStatus::Init { + log::info!( + "============place order, type:{:?}======================", + order_type + ); + let order_result = try_place_order::( + order_record_local.relay_base, + keystore, + para_id, + url, + spot_price, + slot_block, + height, + relay_chain.clone(), + order_record_local.relay_base_height, + ) + .await; + log::info!("===========place order completed==============",); + order_record_local.order_status = OrderStatus::Order; + if order_result.is_err() { + log::info!("===========place_order error:=============={:?}", order_result); } } } - }, + } } Ok(()) } From 381e5454986b0fe65558fc25fb351d4ad2f48e15 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Thu, 11 Jul 2024 22:20:05 +0800 Subject: [PATCH 36/44] Refactoring decode function of relaychain event --- Cargo.lock | 2 + client/coretime/on-demand/src/lib.rs | 253 ++++++++---------- client/coretime/on-demand/src/submit_order.rs | 26 +- node/src/service.rs | 13 +- pallets/on-demand/src/lib.rs | 120 +++++---- primitives/coretime/on-demand/Cargo.toml | 5 +- primitives/coretime/on-demand/src/lib.rs | 57 +++- primitives/coretime/on-demand/src/metadata.rs | 92 ++++++- 8 files changed, 319 insertions(+), 249 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 81c2681..6e9e60a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7240,6 +7240,8 @@ dependencies = [ "async-trait", "cumulus-primitives-core", "cumulus-relay-chain-interface", + "frame-support", + "frame-system", "hex-literal", "log", "parity-scale-codec", diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index 7c218fa..2cafc0f 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -156,33 +156,17 @@ async fn start_on_demand( /// Create an order to purchase core. async fn try_place_order( - hash: H256, keystore: KeystorePtr, para_id: ParaId, url: String, max_amount: Balance, - slot_block: u32, - height: RelayBlockNumber, - relay_chain: impl RelayChainInterface + Clone, - number: u32, ) -> Result<(), SubmitOrderError> where Balance: Codec + MaybeDisplay + 'static + Debug + Into, ParaId: From, { let max_amount_128 = max_amount.into(); - build_rpc_for_submit_order( - &url, - para_id, - max_amount_128, - hash, - keystore, - slot_block, - height, - relay_chain, - number, - ) - .await + build_rpc_for_submit_order(&url, para_id, max_amount_128, keystore).await } /// Whether the mem pool reaches the threshold for purchasing cores. @@ -228,9 +212,10 @@ where .ok()?; } log::info!( - "tx_fee:{:?},all_fee:{:?},can_order:{:?},status:{:?}", + "tx_fee:{:?}, all_fee:{:?}, core_price:{:?}, can_order:{:?}, status:{:?}", query_fee.final_fee(), all_gas_value, + core_price, is_place_order, transaction_pool.status() ); @@ -320,27 +305,23 @@ where PB::Signature: TryFrom> + Member + Codec, ExPool: MaintainedTransactionPool::Hash> + 'static, { - let is_parathread = is_parathread(&relay_chain, p_hash, para_id).await?; + // let is_parathread = is_parathread(&relay_chain, p_hash, para_id).await?; - if !is_parathread { - //parachain mode, clear all data. - let mut order_record_local = order_record.lock().await; - order_record_local.reset(); - return Ok(()); - } else { - //parathread - let p_on_demand = start_on_demand(relay_chain.clone(), p_hash, para_id).await; - if let Some(on_demand) = p_on_demand { - if !on_demand { - // bulk mode - return Ok(()); - } - } - // let order_record_local = order_record.lock().await; - // if order_record_local.relay_height == height { - // return Ok(()); - // } - } + // if !is_parathread { + // //parachain mode, clear all data. + // let mut order_record_local = order_record.lock().await; + // order_record_local.reset(); + // return Ok(()); + // } else { + // //parathread + // let p_on_demand = start_on_demand(relay_chain.clone(), p_hash, para_id).await; + // if let Some(on_demand) = p_on_demand { + // if !on_demand { + // // bulk mode + // return Ok(()); + // } + // } + // } let head = validation_data.clone().parent_head.0; let parachain_head = match <::Header>::decode(&mut &head[..]) { Ok(header) => header, @@ -348,22 +329,16 @@ where }; // parachain hash let hash = parachain_head.hash(); - let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; - let slot_width = parachain.runtime_api().slot_width(hash)?; - let auth_len = authorities.len() as u32; - // The larger the slot width, the longer the rotation time. - let idx = (height >> slot_width) % auth_len; - // Randomly select a collator to place an order. - let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; - let base = 2 as u32; - // Minimum interval for placing an order,calculated in one relaychain block time. - let slot_block = base.pow(slot_width); - if height % slot_block == 0 { - let mut order_record_local = order_record.lock().await; - order_record_local.relay_base = p_hash; - order_record_local.relay_base_height = height; - order_record_local.order_status = OrderStatus::Init; - } + // let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; + // let slot_width = parachain.runtime_api().slot_width(hash)?; + // let auth_len = authorities.len() as u32; + // // The larger the slot width, the longer the rotation time. + // let idx = (height >> slot_width) % auth_len; + // // Randomly select a collator to place an order. + // let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; + // let base = 2 as u32; + // // Minimum interval for placing an order,calculated in one relaychain block time. + // let slot_block = base.pow(slot_width); let mut relevant_keys = Vec::new(); //System Events relevant_keys.push(SYSTEM_EVENTS.to_vec()); @@ -374,99 +349,87 @@ where validation_data.clone(), para_id, )?; - let sequence_number = parachain.runtime_api().sequence_number(hash)?; - // Get information about the OnDemandOrderPlaced event. - if let Some(author) = order_placed { - // Get the event and the account who placed the order - let mut order_record_local = order_record.lock().await; - order_record_local.relay_parent = Some(p_hash); - order_record_local.relay_height = height; - order_record_local.validation_data = Some(validation_data); - order_record_local.author_pub = Some(author); - order_record_local.para_id = para_id; - order_record_local.sequence_number = sequence_number; - order_record_local.txs = get_txs(transaction_pool.clone()).await; - return Ok(()); - } - // Check whether the conditions for placing an order are met, and if so, place the order + // let sequence_number = parachain.runtime_api().sequence_number(hash)?; + // // Get information about the OnDemandOrderPlaced event. + // if let Some(author) = order_placed { + // log::info!("============find order============="); + // // Get the event and the account who placed the order + // let mut order_record_local = order_record.lock().await; + // order_record_local.relay_parent = Some(p_hash); + // order_record_local.relay_height = height; + // order_record_local.validation_data = Some(validation_data); + // order_record_local.author_pub = Some(author); + // order_record_local.sequence_number = sequence_number; + // order_record_local.txs = get_txs(transaction_pool.clone()).await; + // return Ok(()); + // } + // // Check whether the conditions for placing an order are met, and if so, place the order - // Check if it is in the ondemand queue, if so, do not place a order. - // key = OnDemandAssignmentProvider OnDemandQueue - let mut exist_order = false; - let on_demand_queue_storage = relay_chain.get_storage_by_key(p_hash, ON_DEMAND_QUEUE).await?; - let on_demand_queue = on_demand_queue_storage - .map(|raw| >::decode(&mut &raw[..])) - .transpose()?; - if let Some(vvs) = on_demand_queue.clone() { - for vv in vvs.into_iter() { - if vv.para_id == para_id { - exist_order = true; - break; - } - } - } - if exist_order { - return Ok(()); - } - // get on demand core price - let max_amount = parachain.runtime_api().order_max_amount(hash)?; - let p_spot_price = get_spot_price::(relay_chain.clone(), p_hash).await; - let spot_price = if let Some(pot_price) = p_spot_price { pot_price } else { max_amount }; - // Check whether the gas of the transaction pool has reached the spot price threshold. - let mut order_record_local = order_record.lock().await; + // // Check if it is in the ondemand queue, if so, do not place a order. + // // key = OnDemandAssignmentProvider OnDemandQueue + // let mut exist_order = false; + // let on_demand_queue_storage = relay_chain.get_storage_by_key(p_hash, ON_DEMAND_QUEUE).await?; + // let on_demand_queue = on_demand_queue_storage + // .map(|raw| >::decode(&mut &raw[..])) + // .transpose()?; + // if let Some(vvs) = on_demand_queue.clone() { + // for vv in vvs.into_iter() { + // if vv.para_id == para_id { + // exist_order = true; + // break; + // } + // } + // } + // if exist_order { + // return Ok(()); + // } + // // get on demand core price + // let max_amount = parachain.runtime_api().order_max_amount(hash)?; + // let p_spot_price = get_spot_price::(relay_chain.clone(), p_hash).await; + // let spot_price = if let Some(pot_price) = p_spot_price { pot_price } else { max_amount }; + // // Check whether the gas of the transaction pool has reached the spot price threshold. + // let mut order_record_local = order_record.lock().await; - let reached = reach_txpool_threshold::<_, _, _, _, PB>( - parachain, - transaction_pool, - height, - order_record_local.txs.clone(), - spot_price, - ) - .await; - let mut can_order = false; - let mut order_type = OrderType::Normal; - if let Some((reach, o_t)) = reached { - if reach { - order_type = o_t; - can_order = true; - } else { - let trig_xcm_event = relay_chain_xcm_event(relay_chain.clone(), para_id, p_hash).await; - if let Some((trig_flag, o_t)) = trig_xcm_event { - can_order = trig_flag; - order_type = o_t; - } - } - } - if collator_public.is_some() { - //your turn - if can_order { - if height - order_record_local.relay_height > slot_block { - if order_record_local.order_status == OrderStatus::Init { - log::info!( - "============place order, type:{:?}======================", - order_type - ); - let order_result = try_place_order::( - order_record_local.relay_base, - keystore, - para_id, - url, - spot_price, - slot_block, - height, - relay_chain.clone(), - order_record_local.relay_base_height, - ) - .await; - log::info!("===========place order completed==============",); - order_record_local.order_status = OrderStatus::Order; - if order_result.is_err() { - log::info!("===========place_order error:=============={:?}", order_result); - } - } - } - } - } + // let reached = reach_txpool_threshold::<_, _, _, _, PB>( + // parachain, + // transaction_pool, + // height, + // order_record_local.txs.clone(), + // spot_price, + // ) + // .await; + // let mut can_order = false; + // let mut order_type = OrderType::Normal; + // if let Some((reach, o_t)) = reached { + // if reach { + // order_type = o_t; + // can_order = true; + // } else { + // let trig_xcm_event = relay_chain_xcm_event(relay_chain.clone(), para_id, p_hash).await; + // if let Some((trig_flag, o_t)) = trig_xcm_event { + // can_order = trig_flag; + // order_type = o_t; + // } + // } + // } + // if collator_public.is_some() { + // //your turn + // if can_order { + // if height - order_record_local.relay_height > slot_block { + // if order_record_local.order_status == OrderStatus::Init { + // log::info!("============place order, type:{:?}", order_type); + // let order_result = + // try_place_order::(keystore, para_id, url, spot_price).await; + // order_record_local.order_status = OrderStatus::Order; + // if order_result.is_ok() { + // log::info!("===========place order successfully",); + // } else { + // log::info!("===========place order error:{:?}", order_result); + // } + // } + // } + // } + // } Ok(()) } diff --git a/client/coretime/on-demand/src/submit_order.rs b/client/coretime/on-demand/src/submit_order.rs index af49da7..dc77410 100644 --- a/client/coretime/on-demand/src/submit_order.rs +++ b/client/coretime/on-demand/src/submit_order.rs @@ -20,33 +20,20 @@ //! use crate::metadata; -use cumulus_primitives_core::{ - relay_chain::BlockId, relay_chain::BlockNumber as RelayBlockNumber, ParaId, -}; -use cumulus_relay_chain_interface::{RelayChainInterface, RelayChainResult}; +use cumulus_primitives_core::ParaId; use sp_application_crypto::AppCrypto; use sp_core::ByteArray; -use sp_core::H256; use sp_keystore::KeystorePtr; use sp_runtime::{ traits::{IdentifyAccount, Verify}, MultiSignature as SpMultiSignature, }; -use subxt::client::OfflineClientT; -use subxt::{ - config::polkadot::PolkadotExtrinsicParamsBuilder as Params, tx::Signer, utils::MultiSignature, - Config, OnlineClient, PolkadotConfig, -}; +use subxt::{tx::Signer, utils::MultiSignature, Config, OnlineClient, PolkadotConfig}; #[derive(Debug)] pub enum SubmitOrderError { - RPCUrlError, RPCConnectError, RPCCallException, - NonceGetError, - StorageGetError, - GetBlockError, - GetHeadError, } #[derive(Clone, Copy, PartialEq, Eq)] @@ -116,12 +103,7 @@ pub async fn build_rpc_for_submit_order( url: &str, para_id: ParaId, max_amount: u128, - hash: H256, keystore: KeystorePtr, - slot_block: u32, - height: RelayBlockNumber, - relay_chain: impl RelayChainInterface + Clone, - number: u32, ) -> Result<(), SubmitOrderError> { let client = OnlineClient::::from_url(url) .await @@ -131,10 +113,8 @@ pub async fn build_rpc_for_submit_order( let signer_keystore = SignerKeystore::::new(keystore.clone()); - // let tx_params = Params::new().mortal_unchecked(number.into(), hash , slot_block.into()).build(); - let submit_result = client.tx().sign_and_submit_default(&place_order, &signer_keystore).await; - log::info!("submit_result:{:?},{:?},{:?}", submit_result, height, hash); + log::info!("submit_result:{:?}", submit_result); submit_result.map_err(|_e| SubmitOrderError::RPCCallException)?; Ok(()) diff --git a/node/src/service.rs b/node/src/service.rs index 7bc5c12..e195889 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -54,10 +54,8 @@ use mc_coretime_bulk::spawn_bulk_task; use mc_coretime_on_demand::spawn_on_demand_order; use mp_coretime_bulk::BulkMemRecord; use mp_coretime_bulk::BulkStatus; -use mp_coretime_on_demand::{OrderRecord, OrderStatus}; -use sp_core::ByteArray; -use sp_runtime::AccountId32; -use sp_trie::StorageProof; +use mp_coretime_on_demand::OrderRecord; + /// Native executor type. pub struct ParachainNativeExecutor; @@ -459,9 +457,8 @@ async fn start_node_impl( sync_service: sync_service.clone(), })?; if validator { - let order_record = Arc::new(Mutex::new(OrderRecord::< - sp_consensus_aura::sr25519::AuthorityId, - >::new(para_id))); + let order_record = + Arc::new(Mutex::new(OrderRecord::::new())); spawn_on_demand_order::<_, _, _, _, sp_consensus_aura::sr25519::AuthorityPair, _>( client.clone(), para_id, @@ -630,7 +627,7 @@ fn start_consensus( "Failed to create bulk inherent", ) })?; - let parent_hash = relay_chain_interface.best_block_hash().await?; + let parent_hash = relay_chain_interface.finalized_block_hash().await?; let (relay_parent, validation_data, sequence_number, author_pub) = { let order_record_local = order_record_clone.lock().await; if order_record_local.validation_data.is_none() { diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs index 5615a12..e788516 100644 --- a/pallets/on-demand/src/lib.rs +++ b/pallets/on-demand/src/lib.rs @@ -27,9 +27,7 @@ #![cfg_attr(not(feature = "std"), no_std)] use codec::{Decode, MaxEncodedLen}; -use cumulus_pallet_parachain_system::{ - relay_state_snapshot::Error as Relay_Error, RelayChainStateProof, -}; +use cumulus_pallet_parachain_system::RelayChainStateProof; use frame_support::{ dispatch::DispatchResultWithPostInfo, dispatch::PostDispatchInfo, pallet_prelude::*, traits::Currency, @@ -39,6 +37,7 @@ use frame_system::{self, EventRecord}; use mp_coretime_on_demand::{ metadata::{BalancesEvent, OnDemandEvent, RelaychainRuntimeEvent}, well_known_keys::SYSTEM_EVENTS, + MyEventRecord, }; pub use pallet::*; use primitives::Balance; @@ -342,63 +341,66 @@ impl Pallet { let relay_storage_rooted_proof = RelayChainStateProof::new(para_id, relay_storage_root, relay_storage_proof) .expect("Invalid relay chain state proof"); - let head_data = relay_storage_rooted_proof - .read_entry::>>>( - SYSTEM_EVENTS, - None, - ) - .ok()?; - let v_price: Vec = head_data - .iter() - .filter_map(|item| { - if let RelaychainRuntimeEvent::OnDemandAssignmentProvider( - OnDemandEvent::OnDemandOrderPlaced { para_id: pid, spot_price: sprice }, - ) = &item.event - { - if pid.encode() == para_id.encode() { - Some(*sprice) - } else { - None - } - } else { - None - } - }) - .collect(); - let orderer: Vec<(T::AuthorityId, u128)> = v_price - .iter() - .filter_map(|item| { - let mut orderer = None; - let _: Vec<_> = head_data - .iter() - .filter_map(|event| { - if let RelaychainRuntimeEvent::Balances(BalancesEvent::Withdraw { - who: ref order, - amount: eprice, - }) = event.event - { - if eprice == *item { - orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { - Ok(order) => Some((order, eprice)), - Err(_) => None, - }; - Some(()) - } else { - None - } - } else { - None - } - }) - .collect(); - orderer - }) - .collect(); - if orderer.len() > 0 { - Some(orderer[0].clone()) - } else { - None + let r_head_data = relay_storage_rooted_proof.read_entry::>, + >>(SYSTEM_EVENTS, None); + log::info!("head_data:{:?}", r_head_data); + let head_data = r_head_data.ok()?; + for hdata in head_data.iter() { + log::info!("hdata:{:?}", hdata); } + // let v_price: Vec = head_data + // .iter() + // .filter_map(|item| { + // if let RelaychainRuntimeEvent::OnDemandAssignmentProvider( + // OnDemandEvent::OnDemandOrderPlaced { para_id: pid, spot_price: sprice }, + // ) = &item.event + // { + // if pid.encode() == para_id.encode() { + // Some(*sprice) + // } else { + // None + // } + // } else { + // None + // } + // }) + // .collect(); + // let orderer: Vec<(T::AuthorityId, u128)> = v_price + // .iter() + // .filter_map(|item| { + // let mut orderer = None; + // let _: Vec<_> = head_data + // .iter() + // .filter_map(|event| { + // if let RelaychainRuntimeEvent::Balances(BalancesEvent::Withdraw { + // who: ref order, + // amount: eprice, + // }) = event.event + // { + // if eprice == *item { + // orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { + // Ok(order) => Some((order, eprice)), + // Err(_) => None, + // }; + // Some(()) + // } else { + // None + // } + // } else { + // None + // } + // }) + // .collect(); + // orderer + // }) + // .collect(); + // if orderer.len() > 0 { + // Some(orderer[0].clone()) + // } else { + // None + // } + None } /// Check whether the account is in the validation of relaychain. diff --git a/primitives/coretime/on-demand/Cargo.toml b/primitives/coretime/on-demand/Cargo.toml index 4f598be..4e65a9d 100644 --- a/primitives/coretime/on-demand/Cargo.toml +++ b/primitives/coretime/on-demand/Cargo.toml @@ -28,7 +28,8 @@ sp-std = { workspace = true, default-features = false } sp-weights = { workspace = true, default-features = false } sp-session = { workspace = true, default-features = false } sp-consensus-grandpa = { workspace = true, default-features = false } - +frame-support = { workspace = true, default-features = false } +frame-system = { workspace = true, default-features = false } [features] default = [ "std" ] std = [ @@ -49,4 +50,6 @@ std = [ "sp-weights/std", "sp-session/std", "sp-consensus-grandpa/std", + "frame-support/std", + "frame-system/std", ] \ No newline at end of file diff --git a/primitives/coretime/on-demand/src/lib.rs b/primitives/coretime/on-demand/src/lib.rs index 1258682..2b584d4 100644 --- a/primitives/coretime/on-demand/src/lib.rs +++ b/primitives/coretime/on-demand/src/lib.rs @@ -65,16 +65,10 @@ pub struct OrderRecord { pub relay_parent: Option, /// Relaychain block height. pub relay_height: RelayBlockNumber, - /// Hash of relaychain block,block number is special. - pub relay_base: PHash, - /// Relaychain block height,block number is special. - pub relay_base_height: RelayBlockNumber, /// Order status pub order_status: OrderStatus, /// Validation data. pub validation_data: Option, - /// Parachain ID. - pub para_id: ParaId, /// Sequence number of order. pub sequence_number: u64, /// Author of order. @@ -84,15 +78,12 @@ pub struct OrderRecord { } impl OrderRecord { - pub fn new(para_id: ParaId) -> OrderRecord { + pub fn new() -> OrderRecord { OrderRecord { relay_parent: None, relay_height: 0, - relay_base: Default::default(), - relay_base_height: 0, order_status: OrderStatus::Init, validation_data: None, - para_id, sequence_number: 0, author_pub: None, txs: Vec::new(), @@ -101,8 +92,6 @@ impl OrderRecord { pub fn reset(&mut self) { self.relay_parent = None; self.relay_height = 0; - self.relay_base = Default::default(); - self.relay_base_height = 0; self.order_status = OrderStatus::Init; self.validation_data = None; self.sequence_number = 0; @@ -137,3 +126,47 @@ sp_api::decl_runtime_apis! { fn order_executed(sequence_number:u64) -> bool ; } } + +use crate::metadata::MyPhase as Phase; +use crate::metadata::OnDemandEvent; +use crate::metadata::RelaychainRuntimeEvent; +use codec::Error; +use codec::Input; +use frame_support::dispatch::Parameter; +use sp_runtime::traits::Member; +#[derive(Encode, TypeInfo, Debug)] +pub struct MyEventRecord { + /// The phase of the block it happened in. + pub phase: Phase, + /// The event itself. + pub event: E, + /// The list of the topics this event has. + pub topics: Vec, +} + +impl Decode for MyEventRecord { + fn decode(input: &mut I) -> Result { + log::info!("==============begin==============="); + let p_phase = Phase::decode(input); + let phase = if let Ok(phase) = p_phase { + log::info!("=============================phase:{:?}", phase); + phase + } else { + Default::default() + }; + let p_event = E::decode(input); + let t_event = if let Ok(event) = p_event { + log::info!("=============================type_info:{:?}", event); + event + } else { + E::default() + }; + + let p_topics = Vec::::decode(input); + let topics = if let Ok(topics) = p_topics { topics } else { Vec::new() }; + log::info!("==============end==============="); + // Add your custom logic here if needed + + Ok(MyEventRecord { phase, event: t_event, topics }) + } +} diff --git a/primitives/coretime/on-demand/src/metadata.rs b/primitives/coretime/on-demand/src/metadata.rs index 82af83c..9990ab8 100644 --- a/primitives/coretime/on-demand/src/metadata.rs +++ b/primitives/coretime/on-demand/src/metadata.rs @@ -1,3 +1,8 @@ +#![cfg_attr(not(feature = "std"), no_std)] + +#[allow(dead_code, unused_imports, non_camel_case_types)] +#[allow(clippy::all)] +#[allow(rustdoc::broken_intra_doc_links)] #[derive( :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, )] @@ -10,13 +15,72 @@ pub enum OnDemandEvent { #[codec(index = 0)] OnDemandOrderPlaced { para_id: Id, spot_price: u128 }, } - +#[derive( + :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, +)] +pub enum BalanceStatus { + #[codec(index = 0)] + Free, + #[codec(index = 1)] + Reserved, +} #[derive( :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, )] pub enum BalancesEvent { + // #[codec(index = 8)] + // Withdraw { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 0)] + Endowed { account: ::sp_core::crypto::AccountId32, free_balance: ::core::primitive::u128 }, + #[codec(index = 1)] + DustLost { account: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 2)] + Transfer { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + BalanceSet { who: ::sp_core::crypto::AccountId32, free: ::core::primitive::u128 }, + #[codec(index = 4)] + Reserved { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 5)] + Unreserved { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 6)] + ReserveRepatriated { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + destination_status: BalanceStatus, + }, + #[codec(index = 7)] + Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, #[codec(index = 8)] Withdraw { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 9)] + Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 10)] + Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 11)] + Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 12)] + Suspended { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 13)] + Restored { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 14)] + Upgraded { who: ::sp_core::crypto::AccountId32 }, + #[codec(index = 15)] + Issued { amount: ::core::primitive::u128 }, + #[codec(index = 16)] + Rescinded { amount: ::core::primitive::u128 }, + #[codec(index = 17)] + Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 18)] + Unlocked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 19)] + Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 20)] + Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, } #[derive( @@ -27,4 +91,30 @@ pub enum RelaychainRuntimeEvent { Balances(BalancesEvent), #[codec(index = 66)] OnDemandAssignmentProvider(OnDemandEvent), + #[codec(index = 255)] + NULL, +} + +impl Default for RelaychainRuntimeEvent { + fn default() -> Self { + RelaychainRuntimeEvent::NULL + } +} + +#[derive( + :: codec::Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, +)] +pub enum MyPhase { + /// Applying an extrinsic. + ApplyExtrinsic(::core::primitive::u32), + /// Finalizing the block. + Finalization, + /// Initializing the block. + Initialization, +} + +impl Default for MyPhase { + fn default() -> Self { + Self::Initialization + } } From 0a44e6e816c93e1317223ee96f7dc2d5037ffc8b Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Fri, 12 Jul 2024 11:04:23 +0800 Subject: [PATCH 37/44] Use the complete relaychian runtime data generated by the tool to fix decoding errors --- client/coretime/on-demand/src/lib.rs | 214 +- pallets/bulk/src/lib.rs | 10 - pallets/bulk/src/mock.rs | 12 +- pallets/liquidation/src/lib.rs | 43 +- pallets/on-demand/src/lib.rs | 176 +- primitives/coretime/on-demand/src/lib.rs | 44 - primitives/coretime/on-demand/src/metadata.rs | 5454 ++++++++++++++++- runtime/src/lib.rs | 6 +- 8 files changed, 5596 insertions(+), 363 deletions(-) diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index 2cafc0f..9f50046 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -305,23 +305,23 @@ where PB::Signature: TryFrom> + Member + Codec, ExPool: MaintainedTransactionPool::Hash> + 'static, { - // let is_parathread = is_parathread(&relay_chain, p_hash, para_id).await?; + let is_parathread = is_parathread(&relay_chain, p_hash, para_id).await?; - // if !is_parathread { - // //parachain mode, clear all data. - // let mut order_record_local = order_record.lock().await; - // order_record_local.reset(); - // return Ok(()); - // } else { - // //parathread - // let p_on_demand = start_on_demand(relay_chain.clone(), p_hash, para_id).await; - // if let Some(on_demand) = p_on_demand { - // if !on_demand { - // // bulk mode - // return Ok(()); - // } - // } - // } + if !is_parathread { + //parachain mode, clear all data. + let mut order_record_local = order_record.lock().await; + order_record_local.reset(); + return Ok(()); + } else { + //parathread + let p_on_demand = start_on_demand(relay_chain.clone(), p_hash, para_id).await; + if let Some(on_demand) = p_on_demand { + if !on_demand { + // bulk mode + return Ok(()); + } + } + } let head = validation_data.clone().parent_head.0; let parachain_head = match <::Header>::decode(&mut &head[..]) { Ok(header) => header, @@ -329,16 +329,20 @@ where }; // parachain hash let hash = parachain_head.hash(); - // let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; - // let slot_width = parachain.runtime_api().slot_width(hash)?; - // let auth_len = authorities.len() as u32; - // // The larger the slot width, the longer the rotation time. - // let idx = (height >> slot_width) % auth_len; - // // Randomly select a collator to place an order. - // let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; - // let base = 2 as u32; - // // Minimum interval for placing an order,calculated in one relaychain block time. - // let slot_block = base.pow(slot_width); + let authorities = parachain.runtime_api().authorities(hash).map_err(Box::new)?; + let slot_width = parachain.runtime_api().slot_width(hash)?; + let auth_len = authorities.len() as u32; + // The larger the slot width, the longer the rotation time. + let idx = (height >> slot_width) % auth_len; + // Randomly select a collator to place an order. + let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; + let base = 2 as u32; + // Minimum interval for placing an order,calculated in one relaychain block time. + let slot_block = base.pow(slot_width); + if height % slot_block == 0 { + let mut order_record_local = order_record.lock().await; + order_record_local.order_status = OrderStatus::Init; + } let mut relevant_keys = Vec::new(); //System Events relevant_keys.push(SYSTEM_EVENTS.to_vec()); @@ -349,87 +353,87 @@ where validation_data.clone(), para_id, )?; - // let sequence_number = parachain.runtime_api().sequence_number(hash)?; - // // Get information about the OnDemandOrderPlaced event. - // if let Some(author) = order_placed { - // log::info!("============find order============="); - // // Get the event and the account who placed the order - // let mut order_record_local = order_record.lock().await; - // order_record_local.relay_parent = Some(p_hash); - // order_record_local.relay_height = height; - // order_record_local.validation_data = Some(validation_data); - // order_record_local.author_pub = Some(author); - // order_record_local.sequence_number = sequence_number; - // order_record_local.txs = get_txs(transaction_pool.clone()).await; - // return Ok(()); - // } - // // Check whether the conditions for placing an order are met, and if so, place the order + let sequence_number = parachain.runtime_api().sequence_number(hash)?; + // Get information about the OnDemandOrderPlaced event. + if let Some(author) = order_placed { + log::info!("============find order============="); + // Get the event and the account who placed the order + let mut order_record_local = order_record.lock().await; + order_record_local.relay_parent = Some(p_hash); + order_record_local.relay_height = height; + order_record_local.validation_data = Some(validation_data); + order_record_local.author_pub = Some(author); + order_record_local.sequence_number = sequence_number; + order_record_local.txs = get_txs(transaction_pool.clone()).await; + return Ok(()); + } + // Check whether the conditions for placing an order are met, and if so, place the order - // // Check if it is in the ondemand queue, if so, do not place a order. - // // key = OnDemandAssignmentProvider OnDemandQueue - // let mut exist_order = false; - // let on_demand_queue_storage = relay_chain.get_storage_by_key(p_hash, ON_DEMAND_QUEUE).await?; - // let on_demand_queue = on_demand_queue_storage - // .map(|raw| >::decode(&mut &raw[..])) - // .transpose()?; - // if let Some(vvs) = on_demand_queue.clone() { - // for vv in vvs.into_iter() { - // if vv.para_id == para_id { - // exist_order = true; - // break; - // } - // } - // } - // if exist_order { - // return Ok(()); - // } - // // get on demand core price - // let max_amount = parachain.runtime_api().order_max_amount(hash)?; - // let p_spot_price = get_spot_price::(relay_chain.clone(), p_hash).await; - // let spot_price = if let Some(pot_price) = p_spot_price { pot_price } else { max_amount }; - // // Check whether the gas of the transaction pool has reached the spot price threshold. - // let mut order_record_local = order_record.lock().await; + // Check if it is in the ondemand queue, if so, do not place a order. + // key = OnDemandAssignmentProvider OnDemandQueue + let mut exist_order = false; + let on_demand_queue_storage = relay_chain.get_storage_by_key(p_hash, ON_DEMAND_QUEUE).await?; + let on_demand_queue = on_demand_queue_storage + .map(|raw| >::decode(&mut &raw[..])) + .transpose()?; + if let Some(vvs) = on_demand_queue.clone() { + for vv in vvs.into_iter() { + if vv.para_id == para_id { + exist_order = true; + break; + } + } + } + if exist_order { + return Ok(()); + } + // get on demand core price + let max_amount = parachain.runtime_api().order_max_amount(hash)?; + let p_spot_price = get_spot_price::(relay_chain.clone(), p_hash).await; + let spot_price = if let Some(pot_price) = p_spot_price { pot_price } else { max_amount }; + // Check whether the gas of the transaction pool has reached the spot price threshold. + let mut order_record_local = order_record.lock().await; - // let reached = reach_txpool_threshold::<_, _, _, _, PB>( - // parachain, - // transaction_pool, - // height, - // order_record_local.txs.clone(), - // spot_price, - // ) - // .await; - // let mut can_order = false; - // let mut order_type = OrderType::Normal; - // if let Some((reach, o_t)) = reached { - // if reach { - // order_type = o_t; - // can_order = true; - // } else { - // let trig_xcm_event = relay_chain_xcm_event(relay_chain.clone(), para_id, p_hash).await; - // if let Some((trig_flag, o_t)) = trig_xcm_event { - // can_order = trig_flag; - // order_type = o_t; - // } - // } - // } - // if collator_public.is_some() { - // //your turn - // if can_order { - // if height - order_record_local.relay_height > slot_block { - // if order_record_local.order_status == OrderStatus::Init { - // log::info!("============place order, type:{:?}", order_type); - // let order_result = - // try_place_order::(keystore, para_id, url, spot_price).await; - // order_record_local.order_status = OrderStatus::Order; - // if order_result.is_ok() { - // log::info!("===========place order successfully",); - // } else { - // log::info!("===========place order error:{:?}", order_result); - // } - // } - // } - // } - // } + let reached = reach_txpool_threshold::<_, _, _, _, PB>( + parachain, + transaction_pool, + height, + order_record_local.txs.clone(), + spot_price, + ) + .await; + let mut can_order = false; + let mut order_type = OrderType::Normal; + if let Some((reach, o_t)) = reached { + if reach { + order_type = o_t; + can_order = true; + } else { + let trig_xcm_event = relay_chain_xcm_event(relay_chain.clone(), para_id, p_hash).await; + if let Some((trig_flag, o_t)) = trig_xcm_event { + can_order = trig_flag; + order_type = o_t; + } + } + } + if collator_public.is_some() { + //your turn + if can_order { + if height - order_record_local.relay_height > slot_block { + if order_record_local.order_status == OrderStatus::Init { + log::info!("============place order, type:{:?}", order_type); + let order_result = + try_place_order::(keystore, para_id, url, spot_price).await; + order_record_local.order_status = OrderStatus::Order; + if order_result.is_ok() { + log::info!("===========place order successfully",); + } else { + log::info!("===========place order error:{:?}", order_result); + } + } + } + } + } Ok(()) } diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index ae41573..05f9b11 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -344,13 +344,3 @@ impl Pallet { relay_chain_state.number } } - -pub trait BulkGasCost { - /// In Bulk mode, the average gas consumed by a block. - /// - /// Parameters: - /// - `block_number`: The block number of para chain. - fn gas_cost( - block_number: BlockNumberFor, - ) -> Result, DispatchError>; -} diff --git a/pallets/bulk/src/mock.rs b/pallets/bulk/src/mock.rs index 555a5e2..ed5d807 100644 --- a/pallets/bulk/src/mock.rs +++ b/pallets/bulk/src/mock.rs @@ -14,7 +14,7 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -use crate::{self as bulk_pallet, BulkGasCost}; +use crate::{self as bulk_pallet}; use cumulus_pallet_parachain_system::{RelayChainState, RelaychainStateProvider}; pub use frame_support::{ construct_runtime, derive_impl, parameter_types, @@ -135,6 +135,16 @@ impl crate::Config for Test { } pub struct BulkGasCostHandler(); +pub trait BulkGasCost { + /// In Bulk mode, the average gas consumed by a block. + /// + /// Parameters: + /// - `block_number`: The block number of para chain. + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError>; +} + impl BulkGasCost for BulkGasCostHandler where T: crate::Config, diff --git a/pallets/liquidation/src/lib.rs b/pallets/liquidation/src/lib.rs index 99ce8a3..a064798 100644 --- a/pallets/liquidation/src/lib.rs +++ b/pallets/liquidation/src/lib.rs @@ -47,15 +47,6 @@ pub mod pallet { use pallet_balances; // use pallet_order::OrderGasCost; use pallet_utility; - pub trait OrderGasCost { - /// Gas consumed by placing an order in a certain block. - /// - /// Parameters: - /// - `block_number`: The block number of para chain. - fn gas_cost( - block_number: BlockNumberFor, - ) -> Result, DispatchError>; - } #[pallet::pallet] #[pallet::without_storage_info] @@ -88,7 +79,7 @@ pub mod pallet { type WeightToFee: WeightToFeePolynomial; ///get real weight cost from coreTime placeOrder pallet - type OrderGasCost: OrderGasCost; + type OrderGasCost: crate::OrderGasCost; /// ED necessitate the account to exist #[pallet::constant] @@ -756,6 +747,16 @@ pub mod pallet { } } +pub trait OrderGasCost { + /// Gas consumed by placing an order in a certain block. + /// + /// Parameters: + /// - `block_number`: The block number of para chain. + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError>; +} + impl OrderGasCost for () where T: frame_system::Config, @@ -767,3 +768,25 @@ where Ok(None) } } + +pub trait BulkGasCost { + /// In Bulk mode, the average gas consumed by a block. + /// + /// Parameters: + /// - `block_number`: The block number of para chain. + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError>; +} + +impl BulkGasCost for () +where + T: frame_system::Config, + T::AccountId: From<[u8; 32]>, +{ + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError> { + Ok(None) + } +} diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs index e788516..13f8923 100644 --- a/pallets/on-demand/src/lib.rs +++ b/pallets/on-demand/src/lib.rs @@ -35,9 +35,8 @@ use frame_support::{ use frame_system::pallet_prelude::*; use frame_system::{self, EventRecord}; use mp_coretime_on_demand::{ - metadata::{BalancesEvent, OnDemandEvent, RelaychainRuntimeEvent}, + metadata::api::{runtime_types, runtime_types::rococo_runtime as polakdot_runtime}, well_known_keys::SYSTEM_EVENTS, - MyEventRecord, }; pub use pallet::*; use primitives::Balance; @@ -77,7 +76,6 @@ pub struct Order { } #[frame_support::pallet] pub mod pallet { - use sp_runtime::Percent; use super::*; @@ -295,31 +293,52 @@ pub mod pallet { } /// Order pallet parameter settings. + /// Set slot width /// It can only be called by accounts with sudo privileges or authorized organization members. /// /// Parameters: /// - `slot_width`: The order interval is 2^slotwidth.. - /// - `order_max_amount`: The maximum price the user is willing to pay when placing an order. - /// - `tx_pool_threshold`: Gas threshold that triggers order placement. #[pallet::call_index(1)] - #[pallet::weight(T::WeightInfo::set_parameter(*slot_width))] - pub fn set_parameter( + #[pallet::weight(0)] + pub fn set_slot_width(origin: OriginFor, slot_width: u32) -> DispatchResultWithPostInfo { + T::UpdateOrigin::ensure_origin(origin)?; + + >::put(slot_width); + Ok(().into()) + } + + /// Order pallet parameter settings. + /// Set price limit + /// It can only be called by accounts with sudo privileges or authorized organization members. + /// + /// Parameters: + /// - `price_limit`: The maximum price the user is willing to pay when placing an order. + #[pallet::call_index(2)] + #[pallet::weight(0)] + pub fn set_price_limit( origin: OriginFor, - slot_width: Option, - order_max_amount: Option>, - tx_pool_threshold: Option, + price_limit: BalanceOf, ) -> DispatchResultWithPostInfo { T::UpdateOrigin::ensure_origin(origin)?; - if let Some(t_slot_width) = slot_width { - >::put(t_slot_width); - } - if let Some(t_order_max_amount) = order_max_amount { - >::put(t_order_max_amount); - } - if let Some(t_tx_pool_threshold) = tx_pool_threshold { - >::put(t_tx_pool_threshold); - } + >::put(price_limit); + Ok(().into()) + } + /// Order pallet parameter settings. + /// Set gas threshold + /// It can only be called by accounts with sudo privileges or authorized organization members. + /// + /// Parameters: + /// - `threshold`: Gas threshold that triggers order placement. + #[pallet::call_index(3)] + #[pallet::weight(0)] + pub fn set_gas_threshold( + origin: OriginFor, + threshold: Perbill, + ) -> DispatchResultWithPostInfo { + T::UpdateOrigin::ensure_origin(origin)?; + + >::put(threshold); Ok(().into()) } } @@ -341,66 +360,67 @@ impl Pallet { let relay_storage_rooted_proof = RelayChainStateProof::new(para_id, relay_storage_root, relay_storage_proof) .expect("Invalid relay chain state proof"); - let r_head_data = relay_storage_rooted_proof.read_entry::>, - >>(SYSTEM_EVENTS, None); - log::info!("head_data:{:?}", r_head_data); - let head_data = r_head_data.ok()?; - for hdata in head_data.iter() { - log::info!("hdata:{:?}", hdata); + let head_data = relay_storage_rooted_proof + .read_entry::>>>( + SYSTEM_EVENTS, + None, + ) + .ok()?; + let v_price: Vec = head_data + .iter() + .filter_map(|item| { + if let polakdot_runtime::RuntimeEvent::OnDemandAssignmentProvider( + runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event::OnDemandOrderPlaced{ + para_id: pid, + spot_price: sprice, + }) = &item.event + { + if pid.encode() == para_id.encode() { + Some(*sprice) + } else { + None + } + } else { + None + } + }) + .collect(); + let orderer: Vec<(T::AuthorityId, u128)> = v_price + .iter() + .filter_map(|item| { + let mut orderer = None; + let _: Vec<_> = head_data + .iter() + .filter_map(|event| { + if let polakdot_runtime::RuntimeEvent::Balances( + runtime_types::pallet_balances::pallet::Event::Withdraw { + who: ref order, + amount: eprice, + }, + ) = event.event + { + if eprice == *item { + orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { + Ok(order) => Some((order, eprice)), + Err(_) => None, + }; + Some(()) + } else { + None + } + } else { + None + } + }) + .collect(); + orderer + }) + .collect(); + if orderer.len() > 0 { + Some(orderer[0].clone()) + } else { + None } - // let v_price: Vec = head_data - // .iter() - // .filter_map(|item| { - // if let RelaychainRuntimeEvent::OnDemandAssignmentProvider( - // OnDemandEvent::OnDemandOrderPlaced { para_id: pid, spot_price: sprice }, - // ) = &item.event - // { - // if pid.encode() == para_id.encode() { - // Some(*sprice) - // } else { - // None - // } - // } else { - // None - // } - // }) - // .collect(); - // let orderer: Vec<(T::AuthorityId, u128)> = v_price - // .iter() - // .filter_map(|item| { - // let mut orderer = None; - // let _: Vec<_> = head_data - // .iter() - // .filter_map(|event| { - // if let RelaychainRuntimeEvent::Balances(BalancesEvent::Withdraw { - // who: ref order, - // amount: eprice, - // }) = event.event - // { - // if eprice == *item { - // orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { - // Ok(order) => Some((order, eprice)), - // Err(_) => None, - // }; - // Some(()) - // } else { - // None - // } - // } else { - // None - // } - // }) - // .collect(); - // orderer - // }) - // .collect(); - // if orderer.len() > 0 { - // Some(orderer[0].clone()) - // } else { - // None - // } - None } /// Check whether the account is in the validation of relaychain. diff --git a/primitives/coretime/on-demand/src/lib.rs b/primitives/coretime/on-demand/src/lib.rs index 2b584d4..5f7f0dc 100644 --- a/primitives/coretime/on-demand/src/lib.rs +++ b/primitives/coretime/on-demand/src/lib.rs @@ -126,47 +126,3 @@ sp_api::decl_runtime_apis! { fn order_executed(sequence_number:u64) -> bool ; } } - -use crate::metadata::MyPhase as Phase; -use crate::metadata::OnDemandEvent; -use crate::metadata::RelaychainRuntimeEvent; -use codec::Error; -use codec::Input; -use frame_support::dispatch::Parameter; -use sp_runtime::traits::Member; -#[derive(Encode, TypeInfo, Debug)] -pub struct MyEventRecord { - /// The phase of the block it happened in. - pub phase: Phase, - /// The event itself. - pub event: E, - /// The list of the topics this event has. - pub topics: Vec, -} - -impl Decode for MyEventRecord { - fn decode(input: &mut I) -> Result { - log::info!("==============begin==============="); - let p_phase = Phase::decode(input); - let phase = if let Ok(phase) = p_phase { - log::info!("=============================phase:{:?}", phase); - phase - } else { - Default::default() - }; - let p_event = E::decode(input); - let t_event = if let Ok(event) = p_event { - log::info!("=============================type_info:{:?}", event); - event - } else { - E::default() - }; - - let p_topics = Vec::::decode(input); - let topics = if let Ok(topics) = p_topics { topics } else { Vec::new() }; - log::info!("==============end==============="); - // Add your custom logic here if needed - - Ok(MyEventRecord { phase, event: t_event, topics }) - } -} diff --git a/primitives/coretime/on-demand/src/metadata.rs b/primitives/coretime/on-demand/src/metadata.rs index 9990ab8..cfbd9bc 100644 --- a/primitives/coretime/on-demand/src/metadata.rs +++ b/primitives/coretime/on-demand/src/metadata.rs @@ -1,120 +1,5350 @@ -#![cfg_attr(not(feature = "std"), no_std)] - #[allow(dead_code, unused_imports, non_camel_case_types)] #[allow(clippy::all)] #[allow(rustdoc::broken_intra_doc_links)] -#[derive( - :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, -)] -pub struct Id(pub u32); - -#[derive( - :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, -)] -pub enum OnDemandEvent { - #[codec(index = 0)] - OnDemandOrderPlaced { para_id: Id, spot_price: u128 }, -} -#[derive( - :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, -)] -pub enum BalanceStatus { - #[codec(index = 0)] - Free, - #[codec(index = 1)] - Reserved, -} -#[derive( - :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, -)] -pub enum BalancesEvent { - // #[codec(index = 8)] - // Withdraw { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 0)] - Endowed { account: ::sp_core::crypto::AccountId32, free_balance: ::core::primitive::u128 }, - #[codec(index = 1)] - DustLost { account: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 2)] - Transfer { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - BalanceSet { who: ::sp_core::crypto::AccountId32, free: ::core::primitive::u128 }, - #[codec(index = 4)] - Reserved { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 5)] - Unreserved { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 6)] - ReserveRepatriated { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - destination_status: BalanceStatus, - }, - #[codec(index = 7)] - Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - Withdraw { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 9)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - Suspended { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 13)] - Restored { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 14)] - Upgraded { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - Unlocked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 19)] - Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, -} - -#[derive( - :: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, -)] -pub enum RelaychainRuntimeEvent { - #[codec(index = 4)] - Balances(BalancesEvent), - #[codec(index = 66)] - OnDemandAssignmentProvider(OnDemandEvent), - #[codec(index = 255)] - NULL, -} - -impl Default for RelaychainRuntimeEvent { - fn default() -> Self { - RelaychainRuntimeEvent::NULL +pub mod api { + #[allow(unused_imports)] + mod root_mod { + pub use super::*; } -} + pub mod runtime_types { + use super::runtime_types; + pub mod rococo_runtime { + use super::runtime_types; + pub mod validator_manager { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + ValidatorsRegistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), + #[codec(index = 1)] + ValidatorsDeregistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), + } + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum ProxyType { + #[codec(index = 0)] + Any, + #[codec(index = 1)] + NonTransfer, + #[codec(index = 2)] + Governance, + #[codec(index = 3)] + IdentityJudgement, + #[codec(index = 4)] + CancelProxy, + #[codec(index = 5)] + Auction, + #[codec(index = 6)] + Society, + #[codec(index = 7)] + OnDemandOrdering, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum RuntimeEvent { + #[codec(index = 0)] + System(runtime_types::frame_system::pallet::Event), + #[codec(index = 3)] + Indices(runtime_types::pallet_indices::pallet::Event), + #[codec(index = 4)] + Balances(runtime_types::pallet_balances::pallet::Event), + #[codec(index = 33)] + TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), + #[codec(index = 7)] + Offences(runtime_types::pallet_offences::pallet::Event), + #[codec(index = 8)] + Session(runtime_types::pallet_session::pallet::Event), + #[codec(index = 10)] + Grandpa(runtime_types::pallet_grandpa::pallet::Event), + #[codec(index = 11)] + ImOnline(runtime_types::pallet_im_online::pallet::Event), + #[codec(index = 13)] + Democracy(runtime_types::pallet_democracy::pallet::Event), + #[codec(index = 14)] + Council(runtime_types::pallet_collective::pallet::Event), + #[codec(index = 15)] + TechnicalCommittee(runtime_types::pallet_collective::pallet::Event2), + #[codec(index = 16)] + PhragmenElection(runtime_types::pallet_elections_phragmen::pallet::Event), + #[codec(index = 17)] + TechnicalMembership(runtime_types::pallet_membership::pallet::Event), + #[codec(index = 18)] + Treasury(runtime_types::pallet_treasury::pallet::Event), + #[codec(index = 19)] + Claims(runtime_types::polkadot_runtime_common::claims::pallet::Event), + #[codec(index = 24)] + Utility(runtime_types::pallet_utility::pallet::Event), + #[codec(index = 25)] + Identity(runtime_types::pallet_identity::pallet::Event), + #[codec(index = 26)] + Society(runtime_types::pallet_society::pallet::Event), + #[codec(index = 27)] + Recovery(runtime_types::pallet_recovery::pallet::Event), + #[codec(index = 28)] + Vesting(runtime_types::pallet_vesting::pallet::Event), + #[codec(index = 29)] + Scheduler(runtime_types::pallet_scheduler::pallet::Event), + #[codec(index = 30)] + Proxy(runtime_types::pallet_proxy::pallet::Event), + #[codec(index = 31)] + Multisig(runtime_types::pallet_multisig::pallet::Event), + #[codec(index = 32)] + Preimage(runtime_types::pallet_preimage::pallet::Event), + #[codec(index = 35)] + Bounties(runtime_types::pallet_bounties::pallet::Event), + #[codec(index = 40)] + ChildBounties(runtime_types::pallet_child_bounties::pallet::Event), + #[codec(index = 36)] + Tips(runtime_types::pallet_tips::pallet::Event), + #[codec(index = 38)] + Nis(runtime_types::pallet_nis::pallet::Event), + #[codec(index = 45)] + NisCounterpartBalances(runtime_types::pallet_balances::pallet::Event2), + #[codec(index = 53)] + ParaInclusion(runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event), + #[codec(index = 56)] + Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Event), + #[codec(index = 60)] + Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event), + #[codec(index = 62)] + ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Event), + #[codec(index = 64)] + MessageQueue(runtime_types::pallet_message_queue::pallet::Event), + #[codec(index = 66)] + OnDemandAssignmentProvider( + runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event, + ), + #[codec(index = 70)] + Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event), + #[codec(index = 71)] + Slots(runtime_types::polkadot_runtime_common::slots::pallet::Event), + #[codec(index = 72)] + Auctions(runtime_types::polkadot_runtime_common::auctions::pallet::Event), + #[codec(index = 73)] + Crowdloan(runtime_types::polkadot_runtime_common::crowdloan::pallet::Event), + #[codec(index = 99)] + XcmPallet(runtime_types::pallet_xcm::pallet::Event), + #[codec(index = 251)] + AssignedSlots( + runtime_types::polkadot_runtime_common::assigned_slots::pallet::Event, + ), + #[codec(index = 252)] + ValidatorManager(runtime_types::rococo_runtime::validator_manager::pallet::Event), + #[codec(index = 254)] + StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::Event), + #[codec(index = 255)] + Sudo(runtime_types::pallet_sudo::pallet::Event), + } + } + pub mod pallet_indices { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + IndexAssigned { + who: ::sp_core::crypto::AccountId32, + index: ::core::primitive::u32, + }, + #[codec(index = 1)] + IndexFreed { index: ::core::primitive::u32 }, + #[codec(index = 2)] + IndexFrozen { + index: ::core::primitive::u32, + who: ::sp_core::crypto::AccountId32, + }, + } + } + } + pub mod pallet_transaction_payment { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + TransactionFeePaid { + who: ::sp_core::crypto::AccountId32, + actual_fee: ::core::primitive::u128, + tip: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_offences { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Offence { + kind: [::core::primitive::u8; 16usize], + timeslot: ::sp_std::vec::Vec<::core::primitive::u8>, + }, + } + } + } + pub mod pallet_session { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewSession { session_index: ::core::primitive::u32 }, + } + } + } + pub mod sp_consensus_grandpa { + use super::runtime_types; + pub mod app { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub runtime_types::sp_core::ed25519::Public); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); + } + } + pub mod pallet_grandpa { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewAuthorities { + authority_set: ::sp_std::vec::Vec<( + runtime_types::sp_consensus_grandpa::app::Public, + ::core::primitive::u64, + )>, + }, + #[codec(index = 1)] + Paused, + #[codec(index = 2)] + Resumed, + } + } + } + pub mod pallet_im_online { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + HeartbeatReceived { + authority_id: runtime_types::pallet_im_online::sr25519::app_sr25519::Public, + }, + #[codec(index = 1)] + AllGood, + #[codec(index = 2)] + SomeOffline { + offline: ::sp_std::vec::Vec<(::sp_core::crypto::AccountId32, ())>, + }, + } + } + pub mod sr25519 { + use super::runtime_types; + pub mod app_sr25519 { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub runtime_types::sp_core::sr25519::Public); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); + } + } + } + pub mod pallet_democracy { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Proposed { + proposal_index: ::core::primitive::u32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 1)] + Tabled { + proposal_index: ::core::primitive::u32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 2)] + ExternalTabled, + #[codec(index = 3)] + Started { + ref_index: ::core::primitive::u32, + threshold: runtime_types::pallet_democracy::vote_threshold::VoteThreshold, + }, + #[codec(index = 4)] + Passed { ref_index: ::core::primitive::u32 }, + #[codec(index = 5)] + NotPassed { ref_index: ::core::primitive::u32 }, + #[codec(index = 6)] + Cancelled { ref_index: ::core::primitive::u32 }, + #[codec(index = 7)] + Delegated { + who: ::sp_core::crypto::AccountId32, + target: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 8)] + Undelegated { account: ::sp_core::crypto::AccountId32 }, + #[codec(index = 9)] + Vetoed { + who: ::sp_core::crypto::AccountId32, + proposal_hash: runtime_types::primitive_types::H256, + until: ::core::primitive::u32, + }, + #[codec(index = 10)] + Blacklisted { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 11)] + Voted { + voter: ::sp_core::crypto::AccountId32, + ref_index: ::core::primitive::u32, + vote: runtime_types::pallet_democracy::vote::AccountVote< + ::core::primitive::u128, + >, + }, + #[codec(index = 12)] + Seconded { + seconder: ::sp_core::crypto::AccountId32, + prop_index: ::core::primitive::u32, + }, + #[codec(index = 13)] + ProposalCanceled { prop_index: ::core::primitive::u32 }, + #[codec(index = 14)] + MetadataSet { + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: runtime_types::primitive_types::H256, + }, + #[codec(index = 15)] + MetadataCleared { + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: runtime_types::primitive_types::H256, + }, + #[codec(index = 16)] + MetadataTransferred { + prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, + owner: runtime_types::pallet_democracy::types::MetadataOwner, + hash: runtime_types::primitive_types::H256, + }, + } + } + pub mod types { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MetadataOwner { + #[codec(index = 0)] + External, + #[codec(index = 1)] + Proposal(::core::primitive::u32), + #[codec(index = 2)] + Referendum(::core::primitive::u32), + } + } + pub mod vote { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AccountVote<_0> { + #[codec(index = 0)] + Standard { vote: runtime_types::pallet_democracy::vote::Vote, balance: _0 }, + #[codec(index = 1)] + Split { aye: _0, nay: _0 }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Vote(pub ::core::primitive::u8); + } + pub mod vote_threshold { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum VoteThreshold { + #[codec(index = 0)] + SuperMajorityApprove, + #[codec(index = 1)] + SuperMajorityAgainst, + #[codec(index = 2)] + SimpleMajority, + } + } + } + pub mod pallet_collective { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Proposed { + account: ::sp_core::crypto::AccountId32, + proposal_index: ::core::primitive::u32, + proposal_hash: runtime_types::primitive_types::H256, + threshold: ::core::primitive::u32, + }, + #[codec(index = 1)] + Voted { + account: ::sp_core::crypto::AccountId32, + proposal_hash: runtime_types::primitive_types::H256, + voted: ::core::primitive::bool, + yes: ::core::primitive::u32, + no: ::core::primitive::u32, + }, + #[codec(index = 2)] + Approved { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 3)] + Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 4)] + Executed { + proposal_hash: runtime_types::primitive_types::H256, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 5)] + MemberExecuted { + proposal_hash: runtime_types::primitive_types::H256, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 6)] + Closed { + proposal_hash: runtime_types::primitive_types::H256, + yes: ::core::primitive::u32, + no: ::core::primitive::u32, + }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event2 { + #[codec(index = 0)] + Proposed { + account: ::sp_core::crypto::AccountId32, + proposal_index: ::core::primitive::u32, + proposal_hash: runtime_types::primitive_types::H256, + threshold: ::core::primitive::u32, + }, + #[codec(index = 1)] + Voted { + account: ::sp_core::crypto::AccountId32, + proposal_hash: runtime_types::primitive_types::H256, + voted: ::core::primitive::bool, + yes: ::core::primitive::u32, + no: ::core::primitive::u32, + }, + #[codec(index = 2)] + Approved { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 3)] + Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 4)] + Executed { + proposal_hash: runtime_types::primitive_types::H256, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 5)] + MemberExecuted { + proposal_hash: runtime_types::primitive_types::H256, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 6)] + Closed { + proposal_hash: runtime_types::primitive_types::H256, + yes: ::core::primitive::u32, + no: ::core::primitive::u32, + }, + } + } + } + pub mod pallet_elections_phragmen { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewTerm { + new_members: ::sp_std::vec::Vec<( + ::sp_core::crypto::AccountId32, + ::core::primitive::u128, + )>, + }, + #[codec(index = 1)] + EmptyTerm, + #[codec(index = 2)] + ElectionError, + #[codec(index = 3)] + MemberKicked { member: ::sp_core::crypto::AccountId32 }, + #[codec(index = 4)] + Renounced { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 5)] + CandidateSlashed { + candidate: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + SeatHolderSlashed { + seat_holder: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_membership { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + MemberAdded, + #[codec(index = 1)] + MemberRemoved, + #[codec(index = 2)] + MembersSwapped, + #[codec(index = 3)] + MembersReset, + #[codec(index = 4)] + KeyChanged, + #[codec(index = 5)] + Dummy, + } + } + } + pub mod pallet_treasury { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Proposed { proposal_index: ::core::primitive::u32 }, + #[codec(index = 1)] + Spending { budget_remaining: ::core::primitive::u128 }, + #[codec(index = 2)] + Awarded { + proposal_index: ::core::primitive::u32, + award: ::core::primitive::u128, + account: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + Rejected { + proposal_index: ::core::primitive::u32, + slashed: ::core::primitive::u128, + }, + #[codec(index = 4)] + Burnt { burnt_funds: ::core::primitive::u128 }, + #[codec(index = 5)] + Rollover { rollover_balance: ::core::primitive::u128 }, + #[codec(index = 6)] + Deposit { value: ::core::primitive::u128 }, + #[codec(index = 7)] + SpendApproved { + proposal_index: ::core::primitive::u32, + amount: ::core::primitive::u128, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 8)] + UpdatedInactive { + reactivated: ::core::primitive::u128, + deactivated: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_identity { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + IdentitySet { who: ::sp_core::crypto::AccountId32 }, + #[codec(index = 1)] + IdentityCleared { + who: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 2)] + IdentityKilled { + who: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 3)] + JudgementRequested { + who: ::sp_core::crypto::AccountId32, + registrar_index: ::core::primitive::u32, + }, + #[codec(index = 4)] + JudgementUnrequested { + who: ::sp_core::crypto::AccountId32, + registrar_index: ::core::primitive::u32, + }, + #[codec(index = 5)] + JudgementGiven { + target: ::sp_core::crypto::AccountId32, + registrar_index: ::core::primitive::u32, + }, + #[codec(index = 6)] + RegistrarAdded { registrar_index: ::core::primitive::u32 }, + #[codec(index = 7)] + SubIdentityAdded { + sub: ::sp_core::crypto::AccountId32, + main: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 8)] + SubIdentityRemoved { + sub: ::sp_core::crypto::AccountId32, + main: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + #[codec(index = 9)] + SubIdentityRevoked { + sub: ::sp_core::crypto::AccountId32, + main: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_society { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Founded { founder: ::sp_core::crypto::AccountId32 }, + #[codec(index = 1)] + Bid { + candidate_id: ::sp_core::crypto::AccountId32, + offer: ::core::primitive::u128, + }, + #[codec(index = 2)] + Vouch { + candidate_id: ::sp_core::crypto::AccountId32, + offer: ::core::primitive::u128, + vouching: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + AutoUnbid { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 4)] + Unbid { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 5)] + Unvouch { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 6)] + Inducted { + primary: ::sp_core::crypto::AccountId32, + candidates: ::sp_std::vec::Vec<::sp_core::crypto::AccountId32>, + }, + #[codec(index = 7)] + SuspendedMemberJudgement { + who: ::sp_core::crypto::AccountId32, + judged: ::core::primitive::bool, + }, + #[codec(index = 8)] + CandidateSuspended { candidate: ::sp_core::crypto::AccountId32 }, + #[codec(index = 9)] + MemberSuspended { member: ::sp_core::crypto::AccountId32 }, + #[codec(index = 10)] + Challenged { member: ::sp_core::crypto::AccountId32 }, + #[codec(index = 11)] + Vote { + candidate: ::sp_core::crypto::AccountId32, + voter: ::sp_core::crypto::AccountId32, + vote: ::core::primitive::bool, + }, + #[codec(index = 12)] + DefenderVote { + voter: ::sp_core::crypto::AccountId32, + vote: ::core::primitive::bool, + }, + #[codec(index = 13)] + NewParams { + params: runtime_types::pallet_society::GroupParams<::core::primitive::u128>, + }, + #[codec(index = 14)] + Unfounded { founder: ::sp_core::crypto::AccountId32 }, + #[codec(index = 15)] + Deposit { value: ::core::primitive::u128 }, + #[codec(index = 16)] + Elevated { + member: ::sp_core::crypto::AccountId32, + rank: ::core::primitive::u32, + }, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct GroupParams<_0> { + pub max_members: ::core::primitive::u32, + pub max_intake: ::core::primitive::u32, + pub max_strikes: ::core::primitive::u32, + pub candidate_deposit: _0, + } + } + pub mod pallet_recovery { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + RecoveryCreated { account: ::sp_core::crypto::AccountId32 }, + #[codec(index = 1)] + RecoveryInitiated { + lost_account: ::sp_core::crypto::AccountId32, + rescuer_account: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 2)] + RecoveryVouched { + lost_account: ::sp_core::crypto::AccountId32, + rescuer_account: ::sp_core::crypto::AccountId32, + sender: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + RecoveryClosed { + lost_account: ::sp_core::crypto::AccountId32, + rescuer_account: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 4)] + AccountRecovered { + lost_account: ::sp_core::crypto::AccountId32, + rescuer_account: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 5)] + RecoveryRemoved { lost_account: ::sp_core::crypto::AccountId32 }, + } + } + } + pub mod pallet_utility { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + BatchInterrupted { + index: ::core::primitive::u32, + error: runtime_types::sp_runtime::DispatchError, + }, + #[codec(index = 1)] + BatchCompleted, + #[codec(index = 2)] + BatchCompletedWithErrors, + #[codec(index = 3)] + ItemCompleted, + #[codec(index = 4)] + ItemFailed { error: runtime_types::sp_runtime::DispatchError }, + #[codec(index = 5)] + DispatchedAs { + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + } + } + } + pub mod pallet_vesting { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + VestingUpdated { + account: ::sp_core::crypto::AccountId32, + unvested: ::core::primitive::u128, + }, + #[codec(index = 1)] + VestingCompleted { account: ::sp_core::crypto::AccountId32 }, + } + } + } + pub mod pallet_scheduler { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Scheduled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, + #[codec(index = 1)] + Canceled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, + #[codec(index = 2)] + Dispatched { + task: (::core::primitive::u32, ::core::primitive::u32), + id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 3)] + CallUnavailable { + task: (::core::primitive::u32, ::core::primitive::u32), + id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + }, + #[codec(index = 4)] + PeriodicFailed { + task: (::core::primitive::u32, ::core::primitive::u32), + id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + }, + #[codec(index = 5)] + PermanentlyOverweight { + task: (::core::primitive::u32, ::core::primitive::u32), + id: ::core::option::Option<[::core::primitive::u8; 32usize]>, + }, + } + } + } + pub mod pallet_proxy { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + ProxyExecuted { + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 1)] + PureCreated { + pure: ::sp_core::crypto::AccountId32, + who: ::sp_core::crypto::AccountId32, + proxy_type: runtime_types::rococo_runtime::ProxyType, + disambiguation_index: ::core::primitive::u16, + }, + #[codec(index = 2)] + Announced { + real: ::sp_core::crypto::AccountId32, + proxy: ::sp_core::crypto::AccountId32, + call_hash: runtime_types::primitive_types::H256, + }, + #[codec(index = 3)] + ProxyAdded { + delegator: ::sp_core::crypto::AccountId32, + delegatee: ::sp_core::crypto::AccountId32, + proxy_type: runtime_types::rococo_runtime::ProxyType, + delay: ::core::primitive::u32, + }, + #[codec(index = 4)] + ProxyRemoved { + delegator: ::sp_core::crypto::AccountId32, + delegatee: ::sp_core::crypto::AccountId32, + proxy_type: runtime_types::rococo_runtime::ProxyType, + delay: ::core::primitive::u32, + }, + } + } + } + pub mod pallet_multisig { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewMultisig { + approving: ::sp_core::crypto::AccountId32, + multisig: ::sp_core::crypto::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 1)] + MultisigApproval { + approving: ::sp_core::crypto::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::sp_core::crypto::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + MultisigExecuted { + approving: ::sp_core::crypto::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::sp_core::crypto::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 3)] + MultisigCancelled { + cancelling: ::sp_core::crypto::AccountId32, + timepoint: + runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, + multisig: ::sp_core::crypto::AccountId32, + call_hash: [::core::primitive::u8; 32usize], + }, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Timepoint<_0> { + pub height: _0, + pub index: ::core::primitive::u32, + } + } + pub mod pallet_preimage { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Noted { hash: runtime_types::primitive_types::H256 }, + #[codec(index = 1)] + Requested { hash: runtime_types::primitive_types::H256 }, + #[codec(index = 2)] + Cleared { hash: runtime_types::primitive_types::H256 }, + } + } + } + pub mod pallet_bounties { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + BountyProposed { index: ::core::primitive::u32 }, + #[codec(index = 1)] + BountyRejected { index: ::core::primitive::u32, bond: ::core::primitive::u128 }, + #[codec(index = 2)] + BountyBecameActive { index: ::core::primitive::u32 }, + #[codec(index = 3)] + BountyAwarded { + index: ::core::primitive::u32, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 4)] + BountyClaimed { + index: ::core::primitive::u32, + payout: ::core::primitive::u128, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 5)] + BountyCanceled { index: ::core::primitive::u32 }, + #[codec(index = 6)] + BountyExtended { index: ::core::primitive::u32 }, + } + } + } + pub mod pallet_child_bounties { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Added { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, + #[codec(index = 1)] + Awarded { + index: ::core::primitive::u32, + child_index: ::core::primitive::u32, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 2)] + Claimed { + index: ::core::primitive::u32, + child_index: ::core::primitive::u32, + payout: ::core::primitive::u128, + beneficiary: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + Canceled { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, + } + } + } + pub mod pallet_tips { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewTip { tip_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 1)] + TipClosing { tip_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 2)] + TipClosed { + tip_hash: runtime_types::primitive_types::H256, + who: ::sp_core::crypto::AccountId32, + payout: ::core::primitive::u128, + }, + #[codec(index = 3)] + TipRetracted { tip_hash: runtime_types::primitive_types::H256 }, + #[codec(index = 4)] + TipSlashed { + tip_hash: runtime_types::primitive_types::H256, + finder: ::sp_core::crypto::AccountId32, + deposit: ::core::primitive::u128, + }, + } + } + } + pub mod pallet_nis { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + BidPlaced { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + duration: ::core::primitive::u32, + }, + #[codec(index = 1)] + BidRetracted { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + duration: ::core::primitive::u32, + }, + #[codec(index = 2)] + BidDropped { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + duration: ::core::primitive::u32, + }, + #[codec(index = 3)] + Issued { + index: ::core::primitive::u32, + expiry: ::core::primitive::u32, + who: ::sp_core::crypto::AccountId32, + proportion: runtime_types::sp_arithmetic::per_things::Perquintill, + amount: ::core::primitive::u128, + }, + #[codec(index = 4)] + Thawed { + index: ::core::primitive::u32, + who: ::sp_core::crypto::AccountId32, + proportion: runtime_types::sp_arithmetic::per_things::Perquintill, + amount: ::core::primitive::u128, + dropped: ::core::primitive::bool, + }, + #[codec(index = 5)] + Funded { deficit: ::core::primitive::u128 }, + #[codec(index = 6)] + Transferred { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + index: ::core::primitive::u32, + }, + } + } + } + pub mod polkadot_core_primitives { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct CandidateHash(pub runtime_types::primitive_types::H256); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct InboundDownwardMessage<_0> { + pub sent_at: _0, + pub msg: ::sp_std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct InboundHrmpMessage<_0> { + pub sent_at: _0, + pub data: ::sp_std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct OutboundHrmpMessage<_0> { + pub recipient: _0, + pub data: ::sp_std::vec::Vec<::core::primitive::u8>, + } + } + pub mod polkadot_primitives { + use super::runtime_types; + pub mod v5 { + use super::runtime_types; + // pub mod assignment_app { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Public(pub runtime_types::sp_core::sr25519::Public); + // } + pub mod collator_app { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub runtime_types::sp_core::sr25519::Public); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); + } + // pub mod executor_params { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum ExecutorParam { + // #[codec(index = 1)] + // MaxMemoryPages(::core::primitive::u32), + // #[codec(index = 2)] + // StackLogicalMax(::core::primitive::u32), + // #[codec(index = 3)] + // StackNativeMax(::core::primitive::u32), + // #[codec(index = 4)] + // PrecheckingMaxMemory(::core::primitive::u64), + // #[codec(index = 5)] + // PvfPrepTimeout( + // runtime_types::polkadot_primitives::v5::PvfPrepTimeoutKind, + // ::core::primitive::u64, + // ), + // #[codec(index = 6)] + // PvfExecTimeout( + // runtime_types::polkadot_primitives::v5::PvfExecTimeoutKind, + // ::core::primitive::u64, + // ), + // #[codec(index = 7)] + // WasmExtBulkMemory, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct ExecutorParams( + // pub ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::executor_params::ExecutorParam, + // >, + // ); + // } + // pub mod signed { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct UncheckedSigned<_0, _1> { + // pub payload: _0, + // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, + // pub signature: + // runtime_types::polkadot_primitives::v5::validator_app::Signature, + // #[codec(skip)] + // pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, + // } + // } + // pub mod slashing { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct DisputeProof { + // pub time_slot: + // runtime_types::polkadot_primitives::v5::slashing::DisputesTimeSlot, + // pub kind: + // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, + // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, + // pub validator_id: + // runtime_types::polkadot_primitives::v5::validator_app::Public, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct DisputesTimeSlot { + // pub session_index: ::core::primitive::u32, + // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct OpaqueKeyOwnershipProof(pub ::sp_std::vec::Vec<::core::primitive::u8>); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct PendingSlashes { + // pub keys: ::subxt::utils::KeyedVec< + // runtime_types::polkadot_primitives::v5::ValidatorIndex, + // runtime_types::polkadot_primitives::v5::validator_app::Public, + // >, + // pub kind: + // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum SlashingOffenceKind { + // #[codec(index = 0)] + // ForInvalid, + // #[codec(index = 1)] + // AgainstValid, + // } + // } + // pub mod validator_app { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Public(pub runtime_types::sp_core::sr25519::Public); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Assignment { + // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct AvailabilityBitfield( + // pub ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // ); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct BackedCandidate<_0> { + // pub candidate: + // runtime_types::polkadot_primitives::v5::CommittedCandidateReceipt<_0>, + // pub validity_votes: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::ValidityAttestation, + // >, + // pub validator_indices: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct CandidateCommitments<_0> { + // pub upward_messages: + // runtime_types::bounded_collections::bounded_vec::BoundedVec< + // ::sp_std::vec::Vec<::core::primitive::u8>, + // >, + // pub horizontal_messages: + // runtime_types::bounded_collections::bounded_vec::BoundedVec< + // runtime_types::polkadot_core_primitives::OutboundHrmpMessage< + // runtime_types::polkadot_parachain_primitives::primitives::Id, + // >, + // >, + // pub new_validation_code: ::core::option::Option< + // runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, + // >, + // pub head_data: + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // pub processed_downward_messages: ::core::primitive::u32, + // pub hrmp_watermark: _0, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct CandidateDescriptor < _0 > { pub para_id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , pub relay_parent : _0 , pub collator : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Public , pub persisted_validation_data_hash : runtime_types::primitive_types::H256 , pub pov_hash : runtime_types::primitive_types::H256 , pub erasure_root : runtime_types::primitive_types::H256 , pub signature : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Signature , pub para_head : runtime_types::primitive_types::H256 , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum CandidateEvent<_0> { + // #[codec(index = 0)] + // CandidateBacked( + // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // runtime_types::polkadot_primitives::v5::CoreIndex, + // runtime_types::polkadot_primitives::v5::GroupIndex, + // ), + // #[codec(index = 1)] + // CandidateIncluded( + // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // runtime_types::polkadot_primitives::v5::CoreIndex, + // runtime_types::polkadot_primitives::v5::GroupIndex, + // ), + // #[codec(index = 2)] + // CandidateTimedOut( + // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // runtime_types::polkadot_primitives::v5::CoreIndex, + // ), + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct CandidateReceipt<_0> { + pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + pub commitments_hash: runtime_types::primitive_types::H256, + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct CommittedCandidateReceipt<_0> { + // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + // pub commitments: runtime_types::polkadot_primitives::v5::CandidateCommitments< + // ::core::primitive::u32, + // >, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct CoreIndex(pub ::core::primitive::u32); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum CoreOccupied<_0> { + // #[codec(index = 0)] + // Free, + // #[codec(index = 1)] + // Paras(runtime_types::polkadot_primitives::v5::ParasEntry<_0>), + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum CoreState<_0, _1> { + // #[codec(index = 0)] + // Occupied(runtime_types::polkadot_primitives::v5::OccupiedCore<_0, _1>), + // #[codec(index = 1)] + // Scheduled(runtime_types::polkadot_primitives::v5::ScheduledCore), + // #[codec(index = 2)] + // Free, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct DisputeState<_0> { + // pub validators_for: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub validators_against: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub start: _0, + // pub concluded_at: ::core::option::Option<_0>, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum DisputeStatement { + // #[codec(index = 0)] + // Valid(runtime_types::polkadot_primitives::v5::ValidDisputeStatementKind), + // #[codec(index = 1)] + // Invalid(runtime_types::polkadot_primitives::v5::InvalidDisputeStatementKind), + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct DisputeStatementSet { + // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + // pub session: ::core::primitive::u32, + // pub statements: ::sp_std::vec::Vec<( + // runtime_types::polkadot_primitives::v5::DisputeStatement, + // runtime_types::polkadot_primitives::v5::ValidatorIndex, + // runtime_types::polkadot_primitives::v5::validator_app::Signature, + // )>, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct GroupIndex(pub ::core::primitive::u32); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct GroupRotationInfo<_0> { + // pub session_start_block: _0, + // pub group_rotation_frequency: _0, + // pub now: _0, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct IndexedVec<_0, _1>( + // pub ::sp_std::vec::Vec<_1>, + // #[codec(skip)] pub ::core::marker::PhantomData<_0>, + // ); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct InherentData<_0> { + // pub bitfields: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::signed::UncheckedSigned< + // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, + // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, + // >, + // >, + // pub backed_candidates: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::BackedCandidate< + // ::subxt::utils::H256, + // >, + // >, + // pub disputes: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::DisputeStatementSet, + // >, + // pub parent_header: _0, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum InvalidDisputeStatementKind { + // #[codec(index = 0)] + // Explicit, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct OccupiedCore<_0, _1> { + // pub next_up_on_available: ::core::option::Option< + // runtime_types::polkadot_primitives::v5::ScheduledCore, + // >, + // pub occupied_since: _1, + // pub time_out_at: _1, + // pub next_up_on_time_out: ::core::option::Option< + // runtime_types::polkadot_primitives::v5::ScheduledCore, + // >, + // pub availability: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub group_responsible: runtime_types::polkadot_primitives::v5::GroupIndex, + // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + // pub candidate_descriptor: + // runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum OccupiedCoreAssumption { + // #[codec(index = 0)] + // Included, + // #[codec(index = 1)] + // TimedOut, + // #[codec(index = 2)] + // Free, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct ParasEntry<_0> { + // pub assignment: runtime_types::polkadot_primitives::v5::Assignment, + // pub availability_timeouts: ::core::primitive::u32, + // pub ttl: _0, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct PersistedValidationData<_0, _1> { + // pub parent_head: + // runtime_types::polkadot_parachain_primitives::primitives::HeadData, + // pub relay_parent_number: _1, + // pub relay_parent_storage_root: _0, + // pub max_pov_size: ::core::primitive::u32, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct PvfCheckStatement { pub accept : :: core :: primitive :: bool , pub subject : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub session_index : :: core :: primitive :: u32 , pub validator_index : runtime_types :: polkadot_primitives :: v5 :: ValidatorIndex , } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum PvfExecTimeoutKind { + // #[codec(index = 0)] + // Backing, + // #[codec(index = 1)] + // Approval, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum PvfPrepTimeoutKind { + // #[codec(index = 0)] + // Precheck, + // #[codec(index = 1)] + // Lenient, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct ScheduledCore { + // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + // pub collator: ::core::option::Option< + // runtime_types::polkadot_primitives::v5::collator_app::Public, + // >, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct ScrapedOnChainVotes<_0> { + // pub session: ::core::primitive::u32, + // pub backing_validators_per_candidate: ::sp_std::vec::Vec<( + // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, + // ::sp_std::vec::Vec<( + // runtime_types::polkadot_primitives::v5::ValidatorIndex, + // runtime_types::polkadot_primitives::v5::ValidityAttestation, + // )>, + // )>, + // pub disputes: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::DisputeStatementSet, + // >, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct SessionInfo { + // pub active_validator_indices: + // ::sp_std::vec::Vec, + // pub random_seed: [::core::primitive::u8; 32usize], + // pub dispute_period: ::core::primitive::u32, + // pub validators: runtime_types::polkadot_primitives::v5::IndexedVec< + // runtime_types::polkadot_primitives::v5::ValidatorIndex, + // runtime_types::polkadot_primitives::v5::validator_app::Public, + // >, + // pub discovery_keys: + // ::sp_std::vec::Vec, + // pub assignment_keys: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::v5::assignment_app::Public, + // >, + // pub validator_groups: runtime_types::polkadot_primitives::v5::IndexedVec< + // runtime_types::polkadot_primitives::v5::GroupIndex, + // ::sp_std::vec::Vec, + // >, + // pub n_cores: ::core::primitive::u32, + // pub zeroth_delay_tranche_width: ::core::primitive::u32, + // pub relay_vrf_modulo_samples: ::core::primitive::u32, + // pub n_delay_tranches: ::core::primitive::u32, + // pub no_show_slots: ::core::primitive::u32, + // pub needed_approvals: ::core::primitive::u32, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum UpgradeGoAhead { + // #[codec(index = 0)] + // Abort, + // #[codec(index = 1)] + // GoAhead, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum UpgradeRestriction { + // #[codec(index = 0)] + // Present, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum ValidDisputeStatementKind { + // #[codec(index = 0)] + // Explicit, + // #[codec(index = 1)] + // BackingSeconded(::subxt::utils::H256), + // #[codec(index = 2)] + // BackingValid(::subxt::utils::H256), + // #[codec(index = 3)] + // ApprovalChecking, + // } + // #[derive( + // :: codec :: Decode, + // :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + // Clone, + // Debug, + // PartialEq, + // )] + // pub struct ValidatorIndex(pub ::core::primitive::u32); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum ValidityAttestation { + // #[codec(index = 1)] + // Implicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), + // #[codec(index = 2)] + // Explicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), + // } + // } + // pub mod vstaging { + // use super::runtime_types; + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct AsyncBackingParams { + // pub max_candidate_depth: ::core::primitive::u32, + // pub allowed_ancestry_len: ::core::primitive::u32, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct BackingState<_0, _1> { + // pub constraints: runtime_types::polkadot_primitives::vstaging::Constraints<_1>, + // pub pending_availability: ::sp_std::vec::Vec< + // runtime_types::polkadot_primitives::vstaging::CandidatePendingAvailability< + // _0, + // _1, + // >, + // >, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct CandidatePendingAvailability<_0, _1> { + // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, + // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + // pub commitments: + // runtime_types::polkadot_primitives::v5::CandidateCommitments<_1>, + // pub relay_parent_number: _1, + // pub max_pov_size: ::core::primitive::u32, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Constraints < _0 > { pub min_relay_parent_number : _0 , pub max_pov_size : :: core :: primitive :: u32 , pub max_code_size : :: core :: primitive :: u32 , pub ump_remaining : :: core :: primitive :: u32 , pub ump_remaining_bytes : :: core :: primitive :: u32 , pub max_ump_num_per_candidate : :: core :: primitive :: u32 , pub dmp_remaining_messages : :: std :: vec :: Vec < _0 > , pub hrmp_inbound : runtime_types :: polkadot_primitives :: vstaging :: InboundHrmpLimitations < _0 > , pub hrmp_channels_out : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: vstaging :: OutboundHrmpChannelLimitations ,) > , pub max_hrmp_num_per_candidate : :: core :: primitive :: u32 , pub required_parent : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub upgrade_restriction : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v5 :: UpgradeRestriction > , pub future_validation_code : :: core :: option :: Option < (_0 , runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash ,) > , } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct InboundHrmpLimitations<_0> { + // pub valid_watermarks: ::sp_std::vec::Vec<_0>, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct OutboundHrmpChannelLimitations { + // pub bytes_remaining: ::core::primitive::u32, + // pub messages_remaining: ::core::primitive::u32, + // } + } + } + pub mod sp_core { + use super::runtime_types; + pub mod crypto { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); + } + pub mod ecdsa { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub [::core::primitive::u8; 33usize]); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub [::core::primitive::u8; 65usize]); + } + pub mod ed25519 { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub [::core::primitive::u8; 32usize]); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub [::core::primitive::u8; 64usize]); + } + pub mod sr25519 { + use super::runtime_types; + pub mod vrf { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct VrfSignature { + pub output: [::core::primitive::u8; 32usize], + pub proof: [::core::primitive::u8; 64usize], + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Public(pub [::core::primitive::u8; 32usize]); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Signature(pub [::core::primitive::u8; 64usize]); + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct OpaqueMetadata(pub ::sp_std::vec::Vec<::core::primitive::u8>); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Void {} + } + pub mod pallet_message_queue { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + # [codec (index = 0)] ProcessingFailed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , error : runtime_types :: frame_support :: traits :: messages :: ProcessMessageError , } , # [codec (index = 1)] Processed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , weight_used : :: sp_weights :: Weight , success : :: core :: primitive :: bool , } , # [codec (index = 2)] OverweightEnqueued { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , page_index : :: core :: primitive :: u32 , message_index : :: core :: primitive :: u32 , } , # [codec (index = 3)] PageReaped { origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , index : :: core :: primitive :: u32 , } , } + } + } + pub mod pallet_xcm { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Attempted { outcome: runtime_types::staging_xcm::v3::traits::Outcome }, + #[codec(index = 1)] + Sent { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + message: runtime_types::staging_xcm::v3::Xcm, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + UnexpectedResponse { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 3)] + ResponseReady { + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v3::Response, + }, + #[codec(index = 4)] + Notified { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 5)] + NotifyOverweight { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + actual_weight: ::sp_weights::Weight, + max_budgeted_weight: ::sp_weights::Weight, + }, + #[codec(index = 6)] + NotifyDispatchError { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 7)] + NotifyDecodeFailed { + query_id: ::core::primitive::u64, + pallet_index: ::core::primitive::u8, + call_index: ::core::primitive::u8, + }, + #[codec(index = 8)] + InvalidResponder { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + expected_location: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + #[codec(index = 9)] + InvalidResponderVersion { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 10)] + ResponseTaken { query_id: ::core::primitive::u64 }, + #[codec(index = 11)] + AssetsTrapped { + hash: runtime_types::primitive_types::H256, + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + assets: runtime_types::staging_xcm::VersionedMultiAssets, + }, + #[codec(index = 12)] + VersionChangeNotified { + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + result: ::core::primitive::u32, + cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 13)] + SupportedVersionChanged { + location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + version: ::core::primitive::u32, + }, + #[codec(index = 14)] + NotifyTargetSendFail { + location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + error: runtime_types::staging_xcm::v3::traits::Error, + }, + #[codec(index = 15)] + NotifyTargetMigrationFail { + location: runtime_types::staging_xcm::VersionedMultiLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 16)] + InvalidQuerierVersion { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + }, + #[codec(index = 17)] + InvalidQuerier { + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + query_id: ::core::primitive::u64, + expected_querier: + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + maybe_actual_querier: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + #[codec(index = 18)] + VersionNotifyStarted { + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 19)] + VersionNotifyRequested { + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 20)] + VersionNotifyUnrequested { + destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + message_id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 21)] + FeesPaid { + paying: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + fees: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + }, + #[codec(index = 22)] + AssetsClaimed { + hash: runtime_types::primitive_types::H256, + origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + assets: runtime_types::staging_xcm::VersionedMultiAssets, + }, + } + } + } + pub mod staging_xcm { + use super::runtime_types; + pub mod double_encoded { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct DoubleEncoded { + pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct DoubleEncoded2 { + pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, + } + } + pub mod v2 { + use super::runtime_types; + pub mod junction { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Junction { + #[codec(index = 0)] + Parachain(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 1)] + AccountId32 { + network: runtime_types::staging_xcm::v2::NetworkId, + id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + AccountIndex64 { + network: runtime_types::staging_xcm::v2::NetworkId, + #[codec(compact)] + index: ::core::primitive::u64, + }, + #[codec(index = 3)] + AccountKey20 { + network: runtime_types::staging_xcm::v2::NetworkId, + key: [::core::primitive::u8; 20usize], + }, + #[codec(index = 4)] + PalletInstance(::core::primitive::u8), + #[codec(index = 5)] + GeneralIndex(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 6)] + GeneralKey( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 7)] + OnlyChild, + #[codec(index = 8)] + Plurality { + id: runtime_types::staging_xcm::v2::BodyId, + part: runtime_types::staging_xcm::v2::BodyPart, + }, + } + } + pub mod multiasset { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AssetId { + #[codec(index = 0)] + Concrete(runtime_types::staging_xcm::v2::multilocation::MultiLocation), + #[codec(index = 1)] + Abstract(::sp_std::vec::Vec<::core::primitive::u8>), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AssetInstance { + #[codec(index = 0)] + Undefined, + #[codec(index = 1)] + Index(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 2)] + Array4([::core::primitive::u8; 4usize]), + #[codec(index = 3)] + Array8([::core::primitive::u8; 8usize]), + #[codec(index = 4)] + Array16([::core::primitive::u8; 16usize]), + #[codec(index = 5)] + Array32([::core::primitive::u8; 32usize]), + #[codec(index = 6)] + Blob(::sp_std::vec::Vec<::core::primitive::u8>), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Fungibility { + #[codec(index = 0)] + Fungible(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 1)] + NonFungible(runtime_types::staging_xcm::v2::multiasset::AssetInstance), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiAsset { + pub id: runtime_types::staging_xcm::v2::multiasset::AssetId, + pub fun: runtime_types::staging_xcm::v2::multiasset::Fungibility, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MultiAssetFilter { + #[codec(index = 0)] + Definite(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + Wild(runtime_types::staging_xcm::v2::multiasset::WildMultiAsset), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiAssets( + pub ::sp_std::vec::Vec< + runtime_types::staging_xcm::v2::multiasset::MultiAsset, + >, + ); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WildFungibility { + #[codec(index = 0)] + Fungible, + #[codec(index = 1)] + NonFungible, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WildMultiAsset { + #[codec(index = 0)] + All, + #[codec(index = 1)] + AllOf { + id: runtime_types::staging_xcm::v2::multiasset::AssetId, + fun: runtime_types::staging_xcm::v2::multiasset::WildFungibility, + }, + } + } + pub mod multilocation { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Junctions { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + X1(runtime_types::staging_xcm::v2::junction::Junction), + #[codec(index = 2)] + X2( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 3)] + X3( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 4)] + X4( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 5)] + X5( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 6)] + X6( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 7)] + X7( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + #[codec(index = 8)] + X8( + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + runtime_types::staging_xcm::v2::junction::Junction, + ), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiLocation { + pub parents: ::core::primitive::u8, + pub interior: runtime_types::staging_xcm::v2::multilocation::Junctions, + } + } + pub mod traits { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Error { + #[codec(index = 0)] + Overflow, + #[codec(index = 1)] + Unimplemented, + #[codec(index = 2)] + UntrustedReserveLocation, + #[codec(index = 3)] + UntrustedTeleportLocation, + #[codec(index = 4)] + MultiLocationFull, + #[codec(index = 5)] + MultiLocationNotInvertible, + #[codec(index = 6)] + BadOrigin, + #[codec(index = 7)] + InvalidLocation, + #[codec(index = 8)] + AssetNotFound, + #[codec(index = 9)] + FailedToTransactAsset, + #[codec(index = 10)] + NotWithdrawable, + #[codec(index = 11)] + LocationCannotHold, + #[codec(index = 12)] + ExceedsMaxMessageSize, + #[codec(index = 13)] + DestinationUnsupported, + #[codec(index = 14)] + Transport, + #[codec(index = 15)] + Unroutable, + #[codec(index = 16)] + UnknownClaim, + #[codec(index = 17)] + FailedToDecode, + #[codec(index = 18)] + MaxWeightInvalid, + #[codec(index = 19)] + NotHoldingFees, + #[codec(index = 20)] + TooExpensive, + #[codec(index = 21)] + Trap(::core::primitive::u64), + #[codec(index = 22)] + UnhandledXcmVersion, + #[codec(index = 23)] + WeightLimitReached(::core::primitive::u64), + #[codec(index = 24)] + Barrier, + #[codec(index = 25)] + WeightNotComputable, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BodyId { + #[codec(index = 0)] + Unit, + #[codec(index = 1)] + Named( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Index(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + Executive, + #[codec(index = 4)] + Technical, + #[codec(index = 5)] + Legislative, + #[codec(index = 6)] + Judicial, + #[codec(index = 7)] + Defense, + #[codec(index = 8)] + Administration, + #[codec(index = 9)] + Treasury, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BodyPart { + #[codec(index = 0)] + Voice, + #[codec(index = 1)] + Members { + #[codec(compact)] + count: ::core::primitive::u32, + }, + #[codec(index = 2)] + Fraction { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 3)] + AtLeastProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 4)] + MoreThanProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Instruction { + #[codec(index = 0)] + WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v2::Response, + #[codec(compact)] + max_weight: ::core::primitive::u64, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_type: runtime_types::staging_xcm::v2::OriginKind, + #[codec(compact)] + require_weight_at_most: ::core::primitive::u64, + call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), + #[codec(index = 12)] + ReportError { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 18)] + QueryHolding { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, + weight_limit: runtime_types::staging_xcm::v2::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::staging_xcm::v2::Xcm), + #[codec(index = 22)] + SetAppendix(runtime_types::staging_xcm::v2::Xcm), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 27)] + UnsubscribeVersion, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Instruction2 { + #[codec(index = 0)] + WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v2::Response, + #[codec(compact)] + max_weight: ::core::primitive::u64, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_type: runtime_types::staging_xcm::v2::OriginKind, + #[codec(compact)] + require_weight_at_most: ::core::primitive::u64, + call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), + #[codec(index = 12)] + ReportError { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_assets: ::core::primitive::u32, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v2::Xcm, + }, + #[codec(index = 18)] + QueryHolding { + #[codec(compact)] + query_id: ::core::primitive::u64, + dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, + weight_limit: runtime_types::staging_xcm::v2::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::staging_xcm::v2::Xcm2), + #[codec(index = 22)] + SetAppendix(runtime_types::staging_xcm::v2::Xcm2), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, + ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + #[codec(compact)] + max_response_weight: ::core::primitive::u64, + }, + #[codec(index = 27)] + UnsubscribeVersion, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum NetworkId { + #[codec(index = 0)] + Any, + #[codec(index = 1)] + Named( + runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + Polkadot, + #[codec(index = 3)] + Kusama, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum OriginKind { + #[codec(index = 0)] + Native, + #[codec(index = 1)] + SovereignAccount, + #[codec(index = 2)] + Superuser, + #[codec(index = 3)] + Xcm, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Response { + #[codec(index = 0)] + Null, + #[codec(index = 1)] + Assets(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 2)] + ExecutionResult( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::staging_xcm::v2::traits::Error, + )>, + ), + #[codec(index = 3)] + Version(::core::primitive::u32), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WeightLimit { + #[codec(index = 0)] + Unlimited, + #[codec(index = 1)] + Limited(#[codec(compact)] ::core::primitive::u64), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Xcm(pub ::sp_std::vec::Vec); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Xcm2( + pub ::sp_std::vec::Vec, + ); + } + pub mod v3 { + use super::runtime_types; + pub mod junction { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BodyId { + #[codec(index = 0)] + Unit, + #[codec(index = 1)] + Moniker([::core::primitive::u8; 4usize]), + #[codec(index = 2)] + Index(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + Executive, + #[codec(index = 4)] + Technical, + #[codec(index = 5)] + Legislative, + #[codec(index = 6)] + Judicial, + #[codec(index = 7)] + Defense, + #[codec(index = 8)] + Administration, + #[codec(index = 9)] + Treasury, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BodyPart { + #[codec(index = 0)] + Voice, + #[codec(index = 1)] + Members { + #[codec(compact)] + count: ::core::primitive::u32, + }, + #[codec(index = 2)] + Fraction { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 3)] + AtLeastProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + #[codec(index = 4)] + MoreThanProportion { + #[codec(compact)] + nom: ::core::primitive::u32, + #[codec(compact)] + denom: ::core::primitive::u32, + }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Junction { + #[codec(index = 0)] + Parachain(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 1)] + AccountId32 { + network: ::core::option::Option< + runtime_types::staging_xcm::v3::junction::NetworkId, + >, + id: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + AccountIndex64 { + network: ::core::option::Option< + runtime_types::staging_xcm::v3::junction::NetworkId, + >, + #[codec(compact)] + index: ::core::primitive::u64, + }, + #[codec(index = 3)] + AccountKey20 { + network: ::core::option::Option< + runtime_types::staging_xcm::v3::junction::NetworkId, + >, + key: [::core::primitive::u8; 20usize], + }, + #[codec(index = 4)] + PalletInstance(::core::primitive::u8), + #[codec(index = 5)] + GeneralIndex(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 6)] + GeneralKey { + length: ::core::primitive::u8, + data: [::core::primitive::u8; 32usize], + }, + #[codec(index = 7)] + OnlyChild, + #[codec(index = 8)] + Plurality { + id: runtime_types::staging_xcm::v3::junction::BodyId, + part: runtime_types::staging_xcm::v3::junction::BodyPart, + }, + #[codec(index = 9)] + GlobalConsensus(runtime_types::staging_xcm::v3::junction::NetworkId), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum NetworkId { + #[codec(index = 0)] + ByGenesis([::core::primitive::u8; 32usize]), + #[codec(index = 1)] + ByFork { + block_number: ::core::primitive::u64, + block_hash: [::core::primitive::u8; 32usize], + }, + #[codec(index = 2)] + Polkadot, + #[codec(index = 3)] + Kusama, + #[codec(index = 4)] + Westend, + #[codec(index = 5)] + Rococo, + #[codec(index = 6)] + Wococo, + #[codec(index = 7)] + Ethereum { + #[codec(compact)] + chain_id: ::core::primitive::u64, + }, + #[codec(index = 8)] + BitcoinCore, + #[codec(index = 9)] + BitcoinCash, + } + } + pub mod junctions { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Junctions { + #[codec(index = 0)] + Here, + #[codec(index = 1)] + X1(runtime_types::staging_xcm::v3::junction::Junction), + #[codec(index = 2)] + X2( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 3)] + X3( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 4)] + X4( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 5)] + X5( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 6)] + X6( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 7)] + X7( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + #[codec(index = 8)] + X8( + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + runtime_types::staging_xcm::v3::junction::Junction, + ), + } + } + pub mod multiasset { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AssetId { + #[codec(index = 0)] + Concrete(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + #[codec(index = 1)] + Abstract([::core::primitive::u8; 32usize]), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AssetInstance { + #[codec(index = 0)] + Undefined, + #[codec(index = 1)] + Index(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 2)] + Array4([::core::primitive::u8; 4usize]), + #[codec(index = 3)] + Array8([::core::primitive::u8; 8usize]), + #[codec(index = 4)] + Array16([::core::primitive::u8; 16usize]), + #[codec(index = 5)] + Array32([::core::primitive::u8; 32usize]), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Fungibility { + #[codec(index = 0)] + Fungible(#[codec(compact)] ::core::primitive::u128), + #[codec(index = 1)] + NonFungible(runtime_types::staging_xcm::v3::multiasset::AssetInstance), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiAsset { + pub id: runtime_types::staging_xcm::v3::multiasset::AssetId, + pub fun: runtime_types::staging_xcm::v3::multiasset::Fungibility, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MultiAssetFilter { + #[codec(index = 0)] + Definite(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 1)] + Wild(runtime_types::staging_xcm::v3::multiasset::WildMultiAsset), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiAssets( + pub ::sp_std::vec::Vec< + runtime_types::staging_xcm::v3::multiasset::MultiAsset, + >, + ); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WildFungibility { + #[codec(index = 0)] + Fungible, + #[codec(index = 1)] + NonFungible, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WildMultiAsset { + #[codec(index = 0)] + All, + #[codec(index = 1)] + AllOf { + id: runtime_types::staging_xcm::v3::multiasset::AssetId, + fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, + }, + #[codec(index = 2)] + AllCounted(#[codec(compact)] ::core::primitive::u32), + #[codec(index = 3)] + AllOfCounted { + id: runtime_types::staging_xcm::v3::multiasset::AssetId, + fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, + #[codec(compact)] + count: ::core::primitive::u32, + }, + } + } + pub mod multilocation { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct MultiLocation { + pub parents: ::core::primitive::u8, + pub interior: runtime_types::staging_xcm::v3::junctions::Junctions, + } + } -#[derive( - :: codec::Decode, :: codec :: Encode, Clone, Debug, PartialEq, Eq, scale_info::TypeInfo, -)] -pub enum MyPhase { - /// Applying an extrinsic. - ApplyExtrinsic(::core::primitive::u32), - /// Finalizing the block. - Finalization, - /// Initializing the block. - Initialization, -} + pub mod traits { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Error { + #[codec(index = 0)] + Overflow, + #[codec(index = 1)] + Unimplemented, + #[codec(index = 2)] + UntrustedReserveLocation, + #[codec(index = 3)] + UntrustedTeleportLocation, + #[codec(index = 4)] + LocationFull, + #[codec(index = 5)] + LocationNotInvertible, + #[codec(index = 6)] + BadOrigin, + #[codec(index = 7)] + InvalidLocation, + #[codec(index = 8)] + AssetNotFound, + #[codec(index = 9)] + FailedToTransactAsset, + #[codec(index = 10)] + NotWithdrawable, + #[codec(index = 11)] + LocationCannotHold, + #[codec(index = 12)] + ExceedsMaxMessageSize, + #[codec(index = 13)] + DestinationUnsupported, + #[codec(index = 14)] + Transport, + #[codec(index = 15)] + Unroutable, + #[codec(index = 16)] + UnknownClaim, + #[codec(index = 17)] + FailedToDecode, + #[codec(index = 18)] + MaxWeightInvalid, + #[codec(index = 19)] + NotHoldingFees, + #[codec(index = 20)] + TooExpensive, + #[codec(index = 21)] + Trap(::core::primitive::u64), + #[codec(index = 22)] + ExpectationFalse, + #[codec(index = 23)] + PalletNotFound, + #[codec(index = 24)] + NameMismatch, + #[codec(index = 25)] + VersionIncompatible, + #[codec(index = 26)] + HoldingWouldOverflow, + #[codec(index = 27)] + ExportError, + #[codec(index = 28)] + ReanchorFailed, + #[codec(index = 29)] + NoDeal, + #[codec(index = 30)] + FeesNotMet, + #[codec(index = 31)] + LockError, + #[codec(index = 32)] + NoPermission, + #[codec(index = 33)] + Unanchored, + #[codec(index = 34)] + NotDepositable, + #[codec(index = 35)] + UnhandledXcmVersion, + #[codec(index = 36)] + WeightLimitReached(::sp_weights::Weight), + #[codec(index = 37)] + Barrier, + #[codec(index = 38)] + WeightNotComputable, + #[codec(index = 39)] + ExceedsStackLimit, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Outcome { + #[codec(index = 0)] + Complete(::sp_weights::Weight), + #[codec(index = 1)] + Incomplete( + ::sp_weights::Weight, + runtime_types::staging_xcm::v3::traits::Error, + ), + #[codec(index = 2)] + Error(runtime_types::staging_xcm::v3::traits::Error), + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Instruction { + #[codec(index = 0)] + WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 1)] + ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 2)] + ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 3)] + QueryResponse { + #[codec(compact)] + query_id: ::core::primitive::u64, + response: runtime_types::staging_xcm::v3::Response, + max_weight: ::sp_weights::Weight, + querier: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + #[codec(index = 4)] + TransferAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 5)] + TransferReserveAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 6)] + Transact { + origin_kind: runtime_types::staging_xcm::v2::OriginKind, + require_weight_at_most: ::sp_weights::Weight, + call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, + }, + #[codec(index = 7)] + HrmpNewChannelOpenRequest { + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + max_message_size: ::core::primitive::u32, + #[codec(compact)] + max_capacity: ::core::primitive::u32, + }, + #[codec(index = 8)] + HrmpChannelAccepted { + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 9)] + HrmpChannelClosing { + #[codec(compact)] + initiator: ::core::primitive::u32, + #[codec(compact)] + sender: ::core::primitive::u32, + #[codec(compact)] + recipient: ::core::primitive::u32, + }, + #[codec(index = 10)] + ClearOrigin, + #[codec(index = 11)] + DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), + #[codec(index = 12)] + ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), + #[codec(index = 13)] + DepositAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 14)] + DepositReserveAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 15)] + ExchangeAsset { + give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + maximal: ::core::primitive::bool, + }, + #[codec(index = 16)] + InitiateReserveWithdraw { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 17)] + InitiateTeleport { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 18)] + ReportHolding { + response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + }, + #[codec(index = 19)] + BuyExecution { + fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + weight_limit: runtime_types::staging_xcm::v3::WeightLimit, + }, + #[codec(index = 20)] + RefundSurplus, + #[codec(index = 21)] + SetErrorHandler(runtime_types::staging_xcm::v3::Xcm), + #[codec(index = 22)] + SetAppendix(runtime_types::staging_xcm::v3::Xcm), + #[codec(index = 23)] + ClearError, + #[codec(index = 24)] + ClaimAsset { + assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 25)] + Trap(#[codec(compact)] ::core::primitive::u64), + #[codec(index = 26)] + SubscribeVersion { + #[codec(compact)] + query_id: ::core::primitive::u64, + max_response_weight: ::sp_weights::Weight, + }, + #[codec(index = 27)] + UnsubscribeVersion, + #[codec(index = 28)] + BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 29)] + ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 30)] + ExpectOrigin( + ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + ), + #[codec(index = 31)] + ExpectError( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::staging_xcm::v3::traits::Error, + )>, + ), + #[codec(index = 32)] + ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), + #[codec(index = 33)] + QueryPallet { + module_name: ::sp_std::vec::Vec<::core::primitive::u8>, + response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, + }, + #[codec(index = 34)] + ExpectPallet { + #[codec(compact)] + index: ::core::primitive::u32, + name: ::sp_std::vec::Vec<::core::primitive::u8>, + module_name: ::sp_std::vec::Vec<::core::primitive::u8>, + #[codec(compact)] + crate_major: ::core::primitive::u32, + #[codec(compact)] + min_crate_minor: ::core::primitive::u32, + }, + #[codec(index = 35)] + ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), + #[codec(index = 36)] + ClearTransactStatus, + #[codec(index = 37)] + UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), + #[codec(index = 38)] + ExportMessage { + network: runtime_types::staging_xcm::v3::junction::NetworkId, + destination: runtime_types::staging_xcm::v3::junctions::Junctions, + xcm: runtime_types::staging_xcm::v3::Xcm, + }, + #[codec(index = 39)] + LockAsset { + asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 40)] + UnlockAsset { + asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 41)] + NoteUnlockable { + asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 42)] + RequestUnlock { + asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + }, + #[codec(index = 43)] + SetFeesMode { jit_withdraw: ::core::primitive::bool }, + #[codec(index = 44)] + SetTopic([::core::primitive::u8; 32usize]), + #[codec(index = 45)] + ClearTopic, + #[codec(index = 46)] + AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + #[codec(index = 47)] + UnpaidExecution { + weight_limit: runtime_types::staging_xcm::v3::WeightLimit, + check_origin: ::core::option::Option< + runtime_types::staging_xcm::v3::multilocation::MultiLocation, + >, + }, + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum Instruction2 { + // #[codec(index = 0)] + // WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 1)] + // ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 2)] + // ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 3)] + // QueryResponse { + // #[codec(compact)] + // query_id: ::core::primitive::u64, + // response: runtime_types::staging_xcm::v3::Response, + // max_weight: ::sp_weights::Weight, + // querier: ::core::option::Option< + // runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // >, + // }, + // #[codec(index = 4)] + // TransferAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 5)] + // TransferReserveAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 6)] + // Transact { + // origin_kind: runtime_types::staging_xcm::v2::OriginKind, + // require_weight_at_most: ::sp_weights::Weight, + // call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, + // }, + // #[codec(index = 7)] + // HrmpNewChannelOpenRequest { + // #[codec(compact)] + // sender: ::core::primitive::u32, + // #[codec(compact)] + // max_message_size: ::core::primitive::u32, + // #[codec(compact)] + // max_capacity: ::core::primitive::u32, + // }, + // #[codec(index = 8)] + // HrmpChannelAccepted { + // #[codec(compact)] + // recipient: ::core::primitive::u32, + // }, + // #[codec(index = 9)] + // HrmpChannelClosing { + // #[codec(compact)] + // initiator: ::core::primitive::u32, + // #[codec(compact)] + // sender: ::core::primitive::u32, + // #[codec(compact)] + // recipient: ::core::primitive::u32, + // }, + // #[codec(index = 10)] + // ClearOrigin, + // #[codec(index = 11)] + // DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), + // #[codec(index = 12)] + // ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), + // #[codec(index = 13)] + // DepositAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 14)] + // DepositReserveAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 15)] + // ExchangeAsset { + // give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + // maximal: ::core::primitive::bool, + // }, + // #[codec(index = 16)] + // InitiateReserveWithdraw { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 17)] + // InitiateTeleport { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 18)] + // ReportHolding { + // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, + // }, + // #[codec(index = 19)] + // BuyExecution { + // fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, + // }, + // #[codec(index = 20)] + // RefundSurplus, + // #[codec(index = 21)] + // SetErrorHandler(runtime_types::staging_xcm::v3::Xcm2), + // #[codec(index = 22)] + // SetAppendix(runtime_types::staging_xcm::v3::Xcm2), + // #[codec(index = 23)] + // ClearError, + // #[codec(index = 24)] + // ClaimAsset { + // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, + // ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 25)] + // Trap(#[codec(compact)] ::core::primitive::u64), + // #[codec(index = 26)] + // SubscribeVersion { + // #[codec(compact)] + // query_id: ::core::primitive::u64, + // max_response_weight: ::sp_weights::Weight, + // }, + // #[codec(index = 27)] + // UnsubscribeVersion, + // #[codec(index = 28)] + // BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 29)] + // ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + // #[codec(index = 30)] + // ExpectOrigin( + // ::core::option::Option< + // runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // >, + // ), + // #[codec(index = 31)] + // ExpectError( + // ::core::option::Option<( + // ::core::primitive::u32, + // runtime_types::staging_xcm::v3::traits::Error, + // )>, + // ), + // #[codec(index = 32)] + // ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), + // #[codec(index = 33)] + // QueryPallet { + // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, + // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, + // }, + // #[codec(index = 34)] + // ExpectPallet { + // #[codec(compact)] + // index: ::core::primitive::u32, + // name: ::sp_std::vec::Vec<::core::primitive::u8>, + // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, + // #[codec(compact)] + // crate_major: ::core::primitive::u32, + // #[codec(compact)] + // min_crate_minor: ::core::primitive::u32, + // }, + // #[codec(index = 35)] + // ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), + // #[codec(index = 36)] + // ClearTransactStatus, + // #[codec(index = 37)] + // UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), + // #[codec(index = 38)] + // ExportMessage { + // network: runtime_types::staging_xcm::v3::junction::NetworkId, + // destination: runtime_types::staging_xcm::v3::junctions::Junctions, + // xcm: runtime_types::staging_xcm::v3::Xcm, + // }, + // #[codec(index = 39)] + // LockAsset { + // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 40)] + // UnlockAsset { + // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 41)] + // NoteUnlockable { + // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 42)] + // RequestUnlock { + // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, + // locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // }, + // #[codec(index = 43)] + // SetFeesMode { jit_withdraw: ::core::primitive::bool }, + // #[codec(index = 44)] + // SetTopic([::core::primitive::u8; 32usize]), + // #[codec(index = 45)] + // ClearTopic, + // #[codec(index = 46)] + // AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + // #[codec(index = 47)] + // UnpaidExecution { + // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, + // check_origin: ::core::option::Option< + // runtime_types::staging_xcm::v3::multilocation::MultiLocation, + // >, + // }, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MaybeErrorCode { + #[codec(index = 0)] + Success, + #[codec(index = 1)] + Error( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + #[codec(index = 2)] + TruncatedError( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + ), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct PalletInfo { + #[codec(compact)] + pub index: ::core::primitive::u32, + pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< + ::core::primitive::u8, + >, + #[codec(compact)] + pub major: ::core::primitive::u32, + #[codec(compact)] + pub minor: ::core::primitive::u32, + #[codec(compact)] + pub patch: ::core::primitive::u32, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct QueryResponseInfo { + pub destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, + #[codec(compact)] + pub query_id: ::core::primitive::u64, + pub max_weight: ::sp_weights::Weight, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Response { + #[codec(index = 0)] + Null, + #[codec(index = 1)] + Assets(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + #[codec(index = 2)] + ExecutionResult( + ::core::option::Option<( + ::core::primitive::u32, + runtime_types::staging_xcm::v3::traits::Error, + )>, + ), + #[codec(index = 3)] + Version(::core::primitive::u32), + #[codec(index = 4)] + PalletsInfo( + runtime_types::bounded_collections::bounded_vec::BoundedVec< + runtime_types::staging_xcm::v3::PalletInfo, + >, + ), + #[codec(index = 5)] + DispatchResult(runtime_types::staging_xcm::v3::MaybeErrorCode), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum WeightLimit { + #[codec(index = 0)] + Unlimited, + #[codec(index = 1)] + Limited(::sp_weights::Weight), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Xcm(pub ::sp_std::vec::Vec); + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct Xcm2(pub ::sp_std::vec::Vec); + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum VersionedAssetId { + // #[codec(index = 3)] + // V3(runtime_types::staging_xcm::v3::multiasset::AssetId), + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum VersionedMultiAssets { + #[codec(index = 1)] + V2(runtime_types::staging_xcm::v2::multiasset::MultiAssets), + #[codec(index = 3)] + V3(runtime_types::staging_xcm::v3::multiasset::MultiAssets), + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum VersionedMultiLocation { + #[codec(index = 1)] + V2(runtime_types::staging_xcm::v2::multilocation::MultiLocation), + #[codec(index = 3)] + V3(runtime_types::staging_xcm::v3::multilocation::MultiLocation), + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum VersionedResponse { + // #[codec(index = 2)] + // V2(runtime_types::staging_xcm::v2::Response), + // #[codec(index = 3)] + // V3(runtime_types::staging_xcm::v3::Response), + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum VersionedXcm { + // #[codec(index = 2)] + // V2(runtime_types::staging_xcm::v2::Xcm), + // #[codec(index = 3)] + // V3(runtime_types::staging_xcm::v3::Xcm), + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub enum VersionedXcm2 { + // #[codec(index = 2)] + // V2(runtime_types::staging_xcm::v2::Xcm2), + // #[codec(index = 3)] + // V3(runtime_types::staging_xcm::v3::Xcm2), + // } + } + + pub mod polkadot_runtime_common { + use super::runtime_types; + pub mod assigned_slots { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + PermanentSlotAssigned( + runtime_types::polkadot_parachain_primitives::primitives::Id, + ), + #[codec(index = 1)] + TemporarySlotAssigned( + runtime_types::polkadot_parachain_primitives::primitives::Id, + ), + #[codec(index = 2)] + MaxPermanentSlotsChanged { slots: ::core::primitive::u32 }, + #[codec(index = 3)] + MaxTemporarySlotsChanged { slots: ::core::primitive::u32 }, + } + } + } + pub mod auctions { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + AuctionStarted { + auction_index: ::core::primitive::u32, + lease_period: ::core::primitive::u32, + ending: ::core::primitive::u32, + }, + #[codec(index = 1)] + AuctionClosed { auction_index: ::core::primitive::u32 }, + #[codec(index = 2)] + Reserved { + bidder: ::sp_core::crypto::AccountId32, + extra_reserved: ::core::primitive::u128, + total_amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + Unreserved { + bidder: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 4)] + ReserveConfiscated { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + leaser: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 5)] + BidAccepted { + bidder: ::sp_core::crypto::AccountId32, + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + amount: ::core::primitive::u128, + first_slot: ::core::primitive::u32, + last_slot: ::core::primitive::u32, + }, + #[codec(index = 6)] + WinningOffset { + auction_index: ::core::primitive::u32, + block_number: ::core::primitive::u32, + }, + } + } + } + pub mod claims { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Claimed { + who: ::sp_core::crypto::AccountId32, + ethereum_address: + runtime_types::polkadot_runtime_common::claims::EthereumAddress, + amount: ::core::primitive::u128, + }, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct EthereumAddress(pub [::core::primitive::u8; 20usize]); + } + pub mod crowdloan { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Created { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 1)] + Contributed { + who: ::sp_core::crypto::AccountId32, + fund_index: + runtime_types::polkadot_parachain_primitives::primitives::Id, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + Withdrew { + who: ::sp_core::crypto::AccountId32, + fund_index: + runtime_types::polkadot_parachain_primitives::primitives::Id, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + PartiallyRefunded { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 4)] + AllRefunded { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 5)] + Dissolved { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 6)] + HandleBidResult { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + result: ::core::result::Result< + (), + runtime_types::sp_runtime::DispatchError, + >, + }, + #[codec(index = 7)] + Edited { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 8)] + MemoUpdated { + who: ::sp_core::crypto::AccountId32, + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + memo: ::sp_std::vec::Vec<::core::primitive::u8>, + }, + #[codec(index = 9)] + AddedToNewRaise { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + } + } + } + pub mod paras_registrar { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Registered { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + manager: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 1)] + Deregistered { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + #[codec(index = 2)] + Reserved { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + who: ::sp_core::crypto::AccountId32, + }, + #[codec(index = 3)] + Swapped { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + other_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + }, + } + } + } + pub mod slots { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + NewLeasePeriod { lease_period: ::core::primitive::u32 }, + #[codec(index = 1)] + Leased { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + leaser: ::sp_core::crypto::AccountId32, + period_begin: ::core::primitive::u32, + period_count: ::core::primitive::u32, + extra_reserved: ::core::primitive::u128, + total_amount: ::core::primitive::u128, + }, + } + } + } + } -impl Default for MyPhase { - fn default() -> Self { - Self::Initialization + pub mod pallet_state_trie_migration { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Error { + #[codec(index = 0)] + MaxSignedLimits, + #[codec(index = 1)] + KeyTooLong, + #[codec(index = 2)] + NotEnoughFunds, + #[codec(index = 3)] + BadWitness, + #[codec(index = 4)] + SignedMigrationNotAllowed, + #[codec(index = 5)] + BadChildRoot, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Migrated { + top: ::core::primitive::u32, + child: ::core::primitive::u32, + compute: + runtime_types::pallet_state_trie_migration::pallet::MigrationCompute, + }, + #[codec(index = 1)] + Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 2)] + AutoMigrationFinished, + #[codec(index = 3)] + Halted { error: runtime_types::pallet_state_trie_migration::pallet::Error }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum MigrationCompute { + #[codec(index = 0)] + Signed, + #[codec(index = 1)] + Auto, + } + } + } + pub mod bounded_collections { + use super::runtime_types; + pub mod bounded_vec { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct BoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); + } + pub mod weak_bounded_vec { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct WeakBoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); + } + } + pub mod primitive_types { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct H256(pub [::core::primitive::u8; 32usize]); + } + pub mod frame_system { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + ExtrinsicSuccess { + dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + }, + #[codec(index = 1)] + ExtrinsicFailed { + dispatch_error: runtime_types::sp_runtime::DispatchError, + dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, + }, + #[codec(index = 2)] + CodeUpdated, + #[codec(index = 3)] + NewAccount { account: ::sp_core::crypto::AccountId32 }, + #[codec(index = 4)] + KilledAccount { account: ::sp_core::crypto::AccountId32 }, + #[codec(index = 5)] + Remarked { + sender: ::sp_core::crypto::AccountId32, + hash: runtime_types::primitive_types::H256, + }, + } + } + } + pub mod frame_support { + use super::runtime_types; + pub mod dispatch { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum DispatchClass { + #[codec(index = 0)] + Normal, + #[codec(index = 1)] + Operational, + #[codec(index = 2)] + Mandatory, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct DispatchInfo { + pub weight: ::sp_weights::Weight, + pub class: runtime_types::frame_support::dispatch::DispatchClass, + pub pays_fee: runtime_types::frame_support::dispatch::Pays, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Pays { + #[codec(index = 0)] + Yes, + #[codec(index = 1)] + No, + } + } + pub mod traits { + use super::runtime_types; + pub mod messages { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum ProcessMessageError { + #[codec(index = 0)] + BadFormat, + #[codec(index = 1)] + Corrupt, + #[codec(index = 2)] + Unsupported, + #[codec(index = 3)] + Overweight(::sp_weights::Weight), + #[codec(index = 4)] + Yield, + } + } + pub mod tokens { + use super::runtime_types; + pub mod misc { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum BalanceStatus { + #[codec(index = 0)] + Free, + #[codec(index = 1)] + Reserved, + } + } + } + } + } + pub mod pallet_balances { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Endowed { + account: ::sp_core::crypto::AccountId32, + free_balance: ::core::primitive::u128, + }, + #[codec(index = 1)] + DustLost { + account: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + Transfer { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + BalanceSet { + who: ::sp_core::crypto::AccountId32, + free: ::core::primitive::u128, + }, + #[codec(index = 4)] + Reserved { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 5)] + Unreserved { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + ReserveRepatriated { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + destination_status: + runtime_types::frame_support::traits::tokens::misc::BalanceStatus, + }, + #[codec(index = 7)] + Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 8)] + Withdraw { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 9)] + Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 10)] + Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 11)] + Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 12)] + Suspended { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 13)] + Restored { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 14)] + Upgraded { who: ::sp_core::crypto::AccountId32 }, + #[codec(index = 15)] + Issued { amount: ::core::primitive::u128 }, + #[codec(index = 16)] + Rescinded { amount: ::core::primitive::u128 }, + #[codec(index = 17)] + Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 18)] + Unlocked { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 19)] + Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 20)] + Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event2 { + #[codec(index = 0)] + Endowed { + account: ::sp_core::crypto::AccountId32, + free_balance: ::core::primitive::u128, + }, + #[codec(index = 1)] + DustLost { + account: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 2)] + Transfer { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 3)] + BalanceSet { + who: ::sp_core::crypto::AccountId32, + free: ::core::primitive::u128, + }, + #[codec(index = 4)] + Reserved { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 5)] + Unreserved { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 6)] + ReserveRepatriated { + from: ::sp_core::crypto::AccountId32, + to: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + destination_status: + runtime_types::frame_support::traits::tokens::misc::BalanceStatus, + }, + #[codec(index = 7)] + Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 8)] + Withdraw { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 9)] + Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 10)] + Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 11)] + Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 12)] + Suspended { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 13)] + Restored { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 14)] + Upgraded { who: ::sp_core::crypto::AccountId32 }, + #[codec(index = 15)] + Issued { amount: ::core::primitive::u128 }, + #[codec(index = 16)] + Rescinded { amount: ::core::primitive::u128 }, + #[codec(index = 17)] + Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 18)] + Unlocked { + who: ::sp_core::crypto::AccountId32, + amount: ::core::primitive::u128, + }, + #[codec(index = 19)] + Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + #[codec(index = 20)] + Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, + } + } + } + pub mod polkadot_runtime_parachains { + use super::runtime_types; + pub mod assigner_on_demand { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + OnDemandOrderPlaced { + para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, + spot_price: ::core::primitive::u128, + }, + #[codec(index = 1)] + SpotTrafficSet { + traffic: runtime_types::sp_arithmetic::fixed_point::FixedU128, + }, + } + } + } + pub mod inclusion { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + CandidateBacked( + runtime_types::polkadot_primitives::v5::CandidateReceipt< + runtime_types::primitive_types::H256, + >, + runtime_types::polkadot_parachain_primitives::primitives::HeadData, + runtime_types::polkadot_primitives::v5::CoreIndex, + runtime_types::polkadot_primitives::v5::GroupIndex, + ), + #[codec(index = 1)] + CandidateIncluded( + runtime_types::polkadot_primitives::v5::CandidateReceipt< + runtime_types::primitive_types::H256, + >, + runtime_types::polkadot_parachain_primitives::primitives::HeadData, + runtime_types::polkadot_primitives::v5::CoreIndex, + runtime_types::polkadot_primitives::v5::GroupIndex, + ), + #[codec(index = 2)] + CandidateTimedOut( + runtime_types::polkadot_primitives::v5::CandidateReceipt< + runtime_types::primitive_types::H256, + >, + runtime_types::polkadot_parachain_primitives::primitives::HeadData, + runtime_types::polkadot_primitives::v5::CoreIndex, + ), + #[codec(index = 3)] + UpwardMessagesReceived { + from: runtime_types::polkadot_parachain_primitives::primitives::Id, + count: ::core::primitive::u32, + }, + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum AggregateMessageOrigin { + #[codec(index = 0)] + Ump(runtime_types::polkadot_runtime_parachains::inclusion::UmpQueueId), + } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct AvailabilityBitfieldRecord<_0> { + // pub bitfield: runtime_types::polkadot_primitives::v5::AvailabilityBitfield, + // pub submitted_at: _0, + // } + // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] + // pub struct CandidatePendingAvailability<_0, _1> { + // pub core: runtime_types::polkadot_primitives::v5::CoreIndex, + // pub hash: runtime_types::polkadot_core_primitives::CandidateHash, + // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, + // pub availability_votes: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub backers: ::subxt::utils::bits::DecodedBits< + // ::core::primitive::u8, + // ::subxt::utils::bits::Lsb0, + // >, + // pub relay_parent_number: _1, + // pub backed_in_number: _1, + // pub backing_group: runtime_types::polkadot_primitives::v5::GroupIndex, + // } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum UmpQueueId { + #[codec(index = 0)] + Para(runtime_types::polkadot_parachain_primitives::primitives::Id), + } + } + pub mod paras { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + # [codec (index = 0)] CurrentCodeUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 1)] CurrentHeadUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 2)] CodeUpgradeScheduled (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 3)] NewHeadNoted (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 4)] ActionQueued (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , :: core :: primitive :: u32 ,) , # [codec (index = 5)] PvfCheckStarted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 6)] PvfCheckAccepted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 7)] PvfCheckRejected (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , } + } + } + pub mod hrmp { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + OpenChannelRequested( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::Id, + ::core::primitive::u32, + ::core::primitive::u32, + ), + #[codec(index = 1)] + OpenChannelCanceled( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, + ), + #[codec(index = 2)] + OpenChannelAccepted( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::Id, + ), + #[codec(index = 3)] + ChannelClosed( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, + ), + #[codec(index = 4)] + HrmpChannelForceOpened( + runtime_types::polkadot_parachain_primitives::primitives::Id, + runtime_types::polkadot_parachain_primitives::primitives::Id, + ::core::primitive::u32, + ::core::primitive::u32, + ), + } + } + } + pub mod disputes { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + DisputeInitiated( + runtime_types::polkadot_core_primitives::CandidateHash, + runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, + ), + #[codec(index = 1)] + DisputeConcluded( + runtime_types::polkadot_core_primitives::CandidateHash, + runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, + ), + #[codec(index = 2)] + Revert(::core::primitive::u32), + } + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum DisputeLocation { + #[codec(index = 0)] + Local, + #[codec(index = 1)] + Remote, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum DisputeResult { + #[codec(index = 0)] + Valid, + #[codec(index = 1)] + Invalid, + } + } + } + pub mod polkadot_parachain_primitives { + use super::runtime_types; + pub mod primitives { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct HeadData(pub ::sp_std::vec::Vec<::core::primitive::u8>); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct HrmpChannelId { + pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, + pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Id(pub ::core::primitive::u32); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct ValidationCode(pub ::sp_std::vec::Vec<::core::primitive::u8>); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct ValidationCodeHash(pub runtime_types::primitive_types::H256); + } + } + pub mod pallet_sudo { + use super::runtime_types; + pub mod pallet { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum Event { + #[codec(index = 0)] + Sudid { + sudo_result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + #[codec(index = 1)] + KeyChanged { + old_sudoer: ::core::option::Option<::sp_core::crypto::AccountId32>, + }, + #[codec(index = 2)] + SudoAsDone { + sudo_result: + ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, + }, + } + } + } + pub mod sp_arithmetic { + use super::runtime_types; + pub mod fixed_point { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct FixedU128(pub ::core::primitive::u128); + } + pub mod per_things { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Perbill(pub ::core::primitive::u32); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Percent(pub ::core::primitive::u8); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Permill(pub ::core::primitive::u32); + #[derive( + :: codec :: Decode, + :: codec :: Encode, + // :: subxt :: ext :: codec :: CompactAs, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct Perquintill(pub ::core::primitive::u64); + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum ArithmeticError { + #[codec(index = 0)] + Underflow, + #[codec(index = 1)] + Overflow, + #[codec(index = 2)] + DivisionByZero, + } + } + pub mod sp_runtime { + use super::runtime_types; + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum DispatchError { + #[codec(index = 0)] + Other, + #[codec(index = 1)] + CannotLookup, + #[codec(index = 2)] + BadOrigin, + #[codec(index = 3)] + Module(runtime_types::sp_runtime::ModuleError), + #[codec(index = 4)] + ConsumerRemaining, + #[codec(index = 5)] + NoProviders, + #[codec(index = 6)] + TooManyConsumers, + #[codec(index = 7)] + Token(runtime_types::sp_runtime::TokenError), + #[codec(index = 8)] + Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), + #[codec(index = 9)] + Transactional(runtime_types::sp_runtime::TransactionalError), + #[codec(index = 10)] + Exhausted, + #[codec(index = 11)] + Corruption, + #[codec(index = 12)] + Unavailable, + #[codec(index = 13)] + RootNotAllowed, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub struct ModuleError { + pub index: ::core::primitive::u8, + pub error: [::core::primitive::u8; 4usize], + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum TokenError { + #[codec(index = 0)] + FundsUnavailable, + #[codec(index = 1)] + OnlyProvider, + #[codec(index = 2)] + BelowMinimum, + #[codec(index = 3)] + CannotCreate, + #[codec(index = 4)] + UnknownAsset, + #[codec(index = 5)] + Frozen, + #[codec(index = 6)] + Unsupported, + #[codec(index = 7)] + CannotCreateHold, + #[codec(index = 8)] + NotExpendable, + #[codec(index = 9)] + Blocked, + } + #[derive( + :: codec :: Decode, + :: codec :: Encode, + Clone, + Debug, + PartialEq, + Eq, + scale_info::TypeInfo, + )] + pub enum TransactionalError { + #[codec(index = 0)] + LimitReached, + #[codec(index = 1)] + NoLayer, + } + } } } diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index 1d53888..ef3e3fd 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -90,8 +90,8 @@ use sp_runtime::SaturatedConversion; use weights::{BlockExecutionWeight, ExtrinsicBaseWeight}; // XCM Imports use cumulus_primitives_core::{AggregateMessageOrigin, ParaId, PersistedValidationData}; -pub use pallet_bulk::{self, BulkGasCost}; -use pallet_liquidation::OrderGasCost; +pub use pallet_bulk; +use pallet_liquidation::{BulkGasCost, OrderGasCost}; pub use pallet_on_demand; use xcm::latest::prelude::{ Asset as MultiAsset, BodyId, InteriorLocation as InteriorMultiLocation, @@ -1013,7 +1013,7 @@ impl pallet_liquidation::Config for Runtime { type Currency = Balances; type XcmSender = xcm_config::XcmRouter; type WeightToFee = WeightToFee; - type OrderGasCost = (); + type OrderGasCost = OrderGasCostHandler; type ExistentialDeposit = ExistDeposit; type SystemAccountName = SystemAccountName; type TreasuryAccountName = TreasuryAccountName; From b7414108b232b32147dd5677f8fbb21dfda137c2 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Sat, 13 Jul 2024 09:44:19 +0800 Subject: [PATCH 38/44] Refactored the Assurance module and removed the liquidation-related code --- client/coretime/on-demand/src/lib.rs | 2 +- client/coretime/on-demand/src/metadata.rs | 2 +- pallets/assurance/src/lib.rs | 87 +++-------------------- pallets/assurance/src/mock.rs | 31 -------- pallets/assurance/src/tests.rs | 48 +------------ primitives/system/src/lib.rs | 13 +--- runtime/src/lib.rs | 5 +- 7 files changed, 17 insertions(+), 171 deletions(-) diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index 9f50046..3ccb468 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -225,7 +225,7 @@ where if !is_place_order { //check is need force bid coretime let force_bid = parachain.runtime_api().on_relaychain(block_hash, height).ok()?; - if all_gas_value.cmp(&Balance::from(0u32)) == Ordering::Greater && force_bid == 1 { + if all_gas_value.cmp(&Balance::from(0u32)) == Ordering::Greater && force_bid { is_place_order = true; order_type = OrderType::Force; } diff --git a/client/coretime/on-demand/src/metadata.rs b/client/coretime/on-demand/src/metadata.rs index 3da3849..31cb145 100644 --- a/client/coretime/on-demand/src/metadata.rs +++ b/client/coretime/on-demand/src/metadata.rs @@ -181,7 +181,7 @@ impl ::subxt::blocks::StaticExtrinsic for PlaceOrderKeepAlive { const CALL: &'static str = "place_order_keep_alive"; } -#[warn(dead_code)] +#[allow(dead_code)] pub fn place_order_keep_alive( max_amount: u128, para_id: Id, diff --git a/pallets/assurance/src/lib.rs b/pallets/assurance/src/lib.rs index 9f344e5..e0bb760 100644 --- a/pallets/assurance/src/lib.rs +++ b/pallets/assurance/src/lib.rs @@ -21,11 +21,9 @@ mod mock; #[cfg(test)] mod tests; -use frame_support::traits::{Currency, Get}; -use frame_support::{sp_runtime, weights::Weight}; -use mp_system::Liquidate; +use frame_support::traits::Get; +use frame_support::weights::Weight; pub use pallet::*; -use sp_core::crypto::AccountId32; #[frame_support::pallet] pub mod pallet { @@ -35,17 +33,10 @@ pub mod pallet { use frame_system::pallet_prelude::*; #[pallet::config] - pub trait Config: - pallet_pot::Config + cumulus_pallet_parachain_system::Config + frame_system::Config - { + pub trait Config: cumulus_pallet_parachain_system::Config + frame_system::Config { type RuntimeEvent: From> + IsType<::RuntimeEvent>; - /// System pot name - type SystemPotName: Get<&'static str>; - /// Liquidate type for liquidate - type Liquidate: Liquidate; - /// Threshod for force bid coretime and force liquidate + /// Threshod for force bid coretime type DefaultBidThreshold: Get; - type DefaultLiquidateThreshold: Get>; } #[pallet::pallet] @@ -55,8 +46,6 @@ pub mod pallet { #[pallet::generate_deposit(pub(super) fn deposit_event)] pub enum Event { NewBidThreshold(u32), - NewLiquidateThreshold(BalanceOf), - ForceLiquidate(BalanceOf), } #[pallet::error] @@ -65,24 +54,19 @@ pub mod pallet { #[pallet::genesis_config] pub struct GenesisConfig { pub bid_threshold: u32, - pub liquidate_threshold: BalanceOf, #[serde(skip)] pub _marker: PhantomData, } impl GenesisConfig { - pub fn new(bid_threshold: u32, liquidate_threshold: BalanceOf) -> Self { - Self { bid_threshold, liquidate_threshold, _marker: PhantomData } + pub fn new(bid_threshold: u32) -> Self { + Self { bid_threshold, _marker: PhantomData } } } impl Default for GenesisConfig { fn default() -> Self { - Self { - bid_threshold: T::DefaultBidThreshold::get(), - liquidate_threshold: T::DefaultLiquidateThreshold::get(), - _marker: PhantomData, - } + Self { bid_threshold: T::DefaultBidThreshold::get(), _marker: PhantomData } } } @@ -90,7 +74,6 @@ pub mod pallet { impl BuildGenesisConfig for GenesisConfig { fn build(&self) { >::put(self.bid_threshold); - >::put(self.liquidate_threshold); } } @@ -102,35 +85,8 @@ pub mod pallet { #[pallet::storage] pub type BidThreshold = StorageValue<_, u32, ValueQuery, DefaultBidThreshold>; - #[pallet::type_value] - pub fn DefaultLiquidateThreshold() -> BalanceOf { - T::DefaultLiquidateThreshold::get() - } - - #[pallet::storage] - pub type LiquidateThreshold = - StorageValue<_, BalanceOf, ValueQuery, DefaultLiquidateThreshold>; - #[pallet::hooks] - impl Hooks> for Pallet - where - T::AccountId: From, - { - fn on_initialize(_n: BlockNumberFor) -> Weight { - let mut weight = Weight::zero(); - - if let Ok(balance) = pallet_pot::Pallet::::balance_of(T::SystemPotName::get()) { - if balance < LiquidateThreshold::::get() { - weight += T::Liquidate::liquidate(); - Self::deposit_event(Event::ForceLiquidate(balance)); - } - weight += T::DbWeight::get().writes(1); - } - weight += T::DbWeight::get().reads(2); - - weight - } - } + impl Hooks> for Pallet {} #[pallet::call] impl Pallet { @@ -142,18 +98,6 @@ pub mod pallet { Self::deposit_event(Event::NewBidThreshold(blocknumber)); Ok(()) } - - #[pallet::call_index(1)] - #[pallet::weight(10_000 + T::DbWeight::get().writes(1).ref_time())] - pub fn set_liquidate_threshold( - origin: OriginFor, - balance: BalanceOf, - ) -> DispatchResult { - ensure_root(origin)?; - let _ = Self::set_liquidate_threshold_inner(balance); - Self::deposit_event(Event::NewLiquidateThreshold(balance)); - Ok(()) - } } impl Pallet { @@ -162,23 +106,14 @@ pub mod pallet { T::DbWeight::get().writes(1) } - pub fn set_liquidate_threshold_inner(value: BalanceOf) -> Weight { - >::put(value); - T::DbWeight::get().writes(1) - } - - pub fn on_relaychain(blocknumber: u32) -> i32 { + pub fn on_relaychain(blocknumber: u32) -> bool { let last_relay_block_number = RelaychainDataProvider::::current_relay_chain_state().number; if blocknumber > BidThreshold::::get() + u32::from(last_relay_block_number) { - return 1; + return true; } - 0 + false } } } - -pub type BalanceOf = <::Currency as Currency< - ::AccountId, ->>::Balance; diff --git a/pallets/assurance/src/mock.rs b/pallets/assurance/src/mock.rs index 2640979..44f77c7 100644 --- a/pallets/assurance/src/mock.rs +++ b/pallets/assurance/src/mock.rs @@ -14,8 +14,6 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -use super::*; - use cumulus_pallet_parachain_system::{ consensus_hook::{ConsensusHook, UnincludedSegmentCapacity}, relay_state_snapshot::RelayChainStateProof, @@ -28,15 +26,12 @@ use frame_support::{ traits::{ConstU32, ConstU64, Get}, weights::{constants::WEIGHT_REF_TIME_PER_SECOND, Weight}, }; -use pallet_pot::PotNameBtreemap; use sp_core::{crypto::AccountId32, H256}; use sp_runtime::{ traits::{BlakeTwo256, IdentityLookup}, BuildStorage, }; -use sp_std::collections::btree_map::BTreeMap; use sp_std::{cell::RefCell, num::NonZeroU32}; -//use frame_system::pallet_prelude::*; use crate as pallet_assurance; @@ -48,7 +43,6 @@ frame_support::construct_runtime!( Balances: pallet_balances::{Pallet, Call, Storage, Config, Event}, Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent}, ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Config, Storage, Event}, - Pot: pallet_pot::{Pallet, Call, Storage, Event}, Assurance: pallet_assurance::{Pallet, Call, Config, Storage, Event}, } ); @@ -168,35 +162,11 @@ impl ConsensusHook for TestConsensusHook { } } -parameter_types! { - pub const PotNames: [&'static str;3] = ["system", "treasury", "maintenance"]; - pub Pots: BTreeMap = pallet_pot - ::HashedPotNameBtreemap - ::> - ::pots_btreemap(&(PotNames::get())); -} - -impl pallet_pot::Config for Test { - type RuntimeEvent = RuntimeEvent; - type PotNameMapping = pallet_pot::HashedPotNameMapping; - type Currency = Balances; - type Pots = Pots; -} - -parameter_types! { - pub const SystemPotName: &'static str = "system"; -} - impl pallet_assurance::Config for Test { type RuntimeEvent = RuntimeEvent; - type SystemPotName = SystemPotName; - type Liquidate = (); type DefaultBidThreshold = ConstU32<8u32>; - type DefaultLiquidateThreshold = ConstU64<100_000_000_000_000>; } -pub const ALICE: AccountId32 = AccountId32::new([21u8; 32]); - pub struct ExtBuilder { existential_deposit: u64, } @@ -223,7 +193,6 @@ impl ExtBuilder { .unwrap(); pallet_assurance::GenesisConfig:: { bid_threshold: 8u32, - liquidate_threshold: 100_000_000_000_000u64, _marker: Default::default(), } .assimilate_storage(&mut t) diff --git a/pallets/assurance/src/tests.rs b/pallets/assurance/src/tests.rs index c1f9951..4798313 100644 --- a/pallets/assurance/src/tests.rs +++ b/pallets/assurance/src/tests.rs @@ -20,7 +20,6 @@ use crate as pallet_assurance; use crate::mock::*; use cumulus_pallet_parachain_system::{RelaychainDataProvider, RelaychainStateProvider}; use frame_support::assert_ok; -use frame_support::traits::Hooks; use Event as AssuranceEvent; #[test] @@ -34,20 +33,6 @@ fn set_bid_threshold_works() { }) } -#[test] -fn set_liquidate_threshold_works() { - ExtBuilder::default().existential_deposit(100).build().execute_with(|| { - let default_liquidate_threshold = pallet_assurance::LiquidateThreshold::::get(); - assert_eq!(default_liquidate_threshold, 100_000_000_000_000u64); - assert_ok!(Assurance::set_liquidate_threshold( - RuntimeOrigin::root(), - 200_000_000_000_000u64 - )); - expect_event(AssuranceEvent::NewLiquidateThreshold(200_000_000_000_000u64)); - assert_eq!(pallet_assurance::LiquidateThreshold::::get(), 200_000_000_000_000u64); - }) -} - #[test] fn on_relaychain_works() { ExtBuilder::default().existential_deposit(100).build().execute_with(|| { @@ -57,39 +42,10 @@ fn on_relaychain_works() { assert_eq!(bid_threshold, 8u32); let on_relay_return = Assurance::on_relaychain(parent_relay_blocknumber); - assert_eq!(on_relay_return, 0); + assert_eq!(on_relay_return, false); let on_relay_return = Assurance::on_relaychain(parent_relay_blocknumber + bid_threshold + 1u32); - assert_eq!(on_relay_return, 1); - }) -} - -#[test] -fn force_liquidate_works() { - ExtBuilder::default().existential_deposit(100).build().execute_with(|| { - assert_ok!(Pot::ensure_pot("system")); - let pot_system = Pot::ensure_pot("system").unwrap(); - let liquidate_threshold = pallet_assurance::LiquidateThreshold::::get(); - assert_eq!(liquidate_threshold, 100_000_000_000_000u64); - - let _ = Balances::deposit_creating(&pot_system, liquidate_threshold); - - System::on_finalize(System::block_number()); - System::reset_events(); - System::set_block_number(System::block_number() + 1); - System::on_initialize(System::block_number()); - Assurance::on_initialize(System::block_number()); - System::on_finalize(System::block_number()); - - assert_ok!(Pot::withdraw(RuntimeOrigin::root(), ALICE, "system".to_string(), 1)); - - System::on_finalize(System::block_number()); - System::reset_events(); - System::set_block_number(System::block_number() + 1); - System::on_initialize(System::block_number()); - Assurance::on_initialize(System::block_number()); - expect_event(AssuranceEvent::ForceLiquidate(liquidate_threshold - 1)); - System::on_finalize(System::block_number()); + assert_eq!(on_relay_return, true); }) } diff --git a/primitives/system/src/lib.rs b/primitives/system/src/lib.rs index fb52ae5..f94a034 100644 --- a/primitives/system/src/lib.rs +++ b/primitives/system/src/lib.rs @@ -16,7 +16,6 @@ #![cfg_attr(not(feature = "std"), no_std)] -use frame_support::weights::Weight; use sp_core::crypto::AccountId32; // Base account id b"system:base' and fill with 1u32 @@ -26,20 +25,10 @@ const A: [u8; 32] = [ ]; pub const BASE_ACCOUNT: AccountId32 = AccountId32::new(A); -pub trait Liquidate { - fn liquidate() -> Weight; -} - -impl Liquidate for () { - fn liquidate() -> Weight { - Weight::zero() - } -} - sp_api::decl_runtime_apis! { // API for on_relaychain call pub trait OnRelayChainApi { // return on_relaychain call result, 1 for force bid coretime - fn on_relaychain(blocknumber: u32) -> i32; + fn on_relaychain(blocknumber: u32) -> bool; } } diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index ef3e3fd..c9f66f8 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -983,10 +983,7 @@ parameter_types! { impl pallet_assurance::Config for Runtime { type RuntimeEvent = RuntimeEvent; - type SystemPotName = SystemPotName; - type Liquidate = (); type DefaultBidThreshold = ConstU32<8>; - type DefaultLiquidateThreshold = ConstU128<0>; } impl pallet_utility::Config for Runtime { @@ -1719,7 +1716,7 @@ impl_runtime_apis! { } impl mp_system::OnRelayChainApi for Runtime { - fn on_relaychain(block_number: u32) -> i32 { + fn on_relaychain(block_number: u32) -> bool { Assurance::on_relaychain(block_number) } } From 920b1cb3fcf000c52e94bb95844c599212eccb1a Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Mon, 15 Jul 2024 17:26:56 +0800 Subject: [PATCH 39/44] Refactor on demand code, add test files and benchmark test files --- Cargo.lock | 7 +- Cargo.toml | 1 + client/coretime/bulk/src/lib.rs | 6 +- client/coretime/on-demand/Cargo.toml | 3 +- client/coretime/on-demand/src/lib.rs | 165 +- client/coretime/on-demand/src/metadata.rs | 20 + node/src/chain_spec.rs | 4 +- node/src/service.rs | 29 +- pallets/assurance/Cargo.toml | 3 +- pallets/assurance/README.md | 3 +- pallets/on-demand/Cargo.toml | 4 + pallets/on-demand/src/benchmarking.rs | 119 +- pallets/on-demand/src/lib.rs | 343 +- pallets/on-demand/src/mock.rs | 441 +- pallets/on-demand/src/proof_data.rs | 29 - pallets/on-demand/src/tests.rs | 134 +- pallets/on-demand/src/weights.rs | 132 +- .../coretime/on-demand/src/inherent_client.rs | 46 +- primitives/coretime/on-demand/src/lib.rs | 45 +- primitives/coretime/on-demand/src/metadata.rs | 5350 ----------------- .../coretime/on-demand/src/well_known_keys.rs | 29 +- runtime/Cargo.toml | 2 +- runtime/src/lib.rs | 25 +- 23 files changed, 847 insertions(+), 6093 deletions(-) delete mode 100644 pallets/on-demand/src/proof_data.rs delete mode 100644 primitives/coretime/on-demand/src/metadata.rs diff --git a/Cargo.lock b/Cargo.lock index 6e9e60a..4310c35 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -6444,6 +6444,7 @@ dependencies = [ "mp-coretime-common", "mp-coretime-on-demand", "mp-system", + "pallet-balances", "pallet-broker", "pallet-transaction-payment-rpc-runtime-api", "parity-scale-codec", @@ -6470,6 +6471,7 @@ dependencies = [ "sp-consensus-aura", "sp-core 28.0.0", "sp-inherents", + "sp-keyring", "sp-keystore 0.34.0", "sp-runtime 31.0.1", "sp-state-machine 0.35.0", @@ -8008,9 +8010,9 @@ dependencies = [ "frame-benchmarking", "frame-support", "frame-system", + "log", "mp-system", "pallet-balances", - "pallet-pot", "pallet-timestamp", "parity-scale-codec", "scale-info", @@ -8970,9 +8972,11 @@ dependencies = [ "hex-literal", "log", "mp-coretime-on-demand", + "pallet-aura", "pallet-balances", "pallet-collective", "pallet-society", + "pallet-timestamp", "pallet-xcm", "parachains-common", "parity-scale-codec", @@ -8983,6 +8987,7 @@ dependencies = [ "sp-consensus-aura", "sp-core 28.0.0", "sp-io 30.0.0", + "sp-keyring", "sp-runtime 31.0.1", "sp-trie 29.0.0", "staging-xcm-builder", diff --git a/Cargo.toml b/Cargo.toml index b4283ce..96be7da 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -118,6 +118,7 @@ sp-version = { git = "https://github.com/paritytech/polkadot-sdk", branch = "rel sp-weights = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } pallet-broker = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } sp-storage = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } +sp-keyring = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } # Substrate FRAME frame-benchmarking = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.7.0", default-features = false } diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index fde6d37..488aea6 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -243,7 +243,7 @@ pub async fn run_coretime_bulk_task( PB::Public: AppPublic + Member + Codec, PB::Signature: TryFrom> + Member + Codec, { - let relay_chain_notification = async move { + let bulk_task = async move { loop { let _ = coretime_bulk_task::<_, _, _, PB>( &*parachain, @@ -255,7 +255,7 @@ pub async fn run_coretime_bulk_task( } }; select! { - _ = relay_chain_notification.fuse() => {}, + _ = bulk_task.fuse() => {}, } } @@ -284,6 +284,6 @@ where ); task_manager .spawn_essential_handle() - .spawn("bulk task", "magport", coretime_bulk_task); + .spawn("bulk task", "coretime", coretime_bulk_task); Ok(()) } diff --git a/client/coretime/on-demand/Cargo.toml b/client/coretime/on-demand/Cargo.toml index 2e57e5e..d59fbe7 100644 --- a/client/coretime/on-demand/Cargo.toml +++ b/client/coretime/on-demand/Cargo.toml @@ -49,7 +49,8 @@ sc-service = { workspace = true } pallet-broker = { workspace = true} sp-storage = { workspace = true } pallet-transaction-payment-rpc-runtime-api = { workspace = true} - +sp-keyring = { workspace = true } +pallet-balances = { workspace = true} # Cumulus cumulus-client-consensus-common = { workspace = true } cumulus-client-parachain-inherent = { workspace = true } diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index 3ccb468..6d0b7a5 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -35,11 +35,12 @@ use mc_coretime_common::is_parathread; use metadata::{CoreAssignment, CoreDescriptor}; use mp_coretime_on_demand::{ self, - well_known_keys::paras_core_descriptors, - well_known_keys::{ACTIVE_CONFIG, ON_DEMAND_QUEUE, SPOT_TRAFFIC, SYSTEM_EVENTS}, + well_known_keys::{acount_balance, paras_core_descriptors}, + well_known_keys::{EnqueuedOrder, ACTIVE_CONFIG, ON_DEMAND_QUEUE, SPOT_TRAFFIC, SYSTEM_EVENTS}, OrderRecord, OrderRuntimeApi, OrderStatus, }; use mp_system::OnRelayChainApi; +use pallet_balances::AccountData; pub use pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi; use polkadot_primitives::OccupiedCoreAssumption; use runtime_parachains::configuration::HostConfiguration; @@ -51,6 +52,7 @@ use sp_application_crypto::AppPublic; use sp_consensus_aura::AuraApi; use sp_core::{crypto::Pair, H256}; use sp_keystore::KeystorePtr; +use sp_runtime::AccountId32; use sp_runtime::{ codec::Encode, traits::{ @@ -62,12 +64,10 @@ use sp_runtime::{ use std::{cmp::Ordering, net::SocketAddr}; use std::{convert::TryFrom, error::Error, fmt::Debug, sync::Arc}; use submit_order::{build_rpc_for_submit_order, SubmitOrderError}; - -#[derive(Encode, Decode, Debug, PartialEq, Clone)] -struct EnqueuedOrder { - /// Parachain ID - pub para_id: ParaId, -} +use subxt::{ + backend::{legacy::LegacyRpcMethods, rpc::RpcClient}, + OnlineClient, PolkadotConfig, +}; /// Order type #[derive(Clone, PartialEq, Debug)] @@ -206,9 +206,14 @@ where .ok()?; all_gas_value = query_fee.final_fee().add(all_gas_value); if transaction_pool.status().ready != 0 { + // Converted to a precision of 18 is_place_order = parachain .runtime_api() - .reach_txpool_threshold(block_hash, all_gas_value, core_price) + .reach_txpool_threshold( + block_hash, + all_gas_value, + core_price.saturating_mul(1_000_000u32.into()), + ) .ok()?; } log::info!( @@ -341,32 +346,11 @@ where let slot_block = base.pow(slot_width); if height % slot_block == 0 { let mut order_record_local = order_record.lock().await; - order_record_local.order_status = OrderStatus::Init; - } - let mut relevant_keys = Vec::new(); - //System Events - relevant_keys.push(SYSTEM_EVENTS.to_vec()); - let storage_proof = relay_chain.prove_read(p_hash, &relevant_keys).await?; - let order_placed = parachain.runtime_api().order_placed( - hash, - storage_proof, - validation_data.clone(), - para_id, - )?; - let sequence_number = parachain.runtime_api().sequence_number(hash)?; - // Get information about the OnDemandOrderPlaced event. - if let Some(author) = order_placed { - log::info!("============find order============="); - // Get the event and the account who placed the order - let mut order_record_local = order_record.lock().await; - order_record_local.relay_parent = Some(p_hash); - order_record_local.relay_height = height; - order_record_local.validation_data = Some(validation_data); - order_record_local.author_pub = Some(author); - order_record_local.sequence_number = sequence_number; - order_record_local.txs = get_txs(transaction_pool.clone()).await; - return Ok(()); + order_record_local.reset(); } + let order_period = height & (slot_block - 1) < slot_block / 2; + log::info!("===============relaychain height:{:?},is order period:{:?}", height, order_period); + // Check whether the conditions for placing an order are met, and if so, place the order // Check if it is in the ondemand queue, if so, do not place a order. @@ -385,6 +369,8 @@ where } } if exist_order { + let mut order_record_local = order_record.lock().await; + order_record_local.order_status = OrderStatus::Complete; return Ok(()); } // get on demand core price @@ -396,7 +382,7 @@ where let reached = reach_txpool_threshold::<_, _, _, _, PB>( parachain, - transaction_pool, + transaction_pool.clone(), height, order_record_local.txs.clone(), spot_price, @@ -416,12 +402,16 @@ where } } } - if collator_public.is_some() { + if let Some(author) = collator_public { //your turn if can_order { - if height - order_record_local.relay_height > slot_block { + if order_period { if order_record_local.order_status == OrderStatus::Init { log::info!("============place order, type:{:?}", order_type); + order_record_local.relay_parent = p_hash; + order_record_local.relay_height = height; + order_record_local.author_pub = Some(author); + order_record_local.txs = get_txs(transaction_pool).await; let order_result = try_place_order::(keystore, para_id, url, spot_price).await; order_record_local.order_status = OrderStatus::Order; @@ -509,6 +499,89 @@ async fn relay_chain_notification( } } +pub async fn ondemand_event_task( + parachain: &P, + relay_chain: R, + para_id: ParaId, + rpc_url: String, + order_record: Arc>>, +) -> Result<(), Box> +where + Block: BlockT, + P: ProvideRuntimeApi + UsageProvider, + R: RelayChainInterface + Clone, + PB: Pair, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, +{ + let relay_chain_clone = relay_chain.clone(); + + let hash = parachain.usage_info().chain.finalized_hash; + + // Get the final block of the relaychain through subxt. + + let api = OnlineClient::::from_url(rpc_url).await?; + + let mut blocks_sub = api.blocks().subscribe_best().await?; + + // For each block, print a bunch of information about it: + while let Some(block) = blocks_sub.next().await { + let block = block?; + + let block_number = block.header().number; + + let events = block.events().await?; + for event in events.iter() { + let event = event?; + // Query Broker Assigned Event + let ev_order_placed = event.as_event::(); + if let Ok(order_placed_event) = ev_order_placed { + if let Some(ev) = order_placed_event { + log::info!( + "=====================Find OnDemandOrderPlaced event:{:?},{:?}================", + ev.para_id, + ev.spot_price, + ); + let exp_id: u32 = para_id.into(); + if ev.para_id.0 == exp_id { + // The orderer gets it from the slot by default. + let mut order_record_local = order_record.lock().await; + order_record_local.price = ev.spot_price; + order_record_local.order_status = OrderStatus::Execute; + } + } + } + } + } + Ok(()) +} + +async fn event_notification( + parachain: Arc

, + relay_chain: R, + para_id: ParaId, + url: String, + order_record: Arc>>, +) where + R: RelayChainInterface + Clone, + Block: BlockT, + P: ProvideRuntimeApi + UsageProvider, + PB: Pair, + PB::Public: AppPublic + Member + Codec, + PB::Signature: TryFrom> + Member + Codec, +{ + loop { + let _ = ondemand_event_task::<_, _, _, PB>( + &*parachain, + relay_chain.clone(), + para_id, + url.clone(), + order_record.clone(), + ) + .await; + } +} + pub async fn run_on_demand_task( para_id: ParaId, parachain: Arc

, @@ -541,17 +614,25 @@ pub async fn run_on_demand_task( let relay_chain_notification = relay_chain_notification::<_, _, _, PB, _, _>( para_id, parachain.clone(), - relay_chain, + relay_chain.clone(), keystore, - order_record, + order_record.clone(), transaction_pool, + url.clone(), + ); + let event_notification = event_notification::<_, _, _, PB>( + parachain.clone(), + relay_chain.clone(), + para_id, url, + order_record, ); select! { _ = relay_chain_notification.fuse() => {}, + _ = event_notification.fuse() => {}, } } - +use sp_keyring::Sr25519Keyring::Alice; pub fn spawn_on_demand_order( parachain: Arc, para_id: ParaId, @@ -597,8 +678,8 @@ where url, ); task_manager.spawn_essential_handle().spawn_blocking( - "on_demand_order_task", - None, + "on demand order task", + "coretime", on_demand_order_task, ); Ok(()) diff --git a/client/coretime/on-demand/src/metadata.rs b/client/coretime/on-demand/src/metadata.rs index 31cb145..ce5404b 100644 --- a/client/coretime/on-demand/src/metadata.rs +++ b/client/coretime/on-demand/src/metadata.rs @@ -197,3 +197,23 @@ pub fn place_order_keep_alive( ], ) } + +#[derive( + :: subxt :: ext :: codec :: Decode, + :: subxt :: ext :: codec :: Encode, + :: subxt :: ext :: scale_decode :: DecodeAsType, + :: subxt :: ext :: scale_encode :: EncodeAsType, + Debug, +)] +# [codec (crate = :: subxt :: ext :: codec)] +#[decode_as_type(crate_path = ":: subxt :: ext :: scale_decode")] +#[encode_as_type(crate_path = ":: subxt :: ext :: scale_encode")] +pub struct OnDemandOrderPlaced { + pub para_id: Id, + pub spot_price: u128, +} + +impl ::subxt::events::StaticEvent for OnDemandOrderPlaced { + const PALLET: &'static str = "OnDemandAssignmentProvider"; + const EVENT: &'static str = "OnDemandOrderPlaced"; +} diff --git a/node/src/chain_spec.rs b/node/src/chain_spec.rs index bd14c8f..e1d2408 100644 --- a/node/src/chain_spec.rs +++ b/node/src/chain_spec.rs @@ -292,9 +292,9 @@ fn testnet_genesis( "genesisHash": U256::from_str("0x4ea18c8f295ba903acbbed39c70ea0569cf1705fa954a537ffa3b8b7125eaf58").expect("internal U256 is valid; qed") }, "orderPallet": { - "slotWidth": 2, + "slotWidth": 3, "priceLimit": 200000000, - "priceThreshold": 10, + "gasThreshold": 10, }, "liquidation":{ "adminKey": Some(root.clone()), diff --git a/node/src/service.rs b/node/src/service.rs index e195889..3abf526 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -49,13 +49,14 @@ use crate::eth::{ FrontierBlockImport as TFrontierBlockImport, FrontierPartialComponents, }; +use cumulus_relay_chain_interface::OccupiedCoreAssumption; +use cumulus_relay_chain_interface::PersistedValidationData; use futures::lock::Mutex; use mc_coretime_bulk::spawn_bulk_task; use mc_coretime_on_demand::spawn_on_demand_order; use mp_coretime_bulk::BulkMemRecord; use mp_coretime_bulk::BulkStatus; use mp_coretime_on_demand::OrderRecord; - /// Native executor type. pub struct ParachainNativeExecutor; @@ -627,27 +628,19 @@ fn start_consensus( "Failed to create bulk inherent", ) })?; - let parent_hash = relay_chain_interface.finalized_block_hash().await?; - let (relay_parent, validation_data, sequence_number, author_pub) = { + + let (author_pub, relay_chian_number, price) = { let order_record_local = order_record_clone.lock().await; - if order_record_local.validation_data.is_none() { - (parent_hash, None, order_record_local.sequence_number, None) - } else { - ( - order_record_local.relay_parent.expect("can not get relay_parent hash"), - order_record_local.validation_data.clone(), - order_record_local.sequence_number, - order_record_local.author_pub.clone(), - ) - } + ( + order_record_local.author_pub.clone(), + order_record_local.relay_height, + order_record_local.price, + ) }; let order_inherent = mp_coretime_on_demand::OrderInherentData::create_at( - relay_parent, - &relay_chain_interface, - &validation_data, - para_id, - sequence_number, + relay_chian_number, &author_pub, + price, ) .await; let order_inherent = order_inherent.ok_or_else(|| { diff --git a/pallets/assurance/Cargo.toml b/pallets/assurance/Cargo.toml index 4b4abba..e48d85b 100644 --- a/pallets/assurance/Cargo.toml +++ b/pallets/assurance/Cargo.toml @@ -16,7 +16,7 @@ targets = ["x86_64-unknown-linux-gnu"] codec = { package = "parity-scale-codec", workspace = true, features = ["derive"], default-features = false } scale-info = { workspace = true, default-features = false, features = ["derive"] } mp-system = { path = "../../primitives/system", default-features = false } -pallet-pot = { path = "../pot", default-features = false } +log = { workspace = true } # Substrate frame-benchmarking = { workspace = true, default-features = false, optional = true} @@ -61,7 +61,6 @@ std = [ "cumulus-pallet-parachain-system/std", "cumulus-primitives-core/std", "mp-system/std", - "pallet-pot/std", ] try-runtime = [ "frame-support/try-runtime", diff --git a/pallets/assurance/README.md b/pallets/assurance/README.md index 6f483c2..4a390c2 100644 --- a/pallets/assurance/README.md +++ b/pallets/assurance/README.md @@ -1,4 +1,4 @@ -# EVM-Utils Pallet +# Assurance Pallet The Assurance Pallet ensuring block production as parathread. @@ -7,7 +7,6 @@ The Assurance Pallet ensuring block production as parathread. ### Dispatchable Functions -- `deposit` - deposit currency Dot to systems and special accounts. diff --git a/pallets/on-demand/Cargo.toml b/pallets/on-demand/Cargo.toml index ea3e80f..9851647 100644 --- a/pallets/on-demand/Cargo.toml +++ b/pallets/on-demand/Cargo.toml @@ -37,6 +37,7 @@ sp-runtime = { workspace = true, default-features = false} sp-trie = { workspace = true, default-features = false } pallet-balances = { workspace = true, default-features = false } sp-core = { workspace = true , default-features = false} +pallet-aura = { workspace = true, default-features = false } [dev-dependencies] serde = { workspace = true } @@ -54,6 +55,8 @@ pallet-xcm = { workspace = true, default-features = false} pallet-society ={ workspace = true, default-features = false} xcm-builder = { workspace = true, default-features = false } parachains-common = { workspace = true, default-features = false } +pallet-timestamp = { workspace = true, default-features = false } +sp-keyring = { workspace = true, default-features = false} [features] default = [ "std" ] @@ -82,6 +85,7 @@ std = [ "sp-trie/std", "pallet-balances/std", "sp-core/std", + "pallet-aura/std", ] try-runtime = [ "frame-support/try-runtime", diff --git a/pallets/on-demand/src/benchmarking.rs b/pallets/on-demand/src/benchmarking.rs index 3abea2f..ffa1f93 100644 --- a/pallets/on-demand/src/benchmarking.rs +++ b/pallets/on-demand/src/benchmarking.rs @@ -1,40 +1,85 @@ -// // Copyright (C) Magnet. -// // This file is part of Magnet. - -// // Magnet is free software: you can redistribute it and/or modify -// // it under the terms of the GNU General Public License as published by -// // the Free Software Foundation, either version 3 of the License, or -// // (at your option) any later version. - -// // Magnet is distributed in the hope that it will be useful, -// // but WITHOUT ANY WARRANTY; without even the implied warranty of -// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// // GNU General Public License for more details. - -// // You should have received a copy of the GNU General Public License -// // along with Magnet. If not, see . - -// //! Benchmarking setup for pallet-order - -// use super::*; - -// #[allow(unused)] -// use crate::Pallet as Order; -// use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller}; -// use frame_system::RawOrigin; - -// benchmarks! { -// set_parameter { -// let s in 0 .. 100; -// let caller: T::AccountId = whitelisted_caller(); -// let test_balance = BalanceOf::::from(200000000 as u32); -// let test_threshold = BalanceOf::::from(3000000000 as u32); -// }: _(RawOrigin::Root, Some(4), Some(test_balance), Some(test_threshold)) -// verify { -// assert_eq!(SlotWidth::::get(), 4); -// assert_eq!(OrderMaxAmount::::get(), test_balance); -// assert_eq!(TxPoolThreshold::::get(), test_threshold); +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +//! Benchmarking setup for pallet-order +#![cfg(feature = "runtime-benchmarks")] +pub use super::*; + +#[allow(unused)] +use crate::Pallet as Order; +use codec::Encode; +use frame_benchmarking::{benchmarks, impl_benchmark_test_suite, whitelisted_caller}; +use frame_system::RawOrigin; +use sp_core::crypto::UncheckedFrom; +use sp_runtime::Perbill; + +// mod test_mod { +// use scale_info::prelude::format; +// use sp_core::{Pair, Public, H160, U256}; +// pub fn get_from_seed(seed: &str) -> ::Public { +// TPublic::Pair::from_string(&format!("//{}", seed), None) +// .expect("static values are valid; qed") +// .public() // } // } +benchmarks! { + set_slot_width { + let s in 0 .. 100; + let caller: T::AccountId = whitelisted_caller(); + }: _(RawOrigin::Root, 3) + verify { + assert_eq!(SlotWidth::::get(), 3); + + } + + set_price_limit { + let s in 0 .. 100; + let caller: T::AccountId = whitelisted_caller(); + let price_limit = BalanceOf::::from(1000000000 as u32); + }: _(RawOrigin::Root, price_limit) + verify { + assert_eq!(PriceLimit::::get(), price_limit); + } + + set_gas_threshold { + let s in 0 .. 100; + let caller: T::AccountId = whitelisted_caller(); + let threshold = Perbill::from_percent(10); + }: _(RawOrigin::Root, threshold) + verify { + assert_eq!(GasThreshold::::get(), threshold); + } + + create_order { + let s in 0..100; + // let author = test_mod::get_from_seed::("Alice"); + // let mut r = [0u8; 32]; + // r.copy_from_slice(author.encode().as_slice()); + let r = [0xd4,0x35,0x93,0xc7,0x15,0xfd,0xd3,0x1c,0x61,0x14,0x1a,0xbd,0x04,0xa9,0x9f,0xd6,0x82,0x2c,0x85,0x58,0x85,0x4c,0xcd,0xe3,0x9a,0x56,0x84,0xe7,0xa5,0x6d,0xa2,0x7d]; + let author_pub = ::AuthorityId::unchecked_from(r); + let bulk_inherent_data = mp_coretime_on_demand::OrderInherentData { + relay_chian_number: 40, + author_pub: Some(author_pub), + price: 10000000, + }; + + }: _(RawOrigin::None, bulk_inherent_data) + verify { + assert_eq!(SequenceNumber::::get(), 1); + } +} -// impl_benchmark_test_suite!(Order, crate::mock::ExtBuilder::default().build(), crate::mock::Test,); +impl_benchmark_test_suite!(Order, crate::mock::ExtBuilder::default().build(), crate::mock::Test,); diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs index 13f8923..8ce56e7 100644 --- a/pallets/on-demand/src/lib.rs +++ b/pallets/on-demand/src/lib.rs @@ -26,7 +26,7 @@ //! whether the order has been executed, whether the order threshold has been reached, etc. #![cfg_attr(not(feature = "std"), no_std)] -use codec::{Decode, MaxEncodedLen}; +use codec::{Decode, EncodeLike, MaxEncodedLen}; use cumulus_pallet_parachain_system::RelayChainStateProof; use frame_support::{ dispatch::DispatchResultWithPostInfo, dispatch::PostDispatchInfo, pallet_prelude::*, @@ -34,28 +34,31 @@ use frame_support::{ }; use frame_system::pallet_prelude::*; use frame_system::{self, EventRecord}; -use mp_coretime_on_demand::{ - metadata::api::{runtime_types, runtime_types::rococo_runtime as polakdot_runtime}, - well_known_keys::SYSTEM_EVENTS, -}; pub use pallet::*; use primitives::Balance; use primitives::{Id as ParaId, PersistedValidationData}; use sp_runtime::sp_std::{prelude::*, vec}; use sp_runtime::{traits::Member, RuntimeAppPublic}; pub mod weights; +use cumulus_pallet_parachain_system::RelaychainStateProvider; +use frame_system::AccountInfo; +use mp_coretime_on_demand::well_known_keys::{acount_balance, EnqueuedOrder, ON_DEMAND_QUEUE}; +use pallet_balances::AccountData; use sp_core::crypto::ByteArray; +use sp_core::crypto::UncheckedFrom; +use sp_runtime::traits::AccountIdConversion; use sp_runtime::Perbill; +use sp_runtime::{self, AccountId32}; use weights::WeightInfo; + #[cfg(test)] mod mock; #[cfg(test)] mod tests; -#[cfg(any(test, feature = "runtime-benchmarks"))] +#[cfg(feature = "runtime-benchmarks")] mod benchmarking; -mod proof_data; type BalanceOf = <::Currency as Currency<::AccountId>>::Balance; @@ -65,14 +68,14 @@ type BalanceOf = pub struct Order { /// The number used to record the order, incremented each time. pub sequence_number: u64, - // relaychain_block_hash:Hash, - // relaychain_block_height:u32, + /// The height of the relay chain block that created the record. + pub relay_chian_height: u32, + /// The height of the relay chain block that place this order. + pub place_order_height: u32, /// Account for placing order. pub orderer: AuthorityId, /// Order price. pub price: Balance, - /// Whether the order was executed. - pub executed: bool, } #[frame_support::pallet] pub mod pallet { @@ -81,7 +84,7 @@ pub mod pallet { /// Configure the pallet by specifying the parameters and types on which it depends. #[pallet::config] - pub trait Config: frame_system::Config { + pub trait Config: frame_system::Config + pallet_aura::Config { /// Because this pallet emits events, it depends on the runtime's definition of an event. type RuntimeEvent: From> + IsType<::RuntimeEvent>; @@ -92,11 +95,14 @@ pub mod pallet { + RuntimeAppPublic + MaybeSerializeDeserialize + MaxEncodedLen - + for<'a> TryFrom<&'a [u8]>; + + UncheckedFrom<[u8; 32]>; + // + for<'a> TryFrom<&'a [u8]>; type UpdateOrigin: EnsureOrigin; type WeightInfo: WeightInfo; + + type RelayChainStateProvider: cumulus_pallet_parachain_system::RelaychainStateProvider; } #[pallet::pallet] @@ -107,11 +113,6 @@ pub mod pallet { #[pallet::getter(fn sequence_number)] pub type SequenceNumber = StorageValue<_, u64, ValueQuery>; - /// Record the relaychain block height of the latest order - #[pallet::storage] - #[pallet::getter(fn current_relay_height)] - pub type CurrentRelayHeight = StorageValue<_, u32, ValueQuery>; - /// The order interval is 2^slotwidth. #[pallet::storage] #[pallet::getter(fn slot_width)] @@ -119,19 +120,19 @@ pub mod pallet { /// The maximum price the user is willing to pay when placing an order. #[pallet::storage] - #[pallet::getter(fn order_max_amount)] - pub(super) type OrderMaxAmount = StorageValue<_, BalanceOf, ValueQuery>; + #[pallet::getter(fn price_limit)] + pub(super) type PriceLimit = StorageValue<_, BalanceOf, ValueQuery>; /// Gas threshold that triggers order placement. #[pallet::storage] - #[pallet::getter(fn txpool_threshold)] - pub(super) type TxPoolThreshold = StorageValue<_, Perbill, ValueQuery>; + #[pallet::getter(fn gas_threshold)] + pub(super) type GasThreshold = StorageValue<_, Perbill, ValueQuery>; /// Order Information Map. #[pallet::storage] #[pallet::getter(fn order_map)] pub type OrderMap = - StorageMap<_, Twox64Concat, u64, Order, OptionQuery>; + StorageMap<_, Twox64Concat, u64, Order<::AuthorityId>, OptionQuery>; /// Convert block height to sequence number. #[pallet::storage] @@ -144,15 +145,15 @@ pub mod pallet { pub struct GenesisConfig { pub slot_width: u32, pub price_limit: BalanceOf, - pub price_threshold: Perbill, + pub gas_threshold: Perbill, } #[pallet::genesis_build] impl BuildGenesisConfig for GenesisConfig { fn build(&self) { SlotWidth::::put(&self.slot_width); - OrderMaxAmount::::put(&self.price_limit); - TxPoolThreshold::::put(&self.price_threshold); + PriceLimit::::put(&self.price_limit); + GasThreshold::::put(&self.gas_threshold); } } @@ -160,7 +161,7 @@ pub mod pallet { #[pallet::generate_deposit(pub(super) fn deposit_event)] pub enum Event { /// Create order event. - OrderCreate { sequence_number: u64, orderer: T::AuthorityId }, + OrderCreate { sequence_number: u64, orderer: ::AuthorityId }, } #[pallet::error] @@ -175,36 +176,14 @@ pub mod pallet { InvalidValidation, /// Incorrect sequence number WrongSequenceNumber, + /// Create root proof failed. + FailedCreateProof, + /// Slot author incorrect + SlotAuthorError, } #[pallet::hooks] - impl Hooks> for Pallet { - /// Called at the end of each block to check whether an order has been placed. - /// If so, modify the execution status and increase the sequencer number. - fn on_finalize(block_number: BlockNumberFor) { - let old_sequence_number = SequenceNumber::::get(); - let order = OrderMap::::get(old_sequence_number); - if let Some(t_order) = order { - let orderer = t_order.orderer; - OrderMap::::remove(old_sequence_number); - OrderMap::::insert( - old_sequence_number, - Order:: { - sequence_number: old_sequence_number, - orderer: orderer.clone(), - price: t_order.price, - executed: true, - }, - ); - SequenceNumber::::set(old_sequence_number + 1); - Block2Sequence::::insert(block_number, old_sequence_number); - Self::deposit_event(Event::OrderCreate { - sequence_number: old_sequence_number, - orderer, - }); - } - } - } + impl Hooks> for Pallet {} #[pallet::inherent] impl ProvideInherent for Pallet { @@ -213,15 +192,15 @@ pub mod pallet { const INHERENT_IDENTIFIER: InherentIdentifier = mp_coretime_on_demand::INHERENT_IDENTIFIER; fn create_inherent(data: &InherentData) -> Option { - let data: mp_coretime_on_demand::OrderInherentData = data - .get_data(&mp_coretime_on_demand::INHERENT_IDENTIFIER) - .ok() - .flatten() - .expect("there is not data to be posted; qed"); - if data.validation_data.is_some() { - Some(Call::create_order { data }) - } else { + let data: mp_coretime_on_demand::OrderInherentData<::AuthorityId> = + data.get_data(&mp_coretime_on_demand::INHERENT_IDENTIFIER) + .ok() + .flatten() + .expect("there is not data to be posted; qed"); + if data.author_pub.is_none() { None + } else { + Some(Call::create_order { data }) } } fn is_inherent(call: &Self::Call) -> bool { @@ -238,57 +217,49 @@ pub mod pallet { /// Parameters: /// - `data`: The inherent data. #[pallet::call_index(0)] - #[pallet::weight((0, DispatchClass::Mandatory))] + #[pallet::weight((::WeightInfo::create_order(), DispatchClass::Mandatory))] pub fn create_order( origin: OriginFor, - data: mp_coretime_on_demand::OrderInherentData, + data: mp_coretime_on_demand::OrderInherentData<::AuthorityId>, ) -> DispatchResultWithPostInfo { ensure_none(origin)?; let mp_coretime_on_demand::OrderInherentData { - relay_storage_proof, - validation_data, - sequence_number, - para_id, + relay_chian_number: place_order_height, author_pub, + price, } = data; - let total_weight = match validation_data { - Some(validation_data) => { - let (_, price) = Self::check_order_proof( - relay_storage_proof, - validation_data.clone(), - author_pub.clone(), - para_id, - ) - .ok_or(Error::::CreateOrderFail)?; - let old_sequence_number = SequenceNumber::::get(); - let order = OrderMap::::get(old_sequence_number); - if sequence_number != old_sequence_number { - // In the worst-case scenario, if there are multiple orders at the same - // time, it may be due to system issues or it may be due to human - // intervention. Currently, we only support running one order at the same - // time Err(Error::::WrongSequenceNumber)?; - // Continuing to produce blocks, recording errors - log::info!("========WrongSequenceNumber:{:?}========", sequence_number); - } - if order.is_none() { - OrderMap::::insert( - old_sequence_number, - Order:: { - sequence_number: old_sequence_number, - orderer: author_pub.unwrap(), - price, - executed: false, - }, - ); - CurrentRelayHeight::::set(validation_data.relay_parent_number); - } else { - Err(Error::::OrderExist)?; - } - T::DbWeight::get().reads_writes(2, 1) - }, - None => T::DbWeight::get().reads_writes(0, 0), - }; + let old_sequence_number = SequenceNumber::::get(); + let order = OrderMap::::get(old_sequence_number); + // relay chian block number + let relay_chian_height = T::RelayChainStateProvider::current_relay_chain_state().number; + let block_number = frame_system::Pallet::::block_number(); + let orderer = author_pub.expect("author must exist"); + // Check if the order is in author slot + if !Self::check_slot_author(place_order_height, orderer.clone()) { + Err(Error::::SlotAuthorError)?; + } + if order.is_none() { + OrderMap::::insert( + old_sequence_number, + Order::<::AuthorityId> { + sequence_number: old_sequence_number, + relay_chian_height, + place_order_height, + orderer: orderer.clone(), + price, + }, + ); + SequenceNumber::::set(old_sequence_number + 1); + Block2Sequence::::insert(block_number, old_sequence_number); + Self::deposit_event(Event::OrderCreate { + sequence_number: old_sequence_number, + orderer, + }); + } else { + Err(Error::::OrderExist)?; + } + let total_weight = T::DbWeight::get().reads_writes(2, 1); Ok(PostDispatchInfo { actual_weight: Some(total_weight), pays_fee: Pays::No }) } @@ -299,7 +270,7 @@ pub mod pallet { /// Parameters: /// - `slot_width`: The order interval is 2^slotwidth.. #[pallet::call_index(1)] - #[pallet::weight(0)] + #[pallet::weight(::WeightInfo::set_slot_width())] pub fn set_slot_width(origin: OriginFor, slot_width: u32) -> DispatchResultWithPostInfo { T::UpdateOrigin::ensure_origin(origin)?; @@ -314,14 +285,14 @@ pub mod pallet { /// Parameters: /// - `price_limit`: The maximum price the user is willing to pay when placing an order. #[pallet::call_index(2)] - #[pallet::weight(0)] + #[pallet::weight(::WeightInfo::set_price_limit())] pub fn set_price_limit( origin: OriginFor, price_limit: BalanceOf, ) -> DispatchResultWithPostInfo { T::UpdateOrigin::ensure_origin(origin)?; - >::put(price_limit); + >::put(price_limit); Ok(().into()) } /// Order pallet parameter settings. @@ -331,160 +302,48 @@ pub mod pallet { /// Parameters: /// - `threshold`: Gas threshold that triggers order placement. #[pallet::call_index(3)] - #[pallet::weight(0)] + #[pallet::weight(::WeightInfo::set_gas_threshold())] pub fn set_gas_threshold( origin: OriginFor, threshold: Perbill, ) -> DispatchResultWithPostInfo { T::UpdateOrigin::ensure_origin(origin)?; - >::put(threshold); + >::put(threshold); Ok(().into()) } } } impl Pallet { - /// Obtain the order account and price from the relaychain's validation. - /// - /// Parameters: - /// - `relay_storage_proof`: The proof of relay chain storage. - ///- `validation_data`: The validation data. - /// - `para_id`: ID of parachain. - fn get_author_from_proof( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - para_id: ParaId, - ) -> Option<(T::AuthorityId, Balance)> { - let relay_storage_root = validation_data.relay_parent_storage_root; - let relay_storage_rooted_proof = - RelayChainStateProof::new(para_id, relay_storage_root, relay_storage_proof) - .expect("Invalid relay chain state proof"); - let head_data = relay_storage_rooted_proof - .read_entry::>>>( - SYSTEM_EVENTS, - None, - ) - .ok()?; - let v_price: Vec = head_data - .iter() - .filter_map(|item| { - if let polakdot_runtime::RuntimeEvent::OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event::OnDemandOrderPlaced{ - para_id: pid, - spot_price: sprice, - }) = &item.event - { - if pid.encode() == para_id.encode() { - Some(*sprice) - } else { - None - } - } else { - None - } - }) - .collect(); - let orderer: Vec<(T::AuthorityId, u128)> = v_price - .iter() - .filter_map(|item| { - let mut orderer = None; - let _: Vec<_> = head_data - .iter() - .filter_map(|event| { - if let polakdot_runtime::RuntimeEvent::Balances( - runtime_types::pallet_balances::pallet::Event::Withdraw { - who: ref order, - amount: eprice, - }, - ) = event.event - { - if eprice == *item { - orderer = match T::AuthorityId::try_from(order.clone().as_slice()) { - Ok(order) => Some((order, eprice)), - Err(_) => None, - }; - Some(()) - } else { - None - } - } else { - None - } - }) - .collect(); - orderer - }) - .collect(); - if orderer.len() > 0 { - Some(orderer[0].clone()) - } else { - None - } - } - - /// Check whether the account is in the validation of relaychain. - /// - /// Parameters: - /// - `relay_storage_proof`: The proof of relay chain storage. - /// - `validation_data`: The validation data. - /// - `author_pub`: Account. - /// - `para_id`: ID of parachain. - fn check_order_proof( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - author_pub: Option, - para_id: ParaId, - ) -> Option<(T::AuthorityId, Balance)> { - let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); - match op_author { - Some((author, spot_price)) => { - if author_pub == Some(author.clone()) { - Some((author, spot_price)) - } else { - None - } - }, - None => None, - } - } - - /// Check whether there is an order event in the validation of relaychain. - /// - /// Parameters: - /// - `relay_storage_proof`: The proof of relay chain storage. - /// - `validation_data`: The validation data. - /// - `para_id`: ID of parachain. - pub fn order_placed( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - para_id: ParaId, - ) -> Option { - let op_author = Self::get_author_from_proof(relay_storage_proof, validation_data, para_id); - match op_author { - Some((author, _)) => Some(author), - None => None, - } - } - /// Whether the gas threshold for placing an order has been reached. /// /// Parameters: /// - `gas_balance`: The total gas. pub fn reach_txpool_threshold(gas_balance: BalanceOf, core_price: BalanceOf) -> bool { - let txpool_threshold = TxPoolThreshold::::get(); + let txpool_threshold = GasThreshold::::get(); gas_balance > txpool_threshold * core_price } - /// Whether the order with the specified sequence number is executed. - /// - /// Parameters: - /// - `sequence_number`: The sequence number. - pub fn order_executed(sequence_number: u64) -> bool { - let order_map = OrderMap::::get(sequence_number); - match order_map { - Some(order) => order.executed, - None => false, + fn check_slot_author( + relaychian_number: u32, + author: ::AuthorityId, + ) -> bool { + let authorities = pallet_aura::Pallet::::authorities(); + let slot_width = Self::slot_width(); + let auth_len = authorities.len() as u32; + // The larger the slot width, the longer the rotation time. + let idx = (relaychian_number >> slot_width) % auth_len; + let expected_author = authorities.get(idx as usize); + log::info!("idx:{:?}, expected_author:{:?}", idx, expected_author); + if let Some(exp_author) = expected_author { + if *exp_author.encode() == author.encode() { + true + } else { + false + } + } else { + false } } } diff --git a/pallets/on-demand/src/mock.rs b/pallets/on-demand/src/mock.rs index 71fa00d..412373c 100644 --- a/pallets/on-demand/src/mock.rs +++ b/pallets/on-demand/src/mock.rs @@ -1,183 +1,258 @@ -// // Copyright (C) Magnet. -// // This file is part of Magnet. - -// // Magnet is free software: you can redistribute it and/or modify -// // it under the terms of the GNU General Public License as published by -// // the Free Software Foundation, either version 3 of the License, or -// // (at your option) any later version. - -// // Magnet is distributed in the hope that it will be useful, -// // but WITHOUT ANY WARRANTY; without even the implied warranty of -// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// // GNU General Public License for more details. - -// // You should have received a copy of the GNU General Public License -// // along with Magnet. If not, see . - -// use crate::{self as order_pallet, OrderGasCost}; -// use codec::Encode; -// pub use frame_support::{ -// construct_runtime, derive_impl, parameter_types, -// traits::{Everything, Hooks}, -// }; -// use frame_system as system; -// use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; -// pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; -// use sp_core::{crypto::AccountId32, H256}; -// use sp_runtime::{ -// traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, -// BuildStorage, MultiSignature, -// }; - -// type Block = frame_system::mocking::MockBlock; -// type Signature = MultiSignature; -// type AccountId = <::Signer as IdentifyAccount>::AccountId; -// type Balance = u128; -// // Configure a mock runtime to test the pallet. -// construct_runtime!( -// pub enum Test -// { -// System: frame_system::{Pallet, Call, Config, Storage, Event}, -// Balances: pallet_balances::{Pallet, Call, Event}, -// OrderPallet: order_pallet::{Pallet, Call, Storage, Event}, -// MockPallet: mock_pallet, -// } -// ); - -// parameter_types! { -// pub const BlockHashCount: u64 = 250; -// pub const SS58Prefix: u8 = 42; -// } - -// #[derive_impl(frame_system::config_preludes::ParaChainDefaultConfig as frame_system::DefaultConfig)] -// impl system::Config for Test { -// type BaseCallFilter = Everything; -// type BlockWeights = (); -// type BlockLength = (); -// type DbWeight = (); -// type RuntimeOrigin = RuntimeOrigin; -// type RuntimeCall = RuntimeCall; -// type Nonce = u64; -// type Hash = H256; -// type Hashing = BlakeTwo256; -// type AccountId = AccountId32; -// type Lookup = IdentityLookup; -// type Block = Block; -// type RuntimeEvent = RuntimeEvent; -// type BlockHashCount = BlockHashCount; -// type Version = (); -// type PalletInfo = PalletInfo; -// type AccountData = pallet_balances::AccountData; -// type OnNewAccount = (); -// type OnKilledAccount = (); -// type SystemWeightInfo = (); -// type SS58Prefix = SS58Prefix; -// type OnSetCode = (); -// type MaxConsumers = frame_support::traits::ConstU32<16>; -// } -// parameter_types! { -// pub const ExistentialDeposit: u64 = 5; -// } -// impl pallet_balances::Config for Test { -// type MaxLocks = (); -// type MaxReserves = (); -// type ReserveIdentifier = [u8; 8]; -// type Balance = u128; -// type RuntimeEvent = RuntimeEvent; -// type DustRemoval = (); -// type ExistentialDeposit = ExistentialDeposit; -// type AccountStore = System; -// type WeightInfo = (); -// type FreezeIdentifier = (); -// type MaxFreezes = (); -// type RuntimeHoldReason = (); -// type RuntimeFreezeReason = (); -// } -// parameter_types! { -// pub const SlotWidth: u32 = 2; -// pub const OrderMaxAmount:Balance = 200000000; -// pub const TxPoolThreshold:Balance = 3000000000; -// } -// impl crate::Config for Test { -// type RuntimeEvent = RuntimeEvent; -// type AuthorityId = AuraId; -// type UpdateOrigin = EnsureRoot; -// type Currency = Balances; -// type OrderMaxAmount = OrderMaxAmount; -// type SlotWidth = SlotWidth; -// type TxPoolThreshold = TxPoolThreshold; -// type WeightInfo = (); -// } -// pub struct OrderGasCostHandler(); - -// impl OrderGasCost for OrderGasCostHandler -// where -// T: crate::Config, -// T::AccountId: From<[u8; 32]>, -// { -// fn gas_cost( -// block_number: BlockNumberFor, -// ) -> Result, sp_runtime::DispatchError> { -// let sequece_number = >::block_2_sequence(block_number); -// if sequece_number.is_none() { -// return Ok(None); -// } -// let order = >::order_map( -// sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, -// ) -// .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; -// let mut r = [0u8; 32]; -// r.copy_from_slice(order.orderer.encode().as_slice()); -// let account = T::AccountId::try_from(r) -// .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; -// Ok(Some((account, order.price))) -// } -// } - -// #[frame_support::pallet] -// pub mod mock_pallet { -// use super::*; -// #[pallet::config] -// pub trait Config: frame_system::Config { -// type OrderGasCost: OrderGasCost; -// } - -// #[pallet::call] -// impl Pallet {} - -// #[pallet::pallet] -// #[pallet::without_storage_info] -// pub struct Pallet(_); - -// impl Pallet { -// pub fn get_gas_cost(block_number: BlockNumberFor) -> Option<(T::AccountId, Balance)> { -// T::OrderGasCost::gas_cost(block_number).unwrap() -// } -// } -// } - -// impl mock_pallet::Config for Test { -// type OrderGasCost = OrderGasCostHandler; -// } -// pub struct ExtBuilder { -// balances: Vec<(AccountId32, u128)>, -// } - -// impl Default for ExtBuilder { -// fn default() -> Self { -// Self { balances: Default::default() } -// } -// } - -// impl ExtBuilder { -// pub fn build(self) -> sp_io::TestExternalities { -// // Build genesis storage according to the mock runtime. -// let mut t = frame_system::GenesisConfig::::default().build_storage().unwrap(); -// pallet_balances::GenesisConfig:: { balances: self.balances } -// .assimilate_storage(&mut t) -// .unwrap(); -// let mut ext = sp_io::TestExternalities::new(t); -// ext.execute_with(|| System::set_block_number(1)); -// ext -// } -// } +// Copyright (C) Magnet. +// This file is part of Magnet. + +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. + +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . + +use crate::{self as order_pallet}; +use codec::Encode; +use cumulus_pallet_parachain_system::RelayChainState; +use cumulus_pallet_parachain_system::RelaychainStateProvider; +pub use frame_support::{ + construct_runtime, derive_impl, parameter_types, + traits::{Everything, Hooks}, +}; +use frame_system as system; +use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; +pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; +use sp_core::{crypto::AccountId32, ConstBool, ConstU32, ConstU64, H256}; +use sp_core::{Pair, Public, H160, U256}; +use sp_keyring::sr25519; +use sp_keyring::Sr25519Keyring::Alice; +use sp_runtime::{ + traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, + BuildStorage, MultiSignature, Perbill, +}; + +type Block = frame_system::mocking::MockBlock; +type Signature = MultiSignature; +type AccountId = <::Signer as IdentifyAccount>::AccountId; +type Balance = u128; + +pub const MILLISECS_PER_BLOCK: u64 = 6000; + +pub const SLOT_DURATION: u64 = MILLISECS_PER_BLOCK; + +// Configure a mock runtime to test the pallet. +construct_runtime!( + pub enum Test + { + System: frame_system::{Pallet, Call, Config, Storage, Event}, + Balances: pallet_balances::{Pallet, Call, Event}, + Aura: pallet_aura, + Timestamp: pallet_timestamp, + OrderPallet: order_pallet::{Pallet, Call, Storage, Event}, + MockPallet: mock_pallet, + } +); + +parameter_types! { + pub const BlockHashCount: u64 = 250; + pub const SS58Prefix: u8 = 42; +} + +#[derive_impl(frame_system::config_preludes::ParaChainDefaultConfig as frame_system::DefaultConfig)] +impl system::Config for Test { + type BaseCallFilter = Everything; + type BlockWeights = (); + type BlockLength = (); + type DbWeight = (); + type RuntimeOrigin = RuntimeOrigin; + type RuntimeCall = RuntimeCall; + type Nonce = u64; + type Hash = H256; + type Hashing = BlakeTwo256; + type AccountId = AccountId32; + type Lookup = IdentityLookup; + type Block = Block; + type RuntimeEvent = RuntimeEvent; + type BlockHashCount = BlockHashCount; + type Version = (); + type PalletInfo = PalletInfo; + type AccountData = pallet_balances::AccountData; + type OnNewAccount = (); + type OnKilledAccount = (); + type SystemWeightInfo = (); + type SS58Prefix = SS58Prefix; + type OnSetCode = (); + type MaxConsumers = frame_support::traits::ConstU32<16>; +} +parameter_types! { + pub const ExistentialDeposit: u64 = 5; +} +impl pallet_balances::Config for Test { + type MaxLocks = (); + type MaxReserves = (); + type ReserveIdentifier = [u8; 8]; + type Balance = u128; + type RuntimeEvent = RuntimeEvent; + type DustRemoval = (); + type ExistentialDeposit = ExistentialDeposit; + type AccountStore = System; + type WeightInfo = (); + type FreezeIdentifier = (); + type MaxFreezes = (); + type RuntimeHoldReason = (); + type RuntimeFreezeReason = (); +} + +pub(crate) const MOCK_RELAY_ROOT_KEY: &[u8] = b"MOCK_RELAY_ROOT_KEY"; + +pub struct MockRelayStateProvider; + +impl RelaychainStateProvider for MockRelayStateProvider { + fn current_relay_chain_state() -> RelayChainState { + let root = if let Some(root) = frame_support::storage::unhashed::get(MOCK_RELAY_ROOT_KEY) { + root + } else { + Default::default() + }; + + RelayChainState { + state_root: root, + number: 0, // block number is not relevant here + } + } + + #[cfg(feature = "runtime-benchmarks")] + fn set_current_relay_chain_state(state: RelayChainState) { + frame_support::storage::unhashed::put(b"MOCK_RELAY_ROOT_KEY", &state.state_root); + } +} +impl pallet_timestamp::Config for Test { + /// A timestamp: milliseconds since the unix epoch. + type Moment = u64; + type OnTimestampSet = Aura; + #[cfg(feature = "experimental")] + type MinimumPeriod = ConstU64<0>; + #[cfg(not(feature = "experimental"))] + type MinimumPeriod = ConstU64<{ SLOT_DURATION / 2 }>; + type WeightInfo = (); +} +impl pallet_aura::Config for Test { + type AuthorityId = AuraId; + type DisabledValidators = (); + type MaxAuthorities = ConstU32<100_000>; + type AllowMultipleBlocksPerSlot = ConstBool; + #[cfg(feature = "experimental")] + type SlotDuration = ConstU64; +} + +impl crate::Config for Test { + type RuntimeEvent = RuntimeEvent; + type AuthorityId = AuraId; + type UpdateOrigin = EnsureRoot; + type Currency = Balances; + type WeightInfo = (); + type RelayChainStateProvider = MockRelayStateProvider; +} +pub struct OrderGasCostHandler(); + +pub trait OrderGasCost { + /// Gas consumed by placing an order in a certain block. + /// + /// Parameters: + /// - `block_number`: The block number of para chain. + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError>; +} + +impl OrderGasCost for OrderGasCostHandler +where + T: crate::Config, + T::AccountId: From<[u8; 32]>, +{ + fn gas_cost( + block_number: BlockNumberFor, + ) -> Result, sp_runtime::DispatchError> { + let sequece_number = >::block_2_sequence(block_number); + if sequece_number.is_none() { + return Ok(None); + } + let order = >::order_map( + sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, + ) + .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; + let mut r = [0u8; 32]; + r.copy_from_slice(order.orderer.encode().as_slice()); + let account = T::AccountId::try_from(r) + .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; + Ok(Some((account, order.price))) + } +} + +#[frame_support::pallet] +pub mod mock_pallet { + use super::*; + #[pallet::config] + pub trait Config: frame_system::Config { + type OrderGasCost: OrderGasCost; + } + + #[pallet::call] + impl Pallet {} + + #[pallet::pallet] + #[pallet::without_storage_info] + pub struct Pallet(_); + + impl Pallet { + pub fn get_gas_cost(block_number: BlockNumberFor) -> Option<(T::AccountId, Balance)> { + T::OrderGasCost::gas_cost(block_number).unwrap() + } + } +} + +impl mock_pallet::Config for Test { + type OrderGasCost = OrderGasCostHandler; +} +pub struct ExtBuilder { + balances: Vec<(AccountId32, u128)>, +} + +impl Default for ExtBuilder { + fn default() -> Self { + Self { balances: Default::default() } + } +} + +pub fn get_from_seed(seed: &str) -> ::Public { + TPublic::Pair::from_string(&format!("//{}", seed), None) + .expect("static values are valid; qed") + .public() +} +impl ExtBuilder { + pub fn build(self) -> sp_io::TestExternalities { + // Build genesis storage according to the mock runtime. + let mut t = frame_system::GenesisConfig::::default().build_storage().unwrap(); + pallet_balances::GenesisConfig:: { balances: self.balances } + .assimilate_storage(&mut t) + .unwrap(); + crate::GenesisConfig:: { + slot_width: 3, + price_limit: 200000000, + gas_threshold: Perbill::one(), + } + .assimilate_storage(&mut t) + .unwrap(); + pallet_aura::GenesisConfig:: { + authorities: vec![get_from_seed::("Alice").into()], + } + .assimilate_storage(&mut t) + .unwrap(); + let mut ext = sp_io::TestExternalities::new(t); + ext.execute_with(|| System::set_block_number(1)); + ext + } +} diff --git a/pallets/on-demand/src/proof_data.rs b/pallets/on-demand/src/proof_data.rs deleted file mode 100644 index 5239a0f..0000000 --- a/pallets/on-demand/src/proof_data.rs +++ /dev/null @@ -1,29 +0,0 @@ -// // Copyright (C) Magnet. -// // This file is part of Magnet. - -// // Magnet is free software: you can redistribute it and/or modify -// // it under the terms of the GNU General Public License as published by -// // the Free Software Foundation, either version 3 of the License, or -// // (at your option) any later version. - -// // Magnet is distributed in the hope that it will be useful, -// // but WITHOUT ANY WARRANTY; without even the implied warranty of -// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// // GNU General Public License for more details. - -// // You should have received a copy of the GNU General Public License -// // along with Magnet. If not, see . - -// #[allow(dead_code)] -// pub const ENCODED_PROOFS: &[(&str, &[&str])] = &[ -// ("6b7db61c1bee66952742baa01b5a16efe3b6dbc015db0bbbc0d50349eb86279e",&[ -// "2000000000000000a2e9b53d55170200000001000000000007c09b001b01390202000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000020000000408d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d809698000000000000000000000000000000020000004200e8030000809698000000000000000000000000000000020000000407fe65717dad0447d715f660a0a58411de509b42e6efb8375f562f58a554d5860ee96725030000000000000000000000000000020000002100d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27de96725030000000000000000000000000000000000000000000000000000000000000200000000001a037449c93a000000", -// "3ed41e5e16056765bc8461851072c9d74259dee8a67b8efa0538928edcd6d3dc677e250771c8f75fa2e6cc8942f06f84", -// "800104801a93e89e41a278828d5caad67eb07073bca1b6cccc49807dbb0476cb27dced8b80c11c1757f8dc26ef0d97db7c703034b9a9001ad382ed9e1ff900f6ac927cea97", -// "80c19c8040ccdfa3ac9b91388fa827571930b3c1e805eb35304412ff42cc6df33ca548ee806bd20dcb3f9e7c87137961ace69ccd74eb92eb3ca730ea10fc736b7f261cbd7380257442a3193ebf64fb8a0019b2d9fc1d97734011eb5a8d2ea414f5ff9a27952b804a061d1ed9340acbb3bfeeb8dd6662b24e093240981c068dafa7044ed379307f80c692d333d8a2af1468e95d1583f2ff2dcde7a5607f9490af0e17dff8a1330cc48005beaee4aeb1f362f62d090d987e09cee98c4bbafd8042732406115019b3b6b2809c048073a3a4c42b9174519d6fdac372683ca85cc3b0cac1a1a9ddaf243b59b1", -// "80ffff805f00b947f4aaec99e6613e9511e9cda57d739ea73a0f2db02c08509a021ac7c180c63e2c041524586654422f91098a9b35e5d0ea88d44c334c4ffa6112e7aa696f80f40031d9a794a6cd84c0d942827d55968e796a5350b0df1d18c410b8903ce59980b8acbbf86a4082fb580470e18b67d0099be087b38e04c862e8d2ad2b4b984f68801c8066816a9737e80e67d14190ebabfe1f77c68975a57867a3e721759387b16f800cb049cc6bc5b79fb79d7da92aadb3c7d5df71e403364142445ab1e212424b7c80c0c6776ecc8630ecc28971e2155751cdeead63676a6d5313771f902a26a528a0805b682132c52908705526057f73ab7fccab4af6d72a9805634dd8d3cc53f130d18012b1a0dc047d3b9d5e8792fb372059a04d44300f0f667a2a14a8777ccfe7fdff80de00eff4d3f779a7434826e0d0f3a1ec71dd4028c42e90718c657e3f1c2ed23680af18bd988a60b703c96993f291b836fe5f6df4ea5a7d36c9d1e65cd44bc1c5a98037af338c5d64d1babf36777405396255681f8bef661a6cd600052dceffba87ab80f4429c1b9ec6915b41ad4f0b3aa4f0fcf7ef80690cab6590739ce7e415f4e966800117ab1066009e6ab3db03ed63038d60ed339fccef41d35668e22d99ba0a7142806bfdbbf0e0bedcb993b65c9cea1e929a56d78a3b7bc53d1b7ca6fc488e2295ee8011cf4cd49d702989ad1e066e4983740ef04216f8945156021e524d97b57e240a", -// "9eaa394eea5630e07c48ae0c9558cef7398f80a506ec64a470c01c9ac42ea190d29a5f5d900256035bd485a0563a428f7d0369809aea767c8a069c1f1759636c9f4672b4483e36cc35d06881c141bd5e4c40d75e505f0e7b9012096b41c4eb3aaf947f6ea4290800004c5f0684a022a34dd8bfa2baaf44f172b71004018004952dfbd3c381037ea2a1ddd3c7252f15de49dd55db9697c7513fd0750e1ca980a22e4b0da2642d6cda7bd1dc00e5fd760e4d6e18684676b9612f3045023088cf80809890dfdabf4da4f92e0ffab00c1cedd68369e0cc3ce4432de6f8abe9220b5380690a57078e6f7e247b25365dad04c1fef7b0d5401cad9087216ca0f33d7788a06c5f09cce9c888469bb1a0dceaa129672ef824599318726f636f636f" -// ]) -// ]; -// #[allow(dead_code)] -// pub const HEAD_DATA:&[&str] = &["00000000000000000000000000000000000000000000000000000000000000000070049f18759406809dc703bba5534cd06df7453974b4599e08d6709db651e0a203170a2e7597b7b7e3d84c05391d139a62b157e78786d8c082f29dcf4c11131400"]; diff --git a/pallets/on-demand/src/tests.rs b/pallets/on-demand/src/tests.rs index f12f8c5..80d9a52 100644 --- a/pallets/on-demand/src/tests.rs +++ b/pallets/on-demand/src/tests.rs @@ -1,82 +1,66 @@ -// // Copyright (C) Magnet. -// // This file is part of Magnet. +// Copyright (C) Magnet. +// This file is part of Magnet. -// // Magnet is free software: you can redistribute it and/or modify -// // it under the terms of the GNU General Public License as published by -// // the Free Software Foundation, either version 3 of the License, or -// // (at your option) any later version. +// Magnet is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. -// // Magnet is distributed in the hope that it will be useful, -// // but WITHOUT ANY WARRANTY; without even the implied warranty of -// // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// // GNU General Public License for more details. +// Magnet is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. -// // You should have received a copy of the GNU General Public License -// // along with Magnet. If not, see . +// You should have received a copy of the GNU General Public License +// along with Magnet. If not, see . -// use crate::mock::*; -// use codec::Decode; -// use cumulus_primitives_core::{ParaId, PersistedValidationData}; -// use frame_support::{ -// inherent::{InherentData, ProvideInherent}, -// traits::UnfilteredDispatchable, -// }; -// use frame_system::RawOrigin; -// use parachains_common::AccountId; -// use primitives::HeadData; -// use sp_trie::StorageProof; +use crate::mock::*; +use codec::Decode; +use cumulus_primitives_core::{ParaId, PersistedValidationData}; +use frame_support::{ + inherent::{InherentData, ProvideInherent}, + traits::UnfilteredDispatchable, +}; +use frame_system::RawOrigin; +use parachains_common::AccountId; +use primitives::HeadData; +use sp_consensus_aura::sr25519::AuthorityId; +use sp_trie::StorageProof; -// use crate::proof_data::{ENCODED_PROOFS, HEAD_DATA}; -// #[test] -// fn order_default_value() { -// ExtBuilder::default().build().execute_with(|| { -// assert_eq!(OrderPallet::slot_width(), 2); -// }); -// } +#[test] +fn order_default_value() { + ExtBuilder::default().build().execute_with(|| { + assert_eq!(OrderPallet::slot_width(), 3); + }); +} -// #[test] -// fn order_normal_test() { -// ExtBuilder::default().build().execute_with(|| { -// System::set_block_number(1); +#[test] +fn order_normal_test() { + ExtBuilder::default().build().execute_with(|| { + System::set_block_number(1); -// let encoded = ENCODED_PROOFS[0]; -// let root = hex::decode(encoded.0).unwrap(); -// let relay_chain_state_proof = -// StorageProof::new(encoded.1.iter().map(|s| hex::decode(s).unwrap())); -// let relay_root: cumulus_primitives_core::relay_chain::Hash = -// <[u8; 32]>::try_from(root).unwrap().into(); -// let mut inherent_data = InherentData::default(); -// let head_data = hex::decode(HEAD_DATA[0]).unwrap(); -// let perist_data = PersistedValidationData { -// parent_head: HeadData::decode(&mut head_data.as_slice()).unwrap(), -// relay_parent_number: 29, -// relay_parent_storage_root: relay_root, -// max_pov_size: 5242880 as u32, -// }; -// let order_inherent_data = magnet_primitives_order::OrderInherentData { -// relay_storage_proof: relay_chain_state_proof, -// validation_data: Some(perist_data), -// para_id: ParaId::from(1000), -// sequence_number: 0, -// author_pub: Some(AccountId::from(hex_literal::hex!( -// "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" -// ))), -// }; -// inherent_data -// .put_data(magnet_primitives_order::INHERENT_IDENTIFIER, &order_inherent_data) -// .expect("failed to put VFP inherent"); -// OrderPallet::create_inherent(&inherent_data) -// .expect("got an inherent") -// .dispatch_bypass_filter(RawOrigin::None.into()) -// .expect("dispatch succeeded"); -// OrderPallet::on_finalize(1); -// assert_eq!(OrderPallet::sequence_number(), 1); -// let gas_cost = MockPallet::get_gas_cost(1).unwrap(); -// assert_eq!( -// gas_cost.0, -// AccountId::from(hex_literal::hex!( -// "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" -// )) -// ); -// }); -// } + let mut inherent_data = InherentData::default(); + let order_inherent_data: mp_coretime_on_demand::OrderInherentData = + mp_coretime_on_demand::OrderInherentData { + relay_chian_number: 40, + author_pub: Some(get_from_seed::("Alice").into()), + price: 10000000, + }; + inherent_data + .put_data(mp_coretime_on_demand::INHERENT_IDENTIFIER, &order_inherent_data) + .expect("failed to put VFP inherent"); + OrderPallet::create_inherent(&inherent_data) + .expect("got an inherent") + .dispatch_bypass_filter(RawOrigin::None.into()) + .expect("dispatch succeeded"); + OrderPallet::on_finalize(1); + assert_eq!(OrderPallet::sequence_number(), 1); + let gas_cost = MockPallet::get_gas_cost(1).unwrap(); + assert_eq!( + gas_cost.0, + AccountId::from(hex_literal::hex!( + "d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d" + )) + ); + }); +} diff --git a/pallets/on-demand/src/weights.rs b/pallets/on-demand/src/weights.rs index 6563e21..a422054 100644 --- a/pallets/on-demand/src/weights.rs +++ b/pallets/on-demand/src/weights.rs @@ -36,35 +36,145 @@ use core::marker::PhantomData; use frame_support::weights::constants::RocksDbWeight; pub trait WeightInfo { - fn set_parameter(s: Option, ) -> Weight; + fn set_slot_width() -> Weight; + fn set_price_limit() -> Weight; + fn set_gas_threshold() -> Weight; + fn create_order() -> Weight; } /// Weight functions for `pallet_order`. pub struct SubstrateWeight(PhantomData); impl WeightInfo for SubstrateWeight { /// Storage: `OrderPallet::SlotWidth` (r:0 w:1) /// Proof: `OrderPallet::SlotWidth` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) - /// Storage: `OrderPallet::TxPoolThreshold` (r:0 w:1) - /// Proof: `OrderPallet::TxPoolThreshold` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) - /// Storage: `OrderPallet::OrderMaxAmount` (r:0 w:1) - /// Proof: `OrderPallet::OrderMaxAmount` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) /// The range of component `s` is `[0, 100]`. - fn set_parameter(_s: Option, ) -> Weight { + fn set_slot_width() -> Weight { // Proof Size summary in bytes: // Measured: `0` // Estimated: `0` - // Minimum execution time: 4_649_000 picoseconds. - Weight::from_parts(5_090_860, 0) + // Minimum execution time: 2_505_000 picoseconds. + Weight::from_parts(2_739_117, 0) .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 96 + .saturating_add(Weight::from_parts(153, 0)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `OrderPallet::PriceLimit` (r:0 w:1) + /// Proof: `OrderPallet::PriceLimit` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn set_price_limit() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_515_000 picoseconds. + Weight::from_parts(2_786_295, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 470 + .saturating_add(Weight::from_parts(180, 0)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `OrderPallet::GasThreshold` (r:0 w:1) + /// Proof: `OrderPallet::GasThreshold` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn set_gas_threshold() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_505_000 picoseconds. + Weight::from_parts(2_766_066, 0) + .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(T::DbWeight::get().writes(1)) + } + /// Storage: `OrderPallet::SequenceNumber` (r:1 w:1) + /// Proof: `OrderPallet::SequenceNumber` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `OrderPallet::OrderMap` (r:1 w:1) + /// Proof: `OrderPallet::OrderMap` (`max_values`: None, `max_size`: Some(80), added: 2555, mode: `MaxEncodedLen`) + /// Storage: `ParachainSystem::ValidationData` (r:1 w:0) + /// Proof: `ParachainSystem::ValidationData` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Aura::Authorities` (r:1 w:0) + /// Proof: `Aura::Authorities` (`max_values`: Some(1), `max_size`: Some(3200004), added: 3200499, mode: `MaxEncodedLen`) + /// Storage: `OrderPallet::SlotWidth` (r:1 w:0) + /// Proof: `OrderPallet::SlotWidth` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `OrderPallet::Block2Sequence` (r:0 w:1) + /// Proof: `OrderPallet::Block2Sequence` (`max_values`: None, `max_size`: Some(20), added: 2495, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn create_order() -> Weight { + // Proof Size summary in bytes: + // Measured: `339` + // Estimated: `3201489` + // Minimum execution time: 23_434_000 picoseconds. + Weight::from_parts(25_538_352, 0) + .saturating_add(Weight::from_parts(0, 3201489)) + // Standard Error: 11_114 + .saturating_add(Weight::from_parts(21_074, 0)) + .saturating_add(T::DbWeight::get().reads(5)) .saturating_add(T::DbWeight::get().writes(3)) } } impl WeightInfo for () { - fn set_parameter(_s: Option, ) -> Weight { - Weight::from_parts(5_090_860, 0) + /// Storage: `OrderPallet::SlotWidth` (r:0 w:1) + /// Proof: `OrderPallet::SlotWidth` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn set_slot_width() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_505_000 picoseconds. + Weight::from_parts(2_739_117, 0) + .saturating_add(Weight::from_parts(0, 0)) + // Standard Error: 96 + .saturating_add(Weight::from_parts(153, 0)) + .saturating_add(RocksDbWeight::get().writes(1)) + } + /// Storage: `OrderPallet::PriceLimit` (r:0 w:1) + /// Proof: `OrderPallet::PriceLimit` (`max_values`: Some(1), `max_size`: Some(16), added: 511, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn set_price_limit() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_515_000 picoseconds. + Weight::from_parts(2_786_295, 0) .saturating_add(Weight::from_parts(0, 0)) - // Standard Error: 2_411 + // Standard Error: 470 + .saturating_add(Weight::from_parts(180, 0)) + .saturating_add(RocksDbWeight::get().writes(1)) + } + /// Storage: `OrderPallet::GasThreshold` (r:0 w:1) + /// Proof: `OrderPallet::GasThreshold` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn set_gas_threshold() -> Weight { + // Proof Size summary in bytes: + // Measured: `0` + // Estimated: `0` + // Minimum execution time: 2_505_000 picoseconds. + Weight::from_parts(2_766_066, 0) .saturating_add(Weight::from_parts(0, 0)) + .saturating_add(RocksDbWeight::get().writes(1)) + } + /// Storage: `OrderPallet::SequenceNumber` (r:1 w:1) + /// Proof: `OrderPallet::SequenceNumber` (`max_values`: Some(1), `max_size`: Some(8), added: 503, mode: `MaxEncodedLen`) + /// Storage: `OrderPallet::OrderMap` (r:1 w:1) + /// Proof: `OrderPallet::OrderMap` (`max_values`: None, `max_size`: Some(80), added: 2555, mode: `MaxEncodedLen`) + /// Storage: `ParachainSystem::ValidationData` (r:1 w:0) + /// Proof: `ParachainSystem::ValidationData` (`max_values`: Some(1), `max_size`: None, mode: `Measured`) + /// Storage: `Aura::Authorities` (r:1 w:0) + /// Proof: `Aura::Authorities` (`max_values`: Some(1), `max_size`: Some(3200004), added: 3200499, mode: `MaxEncodedLen`) + /// Storage: `OrderPallet::SlotWidth` (r:1 w:0) + /// Proof: `OrderPallet::SlotWidth` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`) + /// Storage: `OrderPallet::Block2Sequence` (r:0 w:1) + /// Proof: `OrderPallet::Block2Sequence` (`max_values`: None, `max_size`: Some(20), added: 2495, mode: `MaxEncodedLen`) + /// The range of component `s` is `[0, 100]`. + fn create_order() -> Weight { + // Proof Size summary in bytes: + // Measured: `339` + // Estimated: `3201489` + // Minimum execution time: 23_434_000 picoseconds. + Weight::from_parts(25_538_352, 0) + .saturating_add(Weight::from_parts(0, 3201489)) + // Standard Error: 11_114 + .saturating_add(Weight::from_parts(21_074, 0)) + .saturating_add(RocksDbWeight::get().reads(5)) .saturating_add(RocksDbWeight::get().writes(3)) } } \ No newline at end of file diff --git a/primitives/coretime/on-demand/src/inherent_client.rs b/primitives/coretime/on-demand/src/inherent_client.rs index 56eef2d..1e8c7e0 100644 --- a/primitives/coretime/on-demand/src/inherent_client.rs +++ b/primitives/coretime/on-demand/src/inherent_client.rs @@ -14,58 +14,28 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . +// use sp_consensus_aura::sr25519::AuthorityId; +use crate::well_known_keys::{acount_balance, ON_DEMAND_QUEUE}; +use crate::Codec; use sp_consensus_aura::sr25519::AuthorityId; +use sp_core::{crypto::UncheckedFrom, ByteArray}; +use sp_runtime::AccountId32; use { crate::OrderInherentData, cumulus_primitives_core::{ParaId, PersistedValidationData}, cumulus_relay_chain_interface::{PHash, RelayChainInterface}, }; -/// Collect the relevant relay chain state in form of a proof -/// for putting it into the on demand order inherent. -async fn collect_relay_storage_proof( - relay_chain_interface: &impl RelayChainInterface, - relay_parent: PHash, -) -> Option { - let mut relevant_keys = Vec::new(); - //System Events - relevant_keys.push( - hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef780d41e5e16056765bc8461851072c9d7"] - .to_vec(), - ); - - let relay_storage_proof = relay_chain_interface.prove_read(relay_parent, &relevant_keys).await; - match relay_storage_proof { - Ok(proof) => Some(proof), - Err(err) => { - log::info!("RelayChainError:{:?}", err); - None - }, - } -} - impl OrderInherentData { /// Create the [`OrderInherentData`] at the given `relay_parent`. /// /// Returns `None` if the creation failed. pub async fn create_at( - relay_parent: PHash, - relay_chain_interface: &impl RelayChainInterface, - validation_data: &Option, - para_id: ParaId, - sequence_number: u64, + relay_chian_number: u32, author_pub: &Option, + price: u128, ) -> Option> { - let relay_storage_proof = - collect_relay_storage_proof(relay_chain_interface, relay_parent).await?; - - Some(OrderInherentData { - relay_storage_proof: relay_storage_proof.clone(), - validation_data: validation_data.clone(), - para_id, - sequence_number, - author_pub: author_pub.clone(), - }) + Some(OrderInherentData { relay_chian_number, author_pub: author_pub.clone(), price }) } } diff --git a/primitives/coretime/on-demand/src/lib.rs b/primitives/coretime/on-demand/src/lib.rs index 5f7f0dc..a014319 100644 --- a/primitives/coretime/on-demand/src/lib.rs +++ b/primitives/coretime/on-demand/src/lib.rs @@ -20,6 +20,8 @@ //! the on demand order pallet inherent //! #![cfg_attr(not(feature = "std"), no_std)] +use core::default; + use cumulus_primitives_core::{ relay_chain::BlockNumber as RelayBlockNumber, relay_chain::Hash as PHash, ParaId, PersistedValidationData, @@ -29,23 +31,18 @@ use sp_runtime::sp_std::vec::Vec; use sp_runtime::traits::MaybeDisplay; #[cfg(feature = "std")] pub mod inherent_client; -pub mod metadata; pub mod well_known_keys; use codec::{Codec, Decode, Encode}; use {scale_info::TypeInfo, sp_inherents::InherentIdentifier}; #[derive(Encode, Decode, sp_core::RuntimeDebug, Clone, PartialEq, TypeInfo)] pub struct OrderInherentData { - /// Proof of relaychain storage. - pub relay_storage_proof: sp_trie::StorageProof, - /// Validation data. - pub validation_data: Option, - /// Parachain ID. - pub para_id: ParaId, - /// Sequence number of order. - pub sequence_number: u64, + /// Relaychain block height, for check. + pub relay_chian_number: RelayBlockNumber, /// Author of order. pub author_pub: Option, + /// Order price. + pub price: u128, } // Identifier of the order inherent @@ -62,17 +59,15 @@ pub enum OrderStatus { #[derive(Clone)] pub struct OrderRecord { /// Hash of relaychain block. - pub relay_parent: Option, + pub relay_parent: PHash, /// Relaychain block height. pub relay_height: RelayBlockNumber, /// Order status pub order_status: OrderStatus, - /// Validation data. - pub validation_data: Option, - /// Sequence number of order. - pub sequence_number: u64, /// Author of order. pub author_pub: Option, + /// Order price. + pub price: u128, /// Backup transactions hash. pub txs: Vec, } @@ -80,22 +75,20 @@ pub struct OrderRecord { impl OrderRecord { pub fn new() -> OrderRecord { OrderRecord { - relay_parent: None, + relay_parent: Default::default(), relay_height: 0, order_status: OrderStatus::Init, - validation_data: None, - sequence_number: 0, author_pub: None, + price: 0, txs: Vec::new(), } } pub fn reset(&mut self) { - self.relay_parent = None; + self.relay_parent = Default::default(); self.relay_height = 0; self.order_status = OrderStatus::Init; - self.validation_data = None; - self.sequence_number = 0; self.author_pub = None; + self.price = 0; self.txs = Vec::new(); } } @@ -109,20 +102,8 @@ sp_api::decl_runtime_apis! { fn slot_width()-> u32; - fn sequence_number()-> u64; - - fn current_relay_height()->u32; - fn order_max_amount() -> Balance; - fn order_placed( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - para_id:ParaId, - )-> Option; - fn reach_txpool_threshold(gas_balance:Balance, core_price:Balance) -> bool; - - fn order_executed(sequence_number:u64) -> bool ; } } diff --git a/primitives/coretime/on-demand/src/metadata.rs b/primitives/coretime/on-demand/src/metadata.rs deleted file mode 100644 index cfbd9bc..0000000 --- a/primitives/coretime/on-demand/src/metadata.rs +++ /dev/null @@ -1,5350 +0,0 @@ -#[allow(dead_code, unused_imports, non_camel_case_types)] -#[allow(clippy::all)] -#[allow(rustdoc::broken_intra_doc_links)] -pub mod api { - #[allow(unused_imports)] - mod root_mod { - pub use super::*; - } - pub mod runtime_types { - use super::runtime_types; - pub mod rococo_runtime { - use super::runtime_types; - pub mod validator_manager { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ValidatorsRegistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), - #[codec(index = 1)] - ValidatorsDeregistered(::sp_std::vec::Vec<::sp_core::crypto::AccountId32>), - } - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ProxyType { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - NonTransfer, - #[codec(index = 2)] - Governance, - #[codec(index = 3)] - IdentityJudgement, - #[codec(index = 4)] - CancelProxy, - #[codec(index = 5)] - Auction, - #[codec(index = 6)] - Society, - #[codec(index = 7)] - OnDemandOrdering, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum RuntimeEvent { - #[codec(index = 0)] - System(runtime_types::frame_system::pallet::Event), - #[codec(index = 3)] - Indices(runtime_types::pallet_indices::pallet::Event), - #[codec(index = 4)] - Balances(runtime_types::pallet_balances::pallet::Event), - #[codec(index = 33)] - TransactionPayment(runtime_types::pallet_transaction_payment::pallet::Event), - #[codec(index = 7)] - Offences(runtime_types::pallet_offences::pallet::Event), - #[codec(index = 8)] - Session(runtime_types::pallet_session::pallet::Event), - #[codec(index = 10)] - Grandpa(runtime_types::pallet_grandpa::pallet::Event), - #[codec(index = 11)] - ImOnline(runtime_types::pallet_im_online::pallet::Event), - #[codec(index = 13)] - Democracy(runtime_types::pallet_democracy::pallet::Event), - #[codec(index = 14)] - Council(runtime_types::pallet_collective::pallet::Event), - #[codec(index = 15)] - TechnicalCommittee(runtime_types::pallet_collective::pallet::Event2), - #[codec(index = 16)] - PhragmenElection(runtime_types::pallet_elections_phragmen::pallet::Event), - #[codec(index = 17)] - TechnicalMembership(runtime_types::pallet_membership::pallet::Event), - #[codec(index = 18)] - Treasury(runtime_types::pallet_treasury::pallet::Event), - #[codec(index = 19)] - Claims(runtime_types::polkadot_runtime_common::claims::pallet::Event), - #[codec(index = 24)] - Utility(runtime_types::pallet_utility::pallet::Event), - #[codec(index = 25)] - Identity(runtime_types::pallet_identity::pallet::Event), - #[codec(index = 26)] - Society(runtime_types::pallet_society::pallet::Event), - #[codec(index = 27)] - Recovery(runtime_types::pallet_recovery::pallet::Event), - #[codec(index = 28)] - Vesting(runtime_types::pallet_vesting::pallet::Event), - #[codec(index = 29)] - Scheduler(runtime_types::pallet_scheduler::pallet::Event), - #[codec(index = 30)] - Proxy(runtime_types::pallet_proxy::pallet::Event), - #[codec(index = 31)] - Multisig(runtime_types::pallet_multisig::pallet::Event), - #[codec(index = 32)] - Preimage(runtime_types::pallet_preimage::pallet::Event), - #[codec(index = 35)] - Bounties(runtime_types::pallet_bounties::pallet::Event), - #[codec(index = 40)] - ChildBounties(runtime_types::pallet_child_bounties::pallet::Event), - #[codec(index = 36)] - Tips(runtime_types::pallet_tips::pallet::Event), - #[codec(index = 38)] - Nis(runtime_types::pallet_nis::pallet::Event), - #[codec(index = 45)] - NisCounterpartBalances(runtime_types::pallet_balances::pallet::Event2), - #[codec(index = 53)] - ParaInclusion(runtime_types::polkadot_runtime_parachains::inclusion::pallet::Event), - #[codec(index = 56)] - Paras(runtime_types::polkadot_runtime_parachains::paras::pallet::Event), - #[codec(index = 60)] - Hrmp(runtime_types::polkadot_runtime_parachains::hrmp::pallet::Event), - #[codec(index = 62)] - ParasDisputes(runtime_types::polkadot_runtime_parachains::disputes::pallet::Event), - #[codec(index = 64)] - MessageQueue(runtime_types::pallet_message_queue::pallet::Event), - #[codec(index = 66)] - OnDemandAssignmentProvider( - runtime_types::polkadot_runtime_parachains::assigner_on_demand::pallet::Event, - ), - #[codec(index = 70)] - Registrar(runtime_types::polkadot_runtime_common::paras_registrar::pallet::Event), - #[codec(index = 71)] - Slots(runtime_types::polkadot_runtime_common::slots::pallet::Event), - #[codec(index = 72)] - Auctions(runtime_types::polkadot_runtime_common::auctions::pallet::Event), - #[codec(index = 73)] - Crowdloan(runtime_types::polkadot_runtime_common::crowdloan::pallet::Event), - #[codec(index = 99)] - XcmPallet(runtime_types::pallet_xcm::pallet::Event), - #[codec(index = 251)] - AssignedSlots( - runtime_types::polkadot_runtime_common::assigned_slots::pallet::Event, - ), - #[codec(index = 252)] - ValidatorManager(runtime_types::rococo_runtime::validator_manager::pallet::Event), - #[codec(index = 254)] - StateTrieMigration(runtime_types::pallet_state_trie_migration::pallet::Event), - #[codec(index = 255)] - Sudo(runtime_types::pallet_sudo::pallet::Event), - } - } - pub mod pallet_indices { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - IndexAssigned { - who: ::sp_core::crypto::AccountId32, - index: ::core::primitive::u32, - }, - #[codec(index = 1)] - IndexFreed { index: ::core::primitive::u32 }, - #[codec(index = 2)] - IndexFrozen { - index: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - }, - } - } - } - pub mod pallet_transaction_payment { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - TransactionFeePaid { - who: ::sp_core::crypto::AccountId32, - actual_fee: ::core::primitive::u128, - tip: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_offences { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Offence { - kind: [::core::primitive::u8; 16usize], - timeslot: ::sp_std::vec::Vec<::core::primitive::u8>, - }, - } - } - } - pub mod pallet_session { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewSession { session_index: ::core::primitive::u32 }, - } - } - } - pub mod sp_consensus_grandpa { - use super::runtime_types; - pub mod app { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::ed25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::ed25519::Signature); - } - } - pub mod pallet_grandpa { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewAuthorities { - authority_set: ::sp_std::vec::Vec<( - runtime_types::sp_consensus_grandpa::app::Public, - ::core::primitive::u64, - )>, - }, - #[codec(index = 1)] - Paused, - #[codec(index = 2)] - Resumed, - } - } - } - pub mod pallet_im_online { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - HeartbeatReceived { - authority_id: runtime_types::pallet_im_online::sr25519::app_sr25519::Public, - }, - #[codec(index = 1)] - AllGood, - #[codec(index = 2)] - SomeOffline { - offline: ::sp_std::vec::Vec<(::sp_core::crypto::AccountId32, ())>, - }, - } - } - pub mod sr25519 { - use super::runtime_types; - pub mod app_sr25519 { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - } - } - } - pub mod pallet_democracy { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { - proposal_index: ::core::primitive::u32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 1)] - Tabled { - proposal_index: ::core::primitive::u32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 2)] - ExternalTabled, - #[codec(index = 3)] - Started { - ref_index: ::core::primitive::u32, - threshold: runtime_types::pallet_democracy::vote_threshold::VoteThreshold, - }, - #[codec(index = 4)] - Passed { ref_index: ::core::primitive::u32 }, - #[codec(index = 5)] - NotPassed { ref_index: ::core::primitive::u32 }, - #[codec(index = 6)] - Cancelled { ref_index: ::core::primitive::u32 }, - #[codec(index = 7)] - Delegated { - who: ::sp_core::crypto::AccountId32, - target: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 8)] - Undelegated { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 9)] - Vetoed { - who: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - until: ::core::primitive::u32, - }, - #[codec(index = 10)] - Blacklisted { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 11)] - Voted { - voter: ::sp_core::crypto::AccountId32, - ref_index: ::core::primitive::u32, - vote: runtime_types::pallet_democracy::vote::AccountVote< - ::core::primitive::u128, - >, - }, - #[codec(index = 12)] - Seconded { - seconder: ::sp_core::crypto::AccountId32, - prop_index: ::core::primitive::u32, - }, - #[codec(index = 13)] - ProposalCanceled { prop_index: ::core::primitive::u32 }, - #[codec(index = 14)] - MetadataSet { - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 15)] - MetadataCleared { - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 16)] - MetadataTransferred { - prev_owner: runtime_types::pallet_democracy::types::MetadataOwner, - owner: runtime_types::pallet_democracy::types::MetadataOwner, - hash: runtime_types::primitive_types::H256, - }, - } - } - pub mod types { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MetadataOwner { - #[codec(index = 0)] - External, - #[codec(index = 1)] - Proposal(::core::primitive::u32), - #[codec(index = 2)] - Referendum(::core::primitive::u32), - } - } - pub mod vote { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AccountVote<_0> { - #[codec(index = 0)] - Standard { vote: runtime_types::pallet_democracy::vote::Vote, balance: _0 }, - #[codec(index = 1)] - Split { aye: _0, nay: _0 }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Vote(pub ::core::primitive::u8); - } - pub mod vote_threshold { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VoteThreshold { - #[codec(index = 0)] - SuperMajorityApprove, - #[codec(index = 1)] - SuperMajorityAgainst, - #[codec(index = 2)] - SimpleMajority, - } - } - } - pub mod pallet_collective { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { - account: ::sp_core::crypto::AccountId32, - proposal_index: ::core::primitive::u32, - proposal_hash: runtime_types::primitive_types::H256, - threshold: ::core::primitive::u32, - }, - #[codec(index = 1)] - Voted { - account: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - voted: ::core::primitive::bool, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - #[codec(index = 2)] - Approved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 3)] - Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - Executed { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 5)] - MemberExecuted { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 6)] - Closed { - proposal_hash: runtime_types::primitive_types::H256, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event2 { - #[codec(index = 0)] - Proposed { - account: ::sp_core::crypto::AccountId32, - proposal_index: ::core::primitive::u32, - proposal_hash: runtime_types::primitive_types::H256, - threshold: ::core::primitive::u32, - }, - #[codec(index = 1)] - Voted { - account: ::sp_core::crypto::AccountId32, - proposal_hash: runtime_types::primitive_types::H256, - voted: ::core::primitive::bool, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - #[codec(index = 2)] - Approved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 3)] - Disapproved { proposal_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - Executed { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 5)] - MemberExecuted { - proposal_hash: runtime_types::primitive_types::H256, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 6)] - Closed { - proposal_hash: runtime_types::primitive_types::H256, - yes: ::core::primitive::u32, - no: ::core::primitive::u32, - }, - } - } - } - pub mod pallet_elections_phragmen { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewTerm { - new_members: ::sp_std::vec::Vec<( - ::sp_core::crypto::AccountId32, - ::core::primitive::u128, - )>, - }, - #[codec(index = 1)] - EmptyTerm, - #[codec(index = 2)] - ElectionError, - #[codec(index = 3)] - MemberKicked { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - Renounced { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - CandidateSlashed { - candidate: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - SeatHolderSlashed { - seat_holder: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_membership { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - MemberAdded, - #[codec(index = 1)] - MemberRemoved, - #[codec(index = 2)] - MembersSwapped, - #[codec(index = 3)] - MembersReset, - #[codec(index = 4)] - KeyChanged, - #[codec(index = 5)] - Dummy, - } - } - } - pub mod pallet_treasury { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Proposed { proposal_index: ::core::primitive::u32 }, - #[codec(index = 1)] - Spending { budget_remaining: ::core::primitive::u128 }, - #[codec(index = 2)] - Awarded { - proposal_index: ::core::primitive::u32, - award: ::core::primitive::u128, - account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Rejected { - proposal_index: ::core::primitive::u32, - slashed: ::core::primitive::u128, - }, - #[codec(index = 4)] - Burnt { burnt_funds: ::core::primitive::u128 }, - #[codec(index = 5)] - Rollover { rollover_balance: ::core::primitive::u128 }, - #[codec(index = 6)] - Deposit { value: ::core::primitive::u128 }, - #[codec(index = 7)] - SpendApproved { - proposal_index: ::core::primitive::u32, - amount: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 8)] - UpdatedInactive { - reactivated: ::core::primitive::u128, - deactivated: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_identity { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - IdentitySet { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - IdentityCleared { - who: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 2)] - IdentityKilled { - who: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 3)] - JudgementRequested { - who: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 4)] - JudgementUnrequested { - who: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 5)] - JudgementGiven { - target: ::sp_core::crypto::AccountId32, - registrar_index: ::core::primitive::u32, - }, - #[codec(index = 6)] - RegistrarAdded { registrar_index: ::core::primitive::u32 }, - #[codec(index = 7)] - SubIdentityAdded { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 8)] - SubIdentityRemoved { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - #[codec(index = 9)] - SubIdentityRevoked { - sub: ::sp_core::crypto::AccountId32, - main: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_society { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Founded { founder: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - Bid { - candidate_id: ::sp_core::crypto::AccountId32, - offer: ::core::primitive::u128, - }, - #[codec(index = 2)] - Vouch { - candidate_id: ::sp_core::crypto::AccountId32, - offer: ::core::primitive::u128, - vouching: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - AutoUnbid { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - Unbid { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - Unvouch { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 6)] - Inducted { - primary: ::sp_core::crypto::AccountId32, - candidates: ::sp_std::vec::Vec<::sp_core::crypto::AccountId32>, - }, - #[codec(index = 7)] - SuspendedMemberJudgement { - who: ::sp_core::crypto::AccountId32, - judged: ::core::primitive::bool, - }, - #[codec(index = 8)] - CandidateSuspended { candidate: ::sp_core::crypto::AccountId32 }, - #[codec(index = 9)] - MemberSuspended { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 10)] - Challenged { member: ::sp_core::crypto::AccountId32 }, - #[codec(index = 11)] - Vote { - candidate: ::sp_core::crypto::AccountId32, - voter: ::sp_core::crypto::AccountId32, - vote: ::core::primitive::bool, - }, - #[codec(index = 12)] - DefenderVote { - voter: ::sp_core::crypto::AccountId32, - vote: ::core::primitive::bool, - }, - #[codec(index = 13)] - NewParams { - params: runtime_types::pallet_society::GroupParams<::core::primitive::u128>, - }, - #[codec(index = 14)] - Unfounded { founder: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Deposit { value: ::core::primitive::u128 }, - #[codec(index = 16)] - Elevated { - member: ::sp_core::crypto::AccountId32, - rank: ::core::primitive::u32, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct GroupParams<_0> { - pub max_members: ::core::primitive::u32, - pub max_intake: ::core::primitive::u32, - pub max_strikes: ::core::primitive::u32, - pub candidate_deposit: _0, - } - } - pub mod pallet_recovery { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - RecoveryCreated { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 1)] - RecoveryInitiated { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 2)] - RecoveryVouched { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - sender: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - RecoveryClosed { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 4)] - AccountRecovered { - lost_account: ::sp_core::crypto::AccountId32, - rescuer_account: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 5)] - RecoveryRemoved { lost_account: ::sp_core::crypto::AccountId32 }, - } - } - } - pub mod pallet_utility { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BatchInterrupted { - index: ::core::primitive::u32, - error: runtime_types::sp_runtime::DispatchError, - }, - #[codec(index = 1)] - BatchCompleted, - #[codec(index = 2)] - BatchCompletedWithErrors, - #[codec(index = 3)] - ItemCompleted, - #[codec(index = 4)] - ItemFailed { error: runtime_types::sp_runtime::DispatchError }, - #[codec(index = 5)] - DispatchedAs { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod pallet_vesting { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - VestingUpdated { - account: ::sp_core::crypto::AccountId32, - unvested: ::core::primitive::u128, - }, - #[codec(index = 1)] - VestingCompleted { account: ::sp_core::crypto::AccountId32 }, - } - } - } - pub mod pallet_scheduler { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Scheduled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 1)] - Canceled { when: ::core::primitive::u32, index: ::core::primitive::u32 }, - #[codec(index = 2)] - Dispatched { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - CallUnavailable { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 4)] - PeriodicFailed { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - #[codec(index = 5)] - PermanentlyOverweight { - task: (::core::primitive::u32, ::core::primitive::u32), - id: ::core::option::Option<[::core::primitive::u8; 32usize]>, - }, - } - } - } - pub mod pallet_proxy { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ProxyExecuted { - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - PureCreated { - pure: ::sp_core::crypto::AccountId32, - who: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - disambiguation_index: ::core::primitive::u16, - }, - #[codec(index = 2)] - Announced { - real: ::sp_core::crypto::AccountId32, - proxy: ::sp_core::crypto::AccountId32, - call_hash: runtime_types::primitive_types::H256, - }, - #[codec(index = 3)] - ProxyAdded { - delegator: ::sp_core::crypto::AccountId32, - delegatee: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - #[codec(index = 4)] - ProxyRemoved { - delegator: ::sp_core::crypto::AccountId32, - delegatee: ::sp_core::crypto::AccountId32, - proxy_type: runtime_types::rococo_runtime::ProxyType, - delay: ::core::primitive::u32, - }, - } - } - } - pub mod pallet_multisig { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewMultisig { - approving: ::sp_core::crypto::AccountId32, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 1)] - MultisigApproval { - approving: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - MultisigExecuted { - approving: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 3)] - MultisigCancelled { - cancelling: ::sp_core::crypto::AccountId32, - timepoint: - runtime_types::pallet_multisig::Timepoint<::core::primitive::u32>, - multisig: ::sp_core::crypto::AccountId32, - call_hash: [::core::primitive::u8; 32usize], - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Timepoint<_0> { - pub height: _0, - pub index: ::core::primitive::u32, - } - } - pub mod pallet_preimage { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Noted { hash: runtime_types::primitive_types::H256 }, - #[codec(index = 1)] - Requested { hash: runtime_types::primitive_types::H256 }, - #[codec(index = 2)] - Cleared { hash: runtime_types::primitive_types::H256 }, - } - } - } - pub mod pallet_bounties { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BountyProposed { index: ::core::primitive::u32 }, - #[codec(index = 1)] - BountyRejected { index: ::core::primitive::u32, bond: ::core::primitive::u128 }, - #[codec(index = 2)] - BountyBecameActive { index: ::core::primitive::u32 }, - #[codec(index = 3)] - BountyAwarded { - index: ::core::primitive::u32, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 4)] - BountyClaimed { - index: ::core::primitive::u32, - payout: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 5)] - BountyCanceled { index: ::core::primitive::u32 }, - #[codec(index = 6)] - BountyExtended { index: ::core::primitive::u32 }, - } - } - } - pub mod pallet_child_bounties { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Added { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, - #[codec(index = 1)] - Awarded { - index: ::core::primitive::u32, - child_index: ::core::primitive::u32, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 2)] - Claimed { - index: ::core::primitive::u32, - child_index: ::core::primitive::u32, - payout: ::core::primitive::u128, - beneficiary: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Canceled { index: ::core::primitive::u32, child_index: ::core::primitive::u32 }, - } - } - } - pub mod pallet_tips { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewTip { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 1)] - TipClosing { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 2)] - TipClosed { - tip_hash: runtime_types::primitive_types::H256, - who: ::sp_core::crypto::AccountId32, - payout: ::core::primitive::u128, - }, - #[codec(index = 3)] - TipRetracted { tip_hash: runtime_types::primitive_types::H256 }, - #[codec(index = 4)] - TipSlashed { - tip_hash: runtime_types::primitive_types::H256, - finder: ::sp_core::crypto::AccountId32, - deposit: ::core::primitive::u128, - }, - } - } - } - pub mod pallet_nis { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - BidPlaced { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 1)] - BidRetracted { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 2)] - BidDropped { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - duration: ::core::primitive::u32, - }, - #[codec(index = 3)] - Issued { - index: ::core::primitive::u32, - expiry: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - Thawed { - index: ::core::primitive::u32, - who: ::sp_core::crypto::AccountId32, - proportion: runtime_types::sp_arithmetic::per_things::Perquintill, - amount: ::core::primitive::u128, - dropped: ::core::primitive::bool, - }, - #[codec(index = 5)] - Funded { deficit: ::core::primitive::u128 }, - #[codec(index = 6)] - Transferred { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - index: ::core::primitive::u32, - }, - } - } - } - pub mod polkadot_core_primitives { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateHash(pub runtime_types::primitive_types::H256); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct InboundDownwardMessage<_0> { - pub sent_at: _0, - pub msg: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct InboundHrmpMessage<_0> { - pub sent_at: _0, - pub data: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct OutboundHrmpMessage<_0> { - pub recipient: _0, - pub data: ::sp_std::vec::Vec<::core::primitive::u8>, - } - } - pub mod polkadot_primitives { - use super::runtime_types; - pub mod v5 { - use super::runtime_types; - // pub mod assignment_app { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Public(pub runtime_types::sp_core::sr25519::Public); - // } - pub mod collator_app { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub runtime_types::sp_core::sr25519::Public); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - } - // pub mod executor_params { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ExecutorParam { - // #[codec(index = 1)] - // MaxMemoryPages(::core::primitive::u32), - // #[codec(index = 2)] - // StackLogicalMax(::core::primitive::u32), - // #[codec(index = 3)] - // StackNativeMax(::core::primitive::u32), - // #[codec(index = 4)] - // PrecheckingMaxMemory(::core::primitive::u64), - // #[codec(index = 5)] - // PvfPrepTimeout( - // runtime_types::polkadot_primitives::v5::PvfPrepTimeoutKind, - // ::core::primitive::u64, - // ), - // #[codec(index = 6)] - // PvfExecTimeout( - // runtime_types::polkadot_primitives::v5::PvfExecTimeoutKind, - // ::core::primitive::u64, - // ), - // #[codec(index = 7)] - // WasmExtBulkMemory, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ExecutorParams( - // pub ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::executor_params::ExecutorParam, - // >, - // ); - // } - // pub mod signed { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct UncheckedSigned<_0, _1> { - // pub payload: _0, - // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, - // pub signature: - // runtime_types::polkadot_primitives::v5::validator_app::Signature, - // #[codec(skip)] - // pub __subxt_unused_type_params: ::core::marker::PhantomData<_1>, - // } - // } - // pub mod slashing { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeProof { - // pub time_slot: - // runtime_types::polkadot_primitives::v5::slashing::DisputesTimeSlot, - // pub kind: - // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, - // pub validator_index: runtime_types::polkadot_primitives::v5::ValidatorIndex, - // pub validator_id: - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputesTimeSlot { - // pub session_index: ::core::primitive::u32, - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OpaqueKeyOwnershipProof(pub ::sp_std::vec::Vec<::core::primitive::u8>); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PendingSlashes { - // pub keys: ::subxt::utils::KeyedVec< - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // >, - // pub kind: - // runtime_types::polkadot_primitives::v5::slashing::SlashingOffenceKind, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum SlashingOffenceKind { - // #[codec(index = 0)] - // ForInvalid, - // #[codec(index = 1)] - // AgainstValid, - // } - // } - // pub mod validator_app { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Public(pub runtime_types::sp_core::sr25519::Public); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Signature(pub runtime_types::sp_core::sr25519::Signature); - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Assignment { - // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AvailabilityBitfield( - // pub ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // ); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct BackedCandidate<_0> { - // pub candidate: - // runtime_types::polkadot_primitives::v5::CommittedCandidateReceipt<_0>, - // pub validity_votes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::ValidityAttestation, - // >, - // pub validator_indices: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidateCommitments<_0> { - // pub upward_messages: - // runtime_types::bounded_collections::bounded_vec::BoundedVec< - // ::sp_std::vec::Vec<::core::primitive::u8>, - // >, - // pub horizontal_messages: - // runtime_types::bounded_collections::bounded_vec::BoundedVec< - // runtime_types::polkadot_core_primitives::OutboundHrmpMessage< - // runtime_types::polkadot_parachain_primitives::primitives::Id, - // >, - // >, - // pub new_validation_code: ::core::option::Option< - // runtime_types::polkadot_parachain_primitives::primitives::ValidationCode, - // >, - // pub head_data: - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // pub processed_downward_messages: ::core::primitive::u32, - // pub hrmp_watermark: _0, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateDescriptor < _0 > { pub para_id : runtime_types :: polkadot_parachain_primitives :: primitives :: Id , pub relay_parent : _0 , pub collator : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Public , pub persisted_validation_data_hash : runtime_types::primitive_types::H256 , pub pov_hash : runtime_types::primitive_types::H256 , pub erasure_root : runtime_types::primitive_types::H256 , pub signature : runtime_types :: polkadot_primitives :: v5 :: collator_app :: Signature , pub para_head : runtime_types::primitive_types::H256 , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CandidateEvent<_0> { - // #[codec(index = 0)] - // CandidateBacked( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ), - // #[codec(index = 1)] - // CandidateIncluded( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ), - // #[codec(index = 2)] - // CandidateTimedOut( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // runtime_types::polkadot_primitives::v5::CoreIndex, - // ), - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CandidateReceipt<_0> { - pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - pub commitments_hash: runtime_types::primitive_types::H256, - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CommittedCandidateReceipt<_0> { - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub commitments: runtime_types::polkadot_primitives::v5::CandidateCommitments< - // ::core::primitive::u32, - // >, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct CoreIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CoreOccupied<_0> { - // #[codec(index = 0)] - // Free, - // #[codec(index = 1)] - // Paras(runtime_types::polkadot_primitives::v5::ParasEntry<_0>), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum CoreState<_0, _1> { - // #[codec(index = 0)] - // Occupied(runtime_types::polkadot_primitives::v5::OccupiedCore<_0, _1>), - // #[codec(index = 1)] - // Scheduled(runtime_types::polkadot_primitives::v5::ScheduledCore), - // #[codec(index = 2)] - // Free, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeState<_0> { - // pub validators_for: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub validators_against: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub start: _0, - // pub concluded_at: ::core::option::Option<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum DisputeStatement { - // #[codec(index = 0)] - // Valid(runtime_types::polkadot_primitives::v5::ValidDisputeStatementKind), - // #[codec(index = 1)] - // Invalid(runtime_types::polkadot_primitives::v5::InvalidDisputeStatementKind), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct DisputeStatementSet { - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub session: ::core::primitive::u32, - // pub statements: ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::DisputeStatement, - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Signature, - // )>, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct GroupIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct GroupRotationInfo<_0> { - // pub session_start_block: _0, - // pub group_rotation_frequency: _0, - // pub now: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct IndexedVec<_0, _1>( - // pub ::sp_std::vec::Vec<_1>, - // #[codec(skip)] pub ::core::marker::PhantomData<_0>, - // ); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct InherentData<_0> { - // pub bitfields: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::signed::UncheckedSigned< - // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // >, - // >, - // pub backed_candidates: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::BackedCandidate< - // ::subxt::utils::H256, - // >, - // >, - // pub disputes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::DisputeStatementSet, - // >, - // pub parent_header: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum InvalidDisputeStatementKind { - // #[codec(index = 0)] - // Explicit, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OccupiedCore<_0, _1> { - // pub next_up_on_available: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::ScheduledCore, - // >, - // pub occupied_since: _1, - // pub time_out_at: _1, - // pub next_up_on_time_out: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::ScheduledCore, - // >, - // pub availability: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub group_responsible: runtime_types::polkadot_primitives::v5::GroupIndex, - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub candidate_descriptor: - // runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum OccupiedCoreAssumption { - // #[codec(index = 0)] - // Included, - // #[codec(index = 1)] - // TimedOut, - // #[codec(index = 2)] - // Free, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ParasEntry<_0> { - // pub assignment: runtime_types::polkadot_primitives::v5::Assignment, - // pub availability_timeouts: ::core::primitive::u32, - // pub ttl: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PersistedValidationData<_0, _1> { - // pub parent_head: - // runtime_types::polkadot_parachain_primitives::primitives::HeadData, - // pub relay_parent_number: _1, - // pub relay_parent_storage_root: _0, - // pub max_pov_size: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct PvfCheckStatement { pub accept : :: core :: primitive :: bool , pub subject : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub session_index : :: core :: primitive :: u32 , pub validator_index : runtime_types :: polkadot_primitives :: v5 :: ValidatorIndex , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum PvfExecTimeoutKind { - // #[codec(index = 0)] - // Backing, - // #[codec(index = 1)] - // Approval, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum PvfPrepTimeoutKind { - // #[codec(index = 0)] - // Precheck, - // #[codec(index = 1)] - // Lenient, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ScheduledCore { - // pub para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - // pub collator: ::core::option::Option< - // runtime_types::polkadot_primitives::v5::collator_app::Public, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct ScrapedOnChainVotes<_0> { - // pub session: ::core::primitive::u32, - // pub backing_validators_per_candidate: ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::CandidateReceipt<_0>, - // ::sp_std::vec::Vec<( - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::ValidityAttestation, - // )>, - // )>, - // pub disputes: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::DisputeStatementSet, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct SessionInfo { - // pub active_validator_indices: - // ::sp_std::vec::Vec, - // pub random_seed: [::core::primitive::u8; 32usize], - // pub dispute_period: ::core::primitive::u32, - // pub validators: runtime_types::polkadot_primitives::v5::IndexedVec< - // runtime_types::polkadot_primitives::v5::ValidatorIndex, - // runtime_types::polkadot_primitives::v5::validator_app::Public, - // >, - // pub discovery_keys: - // ::sp_std::vec::Vec, - // pub assignment_keys: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::v5::assignment_app::Public, - // >, - // pub validator_groups: runtime_types::polkadot_primitives::v5::IndexedVec< - // runtime_types::polkadot_primitives::v5::GroupIndex, - // ::sp_std::vec::Vec, - // >, - // pub n_cores: ::core::primitive::u32, - // pub zeroth_delay_tranche_width: ::core::primitive::u32, - // pub relay_vrf_modulo_samples: ::core::primitive::u32, - // pub n_delay_tranches: ::core::primitive::u32, - // pub no_show_slots: ::core::primitive::u32, - // pub needed_approvals: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum UpgradeGoAhead { - // #[codec(index = 0)] - // Abort, - // #[codec(index = 1)] - // GoAhead, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum UpgradeRestriction { - // #[codec(index = 0)] - // Present, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ValidDisputeStatementKind { - // #[codec(index = 0)] - // Explicit, - // #[codec(index = 1)] - // BackingSeconded(::subxt::utils::H256), - // #[codec(index = 2)] - // BackingValid(::subxt::utils::H256), - // #[codec(index = 3)] - // ApprovalChecking, - // } - // #[derive( - // :: codec :: Decode, - // :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - // Clone, - // Debug, - // PartialEq, - // )] - // pub struct ValidatorIndex(pub ::core::primitive::u32); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum ValidityAttestation { - // #[codec(index = 1)] - // Implicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), - // #[codec(index = 2)] - // Explicit(runtime_types::polkadot_primitives::v5::validator_app::Signature), - // } - // } - // pub mod vstaging { - // use super::runtime_types; - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AsyncBackingParams { - // pub max_candidate_depth: ::core::primitive::u32, - // pub allowed_ancestry_len: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct BackingState<_0, _1> { - // pub constraints: runtime_types::polkadot_primitives::vstaging::Constraints<_1>, - // pub pending_availability: ::sp_std::vec::Vec< - // runtime_types::polkadot_primitives::vstaging::CandidatePendingAvailability< - // _0, - // _1, - // >, - // >, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidatePendingAvailability<_0, _1> { - // pub candidate_hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub commitments: - // runtime_types::polkadot_primitives::v5::CandidateCommitments<_1>, - // pub relay_parent_number: _1, - // pub max_pov_size: ::core::primitive::u32, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Constraints < _0 > { pub min_relay_parent_number : _0 , pub max_pov_size : :: core :: primitive :: u32 , pub max_code_size : :: core :: primitive :: u32 , pub ump_remaining : :: core :: primitive :: u32 , pub ump_remaining_bytes : :: core :: primitive :: u32 , pub max_ump_num_per_candidate : :: core :: primitive :: u32 , pub dmp_remaining_messages : :: std :: vec :: Vec < _0 > , pub hrmp_inbound : runtime_types :: polkadot_primitives :: vstaging :: InboundHrmpLimitations < _0 > , pub hrmp_channels_out : :: std :: vec :: Vec < (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , runtime_types :: polkadot_primitives :: vstaging :: OutboundHrmpChannelLimitations ,) > , pub max_hrmp_num_per_candidate : :: core :: primitive :: u32 , pub required_parent : runtime_types :: polkadot_parachain_primitives :: primitives :: HeadData , pub validation_code_hash : runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , pub upgrade_restriction : :: core :: option :: Option < runtime_types :: polkadot_primitives :: v5 :: UpgradeRestriction > , pub future_validation_code : :: core :: option :: Option < (_0 , runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash ,) > , } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct InboundHrmpLimitations<_0> { - // pub valid_watermarks: ::sp_std::vec::Vec<_0>, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct OutboundHrmpChannelLimitations { - // pub bytes_remaining: ::core::primitive::u32, - // pub messages_remaining: ::core::primitive::u32, - // } - } - } - pub mod sp_core { - use super::runtime_types; - pub mod crypto { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct KeyTypeId(pub [::core::primitive::u8; 4usize]); - } - pub mod ecdsa { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 33usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 65usize]); - } - pub mod ed25519 { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - pub mod sr25519 { - use super::runtime_types; - pub mod vrf { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct VrfSignature { - pub output: [::core::primitive::u8; 32usize], - pub proof: [::core::primitive::u8; 64usize], - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Public(pub [::core::primitive::u8; 32usize]); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Signature(pub [::core::primitive::u8; 64usize]); - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct OpaqueMetadata(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Void {} - } - pub mod pallet_message_queue { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - # [codec (index = 0)] ProcessingFailed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , error : runtime_types :: frame_support :: traits :: messages :: ProcessMessageError , } , # [codec (index = 1)] Processed { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , weight_used : :: sp_weights :: Weight , success : :: core :: primitive :: bool , } , # [codec (index = 2)] OverweightEnqueued { id : [:: core :: primitive :: u8 ; 32usize] , origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , page_index : :: core :: primitive :: u32 , message_index : :: core :: primitive :: u32 , } , # [codec (index = 3)] PageReaped { origin : runtime_types :: polkadot_runtime_parachains :: inclusion :: AggregateMessageOrigin , index : :: core :: primitive :: u32 , } , } - } - } - pub mod pallet_xcm { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Attempted { outcome: runtime_types::staging_xcm::v3::traits::Outcome }, - #[codec(index = 1)] - Sent { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - message: runtime_types::staging_xcm::v3::Xcm, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - UnexpectedResponse { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 3)] - ResponseReady { - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v3::Response, - }, - #[codec(index = 4)] - Notified { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 5)] - NotifyOverweight { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - actual_weight: ::sp_weights::Weight, - max_budgeted_weight: ::sp_weights::Weight, - }, - #[codec(index = 6)] - NotifyDispatchError { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 7)] - NotifyDecodeFailed { - query_id: ::core::primitive::u64, - pallet_index: ::core::primitive::u8, - call_index: ::core::primitive::u8, - }, - #[codec(index = 8)] - InvalidResponder { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - expected_location: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 9)] - InvalidResponderVersion { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 10)] - ResponseTaken { query_id: ::core::primitive::u64 }, - #[codec(index = 11)] - AssetsTrapped { - hash: runtime_types::primitive_types::H256, - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::VersionedMultiAssets, - }, - #[codec(index = 12)] - VersionChangeNotified { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - result: ::core::primitive::u32, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 13)] - SupportedVersionChanged { - location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - version: ::core::primitive::u32, - }, - #[codec(index = 14)] - NotifyTargetSendFail { - location: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - error: runtime_types::staging_xcm::v3::traits::Error, - }, - #[codec(index = 15)] - NotifyTargetMigrationFail { - location: runtime_types::staging_xcm::VersionedMultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 16)] - InvalidQuerierVersion { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - }, - #[codec(index = 17)] - InvalidQuerier { - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - query_id: ::core::primitive::u64, - expected_querier: - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - maybe_actual_querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 18)] - VersionNotifyStarted { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 19)] - VersionNotifyRequested { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 20)] - VersionNotifyUnrequested { - destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - cost: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - message_id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 21)] - FeesPaid { - paying: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - fees: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - }, - #[codec(index = 22)] - AssetsClaimed { - hash: runtime_types::primitive_types::H256, - origin: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::VersionedMultiAssets, - }, - } - } - } - pub mod staging_xcm { - use super::runtime_types; - pub mod double_encoded { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DoubleEncoded { - pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DoubleEncoded2 { - pub encoded: ::sp_std::vec::Vec<::core::primitive::u8>, - } - } - pub mod v2 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: runtime_types::staging_xcm::v2::NetworkId, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: runtime_types::staging_xcm::v2::NetworkId, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: runtime_types::staging_xcm::v2::NetworkId, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::staging_xcm::v2::BodyId, - part: runtime_types::staging_xcm::v2::BodyPart, - }, - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::staging_xcm::v2::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract(::sp_std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - #[codec(index = 6)] - Blob(::sp_std::vec::Vec<::core::primitive::u8>), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::staging_xcm::v2::multiasset::AssetInstance), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAsset { - pub id: runtime_types::staging_xcm::v2::multiasset::AssetId, - pub fun: runtime_types::staging_xcm::v2::multiasset::Fungibility, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::staging_xcm::v2::multiasset::WildMultiAsset), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAssets( - pub ::sp_std::vec::Vec< - runtime_types::staging_xcm::v2::multiasset::MultiAsset, - >, - ); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::staging_xcm::v2::multiasset::AssetId, - fun: runtime_types::staging_xcm::v2::multiasset::WildFungibility, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::staging_xcm::v2::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - runtime_types::staging_xcm::v2::junction::Junction, - ), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::staging_xcm::v2::multilocation::Junctions, - } - } - pub mod traits { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - MultiLocationFull, - #[codec(index = 5)] - MultiLocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - UnhandledXcmVersion, - #[codec(index = 23)] - WeightLimitReached(::core::primitive::u64), - #[codec(index = 24)] - Barrier, - #[codec(index = 25)] - WeightNotComputable, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::staging_xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v2::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v2::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction2 { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v2::Response, - #[codec(compact)] - max_weight: ::core::primitive::u64, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_type: runtime_types::staging_xcm::v2::OriginKind, - #[codec(compact)] - require_weight_at_most: ::core::primitive::u64, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v2::multilocation::Junctions), - #[codec(index = 12)] - ReportError { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - beneficiary: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_assets: ::core::primitive::u32, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - receive: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v2::Xcm, - }, - #[codec(index = 18)] - QueryHolding { - #[codec(compact)] - query_id: ::core::primitive::u64, - dest: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssetFilter, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v2::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v2::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v2::Xcm2), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v2::Xcm2), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v2::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v2::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - #[codec(compact)] - max_response_weight: ::core::primitive::u64, - }, - #[codec(index = 27)] - UnsubscribeVersion, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum NetworkId { - #[codec(index = 0)] - Any, - #[codec(index = 1)] - Named( - runtime_types::bounded_collections::weak_bounded_vec::WeakBoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum OriginKind { - #[codec(index = 0)] - Native, - #[codec(index = 1)] - SovereignAccount, - #[codec(index = 2)] - Superuser, - #[codec(index = 3)] - Xcm, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v2::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(#[codec(compact)] ::core::primitive::u64), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm(pub ::sp_std::vec::Vec); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm2( - pub ::sp_std::vec::Vec, - ); - } - pub mod v3 { - use super::runtime_types; - pub mod junction { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyId { - #[codec(index = 0)] - Unit, - #[codec(index = 1)] - Moniker([::core::primitive::u8; 4usize]), - #[codec(index = 2)] - Index(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - Executive, - #[codec(index = 4)] - Technical, - #[codec(index = 5)] - Legislative, - #[codec(index = 6)] - Judicial, - #[codec(index = 7)] - Defense, - #[codec(index = 8)] - Administration, - #[codec(index = 9)] - Treasury, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BodyPart { - #[codec(index = 0)] - Voice, - #[codec(index = 1)] - Members { - #[codec(compact)] - count: ::core::primitive::u32, - }, - #[codec(index = 2)] - Fraction { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 3)] - AtLeastProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - #[codec(index = 4)] - MoreThanProportion { - #[codec(compact)] - nom: ::core::primitive::u32, - #[codec(compact)] - denom: ::core::primitive::u32, - }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junction { - #[codec(index = 0)] - Parachain(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 1)] - AccountId32 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - id: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - AccountIndex64 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - #[codec(compact)] - index: ::core::primitive::u64, - }, - #[codec(index = 3)] - AccountKey20 { - network: ::core::option::Option< - runtime_types::staging_xcm::v3::junction::NetworkId, - >, - key: [::core::primitive::u8; 20usize], - }, - #[codec(index = 4)] - PalletInstance(::core::primitive::u8), - #[codec(index = 5)] - GeneralIndex(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 6)] - GeneralKey { - length: ::core::primitive::u8, - data: [::core::primitive::u8; 32usize], - }, - #[codec(index = 7)] - OnlyChild, - #[codec(index = 8)] - Plurality { - id: runtime_types::staging_xcm::v3::junction::BodyId, - part: runtime_types::staging_xcm::v3::junction::BodyPart, - }, - #[codec(index = 9)] - GlobalConsensus(runtime_types::staging_xcm::v3::junction::NetworkId), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum NetworkId { - #[codec(index = 0)] - ByGenesis([::core::primitive::u8; 32usize]), - #[codec(index = 1)] - ByFork { - block_number: ::core::primitive::u64, - block_hash: [::core::primitive::u8; 32usize], - }, - #[codec(index = 2)] - Polkadot, - #[codec(index = 3)] - Kusama, - #[codec(index = 4)] - Westend, - #[codec(index = 5)] - Rococo, - #[codec(index = 6)] - Wococo, - #[codec(index = 7)] - Ethereum { - #[codec(compact)] - chain_id: ::core::primitive::u64, - }, - #[codec(index = 8)] - BitcoinCore, - #[codec(index = 9)] - BitcoinCash, - } - } - pub mod junctions { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Junctions { - #[codec(index = 0)] - Here, - #[codec(index = 1)] - X1(runtime_types::staging_xcm::v3::junction::Junction), - #[codec(index = 2)] - X2( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 3)] - X3( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 4)] - X4( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 5)] - X5( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 6)] - X6( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 7)] - X7( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - #[codec(index = 8)] - X8( - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - runtime_types::staging_xcm::v3::junction::Junction, - ), - } - } - pub mod multiasset { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetId { - #[codec(index = 0)] - Concrete(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 1)] - Abstract([::core::primitive::u8; 32usize]), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AssetInstance { - #[codec(index = 0)] - Undefined, - #[codec(index = 1)] - Index(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 2)] - Array4([::core::primitive::u8; 4usize]), - #[codec(index = 3)] - Array8([::core::primitive::u8; 8usize]), - #[codec(index = 4)] - Array16([::core::primitive::u8; 16usize]), - #[codec(index = 5)] - Array32([::core::primitive::u8; 32usize]), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Fungibility { - #[codec(index = 0)] - Fungible(#[codec(compact)] ::core::primitive::u128), - #[codec(index = 1)] - NonFungible(runtime_types::staging_xcm::v3::multiasset::AssetInstance), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAsset { - pub id: runtime_types::staging_xcm::v3::multiasset::AssetId, - pub fun: runtime_types::staging_xcm::v3::multiasset::Fungibility, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MultiAssetFilter { - #[codec(index = 0)] - Definite(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - Wild(runtime_types::staging_xcm::v3::multiasset::WildMultiAsset), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiAssets( - pub ::sp_std::vec::Vec< - runtime_types::staging_xcm::v3::multiasset::MultiAsset, - >, - ); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildFungibility { - #[codec(index = 0)] - Fungible, - #[codec(index = 1)] - NonFungible, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WildMultiAsset { - #[codec(index = 0)] - All, - #[codec(index = 1)] - AllOf { - id: runtime_types::staging_xcm::v3::multiasset::AssetId, - fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, - }, - #[codec(index = 2)] - AllCounted(#[codec(compact)] ::core::primitive::u32), - #[codec(index = 3)] - AllOfCounted { - id: runtime_types::staging_xcm::v3::multiasset::AssetId, - fun: runtime_types::staging_xcm::v3::multiasset::WildFungibility, - #[codec(compact)] - count: ::core::primitive::u32, - }, - } - } - pub mod multilocation { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct MultiLocation { - pub parents: ::core::primitive::u8, - pub interior: runtime_types::staging_xcm::v3::junctions::Junctions, - } - } - - pub mod traits { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - Overflow, - #[codec(index = 1)] - Unimplemented, - #[codec(index = 2)] - UntrustedReserveLocation, - #[codec(index = 3)] - UntrustedTeleportLocation, - #[codec(index = 4)] - LocationFull, - #[codec(index = 5)] - LocationNotInvertible, - #[codec(index = 6)] - BadOrigin, - #[codec(index = 7)] - InvalidLocation, - #[codec(index = 8)] - AssetNotFound, - #[codec(index = 9)] - FailedToTransactAsset, - #[codec(index = 10)] - NotWithdrawable, - #[codec(index = 11)] - LocationCannotHold, - #[codec(index = 12)] - ExceedsMaxMessageSize, - #[codec(index = 13)] - DestinationUnsupported, - #[codec(index = 14)] - Transport, - #[codec(index = 15)] - Unroutable, - #[codec(index = 16)] - UnknownClaim, - #[codec(index = 17)] - FailedToDecode, - #[codec(index = 18)] - MaxWeightInvalid, - #[codec(index = 19)] - NotHoldingFees, - #[codec(index = 20)] - TooExpensive, - #[codec(index = 21)] - Trap(::core::primitive::u64), - #[codec(index = 22)] - ExpectationFalse, - #[codec(index = 23)] - PalletNotFound, - #[codec(index = 24)] - NameMismatch, - #[codec(index = 25)] - VersionIncompatible, - #[codec(index = 26)] - HoldingWouldOverflow, - #[codec(index = 27)] - ExportError, - #[codec(index = 28)] - ReanchorFailed, - #[codec(index = 29)] - NoDeal, - #[codec(index = 30)] - FeesNotMet, - #[codec(index = 31)] - LockError, - #[codec(index = 32)] - NoPermission, - #[codec(index = 33)] - Unanchored, - #[codec(index = 34)] - NotDepositable, - #[codec(index = 35)] - UnhandledXcmVersion, - #[codec(index = 36)] - WeightLimitReached(::sp_weights::Weight), - #[codec(index = 37)] - Barrier, - #[codec(index = 38)] - WeightNotComputable, - #[codec(index = 39)] - ExceedsStackLimit, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Outcome { - #[codec(index = 0)] - Complete(::sp_weights::Weight), - #[codec(index = 1)] - Incomplete( - ::sp_weights::Weight, - runtime_types::staging_xcm::v3::traits::Error, - ), - #[codec(index = 2)] - Error(runtime_types::staging_xcm::v3::traits::Error), - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Instruction { - #[codec(index = 0)] - WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 1)] - ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 3)] - QueryResponse { - #[codec(compact)] - query_id: ::core::primitive::u64, - response: runtime_types::staging_xcm::v3::Response, - max_weight: ::sp_weights::Weight, - querier: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - #[codec(index = 4)] - TransferAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 5)] - TransferReserveAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 6)] - Transact { - origin_kind: runtime_types::staging_xcm::v2::OriginKind, - require_weight_at_most: ::sp_weights::Weight, - call: runtime_types::staging_xcm::double_encoded::DoubleEncoded, - }, - #[codec(index = 7)] - HrmpNewChannelOpenRequest { - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - max_message_size: ::core::primitive::u32, - #[codec(compact)] - max_capacity: ::core::primitive::u32, - }, - #[codec(index = 8)] - HrmpChannelAccepted { - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 9)] - HrmpChannelClosing { - #[codec(compact)] - initiator: ::core::primitive::u32, - #[codec(compact)] - sender: ::core::primitive::u32, - #[codec(compact)] - recipient: ::core::primitive::u32, - }, - #[codec(index = 10)] - ClearOrigin, - #[codec(index = 11)] - DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), - #[codec(index = 12)] - ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), - #[codec(index = 13)] - DepositAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 14)] - DepositReserveAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 15)] - ExchangeAsset { - give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - maximal: ::core::primitive::bool, - }, - #[codec(index = 16)] - InitiateReserveWithdraw { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 17)] - InitiateTeleport { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 18)] - ReportHolding { - response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - }, - #[codec(index = 19)] - BuyExecution { - fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - }, - #[codec(index = 20)] - RefundSurplus, - #[codec(index = 21)] - SetErrorHandler(runtime_types::staging_xcm::v3::Xcm), - #[codec(index = 22)] - SetAppendix(runtime_types::staging_xcm::v3::Xcm), - #[codec(index = 23)] - ClearError, - #[codec(index = 24)] - ClaimAsset { - assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 25)] - Trap(#[codec(compact)] ::core::primitive::u64), - #[codec(index = 26)] - SubscribeVersion { - #[codec(compact)] - query_id: ::core::primitive::u64, - max_response_weight: ::sp_weights::Weight, - }, - #[codec(index = 27)] - UnsubscribeVersion, - #[codec(index = 28)] - BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 29)] - ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 30)] - ExpectOrigin( - ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - ), - #[codec(index = 31)] - ExpectError( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v3::traits::Error, - )>, - ), - #[codec(index = 32)] - ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), - #[codec(index = 33)] - QueryPallet { - module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - }, - #[codec(index = 34)] - ExpectPallet { - #[codec(compact)] - index: ::core::primitive::u32, - name: ::sp_std::vec::Vec<::core::primitive::u8>, - module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - #[codec(compact)] - crate_major: ::core::primitive::u32, - #[codec(compact)] - min_crate_minor: ::core::primitive::u32, - }, - #[codec(index = 35)] - ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), - #[codec(index = 36)] - ClearTransactStatus, - #[codec(index = 37)] - UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), - #[codec(index = 38)] - ExportMessage { - network: runtime_types::staging_xcm::v3::junction::NetworkId, - destination: runtime_types::staging_xcm::v3::junctions::Junctions, - xcm: runtime_types::staging_xcm::v3::Xcm, - }, - #[codec(index = 39)] - LockAsset { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 40)] - UnlockAsset { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 41)] - NoteUnlockable { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 42)] - RequestUnlock { - asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - }, - #[codec(index = 43)] - SetFeesMode { jit_withdraw: ::core::primitive::bool }, - #[codec(index = 44)] - SetTopic([::core::primitive::u8; 32usize]), - #[codec(index = 45)] - ClearTopic, - #[codec(index = 46)] - AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - #[codec(index = 47)] - UnpaidExecution { - weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - check_origin: ::core::option::Option< - runtime_types::staging_xcm::v3::multilocation::MultiLocation, - >, - }, - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum Instruction2 { - // #[codec(index = 0)] - // WithdrawAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 1)] - // ReserveAssetDeposited(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 2)] - // ReceiveTeleportedAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 3)] - // QueryResponse { - // #[codec(compact)] - // query_id: ::core::primitive::u64, - // response: runtime_types::staging_xcm::v3::Response, - // max_weight: ::sp_weights::Weight, - // querier: ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // }, - // #[codec(index = 4)] - // TransferAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 5)] - // TransferReserveAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 6)] - // Transact { - // origin_kind: runtime_types::staging_xcm::v2::OriginKind, - // require_weight_at_most: ::sp_weights::Weight, - // call: runtime_types::staging_xcm::double_encoded::DoubleEncoded2, - // }, - // #[codec(index = 7)] - // HrmpNewChannelOpenRequest { - // #[codec(compact)] - // sender: ::core::primitive::u32, - // #[codec(compact)] - // max_message_size: ::core::primitive::u32, - // #[codec(compact)] - // max_capacity: ::core::primitive::u32, - // }, - // #[codec(index = 8)] - // HrmpChannelAccepted { - // #[codec(compact)] - // recipient: ::core::primitive::u32, - // }, - // #[codec(index = 9)] - // HrmpChannelClosing { - // #[codec(compact)] - // initiator: ::core::primitive::u32, - // #[codec(compact)] - // sender: ::core::primitive::u32, - // #[codec(compact)] - // recipient: ::core::primitive::u32, - // }, - // #[codec(index = 10)] - // ClearOrigin, - // #[codec(index = 11)] - // DescendOrigin(runtime_types::staging_xcm::v3::junctions::Junctions), - // #[codec(index = 12)] - // ReportError(runtime_types::staging_xcm::v3::QueryResponseInfo), - // #[codec(index = 13)] - // DepositAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // beneficiary: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 14)] - // DepositReserveAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 15)] - // ExchangeAsset { - // give: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // want: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // maximal: ::core::primitive::bool, - // }, - // #[codec(index = 16)] - // InitiateReserveWithdraw { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // reserve: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 17)] - // InitiateTeleport { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // dest: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 18)] - // ReportHolding { - // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssetFilter, - // }, - // #[codec(index = 19)] - // BuyExecution { - // fees: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - // }, - // #[codec(index = 20)] - // RefundSurplus, - // #[codec(index = 21)] - // SetErrorHandler(runtime_types::staging_xcm::v3::Xcm2), - // #[codec(index = 22)] - // SetAppendix(runtime_types::staging_xcm::v3::Xcm2), - // #[codec(index = 23)] - // ClearError, - // #[codec(index = 24)] - // ClaimAsset { - // assets: runtime_types::staging_xcm::v3::multiasset::MultiAssets, - // ticket: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 25)] - // Trap(#[codec(compact)] ::core::primitive::u64), - // #[codec(index = 26)] - // SubscribeVersion { - // #[codec(compact)] - // query_id: ::core::primitive::u64, - // max_response_weight: ::sp_weights::Weight, - // }, - // #[codec(index = 27)] - // UnsubscribeVersion, - // #[codec(index = 28)] - // BurnAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 29)] - // ExpectAsset(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - // #[codec(index = 30)] - // ExpectOrigin( - // ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // ), - // #[codec(index = 31)] - // ExpectError( - // ::core::option::Option<( - // ::core::primitive::u32, - // runtime_types::staging_xcm::v3::traits::Error, - // )>, - // ), - // #[codec(index = 32)] - // ExpectTransactStatus(runtime_types::staging_xcm::v3::MaybeErrorCode), - // #[codec(index = 33)] - // QueryPallet { - // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - // response_info: runtime_types::staging_xcm::v3::QueryResponseInfo, - // }, - // #[codec(index = 34)] - // ExpectPallet { - // #[codec(compact)] - // index: ::core::primitive::u32, - // name: ::sp_std::vec::Vec<::core::primitive::u8>, - // module_name: ::sp_std::vec::Vec<::core::primitive::u8>, - // #[codec(compact)] - // crate_major: ::core::primitive::u32, - // #[codec(compact)] - // min_crate_minor: ::core::primitive::u32, - // }, - // #[codec(index = 35)] - // ReportTransactStatus(runtime_types::staging_xcm::v3::QueryResponseInfo), - // #[codec(index = 36)] - // ClearTransactStatus, - // #[codec(index = 37)] - // UniversalOrigin(runtime_types::staging_xcm::v3::junction::Junction), - // #[codec(index = 38)] - // ExportMessage { - // network: runtime_types::staging_xcm::v3::junction::NetworkId, - // destination: runtime_types::staging_xcm::v3::junctions::Junctions, - // xcm: runtime_types::staging_xcm::v3::Xcm, - // }, - // #[codec(index = 39)] - // LockAsset { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // unlocker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 40)] - // UnlockAsset { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // target: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 41)] - // NoteUnlockable { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // owner: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 42)] - // RequestUnlock { - // asset: runtime_types::staging_xcm::v3::multiasset::MultiAsset, - // locker: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // }, - // #[codec(index = 43)] - // SetFeesMode { jit_withdraw: ::core::primitive::bool }, - // #[codec(index = 44)] - // SetTopic([::core::primitive::u8; 32usize]), - // #[codec(index = 45)] - // ClearTopic, - // #[codec(index = 46)] - // AliasOrigin(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - // #[codec(index = 47)] - // UnpaidExecution { - // weight_limit: runtime_types::staging_xcm::v3::WeightLimit, - // check_origin: ::core::option::Option< - // runtime_types::staging_xcm::v3::multilocation::MultiLocation, - // >, - // }, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MaybeErrorCode { - #[codec(index = 0)] - Success, - #[codec(index = 1)] - Error( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - #[codec(index = 2)] - TruncatedError( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - ), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct PalletInfo { - #[codec(compact)] - pub index: ::core::primitive::u32, - pub name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - pub module_name: runtime_types::bounded_collections::bounded_vec::BoundedVec< - ::core::primitive::u8, - >, - #[codec(compact)] - pub major: ::core::primitive::u32, - #[codec(compact)] - pub minor: ::core::primitive::u32, - #[codec(compact)] - pub patch: ::core::primitive::u32, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct QueryResponseInfo { - pub destination: runtime_types::staging_xcm::v3::multilocation::MultiLocation, - #[codec(compact)] - pub query_id: ::core::primitive::u64, - pub max_weight: ::sp_weights::Weight, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Response { - #[codec(index = 0)] - Null, - #[codec(index = 1)] - Assets(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - #[codec(index = 2)] - ExecutionResult( - ::core::option::Option<( - ::core::primitive::u32, - runtime_types::staging_xcm::v3::traits::Error, - )>, - ), - #[codec(index = 3)] - Version(::core::primitive::u32), - #[codec(index = 4)] - PalletsInfo( - runtime_types::bounded_collections::bounded_vec::BoundedVec< - runtime_types::staging_xcm::v3::PalletInfo, - >, - ), - #[codec(index = 5)] - DispatchResult(runtime_types::staging_xcm::v3::MaybeErrorCode), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum WeightLimit { - #[codec(index = 0)] - Unlimited, - #[codec(index = 1)] - Limited(::sp_weights::Weight), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Xcm(pub ::sp_std::vec::Vec); - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct Xcm2(pub ::sp_std::vec::Vec); - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedAssetId { - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::multiasset::AssetId), - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VersionedMultiAssets { - #[codec(index = 1)] - V2(runtime_types::staging_xcm::v2::multiasset::MultiAssets), - #[codec(index = 3)] - V3(runtime_types::staging_xcm::v3::multiasset::MultiAssets), - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum VersionedMultiLocation { - #[codec(index = 1)] - V2(runtime_types::staging_xcm::v2::multilocation::MultiLocation), - #[codec(index = 3)] - V3(runtime_types::staging_xcm::v3::multilocation::MultiLocation), - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedResponse { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Response), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Response), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedXcm { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Xcm), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Xcm), - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub enum VersionedXcm2 { - // #[codec(index = 2)] - // V2(runtime_types::staging_xcm::v2::Xcm2), - // #[codec(index = 3)] - // V3(runtime_types::staging_xcm::v3::Xcm2), - // } - } - - pub mod polkadot_runtime_common { - use super::runtime_types; - pub mod assigned_slots { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - PermanentSlotAssigned( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 1)] - TemporarySlotAssigned( - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 2)] - MaxPermanentSlotsChanged { slots: ::core::primitive::u32 }, - #[codec(index = 3)] - MaxTemporarySlotsChanged { slots: ::core::primitive::u32 }, - } - } - } - pub mod auctions { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - AuctionStarted { - auction_index: ::core::primitive::u32, - lease_period: ::core::primitive::u32, - ending: ::core::primitive::u32, - }, - #[codec(index = 1)] - AuctionClosed { auction_index: ::core::primitive::u32 }, - #[codec(index = 2)] - Reserved { - bidder: ::sp_core::crypto::AccountId32, - extra_reserved: ::core::primitive::u128, - total_amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - Unreserved { - bidder: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 4)] - ReserveConfiscated { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - BidAccepted { - bidder: ::sp_core::crypto::AccountId32, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - first_slot: ::core::primitive::u32, - last_slot: ::core::primitive::u32, - }, - #[codec(index = 6)] - WinningOffset { - auction_index: ::core::primitive::u32, - block_number: ::core::primitive::u32, - }, - } - } - } - pub mod claims { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Claimed { - who: ::sp_core::crypto::AccountId32, - ethereum_address: - runtime_types::polkadot_runtime_common::claims::EthereumAddress, - amount: ::core::primitive::u128, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct EthereumAddress(pub [::core::primitive::u8; 20usize]); - } - pub mod crowdloan { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Created { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 1)] - Contributed { - who: ::sp_core::crypto::AccountId32, - fund_index: - runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Withdrew { - who: ::sp_core::crypto::AccountId32, - fund_index: - runtime_types::polkadot_parachain_primitives::primitives::Id, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - PartiallyRefunded { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 4)] - AllRefunded { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 5)] - Dissolved { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 6)] - HandleBidResult { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - result: ::core::result::Result< - (), - runtime_types::sp_runtime::DispatchError, - >, - }, - #[codec(index = 7)] - Edited { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 8)] - MemoUpdated { - who: ::sp_core::crypto::AccountId32, - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - memo: ::sp_std::vec::Vec<::core::primitive::u8>, - }, - #[codec(index = 9)] - AddedToNewRaise { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - } - } - pub mod paras_registrar { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Registered { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - manager: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 1)] - Deregistered { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - #[codec(index = 2)] - Reserved { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - who: ::sp_core::crypto::AccountId32, - }, - #[codec(index = 3)] - Swapped { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - other_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - }, - } - } - } - pub mod slots { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - NewLeasePeriod { lease_period: ::core::primitive::u32 }, - #[codec(index = 1)] - Leased { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - leaser: ::sp_core::crypto::AccountId32, - period_begin: ::core::primitive::u32, - period_count: ::core::primitive::u32, - extra_reserved: ::core::primitive::u128, - total_amount: ::core::primitive::u128, - }, - } - } - } - } - - pub mod pallet_state_trie_migration { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Error { - #[codec(index = 0)] - MaxSignedLimits, - #[codec(index = 1)] - KeyTooLong, - #[codec(index = 2)] - NotEnoughFunds, - #[codec(index = 3)] - BadWitness, - #[codec(index = 4)] - SignedMigrationNotAllowed, - #[codec(index = 5)] - BadChildRoot, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Migrated { - top: ::core::primitive::u32, - child: ::core::primitive::u32, - compute: - runtime_types::pallet_state_trie_migration::pallet::MigrationCompute, - }, - #[codec(index = 1)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 2)] - AutoMigrationFinished, - #[codec(index = 3)] - Halted { error: runtime_types::pallet_state_trie_migration::pallet::Error }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum MigrationCompute { - #[codec(index = 0)] - Signed, - #[codec(index = 1)] - Auto, - } - } - } - pub mod bounded_collections { - use super::runtime_types; - pub mod bounded_vec { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct BoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); - } - pub mod weak_bounded_vec { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct WeakBoundedVec<_0>(pub ::sp_std::vec::Vec<_0>); - } - } - pub mod primitive_types { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct H256(pub [::core::primitive::u8; 32usize]); - } - pub mod frame_system { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - ExtrinsicSuccess { - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 1)] - ExtrinsicFailed { - dispatch_error: runtime_types::sp_runtime::DispatchError, - dispatch_info: runtime_types::frame_support::dispatch::DispatchInfo, - }, - #[codec(index = 2)] - CodeUpdated, - #[codec(index = 3)] - NewAccount { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 4)] - KilledAccount { account: ::sp_core::crypto::AccountId32 }, - #[codec(index = 5)] - Remarked { - sender: ::sp_core::crypto::AccountId32, - hash: runtime_types::primitive_types::H256, - }, - } - } - } - pub mod frame_support { - use super::runtime_types; - pub mod dispatch { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DispatchClass { - #[codec(index = 0)] - Normal, - #[codec(index = 1)] - Operational, - #[codec(index = 2)] - Mandatory, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct DispatchInfo { - pub weight: ::sp_weights::Weight, - pub class: runtime_types::frame_support::dispatch::DispatchClass, - pub pays_fee: runtime_types::frame_support::dispatch::Pays, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Pays { - #[codec(index = 0)] - Yes, - #[codec(index = 1)] - No, - } - } - pub mod traits { - use super::runtime_types; - pub mod messages { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ProcessMessageError { - #[codec(index = 0)] - BadFormat, - #[codec(index = 1)] - Corrupt, - #[codec(index = 2)] - Unsupported, - #[codec(index = 3)] - Overweight(::sp_weights::Weight), - #[codec(index = 4)] - Yield, - } - } - pub mod tokens { - use super::runtime_types; - pub mod misc { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum BalanceStatus { - #[codec(index = 0)] - Free, - #[codec(index = 1)] - Reserved, - } - } - } - } - } - pub mod pallet_balances { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Endowed { - account: ::sp_core::crypto::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - DustLost { - account: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Transfer { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - BalanceSet { - who: ::sp_core::crypto::AccountId32, - free: ::core::primitive::u128, - }, - #[codec(index = 4)] - Reserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - Unreserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - ReserveRepatriated { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - Withdraw { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - Suspended { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 13)] - Restored { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - Upgraded { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - Unlocked { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 19)] - Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event2 { - #[codec(index = 0)] - Endowed { - account: ::sp_core::crypto::AccountId32, - free_balance: ::core::primitive::u128, - }, - #[codec(index = 1)] - DustLost { - account: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 2)] - Transfer { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 3)] - BalanceSet { - who: ::sp_core::crypto::AccountId32, - free: ::core::primitive::u128, - }, - #[codec(index = 4)] - Reserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 5)] - Unreserved { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 6)] - ReserveRepatriated { - from: ::sp_core::crypto::AccountId32, - to: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - destination_status: - runtime_types::frame_support::traits::tokens::misc::BalanceStatus, - }, - #[codec(index = 7)] - Deposit { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 8)] - Withdraw { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 9)] - Slashed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 10)] - Minted { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 11)] - Burned { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 12)] - Suspended { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 13)] - Restored { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 14)] - Upgraded { who: ::sp_core::crypto::AccountId32 }, - #[codec(index = 15)] - Issued { amount: ::core::primitive::u128 }, - #[codec(index = 16)] - Rescinded { amount: ::core::primitive::u128 }, - #[codec(index = 17)] - Locked { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 18)] - Unlocked { - who: ::sp_core::crypto::AccountId32, - amount: ::core::primitive::u128, - }, - #[codec(index = 19)] - Frozen { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - #[codec(index = 20)] - Thawed { who: ::sp_core::crypto::AccountId32, amount: ::core::primitive::u128 }, - } - } - } - pub mod polkadot_runtime_parachains { - use super::runtime_types; - pub mod assigner_on_demand { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - OnDemandOrderPlaced { - para_id: runtime_types::polkadot_parachain_primitives::primitives::Id, - spot_price: ::core::primitive::u128, - }, - #[codec(index = 1)] - SpotTrafficSet { - traffic: runtime_types::sp_arithmetic::fixed_point::FixedU128, - }, - } - } - } - pub mod inclusion { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - CandidateBacked( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - runtime_types::polkadot_primitives::v5::GroupIndex, - ), - #[codec(index = 1)] - CandidateIncluded( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - runtime_types::polkadot_primitives::v5::GroupIndex, - ), - #[codec(index = 2)] - CandidateTimedOut( - runtime_types::polkadot_primitives::v5::CandidateReceipt< - runtime_types::primitive_types::H256, - >, - runtime_types::polkadot_parachain_primitives::primitives::HeadData, - runtime_types::polkadot_primitives::v5::CoreIndex, - ), - #[codec(index = 3)] - UpwardMessagesReceived { - from: runtime_types::polkadot_parachain_primitives::primitives::Id, - count: ::core::primitive::u32, - }, - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum AggregateMessageOrigin { - #[codec(index = 0)] - Ump(runtime_types::polkadot_runtime_parachains::inclusion::UmpQueueId), - } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct AvailabilityBitfieldRecord<_0> { - // pub bitfield: runtime_types::polkadot_primitives::v5::AvailabilityBitfield, - // pub submitted_at: _0, - // } - // #[derive(:: codec :: Decode, :: codec :: Encode, Clone, Debug, PartialEq)] - // pub struct CandidatePendingAvailability<_0, _1> { - // pub core: runtime_types::polkadot_primitives::v5::CoreIndex, - // pub hash: runtime_types::polkadot_core_primitives::CandidateHash, - // pub descriptor: runtime_types::polkadot_primitives::v5::CandidateDescriptor<_0>, - // pub availability_votes: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub backers: ::subxt::utils::bits::DecodedBits< - // ::core::primitive::u8, - // ::subxt::utils::bits::Lsb0, - // >, - // pub relay_parent_number: _1, - // pub backed_in_number: _1, - // pub backing_group: runtime_types::polkadot_primitives::v5::GroupIndex, - // } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum UmpQueueId { - #[codec(index = 0)] - Para(runtime_types::polkadot_parachain_primitives::primitives::Id), - } - } - pub mod paras { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - # [codec (index = 0)] CurrentCodeUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 1)] CurrentHeadUpdated (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 2)] CodeUpgradeScheduled (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 3)] NewHeadNoted (runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 4)] ActionQueued (runtime_types :: polkadot_parachain_primitives :: primitives :: Id , :: core :: primitive :: u32 ,) , # [codec (index = 5)] PvfCheckStarted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 6)] PvfCheckAccepted (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , # [codec (index = 7)] PvfCheckRejected (runtime_types :: polkadot_parachain_primitives :: primitives :: ValidationCodeHash , runtime_types :: polkadot_parachain_primitives :: primitives :: Id ,) , } - } - } - pub mod hrmp { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - OpenChannelRequested( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - ::core::primitive::u32, - ), - #[codec(index = 1)] - OpenChannelCanceled( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - ), - #[codec(index = 2)] - OpenChannelAccepted( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ), - #[codec(index = 3)] - ChannelClosed( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::HrmpChannelId, - ), - #[codec(index = 4)] - HrmpChannelForceOpened( - runtime_types::polkadot_parachain_primitives::primitives::Id, - runtime_types::polkadot_parachain_primitives::primitives::Id, - ::core::primitive::u32, - ::core::primitive::u32, - ), - } - } - } - pub mod disputes { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - DisputeInitiated( - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_runtime_parachains::disputes::DisputeLocation, - ), - #[codec(index = 1)] - DisputeConcluded( - runtime_types::polkadot_core_primitives::CandidateHash, - runtime_types::polkadot_runtime_parachains::disputes::DisputeResult, - ), - #[codec(index = 2)] - Revert(::core::primitive::u32), - } - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DisputeLocation { - #[codec(index = 0)] - Local, - #[codec(index = 1)] - Remote, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DisputeResult { - #[codec(index = 0)] - Valid, - #[codec(index = 1)] - Invalid, - } - } - } - pub mod polkadot_parachain_primitives { - use super::runtime_types; - pub mod primitives { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct HeadData(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct HrmpChannelId { - pub sender: runtime_types::polkadot_parachain_primitives::primitives::Id, - pub recipient: runtime_types::polkadot_parachain_primitives::primitives::Id, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Id(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ValidationCode(pub ::sp_std::vec::Vec<::core::primitive::u8>); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ValidationCodeHash(pub runtime_types::primitive_types::H256); - } - } - pub mod pallet_sudo { - use super::runtime_types; - pub mod pallet { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum Event { - #[codec(index = 0)] - Sudid { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - #[codec(index = 1)] - KeyChanged { - old_sudoer: ::core::option::Option<::sp_core::crypto::AccountId32>, - }, - #[codec(index = 2)] - SudoAsDone { - sudo_result: - ::core::result::Result<(), runtime_types::sp_runtime::DispatchError>, - }, - } - } - } - pub mod sp_arithmetic { - use super::runtime_types; - pub mod fixed_point { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct FixedU128(pub ::core::primitive::u128); - } - pub mod per_things { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Perbill(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Percent(pub ::core::primitive::u8); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Permill(pub ::core::primitive::u32); - #[derive( - :: codec :: Decode, - :: codec :: Encode, - // :: subxt :: ext :: codec :: CompactAs, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct Perquintill(pub ::core::primitive::u64); - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum ArithmeticError { - #[codec(index = 0)] - Underflow, - #[codec(index = 1)] - Overflow, - #[codec(index = 2)] - DivisionByZero, - } - } - pub mod sp_runtime { - use super::runtime_types; - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum DispatchError { - #[codec(index = 0)] - Other, - #[codec(index = 1)] - CannotLookup, - #[codec(index = 2)] - BadOrigin, - #[codec(index = 3)] - Module(runtime_types::sp_runtime::ModuleError), - #[codec(index = 4)] - ConsumerRemaining, - #[codec(index = 5)] - NoProviders, - #[codec(index = 6)] - TooManyConsumers, - #[codec(index = 7)] - Token(runtime_types::sp_runtime::TokenError), - #[codec(index = 8)] - Arithmetic(runtime_types::sp_arithmetic::ArithmeticError), - #[codec(index = 9)] - Transactional(runtime_types::sp_runtime::TransactionalError), - #[codec(index = 10)] - Exhausted, - #[codec(index = 11)] - Corruption, - #[codec(index = 12)] - Unavailable, - #[codec(index = 13)] - RootNotAllowed, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub struct ModuleError { - pub index: ::core::primitive::u8, - pub error: [::core::primitive::u8; 4usize], - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum TokenError { - #[codec(index = 0)] - FundsUnavailable, - #[codec(index = 1)] - OnlyProvider, - #[codec(index = 2)] - BelowMinimum, - #[codec(index = 3)] - CannotCreate, - #[codec(index = 4)] - UnknownAsset, - #[codec(index = 5)] - Frozen, - #[codec(index = 6)] - Unsupported, - #[codec(index = 7)] - CannotCreateHold, - #[codec(index = 8)] - NotExpendable, - #[codec(index = 9)] - Blocked, - } - #[derive( - :: codec :: Decode, - :: codec :: Encode, - Clone, - Debug, - PartialEq, - Eq, - scale_info::TypeInfo, - )] - pub enum TransactionalError { - #[codec(index = 0)] - LimitReached, - #[codec(index = 1)] - NoLayer, - } - } - } -} diff --git a/primitives/coretime/on-demand/src/well_known_keys.rs b/primitives/coretime/on-demand/src/well_known_keys.rs index 46804de..efd5fe4 100644 --- a/primitives/coretime/on-demand/src/well_known_keys.rs +++ b/primitives/coretime/on-demand/src/well_known_keys.rs @@ -17,9 +17,14 @@ //! Keys of well known. #![cfg_attr(not(feature = "std"), no_std)] +use crate::{Decode, ParaId}; use cumulus_primitives_core::relay_chain::CoreIndex; -use {sp_core::Encode, sp_io::hashing::twox_256, sp_std::vec::Vec}; - +use sp_runtime::AccountId32; +use { + sp_core::Encode, + sp_io::hashing::{blake2_128, twox_256}, + sp_std::vec::Vec, +}; pub const SYSTEM_ACCOUNT: &[u8] = &hex_literal::hex!["26aa394eea5630e07c48ae0c9558cef7b99d880ec681799c0cf30e8886371da9"]; @@ -51,3 +56,23 @@ pub fn paras_core_descriptors(core_index: CoreIndex) -> Vec { // ParaScheduler AvailabilityCores pub const AVAILABILITY_CORES: &[u8] = &hex_literal::hex!["94eadf0156a8ad5156507773d0471e4ab8ebad86f546c7e0b135a4212aace339"]; + +pub const BALANCE_ACCOUNT: &[u8] = + &hex_literal::hex!["c2261276cc9d1f8598ea4b6a74b15c2fb99d880ec681799c0cf30e8886371da9"]; + +pub fn acount_balance(account: AccountId32) -> Vec { + account.using_encoded(|account_bytes: &[u8]| { + SYSTEM_ACCOUNT + .iter() + .chain(blake2_128(account_bytes).iter()) + .chain(account_bytes.iter()) + .cloned() + .collect() + }) +} + +#[derive(Encode, Decode, Debug, PartialEq, Clone)] +pub struct EnqueuedOrder { + /// Parachain ID + pub para_id: ParaId, +} diff --git a/runtime/Cargo.toml b/runtime/Cargo.toml index ee28211..7c64e87 100644 --- a/runtime/Cargo.toml +++ b/runtime/Cargo.toml @@ -246,7 +246,7 @@ runtime-benchmarks = [ "pallet-evm-utils/runtime-benchmarks", "pallet-precompile-substrate-utils/runtime-benchmarks", "pallet-precompile-transfer-to-magnet/runtime-benchmarks", -# "pallet-order/runtime-benchmarks", + "pallet-on-demand/runtime-benchmarks", "pallet-collective/runtime-benchmarks", "pallet-society/runtime-benchmarks", "pallet-evm/runtime-benchmarks", diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index c9f66f8..d108e7f 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -738,6 +738,7 @@ impl pallet_on_demand::Config for Runtime { type Currency = Balances; type UpdateOrigin = EnsureRootOrHalf; type WeightInfo = pallet_on_demand::weights::SubstrateWeight; + type RelayChainStateProvider = cumulus_pallet_parachain_system::RelaychainDataProvider; } pub struct BulkGasCostHandler(); @@ -1312,7 +1313,7 @@ mod benches { [pallet_collator_selection, CollatorSelection] [cumulus_pallet_xcmp_queue, XcmpQueue] [pallet_bulk, BulkPallet] - // [pallet_order, OrderPallet] + [pallet_on_demand, OrderPallet] [pallet_move, MoveModule] [pallet_multisig, Multisig] [pallet_proxy, Proxy] @@ -1677,32 +1678,12 @@ impl_runtime_apis! { OrderPallet::slot_width() } fn order_max_amount() -> Balance { - OrderPallet::order_max_amount() - } - fn sequence_number()-> u64 { - OrderPallet::sequence_number() - } - - fn current_relay_height()-> u32 { - OrderPallet::current_relay_height() - } - - fn order_placed( - relay_storage_proof: sp_trie::StorageProof, - validation_data: PersistedValidationData, - para_id:ParaId, - )-> Option { - OrderPallet::order_placed(relay_storage_proof, validation_data, para_id) + OrderPallet::price_limit() } fn reach_txpool_threshold(gas_balance:Balance, core_price:Balance) -> bool { OrderPallet::reach_txpool_threshold(gas_balance, core_price) } - - - fn order_executed(sequence_number:u64) -> bool { - OrderPallet::order_executed(sequence_number) - } } impl mp_coretime_bulk::BulkRuntimeApi for Runtime { From 59fef56aa71a6ddfa8d6755b75ddb29a4c7e9373 Mon Sep 17 00:00:00 2001 From: sulijia <984115358@qq.com> Date: Mon, 15 Jul 2024 22:47:48 +0800 Subject: [PATCH 40/44] Change the stored account from AuthorityId type to AccountId type --- client/coretime/bulk/src/lib.rs | 39 ++--- client/coretime/on-demand/src/lib.rs | 147 ++++++------------ node/src/service.rs | 9 +- pallets/bulk/src/lib.rs | 25 +-- pallets/bulk/src/mock.rs | 3 - pallets/on-demand/src/benchmarking.rs | 14 +- pallets/on-demand/src/lib.rs | 86 +++++----- pallets/on-demand/src/mock.rs | 23 +-- pallets/on-demand/src/tests.rs | 17 +- .../coretime/on-demand/src/inherent_client.rs | 17 +- primitives/coretime/on-demand/src/lib.rs | 14 +- runtime/src/lib.rs | 18 +-- 12 files changed, 135 insertions(+), 277 deletions(-) diff --git a/client/coretime/bulk/src/lib.rs b/client/coretime/bulk/src/lib.rs index 488aea6..76acf33 100644 --- a/client/coretime/bulk/src/lib.rs +++ b/client/coretime/bulk/src/lib.rs @@ -23,7 +23,6 @@ //! mod metadata; -use codec::Codec; use cumulus_primitives_core::ParaId; use cumulus_relay_chain_interface::RelayChainInterface; use futures::{lock::Mutex, select, FutureExt}; @@ -40,10 +39,7 @@ use polkadot_primitives::{AccountId, Balance}; use sc_client_api::UsageProvider; use sc_service::TaskManager; use sp_api::ProvideRuntimeApi; -use sp_application_crypto::AppPublic; -use sp_consensus_aura::AuraApi; -use sp_core::crypto::Pair; -use sp_runtime::traits::{Block as BlockT, Member}; +use sp_runtime::traits::Block as BlockT; use sp_state_machine::StorageProof; use std::{error::Error, sync::Arc}; use subxt::{ @@ -61,7 +57,7 @@ fn u8_array_to_u128(array: [u8; 10]) -> u128 { } /// The main logic of bulk task. -pub async fn coretime_bulk_task( +pub async fn coretime_bulk_task( parachain: &P, relay_chain: R, para_id: ParaId, @@ -71,10 +67,7 @@ where Block: BlockT, P: ProvideRuntimeApi + UsageProvider, R: RelayChainInterface + Clone, - P::Api: AuraApi + BulkRuntimeApi, - PB: Pair + 'static, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, + P::Api: BulkRuntimeApi, { let relay_chain_clone = relay_chain.clone(); @@ -229,7 +222,7 @@ where Ok(()) } -pub async fn run_coretime_bulk_task( +pub async fn run_coretime_bulk_task( parachain: Arc

, relay_chain: R, para_id: ParaId, @@ -238,20 +231,13 @@ pub async fn run_coretime_bulk_task( Block: BlockT, P: ProvideRuntimeApi + UsageProvider, R: RelayChainInterface + Clone, - P::Api: AuraApi + BulkRuntimeApi, - PB: Pair + 'static, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, + P::Api: BulkRuntimeApi, { let bulk_task = async move { loop { - let _ = coretime_bulk_task::<_, _, _, PB>( - &*parachain, - relay_chain.clone(), - para_id, - bulk_record.clone(), - ) - .await; + let _ = + coretime_bulk_task(&*parachain, relay_chain.clone(), para_id, bulk_record.clone()) + .await; } }; select! { @@ -260,7 +246,7 @@ pub async fn run_coretime_bulk_task( } /// Spawn task for bulk mode -pub fn spawn_bulk_task( +pub fn spawn_bulk_task( parachain: Arc

, para_id: ParaId, relay_chain: R, @@ -271,12 +257,9 @@ where Block: BlockT, R: RelayChainInterface + Clone + 'static, P: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, - P::Api: AuraApi + BulkRuntimeApi, - PB: Pair + 'static, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, + P::Api: BulkRuntimeApi, { - let coretime_bulk_task = run_coretime_bulk_task::<_, _, _, PB>( + let coretime_bulk_task = run_coretime_bulk_task( parachain.clone(), relay_chain.clone(), para_id, diff --git a/client/coretime/on-demand/src/lib.rs b/client/coretime/on-demand/src/lib.rs index 6d0b7a5..493a02c 100644 --- a/client/coretime/on-demand/src/lib.rs +++ b/client/coretime/on-demand/src/lib.rs @@ -35,12 +35,12 @@ use mc_coretime_common::is_parathread; use metadata::{CoreAssignment, CoreDescriptor}; use mp_coretime_on_demand::{ self, - well_known_keys::{acount_balance, paras_core_descriptors}, - well_known_keys::{EnqueuedOrder, ACTIVE_CONFIG, ON_DEMAND_QUEUE, SPOT_TRAFFIC, SYSTEM_EVENTS}, + well_known_keys::{ + paras_core_descriptors, EnqueuedOrder, ACTIVE_CONFIG, ON_DEMAND_QUEUE, SPOT_TRAFFIC, + }, OrderRecord, OrderRuntimeApi, OrderStatus, }; use mp_system::OnRelayChainApi; -use pallet_balances::AccountData; pub use pallet_transaction_payment_rpc_runtime_api::TransactionPaymentApi; use polkadot_primitives::OccupiedCoreAssumption; use runtime_parachains::configuration::HostConfiguration; @@ -48,26 +48,22 @@ use sc_client_api::UsageProvider; use sc_service::TaskManager; use sc_transaction_pool_api::{InPoolTransaction, MaintainedTransactionPool}; use sp_api::ProvideRuntimeApi; -use sp_application_crypto::AppPublic; +use sp_consensus_aura::sr25519::AuthorityId; +use sp_consensus_aura::sr25519::AuthorityPair; use sp_consensus_aura::AuraApi; -use sp_core::{crypto::Pair, H256}; +use sp_core::H256; use sp_keystore::KeystorePtr; -use sp_runtime::AccountId32; use sp_runtime::{ codec::Encode, traits::{ - AtLeast32BitUnsigned, Block as BlockT, Header as HeaderT, MaybeDisplay, Member, - SaturatedConversion, + AtLeast32BitUnsigned, Block as BlockT, Header as HeaderT, MaybeDisplay, SaturatedConversion, }, FixedPointNumber, FixedU128, }; use std::{cmp::Ordering, net::SocketAddr}; -use std::{convert::TryFrom, error::Error, fmt::Debug, sync::Arc}; +use std::{error::Error, fmt::Debug, sync::Arc}; use submit_order::{build_rpc_for_submit_order, SubmitOrderError}; -use subxt::{ - backend::{legacy::LegacyRpcMethods, rpc::RpcClient}, - OnlineClient, PolkadotConfig, -}; +use subxt::{OnlineClient, PolkadotConfig}; /// Order type #[derive(Clone, PartialEq, Debug)] @@ -170,7 +166,7 @@ where } /// Whether the mem pool reaches the threshold for purchasing cores. -async fn reach_txpool_threshold( +async fn reach_txpool_threshold( parachain: &P, transaction_pool: Arc, height: RelayBlockNumber, @@ -182,12 +178,9 @@ where P: ProvideRuntimeApi + UsageProvider, Balance: Codec + MaybeDisplay + 'static + Debug + AtLeast32BitUnsigned + Copy, P::Api: TransactionPaymentApi - + OrderRuntimeApi + + OrderRuntimeApi + OnRelayChainApi, ExPool: MaintainedTransactionPool::Hash> + 'static, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, { let mut pending_iterator = transaction_pool.ready(); let mut is_place_order = false; @@ -278,7 +271,7 @@ where } /// The main processing logic of purchasing core. -async fn handle_relaychain_stream( +async fn handle_relaychain_stream( validation_data: PersistedValidationData, height: RelayBlockNumber, parachain: &P, @@ -286,7 +279,7 @@ async fn handle_relaychain_stream( relay_chain: impl RelayChainInterface + Clone, p_hash: H256, para_id: ParaId, - order_record: Arc>>, + order_record: Arc>, transaction_pool: Arc, url: String, ) -> Result<(), Box> @@ -301,13 +294,10 @@ where + AtLeast32BitUnsigned + Copy + From, - P::Api: AuraApi - + OrderRuntimeApi + P::Api: AuraApi + + OrderRuntimeApi + TransactionPaymentApi + OnRelayChainApi, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, ExPool: MaintainedTransactionPool::Hash> + 'static, { let is_parathread = is_parathread(&relay_chain, p_hash, para_id).await?; @@ -340,7 +330,8 @@ where // The larger the slot width, the longer the rotation time. let idx = (height >> slot_width) % auth_len; // Randomly select a collator to place an order. - let collator_public = mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; + let collator_public = + mc_coretime_common::order_slot::(idx, &authorities, &keystore).await; let base = 2 as u32; // Minimum interval for placing an order,calculated in one relaychain block time. let slot_block = base.pow(slot_width); @@ -349,7 +340,12 @@ where order_record_local.reset(); } let order_period = height & (slot_block - 1) < slot_block / 2; - log::info!("===============relaychain height:{:?},is order period:{:?}", height, order_period); + log::info!( + "relaychain height:{:?},order period:{:?}, can place order:{:?}", + height, + order_period, + collator_public.clone().is_some() + ); // Check whether the conditions for placing an order are met, and if so, place the order @@ -380,7 +376,7 @@ where // Check whether the gas of the transaction pool has reached the spot price threshold. let mut order_record_local = order_record.lock().await; - let reached = reach_txpool_threshold::<_, _, _, _, PB>( + let reached = reach_txpool_threshold( parachain, transaction_pool.clone(), height, @@ -447,12 +443,12 @@ async fn new_best_heads( Ok(new_best_notification_stream) } -async fn relay_chain_notification( +async fn relay_chain_notification( para_id: ParaId, parachain: Arc

, relay_chain: R, keystore: KeystorePtr, - order_record: Arc>>, + order_record: Arc>, transaction_pool: Arc, url: String, ) where @@ -467,13 +463,10 @@ async fn relay_chain_notification( + Copy + From, P: ProvideRuntimeApi + UsageProvider, - P::Api: AuraApi - + OrderRuntimeApi + P::Api: AuraApi + + OrderRuntimeApi + TransactionPaymentApi + OnRelayChainApi, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, ExPool: MaintainedTransactionPool::Hash> + 'static, { let new_best_heads = match new_best_heads(relay_chain.clone(), para_id).await { @@ -488,7 +481,7 @@ async fn relay_chain_notification( h = new_best_heads.next() => { match h { Some((height, head, hash)) => { - let _ = handle_relaychain_stream::<_,_,PB,_,_>(head,height, &*parachain,keystore.clone(), relay_chain.clone(), hash, para_id, order_record.clone(),transaction_pool.clone(), url.clone()).await; + let _ = handle_relaychain_stream(head,height, &*parachain,keystore.clone(), relay_chain.clone(), hash, para_id, order_record.clone(),transaction_pool.clone(), url.clone()).await; }, None => { return; @@ -499,25 +492,11 @@ async fn relay_chain_notification( } } -pub async fn ondemand_event_task( - parachain: &P, - relay_chain: R, +pub async fn ondemand_event_task( para_id: ParaId, rpc_url: String, - order_record: Arc>>, -) -> Result<(), Box> -where - Block: BlockT, - P: ProvideRuntimeApi + UsageProvider, - R: RelayChainInterface + Clone, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, -{ - let relay_chain_clone = relay_chain.clone(); - - let hash = parachain.usage_info().chain.finalized_hash; - + order_record: Arc>, +) -> Result<(), Box> { // Get the final block of the relaychain through subxt. let api = OnlineClient::::from_url(rpc_url).await?; @@ -528,8 +507,6 @@ where while let Some(block) = blocks_sub.next().await { let block = block?; - let block_number = block.header().number; - let events = block.events().await?; for event in events.iter() { let event = event?; @@ -556,38 +533,18 @@ where Ok(()) } -async fn event_notification( - parachain: Arc

, - relay_chain: R, - para_id: ParaId, - url: String, - order_record: Arc>>, -) where - R: RelayChainInterface + Clone, - Block: BlockT, - P: ProvideRuntimeApi + UsageProvider, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, -{ +async fn event_notification(para_id: ParaId, url: String, order_record: Arc>) { loop { - let _ = ondemand_event_task::<_, _, _, PB>( - &*parachain, - relay_chain.clone(), - para_id, - url.clone(), - order_record.clone(), - ) - .await; + let _ = ondemand_event_task(para_id, url.clone(), order_record.clone()).await; } } -pub async fn run_on_demand_task( +pub async fn run_on_demand_task( para_id: ParaId, parachain: Arc

, relay_chain: R, keystore: KeystorePtr, - order_record: Arc>>, + order_record: Arc>, transaction_pool: Arc, url: String, ) where @@ -602,16 +559,13 @@ pub async fn run_on_demand_task( + AtLeast32BitUnsigned + Copy + From, - P::Api: AuraApi - + OrderRuntimeApi + P::Api: AuraApi + + OrderRuntimeApi + TransactionPaymentApi + OnRelayChainApi, - PB: Pair, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, ExPool: MaintainedTransactionPool::Hash> + 'static, { - let relay_chain_notification = relay_chain_notification::<_, _, _, PB, _, _>( + let relay_chain_notification = relay_chain_notification( para_id, parachain.clone(), relay_chain.clone(), @@ -620,27 +574,21 @@ pub async fn run_on_demand_task( transaction_pool, url.clone(), ); - let event_notification = event_notification::<_, _, _, PB>( - parachain.clone(), - relay_chain.clone(), - para_id, - url, - order_record, - ); + let event_notification = event_notification(para_id, url, order_record); select! { _ = relay_chain_notification.fuse() => {}, _ = event_notification.fuse() => {}, } } -use sp_keyring::Sr25519Keyring::Alice; -pub fn spawn_on_demand_order( + +pub fn spawn_on_demand_order( parachain: Arc, para_id: ParaId, relay_chain: R, transaction_pool: Arc, task_manager: &TaskManager, keystore: KeystorePtr, - order_record: Arc>>, + order_record: Arc>, relay_rpc: Option, ) -> sc_service::error::Result<()> where @@ -657,18 +605,15 @@ where + From, T: Send + Sync + 'static + ProvideRuntimeApi + UsageProvider, ExPool: MaintainedTransactionPool::Hash> + 'static, - T::Api: AuraApi - + OrderRuntimeApi + T::Api: AuraApi + + OrderRuntimeApi + TransactionPaymentApi + OnRelayChainApi, - PB: Pair + 'static, - PB::Public: AppPublic + Member + Codec, - PB::Signature: TryFrom> + Member + Codec, { let mut url = String::from("ws://"); url.push_str(&relay_rpc.expect("Should set rpc address for submit order extrinic").to_string()); - let on_demand_order_task = run_on_demand_task::<_, _, _, PB, _, _>( + let on_demand_order_task = run_on_demand_task( para_id, parachain.clone(), relay_chain.clone(), diff --git a/node/src/service.rs b/node/src/service.rs index 3abf526..34566b2 100644 --- a/node/src/service.rs +++ b/node/src/service.rs @@ -458,9 +458,8 @@ async fn start_node_impl( sync_service: sync_service.clone(), })?; if validator { - let order_record = - Arc::new(Mutex::new(OrderRecord::::new())); - spawn_on_demand_order::<_, _, _, _, sp_consensus_aura::sr25519::AuthorityPair, _>( + let order_record = Arc::new(Mutex::new(OrderRecord::new())); + spawn_on_demand_order( client.clone(), para_id, relay_chain_interface.clone(), @@ -472,7 +471,7 @@ async fn start_node_impl( )?; let bulk_mem_record = Arc::new(Mutex::new(BulkMemRecord { coretime_para_height: 0, items: Vec::new() })); - spawn_bulk_task::<_, _, _, sp_consensus_aura::sr25519::AuthorityPair>( + spawn_bulk_task( client.clone(), para_id, relay_chain_interface.clone(), @@ -552,7 +551,7 @@ fn start_consensus( collator_key: CollatorPair, overseer_handle: OverseerHandle, announce_block: Arc>) + Send + Sync>, - order_record: Arc>>, + order_record: Arc>, bulk_mem_record: Arc>, ) -> Result<(), sc_service::Error> { use cumulus_client_consensus_aura::collators::lookahead::{self as aura, Params as AuraParams}; diff --git a/pallets/bulk/src/lib.rs b/pallets/bulk/src/lib.rs index 05f9b11..b8a0c00 100644 --- a/pallets/bulk/src/lib.rs +++ b/pallets/bulk/src/lib.rs @@ -34,12 +34,7 @@ use mp_coretime_common::{ }; pub use pallet::*; use pallet_broker::RegionRecord; -use primitives::Balance; -use sp_runtime::{ - sp_std::{prelude::*, vec}, - traits::Member, - RuntimeAppPublic, -}; +use sp_runtime::sp_std::{prelude::*, vec}; use weights::WeightInfo; #[cfg(test)] @@ -88,13 +83,6 @@ pub mod pallet { type RelayChainStateProvider: cumulus_pallet_parachain_system::RelaychainStateProvider; - type AuthorityId: Member - + Parameter - + RuntimeAppPublic - + MaybeSerializeDeserialize - + MaxEncodedLen - + for<'a> TryFrom<&'a [u8]>; - type UpdateOrigin: EnsureOrigin; type WeightInfo: WeightInfo; @@ -131,7 +119,7 @@ pub mod pallet { #[pallet::storage] #[pallet::getter(fn bulk_records)] pub type BulkRecords = - StorageMap<_, Twox64Concat, u32, BulkRecord, T::AuthorityId>, OptionQuery>; + StorageMap<_, Twox64Concat, u32, BulkRecord, T::AccountId>, OptionQuery>; #[pallet::genesis_config] pub struct GenesisConfig { @@ -164,7 +152,7 @@ pub mod pallet { /// Create record event. RecordCreated { /// Account for purchase. - purchaser: T::AuthorityId, + purchaser: T::AccountId, /// Purchase price. price: BalanceOf, /// Purchase duration. @@ -258,10 +246,7 @@ pub mod pallet { let region_key = broker_regions(region_id); // Read RegionRecord from proof. let region_record = storage_rooted_proof - .read_entry::>>( - region_key.as_slice(), - None, - ) + .read_entry::>>(region_key.as_slice(), None) .ok() .ok_or(Error::::FailedReading)?; @@ -283,7 +268,7 @@ pub mod pallet { // Create record of purchase coretime. BulkRecords::::insert( old_record_index, - BulkRecord::, T::AuthorityId> { + BulkRecord::, T::AccountId> { purchaser: purchaser.clone(), price: balance, duration, diff --git a/pallets/bulk/src/mock.rs b/pallets/bulk/src/mock.rs index ed5d807..45db57b 100644 --- a/pallets/bulk/src/mock.rs +++ b/pallets/bulk/src/mock.rs @@ -23,7 +23,6 @@ pub use frame_support::{ }; use frame_system as system; use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; -pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; use sp_core::{crypto::AccountId32, H256}; use sp_runtime::{ traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, @@ -126,7 +125,6 @@ parameter_types! { impl crate::Config for Test { type RuntimeEvent = RuntimeEvent; - type AuthorityId = AuraId; type UpdateOrigin = EnsureRoot; type Currency = Balances; type RelayChainStateProvider = MockRelayStateProvider; @@ -148,7 +146,6 @@ pub trait BulkGasCost { impl BulkGasCost for BulkGasCostHandler where T: crate::Config, - T::AccountId: From<[u8; 32]>, { fn gas_cost( _block_number: BlockNumberFor, diff --git a/pallets/on-demand/src/benchmarking.rs b/pallets/on-demand/src/benchmarking.rs index ffa1f93..35a72e1 100644 --- a/pallets/on-demand/src/benchmarking.rs +++ b/pallets/on-demand/src/benchmarking.rs @@ -26,15 +26,6 @@ use frame_system::RawOrigin; use sp_core::crypto::UncheckedFrom; use sp_runtime::Perbill; -// mod test_mod { -// use scale_info::prelude::format; -// use sp_core::{Pair, Public, H160, U256}; -// pub fn get_from_seed(seed: &str) -> ::Public { -// TPublic::Pair::from_string(&format!("//{}", seed), None) -// .expect("static values are valid; qed") -// .public() -// } -// } benchmarks! { set_slot_width { let s in 0 .. 100; @@ -65,11 +56,8 @@ benchmarks! { create_order { let s in 0..100; - // let author = test_mod::get_from_seed::("Alice"); - // let mut r = [0u8; 32]; - // r.copy_from_slice(author.encode().as_slice()); let r = [0xd4,0x35,0x93,0xc7,0x15,0xfd,0xd3,0x1c,0x61,0x14,0x1a,0xbd,0x04,0xa9,0x9f,0xd6,0x82,0x2c,0x85,0x58,0x85,0x4c,0xcd,0xe3,0x9a,0x56,0x84,0xe7,0xa5,0x6d,0xa2,0x7d]; - let author_pub = ::AuthorityId::unchecked_from(r); + let author_pub = T::AccountId::try_from(r).unwrap(); let bulk_inherent_data = mp_coretime_on_demand::OrderInherentData { relay_chian_number: 40, author_pub: Some(author_pub), diff --git a/pallets/on-demand/src/lib.rs b/pallets/on-demand/src/lib.rs index 8ce56e7..8f45429 100644 --- a/pallets/on-demand/src/lib.rs +++ b/pallets/on-demand/src/lib.rs @@ -26,29 +26,18 @@ //! whether the order has been executed, whether the order threshold has been reached, etc. #![cfg_attr(not(feature = "std"), no_std)] -use codec::{Decode, EncodeLike, MaxEncodedLen}; -use cumulus_pallet_parachain_system::RelayChainStateProof; +use codec::{Decode, MaxEncodedLen}; use frame_support::{ dispatch::DispatchResultWithPostInfo, dispatch::PostDispatchInfo, pallet_prelude::*, traits::Currency, }; use frame_system::pallet_prelude::*; -use frame_system::{self, EventRecord}; pub use pallet::*; use primitives::Balance; -use primitives::{Id as ParaId, PersistedValidationData}; use sp_runtime::sp_std::{prelude::*, vec}; -use sp_runtime::{traits::Member, RuntimeAppPublic}; pub mod weights; use cumulus_pallet_parachain_system::RelaychainStateProvider; -use frame_system::AccountInfo; -use mp_coretime_on_demand::well_known_keys::{acount_balance, EnqueuedOrder, ON_DEMAND_QUEUE}; -use pallet_balances::AccountData; -use sp_core::crypto::ByteArray; -use sp_core::crypto::UncheckedFrom; -use sp_runtime::traits::AccountIdConversion; use sp_runtime::Perbill; -use sp_runtime::{self, AccountId32}; use weights::WeightInfo; #[cfg(test)] @@ -84,20 +73,15 @@ pub mod pallet { /// Configure the pallet by specifying the parameters and types on which it depends. #[pallet::config] - pub trait Config: frame_system::Config + pallet_aura::Config { + pub trait Config: frame_system::Config + pallet_aura::Config + where + ::AccountId: From<[u8; 32]>, + { /// Because this pallet emits events, it depends on the runtime's definition of an event. type RuntimeEvent: From> + IsType<::RuntimeEvent>; type Currency: Currency; - type AuthorityId: Member - + Parameter - + RuntimeAppPublic - + MaybeSerializeDeserialize - + MaxEncodedLen - + UncheckedFrom<[u8; 32]>; - // + for<'a> TryFrom<&'a [u8]>; - type UpdateOrigin: EnsureOrigin; type WeightInfo: WeightInfo; @@ -132,7 +116,7 @@ pub mod pallet { #[pallet::storage] #[pallet::getter(fn order_map)] pub type OrderMap = - StorageMap<_, Twox64Concat, u64, Order<::AuthorityId>, OptionQuery>; + StorageMap<_, Twox64Concat, u64, Order, OptionQuery>; /// Convert block height to sequence number. #[pallet::storage] @@ -142,14 +126,20 @@ pub mod pallet { #[pallet::genesis_config] #[derive(frame_support::DefaultNoBound)] - pub struct GenesisConfig { + pub struct GenesisConfig + where + T::AccountId: From<[u8; 32]>, + { pub slot_width: u32, pub price_limit: BalanceOf, pub gas_threshold: Perbill, } #[pallet::genesis_build] - impl BuildGenesisConfig for GenesisConfig { + impl BuildGenesisConfig for GenesisConfig + where + T::AccountId: From<[u8; 32]>, + { fn build(&self) { SlotWidth::::put(&self.slot_width); PriceLimit::::put(&self.price_limit); @@ -159,9 +149,12 @@ pub mod pallet { #[pallet::event] #[pallet::generate_deposit(pub(super) fn deposit_event)] - pub enum Event { + pub enum Event + where + T::AccountId: From<[u8; 32]>, + { /// Create order event. - OrderCreate { sequence_number: u64, orderer: ::AuthorityId }, + OrderCreate { sequence_number: u64, orderer: T::AccountId }, } #[pallet::error] @@ -183,20 +176,23 @@ pub mod pallet { } #[pallet::hooks] - impl Hooks> for Pallet {} + impl Hooks> for Pallet where T::AccountId: From<[u8; 32]> {} #[pallet::inherent] - impl ProvideInherent for Pallet { + impl ProvideInherent for Pallet + where + T::AccountId: From<[u8; 32]>, + { type Call = Call; type Error = MakeFatalError<()>; const INHERENT_IDENTIFIER: InherentIdentifier = mp_coretime_on_demand::INHERENT_IDENTIFIER; fn create_inherent(data: &InherentData) -> Option { - let data: mp_coretime_on_demand::OrderInherentData<::AuthorityId> = - data.get_data(&mp_coretime_on_demand::INHERENT_IDENTIFIER) - .ok() - .flatten() - .expect("there is not data to be posted; qed"); + let data: mp_coretime_on_demand::OrderInherentData = data + .get_data(&mp_coretime_on_demand::INHERENT_IDENTIFIER) + .ok() + .flatten() + .expect("there is not data to be posted; qed"); if data.author_pub.is_none() { None } else { @@ -209,7 +205,10 @@ pub mod pallet { } #[pallet::call] - impl Pallet { + impl Pallet + where + T::AccountId: From<[u8; 32]>, + { /// Create an order, which is called by the pallet. /// Users cannot actively call this function. /// Obtain order information by parsing inherited data. @@ -220,7 +219,7 @@ pub mod pallet { #[pallet::weight((::WeightInfo::create_order(), DispatchClass::Mandatory))] pub fn create_order( origin: OriginFor, - data: mp_coretime_on_demand::OrderInherentData<::AuthorityId>, + data: mp_coretime_on_demand::OrderInherentData, ) -> DispatchResultWithPostInfo { ensure_none(origin)?; @@ -234,7 +233,10 @@ pub mod pallet { // relay chian block number let relay_chian_height = T::RelayChainStateProvider::current_relay_chain_state().number; let block_number = frame_system::Pallet::::block_number(); - let orderer = author_pub.expect("author must exist"); + let author = author_pub.expect("author must exist"); + let mut r = [0u8; 32]; + r.copy_from_slice(author.encode().as_slice()); + let orderer = T::AccountId::try_from(r).map_err(|_| Error::::SlotAuthorError)?; // Check if the order is in author slot if !Self::check_slot_author(place_order_height, orderer.clone()) { Err(Error::::SlotAuthorError)?; @@ -242,7 +244,7 @@ pub mod pallet { if order.is_none() { OrderMap::::insert( old_sequence_number, - Order::<::AuthorityId> { + Order:: { sequence_number: old_sequence_number, relay_chian_height, place_order_height, @@ -315,7 +317,10 @@ pub mod pallet { } } -impl Pallet { +impl Pallet +where + T::AccountId: From<[u8; 32]>, +{ /// Whether the gas threshold for placing an order has been reached. /// /// Parameters: @@ -325,10 +330,7 @@ impl Pallet { gas_balance > txpool_threshold * core_price } - fn check_slot_author( - relaychian_number: u32, - author: ::AuthorityId, - ) -> bool { + fn check_slot_author(relaychian_number: u32, author: T::AccountId) -> bool { let authorities = pallet_aura::Pallet::::authorities(); let slot_width = Self::slot_width(); let auth_len = authorities.len() as u32; diff --git a/pallets/on-demand/src/mock.rs b/pallets/on-demand/src/mock.rs index 412373c..62d8ab6 100644 --- a/pallets/on-demand/src/mock.rs +++ b/pallets/on-demand/src/mock.rs @@ -15,7 +15,6 @@ // along with Magnet. If not, see . use crate::{self as order_pallet}; -use codec::Encode; use cumulus_pallet_parachain_system::RelayChainState; use cumulus_pallet_parachain_system::RelaychainStateProvider; pub use frame_support::{ @@ -26,8 +25,6 @@ use frame_system as system; use frame_system::{pallet_prelude::BlockNumberFor, EnsureRoot}; pub use sp_consensus_aura::sr25519::AuthorityId as AuraId; use sp_core::{crypto::AccountId32, ConstBool, ConstU32, ConstU64, H256}; -use sp_core::{Pair, Public, H160, U256}; -use sp_keyring::sr25519; use sp_keyring::Sr25519Keyring::Alice; use sp_runtime::{ traits::{BlakeTwo256, IdentifyAccount, IdentityLookup, Verify}, @@ -150,7 +147,6 @@ impl pallet_aura::Config for Test { impl crate::Config for Test { type RuntimeEvent = RuntimeEvent; - type AuthorityId = AuraId; type UpdateOrigin = EnsureRoot; type Currency = Balances; type WeightInfo = (); @@ -184,11 +180,7 @@ where sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, ) .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; - let mut r = [0u8; 32]; - r.copy_from_slice(order.orderer.encode().as_slice()); - let account = T::AccountId::try_from(r) - .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; - Ok(Some((account, order.price))) + Ok(Some((order.orderer, order.price))) } } @@ -227,11 +219,6 @@ impl Default for ExtBuilder { } } -pub fn get_from_seed(seed: &str) -> ::Public { - TPublic::Pair::from_string(&format!("//{}", seed), None) - .expect("static values are valid; qed") - .public() -} impl ExtBuilder { pub fn build(self) -> sp_io::TestExternalities { // Build genesis storage according to the mock runtime. @@ -246,11 +233,9 @@ impl ExtBuilder { } .assimilate_storage(&mut t) .unwrap(); - pallet_aura::GenesisConfig:: { - authorities: vec![get_from_seed::("Alice").into()], - } - .assimilate_storage(&mut t) - .unwrap(); + pallet_aura::GenesisConfig:: { authorities: vec![Alice.public().into()] } + .assimilate_storage(&mut t) + .unwrap(); let mut ext = sp_io::TestExternalities::new(t); ext.execute_with(|| System::set_block_number(1)); ext diff --git a/pallets/on-demand/src/tests.rs b/pallets/on-demand/src/tests.rs index 80d9a52..2b279f5 100644 --- a/pallets/on-demand/src/tests.rs +++ b/pallets/on-demand/src/tests.rs @@ -15,17 +15,13 @@ // along with Magnet. If not, see . use crate::mock::*; -use codec::Decode; -use cumulus_primitives_core::{ParaId, PersistedValidationData}; use frame_support::{ inherent::{InherentData, ProvideInherent}, traits::UnfilteredDispatchable, }; use frame_system::RawOrigin; use parachains_common::AccountId; -use primitives::HeadData; -use sp_consensus_aura::sr25519::AuthorityId; -use sp_trie::StorageProof; +use sp_keyring::Sr25519Keyring::Alice; #[test] fn order_default_value() { @@ -40,12 +36,11 @@ fn order_normal_test() { System::set_block_number(1); let mut inherent_data = InherentData::default(); - let order_inherent_data: mp_coretime_on_demand::OrderInherentData = - mp_coretime_on_demand::OrderInherentData { - relay_chian_number: 40, - author_pub: Some(get_from_seed::("Alice").into()), - price: 10000000, - }; + let order_inherent_data = mp_coretime_on_demand::OrderInherentData { + relay_chian_number: 40, + author_pub: Some(Alice.public().into()), + price: 10000000, + }; inherent_data .put_data(mp_coretime_on_demand::INHERENT_IDENTIFIER, &order_inherent_data) .expect("failed to put VFP inherent"); diff --git a/primitives/coretime/on-demand/src/inherent_client.rs b/primitives/coretime/on-demand/src/inherent_client.rs index 1e8c7e0..8ce1031 100644 --- a/primitives/coretime/on-demand/src/inherent_client.rs +++ b/primitives/coretime/on-demand/src/inherent_client.rs @@ -14,19 +14,10 @@ // You should have received a copy of the GNU General Public License // along with Magnet. If not, see . -// use sp_consensus_aura::sr25519::AuthorityId; -use crate::well_known_keys::{acount_balance, ON_DEMAND_QUEUE}; -use crate::Codec; +use crate::OrderInherentData; use sp_consensus_aura::sr25519::AuthorityId; -use sp_core::{crypto::UncheckedFrom, ByteArray}; -use sp_runtime::AccountId32; -use { - crate::OrderInherentData, - cumulus_primitives_core::{ParaId, PersistedValidationData}, - cumulus_relay_chain_interface::{PHash, RelayChainInterface}, -}; -impl OrderInherentData { +impl OrderInherentData { /// Create the [`OrderInherentData`] at the given `relay_parent`. /// /// Returns `None` if the creation failed. @@ -34,14 +25,14 @@ impl OrderInherentData { relay_chian_number: u32, author_pub: &Option, price: u128, - ) -> Option> { + ) -> Option { Some(OrderInherentData { relay_chian_number, author_pub: author_pub.clone(), price }) } } // Implementation of InherentDataProvider #[async_trait::async_trait] -impl sp_inherents::InherentDataProvider for OrderInherentData { +impl sp_inherents::InherentDataProvider for OrderInherentData { async fn provide_inherent_data( &self, inherent_data: &mut sp_inherents::InherentData, diff --git a/primitives/coretime/on-demand/src/lib.rs b/primitives/coretime/on-demand/src/lib.rs index a014319..eacaa94 100644 --- a/primitives/coretime/on-demand/src/lib.rs +++ b/primitives/coretime/on-demand/src/lib.rs @@ -20,11 +20,9 @@ //! the on demand order pallet inherent //! #![cfg_attr(not(feature = "std"), no_std)] -use core::default; use cumulus_primitives_core::{ relay_chain::BlockNumber as RelayBlockNumber, relay_chain::Hash as PHash, ParaId, - PersistedValidationData, }; use sp_core::H256; use sp_runtime::sp_std::vec::Vec; @@ -33,10 +31,11 @@ use sp_runtime::traits::MaybeDisplay; pub mod inherent_client; pub mod well_known_keys; use codec::{Codec, Decode, Encode}; +use sp_consensus_aura::sr25519::AuthorityId; use {scale_info::TypeInfo, sp_inherents::InherentIdentifier}; #[derive(Encode, Decode, sp_core::RuntimeDebug, Clone, PartialEq, TypeInfo)] -pub struct OrderInherentData { +pub struct OrderInherentData { /// Relaychain block height, for check. pub relay_chian_number: RelayBlockNumber, /// Author of order. @@ -57,7 +56,7 @@ pub enum OrderStatus { } #[derive(Clone)] -pub struct OrderRecord { +pub struct OrderRecord { /// Hash of relaychain block. pub relay_parent: PHash, /// Relaychain block height. @@ -72,8 +71,8 @@ pub struct OrderRecord { pub txs: Vec, } -impl OrderRecord { - pub fn new() -> OrderRecord { +impl OrderRecord { + pub fn new() -> OrderRecord { OrderRecord { relay_parent: Default::default(), relay_height: 0, @@ -95,9 +94,8 @@ impl OrderRecord { sp_api::decl_runtime_apis! { #[api_version(2)] - pub trait OrderRuntimeApi where + pub trait OrderRuntimeApi where Balance: Codec + MaybeDisplay, - AuthorityId:Codec { fn slot_width()-> u32; diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index d108e7f..7333fe2 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -719,11 +719,7 @@ where sequece_number.ok_or(sp_runtime::DispatchError::Other("sequece_number is none"))?, ) .ok_or(sp_runtime::DispatchError::Other("Not exist order"))?; - let mut r = [0u8; 32]; - r.copy_from_slice(order.orderer.encode().as_slice()); - let account = T::AccountId::try_from(r) - .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; - Ok(Some((account, order.price))) + Ok(Some((order.orderer, order.price))) } } @@ -734,7 +730,6 @@ type EnsureRootOrHalf = EitherOfDiverse< impl pallet_on_demand::Config for Runtime { type RuntimeEvent = RuntimeEvent; - type AuthorityId = AuraId; type Currency = Balances; type UpdateOrigin = EnsureRootOrHalf; type WeightInfo = pallet_on_demand::weights::SubstrateWeight; @@ -745,7 +740,6 @@ pub struct BulkGasCostHandler(); impl BulkGasCost for BulkGasCostHandler where T: pallet_bulk::Config, - T::AccountId: From<[u8; 32]>, { fn gas_cost( block_number: BlockNumberFor, @@ -763,24 +757,20 @@ where let balance = price .checked_div(duration) .ok_or(sp_runtime::DispatchError::Other("duration error"))?; - let mut r = [0u8; 32]; - r.copy_from_slice(record.purchaser.encode().as_slice()); - let account = T::AccountId::try_from(r) - .map_err(|_| sp_runtime::DispatchError::Other("Account error"))?; - result = Some((account, balance)); + result = Some((record.purchaser, balance)); } } } Ok(result) } } + parameter_types! { pub const MaxUrlLength: u32 = 300; } impl pallet_bulk::Config for Runtime { type RuntimeEvent = RuntimeEvent; - type AuthorityId = AuraId; type Currency = Balances; type RelayChainStateProvider = cumulus_pallet_parachain_system::RelaychainDataProvider; type UpdateOrigin = EnsureRootOrHalf; @@ -1672,7 +1662,7 @@ impl_runtime_apis! { ConsensusHook::can_build_upon(included_hash, slot) } } - impl mp_coretime_on_demand::OrderRuntimeApi for Runtime { + impl mp_coretime_on_demand::OrderRuntimeApi for Runtime { fn slot_width()-> u32{ OrderPallet::slot_width() From a2eb45a1a3ba13d900feda91596b9946b59f71a9 Mon Sep 17 00:00:00 2001 From: toints Date: Fri, 26 Jul 2024 16:15:49 +0800 Subject: [PATCH 41/44] fixed: fixed percentage calculation --- pallets/liquidation/src/lib.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pallets/liquidation/src/lib.rs b/pallets/liquidation/src/lib.rs index bfab491..502b394 100644 --- a/pallets/liquidation/src/lib.rs +++ b/pallets/liquidation/src/lib.rs @@ -484,11 +484,11 @@ pub mod pallet { let collators_ratio = CollatorRatio::::get(); //let total_operation_ratio: u32 = OperationRatios::::iter().map(|(_, r)| r).sum(); - let treasury_amount = (treasury_ratio as u128) / PERCENT_UNIT * total_profit + let treasury_amount = (treasury_ratio as u128) / PERCENT_UNIT * total_profit / 100 / PARACHAIN_TO_RELAYCHAIN_UNIT; //let operation_amount = (operation_ratio as u128) / PERCENT_UNIT * total_profit; //let system_amount = (system_ratio as u128) / PERCENT_UNIT * total_profit; - let total_collators_profit = (collators_ratio as u128) / PERCENT_UNIT * total_profit; + let total_collators_profit = (collators_ratio as u128) / PERCENT_UNIT * total_profit / 100; let origin: OriginFor = frame_system::RawOrigin::Signed(treasury_account.clone()).into(); @@ -507,7 +507,7 @@ pub mod pallet { */ for (operation_account, ratio) in OperationRatios::::iter() { - let operation_amount = (ratio as u128) / PERCENT_UNIT * total_profit; + let operation_amount = (ratio as u128) / PERCENT_UNIT * total_profit / 100; let operation_account_profit = operation_amount.try_into().unwrap_or_else(|_| Zero::zero()); transfers.push((operation_account, operation_account_profit)); From 013694cb43dc7d37d41583b0e4b74427c5dc4752 Mon Sep 17 00:00:00 2001 From: toints Date: Fri, 26 Jul 2024 16:45:43 +0800 Subject: [PATCH 42/44] fix: add transfer to parachain treasury account --- pallets/liquidation/src/lib.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pallets/liquidation/src/lib.rs b/pallets/liquidation/src/lib.rs index 502b394..79b5b78 100644 --- a/pallets/liquidation/src/lib.rs +++ b/pallets/liquidation/src/lib.rs @@ -495,16 +495,16 @@ pub mod pallet { let _send_treasury_profit = Self::send_assets_to_relaychain_treasury( origin, - treasury_account.into(), + treasury_account.clone().into(), treasury_amount, )?; let mut transfers = Vec::new(); - /* + + let treasury_amount_parachain = treasury_amount * PARACHAIN_TO_RELAYCHAIN_UNIT; let treasury_account_profit = - treasury_amount.try_into().unwrap_or_else(|_| Zero::zero()); + treasury_amount_parachain.try_into().unwrap_or_else(|_| Zero::zero()); transfers.push((treasury_account, treasury_account_profit)); - */ for (operation_account, ratio) in OperationRatios::::iter() { let operation_amount = (ratio as u128) / PERCENT_UNIT * total_profit / 100; From c3fc2902dda9975c93e386aa36722da11fd42b82 Mon Sep 17 00:00:00 2001 From: toints Date: Fri, 26 Jul 2024 16:58:01 +0800 Subject: [PATCH 43/44] style: format style in liquidation --- pallets/liquidation/src/lib.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pallets/liquidation/src/lib.rs b/pallets/liquidation/src/lib.rs index 79b5b78..53fc3dc 100644 --- a/pallets/liquidation/src/lib.rs +++ b/pallets/liquidation/src/lib.rs @@ -484,11 +484,12 @@ pub mod pallet { let collators_ratio = CollatorRatio::::get(); //let total_operation_ratio: u32 = OperationRatios::::iter().map(|(_, r)| r).sum(); - let treasury_amount = (treasury_ratio as u128) / PERCENT_UNIT * total_profit / 100 - / PARACHAIN_TO_RELAYCHAIN_UNIT; + let treasury_amount = (treasury_ratio as u128) / PERCENT_UNIT * total_profit + / 100 / PARACHAIN_TO_RELAYCHAIN_UNIT; //let operation_amount = (operation_ratio as u128) / PERCENT_UNIT * total_profit; //let system_amount = (system_ratio as u128) / PERCENT_UNIT * total_profit; - let total_collators_profit = (collators_ratio as u128) / PERCENT_UNIT * total_profit / 100; + let total_collators_profit = + (collators_ratio as u128) / PERCENT_UNIT * total_profit / 100; let origin: OriginFor = frame_system::RawOrigin::Signed(treasury_account.clone()).into(); From fa8a543117325a445941b8828a892a68e160f8b9 Mon Sep 17 00:00:00 2001 From: zachary0809 <139736437+zachary0809@users.noreply.github.com> Date: Fri, 2 Aug 2024 00:26:13 +0800 Subject: [PATCH 44/44] Update rust.yml Delete cargo update and undelete cargo.lock. --- .github/workflows/rust.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 532f3d6..14d4827 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -66,12 +66,6 @@ jobs: - name: Cargo Clean run: cargo clean - - name: Remove Cargo.lock - run: rm Cargo.lock - - - name: Cargo Update - run: cargo update - - name: Build run: cargo check --release