From 138866f64df84ea56454c248be0c1f2dae886c06 Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Sun, 13 Nov 2022 20:19:19 -0500 Subject: [PATCH] Update to the latest tendermint-machine --- substrate/tendermint/client/src/authority/mod.rs | 2 +- substrate/tendermint/client/src/validators.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/substrate/tendermint/client/src/authority/mod.rs b/substrate/tendermint/client/src/authority/mod.rs index 04234262..e4972fef 100644 --- a/substrate/tendermint/client/src/authority/mod.rs +++ b/substrate/tendermint/client/src/authority/mod.rs @@ -176,7 +176,7 @@ impl TendermintAuthority { let (gossip_tx, mut gossip_rx) = mpsc::unbounded(); // Create the Tendermint machine - let TendermintHandle { mut messages, machine } = { + let TendermintHandle { mut step, mut messages, machine } = { // Set this struct as active *self.import.providers.write().await = Some(providers); self.active = Some(ActiveAuthority { diff --git a/substrate/tendermint/client/src/validators.rs b/substrate/tendermint/client/src/validators.rs index 08454638..c02a61f0 100644 --- a/substrate/tendermint/client/src/validators.rs +++ b/substrate/tendermint/client/src/validators.rs @@ -15,7 +15,7 @@ use sp_api::{BlockId, ProvideRuntimeApi}; use sc_client_api::HeaderBackend; -use tendermint_machine::ext::{BlockNumber, Round, Weights, Signer, SignatureScheme}; +use tendermint_machine::ext::{BlockNumber, RoundNumber, Weights, Signer, SignatureScheme}; use sp_tendermint::TendermintApi; @@ -186,7 +186,7 @@ impl Weights for TendermintValidators { } // TODO - fn proposer(&self, number: BlockNumber, round: Round) -> u16 { + fn proposer(&self, number: BlockNumber, round: RoundNumber) -> u16 { u16::try_from( (number.0 + u64::from(round.0)) % u64::try_from(self.0.read().unwrap().lookup.len()).unwrap(), )