slots: slot lenience must take into account block proposal portion (#9138)

* aura, babe: proposal slot lenience must take into account proposal portion

* slots: add support for max_block_proposal_slot_portion

* fix compilation

* slots: add tests

* aura: fix comment

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* slots: log the actual proposing duration after lenience is applied

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
This commit is contained in:
André Silva
2021-06-19 21:37:33 +01:00
committed by GitHub
parent 0417e4e37f
commit 650fc2f9c9
6 changed files with 193 additions and 97 deletions
@@ -245,6 +245,7 @@ pub fn new_full(mut config: Configuration) -> Result<TaskManager, ServiceError>
sync_oracle: network.clone(),
justification_sync_link: network.clone(),
block_proposal_slot_portion: SlotProportion::new(2f32 / 3f32),
max_block_proposal_slot_portion: None,
telemetry: telemetry.as_ref().map(|x| x.handle()),
},
)?;