lighthouse icon indicating copy to clipboard operation
lighthouse copied to clipboard

Add `--exit-epoch` flag to validator-manager

Open xenowits opened this issue 2 years ago • 7 comments

Description

This is a feature request to add an --exit-epoch flag to the lighthouse account validator exit command.

This feature allows the user to set a specific epoch for the voluntary exit. It is supported by other validator clients such as teku, lodestar and nimbus.

Version

None.

Present Behaviour

Currently, a user can't specify the desired epoch to exit and the lighthouse VC broadcasts exit message with the current epoch.

Expected Behaviour

The validator client should allow a user to set a desired exit epoch.

Steps to resolve

  • Add a new flag --exit-epoch to https://github.com/sigp/lighthouse/blob/stable/account_manager/src/validator/exit.rs.
  • Modify publish_voluntary_exit() function to use the epoch provided above (if any).

xenowits avatar May 17 '23 15:05 xenowits

@xenowits As a workaround, try using the keymanager API for exits: https://ethereum.github.io/keymanager-APIs/?urls.primaryName=dev#/Voluntary%20Exit/signVoluntaryExit

Info on setting up the Lighthouse VC API can be found here: https://lighthouse-book.sigmaprime.io/api-vc.html

michaelsproul avatar May 17 '23 23:05 michaelsproul

This may also be already implemented by https://github.com/sigp/lighthouse/pull/3502, I'm not sure.

michaelsproul avatar May 17 '23 23:05 michaelsproul

This may also be already implemented by https://github.com/sigp/lighthouse/pull/3502, I'm not sure.

Thanks for the workaround!

But, do you think it is feasible to introduce this feature or are there some limitations?

xenowits avatar May 18 '23 04:05 xenowits

@xenowits It's definitely feasible. The lighthouse validator-manager is a new CLI that uses the API, so it would be super easy to include it there. We could also add it to the existing CLI easily enough, but would probably move people towards the validator-manager long term.

michaelsproul avatar May 18 '23 04:05 michaelsproul

okay, so the validator-manager is a new CLI feature that is not yet released i suppose?

Yeah, this subcommand would be cool to use for exits then 👍

xenowits avatar May 18 '23 07:05 xenowits

@michaelsproul is the lighthouse validator-manager command released?

xenowits avatar Jun 14 '23 12:06 xenowits

No, not yet. The PR hasn't merged to unstable yet

michaelsproul avatar Jun 14 '23 12:06 michaelsproul

Specifying --exit-epoch is now available using the lighthouse vm exit command: https://lighthouse-book.sigmaprime.io/validator_manager_api.html#exit

Added in #6612

chong-he avatar Jul 01 '25 03:07 chong-he