From 3cfefca50159296cc20748b5c97a1f61db13a31a Mon Sep 17 00:00:00 2001 From: Tumas Date: Tue, 2 Apr 2024 11:50:45 +0300 Subject: [PATCH] Use head state in validator API #8 Computing the preprocessed state fails when the app is freshly started and has too many empty slots, preventing it from signing voluntary exits. This necessitates changing the signing process to use the head instead of the preprocessed state. --- validator/src/api.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/validator/src/api.rs b/validator/src/api.rs index bbfcfe9e..1b547da8 100644 --- a/validator/src/api.rs +++ b/validator/src/api.rs @@ -628,7 +628,7 @@ async fn keymanager_create_voluntary_exit( EthPath(pubkey): EthPath, EthQuery(query): EthQuery, ) -> Result, Error> { - let state = controller.preprocessed_state_at_current_slot()?; + let state = controller.head_state().value; let epoch = query .epoch