From 983d931a8379b9955c7d38059627ea7279501f47 Mon Sep 17 00:00:00 2001 From: Viktor Kirilov Date: Wed, 5 Aug 2020 13:55:28 +0300 Subject: [PATCH] initializing the pubkeys properly in the rest of the places for the BN/VC communication to work --- beacon_chain/eth2_json_rpc_serialization.nim | 2 +- beacon_chain/validator_client.nim | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/beacon_chain/eth2_json_rpc_serialization.nim b/beacon_chain/eth2_json_rpc_serialization.nim index ad6045ad1..7a128c76a 100644 --- a/beacon_chain/eth2_json_rpc_serialization.nim +++ b/beacon_chain/eth2_json_rpc_serialization.nim @@ -11,7 +11,7 @@ import proc fromJson*(n: JsonNode, argName: string, result: var ValidatorPubKey) = n.kind.expect(JString, argName) - result = ValidatorPubKey.fromHex(n.getStr()).tryGet() + result = ValidatorPubKey.fromHex(n.getStr()).tryGet().initPubKey() proc `%`*(pubkey: ValidatorPubKey): JsonNode = result = newJString($initPubKey(pubkey)) diff --git a/beacon_chain/validator_client.nim b/beacon_chain/validator_client.nim index 763ed7096..48f6875ba 100644 --- a/beacon_chain/validator_client.nim +++ b/beacon_chain/validator_client.nim @@ -215,7 +215,7 @@ programMain: # load all the validators from the data dir into memory for curr in vc.config.validatorKeys: - vc.attachedValidators.addLocalValidator(curr.toPubKey, curr) + vc.attachedValidators.addLocalValidator(curr.toPubKey.initPubKey, curr) waitFor vc.client.connect($vc.config.rpcAddress, Port(vc.config.rpcPort)) info "Connected to BN",