simplify ethcore errors by removing BlockImportError (#9593)
This commit is contained in:
@@ -24,7 +24,7 @@ use blockchain::TreeRoute;
|
||||
use client::Mode;
|
||||
use encoded;
|
||||
use vm::LastHashes;
|
||||
use error::{Error, ImportResult, CallError, BlockImportError};
|
||||
use error::{Error, CallError, EthcoreResult};
|
||||
use evm::Schedule;
|
||||
use executive::Executed;
|
||||
use filter::Filter;
|
||||
@@ -168,7 +168,7 @@ pub trait RegistryInfo {
|
||||
/// Provides methods to import block into blockchain
|
||||
pub trait ImportBlock {
|
||||
/// Import a block into the blockchain.
|
||||
fn import_block(&self, block: Unverified) -> Result<H256, BlockImportError>;
|
||||
fn import_block(&self, block: Unverified) -> EthcoreResult<H256>;
|
||||
}
|
||||
|
||||
/// Provides `call_contract` method
|
||||
@@ -205,7 +205,7 @@ pub trait IoClient: Sync + Send {
|
||||
fn queue_transactions(&self, transactions: Vec<Bytes>, peer_id: usize);
|
||||
|
||||
/// Queue block import with transaction receipts. Does no sealing and transaction validation.
|
||||
fn queue_ancient_block(&self, block_bytes: Unverified, receipts_bytes: Bytes) -> Result<H256, BlockImportError>;
|
||||
fn queue_ancient_block(&self, block_bytes: Unverified, receipts_bytes: Bytes) -> EthcoreResult<H256>;
|
||||
|
||||
/// Queue conensus engine message.
|
||||
fn queue_consensus_message(&self, message: Bytes);
|
||||
@@ -414,7 +414,7 @@ pub trait ScheduleInfo {
|
||||
///Provides `import_sealed_block` method
|
||||
pub trait ImportSealedBlock {
|
||||
/// Import sealed block. Skips all verifications.
|
||||
fn import_sealed_block(&self, block: SealedBlock) -> ImportResult;
|
||||
fn import_sealed_block(&self, block: SealedBlock) -> EthcoreResult<H256>;
|
||||
}
|
||||
|
||||
/// Provides `broadcast_proposal_block` method
|
||||
|
||||
Reference in New Issue
Block a user