chore: regenerate umbrella crate, fix feature propagation

This commit is contained in:
2025-12-16 11:28:32 +03:00
parent dd6d48f528
commit 620b0e3aa0
1358 changed files with 9464 additions and 7656 deletions
+4 -2
View File
@@ -241,8 +241,10 @@ pub trait BlockImportOperation<Block: BlockT> {
fn mark_head(&mut self, hash: Block::Hash) -> pezsp_blockchain::Result<()>;
/// Add a transaction index operation.
fn update_transaction_index(&mut self, index: Vec<IndexOperation>)
-> pezsp_blockchain::Result<()>;
fn update_transaction_index(
&mut self,
index: Vec<IndexOperation>,
) -> pezsp_blockchain::Result<()>;
/// Configure whether to create a block gap if newly imported block is missing parent
fn set_create_gap(&mut self, create_gap: bool);
+12 -4
View File
@@ -137,19 +137,27 @@ pub trait BlockBackend<Block: BlockT> {
///
/// Note that this will only fetch transactions
/// that are indexed by the runtime with `storage_index_transaction`.
fn block_indexed_body(&self, hash: Block::Hash) -> pezsp_blockchain::Result<Option<Vec<Vec<u8>>>>;
fn block_indexed_body(
&self,
hash: Block::Hash,
) -> pezsp_blockchain::Result<Option<Vec<Vec<u8>>>>;
/// Get full block by hash.
fn block(&self, hash: Block::Hash) -> pezsp_blockchain::Result<Option<SignedBlock<Block>>>;
/// Get block status by block hash.
fn block_status(&self, hash: Block::Hash) -> pezsp_blockchain::Result<pezsp_consensus::BlockStatus>;
fn block_status(
&self,
hash: Block::Hash,
) -> pezsp_blockchain::Result<pezsp_consensus::BlockStatus>;
/// Get block justifications for the block with the given hash.
fn justifications(&self, hash: Block::Hash) -> pezsp_blockchain::Result<Option<Justifications>>;
fn justifications(&self, hash: Block::Hash)
-> pezsp_blockchain::Result<Option<Justifications>>;
/// Get block hash by number.
fn block_hash(&self, number: NumberFor<Block>) -> pezsp_blockchain::Result<Option<Block::Hash>>;
fn block_hash(&self, number: NumberFor<Block>)
-> pezsp_blockchain::Result<Option<Block::Hash>>;
/// Get single indexed transaction by content hash.
///
+9 -3
View File
@@ -407,7 +407,10 @@ impl<Block: BlockT> blockchain::Backend<Block> for Blockchain<Block> {
.and_then(|b| b.extrinsics().map(|x| x.to_vec())))
}
fn justifications(&self, hash: Block::Hash) -> pezsp_blockchain::Result<Option<Justifications>> {
fn justifications(
&self,
hash: Block::Hash,
) -> pezsp_blockchain::Result<Option<Justifications>> {
Ok(self.storage.read().blocks.get(&hash).and_then(|b| b.justifications().cloned()))
}
@@ -672,7 +675,10 @@ impl<Block: BlockT> backend::Backend<Block> for Backend<Block> {
Ok(())
}
fn commit_operation(&self, operation: Self::BlockImportOperation) -> pezsp_blockchain::Result<()> {
fn commit_operation(
&self,
operation: Self::BlockImportOperation,
) -> pezsp_blockchain::Result<()> {
if !operation.finalized_blocks.is_empty() {
for (block, justification) in operation.finalized_blocks {
self.blockchain.finalize_header(block, justification)?;
@@ -804,9 +810,9 @@ pub fn check_genesis_storage(storage: &Storage) -> pezsp_blockchain::Result<()>
#[cfg(test)]
mod tests {
use crate::{in_mem::Blockchain, NewBlockState};
use bizinikiwi_test_runtime::{Block, Header, H256};
use pezsp_blockchain::Backend;
use pezsp_runtime::{traits::Header as HeaderT, ConsensusEngineId, Justifications};
use bizinikiwi_test_runtime::{Block, Header, H256};
pub const ID1: ConsensusEngineId = *b"TST1";
pub const ID2: ConsensusEngineId = *b"TST2";
+1 -1
View File
@@ -32,9 +32,9 @@ pub use backend::*;
pub use call_executor::*;
pub use client::*;
pub use notifications::*;
pub use proof_provider::*;
pub use pezsp_blockchain as blockchain;
pub use pezsp_blockchain::HeaderBackend;
pub use proof_provider::*;
pub use pezsp_state_machine::{CompactProof, StorageProof};
pub use pezsp_storage::{ChildInfo, PrefixedStorageKey, StorageData, StorageKey};