mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-12 15:51:12 +00:00
Stop authoring blocks when offline (#1655)
* Don't author blocks when offline * Increased canonicalization delay * Fixed test
This commit is contained in:
committed by
Gav Wood
parent
2155e44e13
commit
641bb7cb46
@@ -272,6 +272,11 @@ pub fn start_aura<B, C, E, I, SO, Error>(
|
||||
}
|
||||
};
|
||||
|
||||
if sync_oracle.is_offline() && authorities.len() > 1 {
|
||||
debug!(target: "aura", "Skipping proposal slot. Waiting for the netork.");
|
||||
return Either::B(future::ok(()));
|
||||
}
|
||||
|
||||
let proposal_work = match slot_author(slot_num, &authorities) {
|
||||
None => return Either::B(future::ok(())),
|
||||
Some(author) => if author.0 == public_key.0 {
|
||||
|
||||
Reference in New Issue
Block a user