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

fixing SSE payloads #12154

Merged
merged 20 commits into from
Mar 17, 2023
Merged

fixing SSE payloads #12154

merged 20 commits into from
Mar 17, 2023

Conversation

james-prysm
Copy link
Contributor

@james-prysm james-prysm commented Mar 17, 2023

What type of PR is this?

Bug fix

What does this PR do? Why is it needed?

fixes the missed json type casing on data
will also send the head information on missed slots

Which issues(s) does this PR fix?

Fixes #12153

related to #12102

@james-prysm james-prysm marked this pull request as ready for review March 17, 2023 16:01
@james-prysm james-prysm requested a review from a team as a code owner March 17, 2023 16:01
terencechain
terencechain previously approved these changes Mar 17, 2023
if !ok {
return nil
}
if err := s.streamPayloadAttributes(stream, emitSlot); err != nil {
Copy link
Member

Choose a reason for hiding this comment

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

Nice! another option is to do s.CurrentSlot() from one of the fetcher. This is fine too

terencechain
terencechain previously approved these changes Mar 17, 2023
@terencechain terencechain added V4 Priority: High High priority item Ready For Review A pull request ready for code review labels Mar 17, 2023
terencechain
terencechain previously approved these changes Mar 17, 2023
terencechain
terencechain previously approved these changes Mar 17, 2023
@@ -250,8 +259,14 @@ func (s *Server) handleStateEvents(

// streamPayloadAttributes on new head event.
// This event stream is intended to be used by builders and relays.
// parent_ fields are based on state at N_{current_slot}, while the rest of fields are based on state of N_{current_slot + 1}
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
// parent_ fields are based on state at N_{current_slot}, while the rest of fields are based on state of N_{current_slot + 1}
// parent_ fields are based on state at N_{current_slot}, while the rest of the fields are based on state at N_{current_slot + 1}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Will make note and hopefully fix in another PR don't want to block this one and retrigger CI/CD for comments.

@james-prysm james-prysm merged commit 67595d5 into develop Mar 17, 2023
@delete-merged-branch delete-merged-branch bot deleted the fixing-sse-payload-attributes branch March 17, 2023 19:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: High High priority item Ready For Review A pull request ready for code review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

payload_attributes SSE event implementation incomplete
3 participants