Skip to content

Validator client HTTP API wouldn't start without a beacon node #5019

Open
@chong-he

Description

@chong-he

Description

Starting lighthouse vc –http alone wouldn’t start the validator client HTTP API. HTTP API queries will get connection refused.

Once lighthouse bn –http is started, only then the validator client logs INFO HTTP API started and HTTP API queries works. If the bn is stopped afterwards, the validator client HTTP API calls still work.

From @michaelsproul, the reason being that the validator client waits to fetch genesis from the BN on start-up here:

// Perform some potentially long-running initialization tasks.
let (genesis_time, genesis_validators_root) = tokio::select! {
tuple = init_from_beacon_node(&beacon_nodes, &proposer_nodes, &context) => tuple?,
() = context.executor.exit() => return Err("Shutting down".to_string())
};

Version

Lighthouse v4.5.0-441fc16

Present Behaviour

Starting lighthouse vc –http alone wouldn’t start the validator client HTTP API

Expected Behaviour

Starting lighthouse vc –http alone should start the validator client HTTP API

Steps to resolve

From @michaelsproul, a possible solution is to refactor that so that the validator client just gets those values (or from the hardcoded genesis state in the network config)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions