Update validator_client for spec v0.2.0

This commit is contained in:
Paul Hauner 2019-02-12 12:57:17 +11:00
parent cb97870c15
commit 5e37e8a33a
No known key found for this signature in database
GPG Key ID: D362883A9218FCC6
2 changed files with 6 additions and 6 deletions

View File

@ -65,11 +65,8 @@ impl BeaconNode for BeaconBlockGrpcClient {
signature,
body: BeaconBlockBody {
proposer_slashings: vec![],
casper_slashings: vec![],
attester_slashings: vec![],
attestations: vec![],
custody_reseeds: vec![],
custody_challenges: vec![],
custody_responses: vec![],
deposits: vec![],
exits: vec![],
},

View File

@ -88,9 +88,12 @@ fn main() {
let spec = Arc::new(ChainSpec::foundation());
// Clock for determining the present slot.
// TODO: this shouldn't be a static time, instead it should be pulled from the beacon node.
// https://github.com/sigp/lighthouse/issues/160
let genesis_time = 1_549_935_547;
let slot_clock = {
info!(log, "Genesis time"; "unix_epoch_seconds" => spec.genesis_time);
let clock = SystemTimeSlotClock::new(spec.genesis_time, spec.slot_duration)
info!(log, "Genesis time"; "unix_epoch_seconds" => genesis_time);
let clock = SystemTimeSlotClock::new(genesis_time, spec.slot_duration)
.expect("Unable to instantiate SystemTimeSlotClock.");
Arc::new(clock)
};