mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-12 13:31:10 +00:00
Fix tracking validator set in ImOnline (#3596)
* Use session::validators instead of staking::current_elected * Basic test framework. * Initialize validators, attempt to heartbeat. * Use dummy crypto for im-online testing. * Remove printlns. * Finish test, make it invalid. * Add reporting test. * Finalize the test. * Remove dumbness. * Updates. * Update AuRa * Update srml/im-online/src/tests.rs Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com> * Derive Ord * Add some more tests. * Remove stray todo. * Bump runtime version. * Bump impl-trait-for-tuples. * Enforce new version of trait-for-tuples.
This commit is contained in:
committed by
Gavin Wood
parent
a7f35680b4
commit
b7c6bc1ed5
@@ -269,7 +269,7 @@ use sr_primitives::traits::{
|
||||
};
|
||||
use phragmen::{elect, equalize, Support, SupportMap, ExtendedBalance, ACCURACY};
|
||||
use sr_staking_primitives::{
|
||||
SessionIndex, CurrentElectedSet,
|
||||
SessionIndex,
|
||||
offence::{OnOffenceHandler, OffenceDetails, Offence, ReportOffence},
|
||||
};
|
||||
#[cfg(feature = "std")]
|
||||
@@ -1586,12 +1586,3 @@ impl<T, Reporter, Offender, R, O> ReportOffence<Reporter, Offender, O>
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns the currently elected validator set represented by their stash accounts.
|
||||
pub struct CurrentElectedStashAccounts<T>(rstd::marker::PhantomData<T>);
|
||||
|
||||
impl<T: Trait> CurrentElectedSet<T::AccountId> for CurrentElectedStashAccounts<T> {
|
||||
fn current_elected_set() -> Vec<T::AccountId> {
|
||||
<Module<T>>::current_elected()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user