feat: Add version to BeaconEngineMessage FCU (#12089)

Co-authored-by: Dan Cline <6798349+Rjected@users.noreply.github.com>
This commit is contained in:
0xOsiris
2024-10-28 05:00:36 -07:00
committed by GitHub
parent 1b0f625f1d
commit 0d07d27f3c
14 changed files with 107 additions and 33 deletions

View File

@ -616,7 +616,8 @@ where
// To do this, we set the payload attrs to `None` if attribute validation failed, but
// we still apply the forkchoice update.
if let Err(err) = attr_validation_res {
let fcu_res = self.inner.beacon_consensus.fork_choice_updated(state, None).await?;
let fcu_res =
self.inner.beacon_consensus.fork_choice_updated(state, None, version).await?;
// TODO: decide if we want this branch - the FCU INVALID response might be more
// useful than the payload attributes INVALID response
if fcu_res.is_invalid() {
@ -626,7 +627,7 @@ where
}
}
Ok(self.inner.beacon_consensus.fork_choice_updated(state, payload_attrs).await?)
Ok(self.inner.beacon_consensus.fork_choice_updated(state, payload_attrs, version).await?)
}
}