Rename BeaconStateTypes to EthSpec

This commit is contained in:
Paul Hauner
2019-05-10 14:47:09 +10:00
parent 75b310a078
commit ce8ebeccbc
60 changed files with 223 additions and 235 deletions

View File

@@ -7,8 +7,7 @@ use std::fs::File;
use std::io::{Error, ErrorKind};
use std::path::PathBuf;
use types::{
BeaconStateTypes, ChainSpec, FewValidatorsStateTypes, FoundationStateTypes,
LighthouseTestnetStateTypes,
ChainSpec, EthSpec, FewValidatorsEthSpec, FoundationEthSpec, LighthouseTestnetEthSpec,
};
/// Stores the core configuration for this validator instance.
@@ -34,7 +33,7 @@ impl Default for Config {
let server = "localhost:5051".to_string();
let spec = FoundationStateTypes::spec();
let spec = FoundationEthSpec::spec();
Self {
data_dir,
@@ -68,9 +67,9 @@ impl Config {
if let Some(spec_str) = args.value_of("spec") {
info!(log, "Using custom spec: {:?}", spec_str);
config.spec = match spec_str {
"foundation" => FoundationStateTypes::spec(),
"few_validators" => FewValidatorsStateTypes::spec(),
"lighthouse_testnet" => LighthouseTestnetStateTypes::spec(),
"foundation" => FoundationEthSpec::spec(),
"few_validators" => FewValidatorsEthSpec::spec(),
"lighthouse_testnet" => LighthouseTestnetEthSpec::spec(),
// Should be impossible due to clap's `possible_values(..)` function.
_ => unreachable!(),
};