update substrate reference (#244)

* port polkadot_runtime and polkadot_validation

* update storages build (#245)

* all tests pass

* rebuild wasm
This commit is contained in:
Robert Habermeier
2019-05-06 18:25:55 +02:00
committed by GitHub
parent e42019e1dc
commit a65be1b2df
18 changed files with 1127 additions and 620 deletions
+4 -1
View File
@@ -135,8 +135,11 @@ impl<C: Collators, P: ProvideRuntimeApi> Future for CollationFetch<C, P>
error_chain! {
types { Error, ErrorKind, ResultExt; }
foreign_links {
Client(::client::error::Error);
}
links {
Client(::client::error::Error, ::client::error::ErrorKind);
WasmValidation(wasm_executor::Error, wasm_executor::ErrorKind);
}
+4 -7
View File
@@ -21,8 +21,11 @@ use runtime_primitives::RuntimeString;
use primitives::ed25519::Public as AuthorityId;
error_chain! {
foreign_links {
Client(::client::error::Error);
}
links {
Client(::client::error::Error, ::client::error::ErrorKind);
Consensus(::consensus::error::Error, ::consensus::error::ErrorKind);
}
@@ -53,9 +56,3 @@ error_chain! {
}
}
}
// impl From<::bft::InputStreamConcluded> for Error {
// fn from(err: ::bft::InputStreamConcluded) -> Self {
// ::bft::Error::from(err).into()
// }
// }
+2 -2
View File
@@ -23,8 +23,8 @@ use polkadot_primitives::{Block, Hash, BlockNumber};
use polkadot_primitives::parachain::Id as ParaId;
error_chain! {
links {
Client(::client::error::Error, ::client::error::ErrorKind);
foreign_links {
Client(::client::error::Error);
}
errors {
+3 -3
View File
@@ -547,7 +547,7 @@ impl<C, N, P, TxApi> consensus::Environment<Block> for ProposerFactory<C, N, P,
parent_id,
parent_number: parent_header.number,
transaction_pool: self.transaction_pool.clone(),
slot_duration: self.aura_slot_duration,
slot_duration: self.aura_slot_duration.clone(),
})
}
}
@@ -720,7 +720,7 @@ impl<C, TxApi> CreateProposal<C, TxApi> where
let runtime_api = self.client.runtime_api();
let mut block_builder = BlockBuilder::at_block(&self.parent_id, &*self.client)?;
let mut block_builder = BlockBuilder::at_block(&self.parent_id, &*self.client, false)?;
{
let inherents = runtime_api.inherent_extrinsics(&self.parent_id, inherent_data)?;
@@ -747,7 +747,7 @@ impl<C, TxApi> CreateProposal<C, TxApi> where
debug!("[{:?}] Pushed to the block.", ready.hash);
pending_size += encoded_size;
}
Err(client::error::Error(client::error::ErrorKind::ApplyExtrinsicFailed(ApplyError::FullBlock), _)) => {
Err(client::error::Error::ApplyExtrinsicFailed(ApplyError::FullBlock)) => {
debug!("Block is full, proceed with proposing.");
break;
}