mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-09 03:31:45 +00:00
Use head state for exit verification (#4183)
## Issue Addressed NA ## Proposed Changes Similar to #4181 but without the version bump and a more nuanced fix. Patches the high CPU usage seen after the Capella fork which was caused by processing exits when there are skip slots. ## Additional Info ~~This is an imperfect solution that will cause us to drop some exits at the fork boundary. This is tracked at #4184.~~
This commit is contained in:
@@ -497,7 +497,8 @@ impl<T: EthSpec> OperationPool<T> {
|
||||
|exit| {
|
||||
filter(exit.as_inner())
|
||||
&& exit.signature_is_still_valid(&state.fork())
|
||||
&& verify_exit(state, exit.as_inner(), VerifySignatures::False, spec).is_ok()
|
||||
&& verify_exit(state, None, exit.as_inner(), VerifySignatures::False, spec)
|
||||
.is_ok()
|
||||
},
|
||||
|exit| exit.as_inner().clone(),
|
||||
T::MaxVoluntaryExits::to_usize(),
|
||||
|
||||
Reference in New Issue
Block a user