Updates to elections-phragmen and some runtime docs. (#3940)

* minor changes

* Refactors for phragmen-election

* Bump.

* Fix genesis stuff

* Fix rest of the errors
This commit is contained in:
Kian Paimani
2019-10-28 15:29:53 +01:00
committed by Gavin Wood
parent fbe9cfad46
commit 9b1dd268bf
9 changed files with 300 additions and 196 deletions
+4 -10
View File
@@ -20,12 +20,12 @@ use chain_spec::ChainSpecExtension;
use primitives::{Pair, Public, crypto::UncheckedInto, sr25519};
use serde::{Serialize, Deserialize};
use node_runtime::{
BabeConfig, BalancesConfig, ContractsConfig, CouncilConfig, DemocracyConfig, ElectionsConfig, GrandpaConfig,
ImOnlineConfig, IndicesConfig, SessionConfig, SessionKeys, StakerStatus, StakingConfig, SudoConfig, SystemConfig,
TechnicalCommitteeConfig, WASM_BINARY,
BabeConfig, BalancesConfig, ContractsConfig, CouncilConfig, DemocracyConfig, GrandpaConfig,
ImOnlineConfig, IndicesConfig, SessionConfig, SessionKeys, StakerStatus, StakingConfig,
SudoConfig, SystemConfig, TechnicalCommitteeConfig, WASM_BINARY,
};
use node_runtime::Block;
use node_runtime::constants::{time::*, currency::*};
use node_runtime::constants::currency::*;
use substrate_service;
use hex_literal::hex;
use substrate_telemetry::TelemetryEndpoints;
@@ -243,12 +243,6 @@ pub fn testnet_genesis(
members: vec![],
phantom: Default::default(),
}),
elections_phragmen: Some(ElectionsConfig {
members: endowed_accounts.iter().take(2).cloned().collect(),
term_duration: 28 * DAYS,
desired_members: 4,
desired_runners_up: 1,
}),
contracts: Some(ContractsConfig {
current_schedule: contracts::Schedule {
enable_println, // this should only be enabled on development chains