mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-07-04 11:37:24 +00:00
ChainSpec extensions (#3692)
* Add some chainspec tests and make sure we validate it. * Manual implementation of Extension + Forks definitions. * Move chain spec to separate crate. * Allow using ChainSpec with extensions. * Renames. * Implement Extension derive. * Implement Extension for Forks. * Support specifying fork blocks. * make for_blocks work * Support forks correctly. * Add a bunch of docs. * Make fork blocks optional. * Add missing docs. * Fix build. * Use struct for check_block params. * Fix tests? * Clean up.
This commit is contained in:
committed by
Gavin Wood
parent
c555b9bf88
commit
667ee95f5d
@@ -89,7 +89,7 @@ use schnorrkel::{
|
||||
},
|
||||
};
|
||||
use consensus_common::{
|
||||
self, BlockImport, Environment, Proposer,
|
||||
self, BlockImport, Environment, Proposer, BlockCheckParams,
|
||||
ForkChoiceStrategy, BlockImportParams, BlockOrigin, Error as ConsensusError,
|
||||
};
|
||||
use srml_babe::{
|
||||
@@ -1367,10 +1367,9 @@ impl<B, E, Block, I, RA, PRA> BlockImport<Block> for BabeBlockImport<B, E, Block
|
||||
|
||||
fn check_block(
|
||||
&mut self,
|
||||
hash: Block::Hash,
|
||||
parent_hash: Block::Hash,
|
||||
block: BlockCheckParams<Block>,
|
||||
) -> Result<ImportResult, Self::Error> {
|
||||
self.inner.check_block(hash, parent_hash).map_err(Into::into)
|
||||
self.inner.check_block(block).map_err(Into::into)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user