Skip to content
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

fix: publish electra attestations / aggregates through api #6759

Merged
merged 1 commit into from
May 13, 2024

Conversation

nflaig
Copy link
Member

@nflaig nflaig commented May 10, 2024

Motivation

Fixes publishing of electra attestations and aggregates through api

Description

Make publish apis fork aware to correctly de-/serialize electra attestations and aggregates.

NOTE: This is not a long-term approach we can use, a proper solution requires to add new v2 apis which are fork aware

@nflaig nflaig force-pushed the nflaig/electra-publish-apis branch from 0ed6efc to 5b7a048 Compare May 10, 2024 13:53
@nflaig nflaig marked this pull request as ready for review May 10, 2024 14:51
@nflaig nflaig requested a review from a team as a code owner May 10, 2024 14:51
};
},
parseReq: ({body, headers}) => [
ArrayOf(ssz.allForks[headers["eth-consensus-version"]].SignedAggregateAndProof).fromJson(body),
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

header must be lower case as Fastify will convert all headers to lower case, this is much better handled on the refactor branch but I think we are fine with skipping input validation here

Copy link
Contributor

@ensi321 ensi321 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ran this using Kurtosis. Everything looks good regarding submitting attestations and publishing aggregates.

@twoeths twoeths merged commit a5ee6ef into electra-fork May 13, 2024
11 of 17 checks passed
@twoeths twoeths deleted the nflaig/electra-publish-apis branch May 13, 2024 07:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants