-
Notifications
You must be signed in to change notification settings - Fork 804
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ensure GET v2/validator/aggregate_attestation
is backwards compatible
#6984
Ensure GET v2/validator/aggregate_attestation
is backwards compatible
#6984
Conversation
8ea91af
to
a57f64c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me.
I tested it by using v2 for both deneb and electra by modifying the lighthouse VC here
lighthouse/validator_client/validator_services/src/attestation_service.rs
Lines 564 to 575 in 431dd7c
beacon_node | |
.get_validator_aggregate_attestation_v2( | |
attestation_data.slot, | |
attestation_data.tree_hash_root(), | |
committee_index, | |
) | |
.await | |
.map_err(|e| { | |
format!("Failed to produce an aggregate attestation: {:?}", e) | |
})? | |
.ok_or_else(|| format!("No aggregate available for {:?}", attestation_data)) | |
.map(|result| result.data) |
It works as expected. Wondering if we v2 all across.
I think at this late stage I'm fine with sticking to v1 prior to Electra. We could consider changing this for v7.0.0 proper though |
@mergify queue |
✅ The pull request has been merged automaticallyThe pull request has been merged automatically at ed8086c |
Issue Addressed
Closes #6983
Proposed Changes
GET v2/validator/aggregate_attestation
is not backwards compatible. It only works for post electra attestations. This PR adds backwards compatibility and additional test coverage. We should include this in the upcoming 7.0 beta release if possible