Clean up justification (#1111)

* adding mac libraries and how to start testnet

* Clean up Justification struct, Issue #1033

* adding mac libraries and how to start testnet
This commit is contained in:
Shawn Tabrizi
2018-11-14 07:39:38 -05:00
committed by Robert Habermeier
parent 74e907f3cb
commit 7f8ee0f53b
7 changed files with 21 additions and 21 deletions
+4 -4
View File
@@ -240,8 +240,8 @@ pub fn start_aura<B, C, E, SO, Error>(
let import_block = ImportBlock {
origin: BlockOrigin::Own,
header,
external_justification: Vec::new(),
post_runtime_digests: vec![item],
justification: Vec::new(),
post_digests: vec![item],
body: Some(body),
finalized: false,
auxiliary: Vec::new(),
@@ -365,8 +365,8 @@ impl<B: Block, C> Verifier<B> for AuraVerifier<C> where
let import_block = ImportBlock {
origin,
header: pre_header,
external_justification: Vec::new(),
post_runtime_digests: vec![item],
justification: Vec::new(),
post_digests: vec![item],
body,
finalized: false,
auxiliary: Vec::new(),
@@ -44,7 +44,7 @@ pub struct ImportBlock<Block: BlockT> {
///
/// Consensus engines which alter the header (by adding post-runtime digests)
/// should strip those off in the initial verification process and pass them
/// via the `post_runtime_digests` field. During block authorship, they should
/// via the `post_digests` field. During block authorship, they should
/// not be pushed to the header directly.
///
/// The reason for this distinction is so the header can be directly
@@ -52,10 +52,10 @@ pub struct ImportBlock<Block: BlockT> {
/// post-runtime digests are pushed back on after.
pub header: Block::Header,
/// Justification provided for this block from the outside:.
pub external_justification: Justification,
pub justification: Justification,
/// Digest items that have been added after the runtime for external
/// work, like a consensus signature.
pub post_runtime_digests: Vec<DigestItemFor<Block>>,
pub post_digests: Vec<DigestItemFor<Block>>,
/// Block's body
pub body: Option<Vec<Block::Extrinsic>>,
/// Is this block finalized already?
@@ -82,8 +82,8 @@ impl<Block: BlockT> ImportBlock<Block> {
(
self.origin,
self.header,
self.external_justification,
self.post_runtime_digests,
self.justification,
self.post_digests,
self.body,
self.finalized,
self.auxiliary,
+2 -2
View File
@@ -417,10 +417,10 @@ impl<B, P, I, InStream, OutSink> Future for BftFuture<B, P, I, InStream, OutSink
let import_block = ImportBlock {
origin: BlockOrigin::ConsensusBroadcast,
header: header,
external_justification: just.into(),
justification: just.into(),
body: Some(body),
finalized: true,
post_runtime_digests: Default::default(),
post_digests: Default::default(),
auxiliary: Default::default()
};