Skip to content

feat(l1, l2): apply fork choice even when PayloadAttributes are invalid#870

Merged
Arkenan merged 2 commits into
mainfrom
apply-fork-choice-even-with-invalid-payloads-2
Oct 16, 2024
Merged

feat(l1, l2): apply fork choice even when PayloadAttributes are invalid#870
Arkenan merged 2 commits into
mainfrom
apply-fork-choice-even-with-invalid-payloads-2

Conversation

@Arkenan

@Arkenan Arkenan commented Oct 16, 2024

Copy link
Copy Markdown
Collaborator

Changes

  • Make payload attributes a result type in the request. This allows us to represent errors in the request that will be handled.
  • handle now takes into account the possibility of payload attributes being an error, but only cares about it after fork choice has been applied.
  • The L2 client has been updated to take this into account and uses Ok(Some(attributes)) now. To the client user it will not notice the changes as the parameters of the function do not change.
  • Re-add the missing beacon block root hive test, now correctly working.

Closes #853

@Arkenan Arkenan requested a review from a team as a code owner October 16, 2024 14:32

@fkrause98 fkrause98 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM!

@Arkenan Arkenan added this pull request to the merge queue Oct 16, 2024
Merged via the queue into main with commit cd86866 Oct 16, 2024
@Arkenan Arkenan deleted the apply-fork-choice-even-with-invalid-payloads-2 branch October 16, 2024 16:50
pedrobergamini pushed a commit to pedrobergamini/ethrex that referenced this pull request Aug 24, 2025
…alid (lambdaclass#870)

Changes

- Make payload attributes a result type in the request. This allows us
to represent errors in the request that will be handled.
- `handle` now takes into account the possibility of payload attributes
being an error, but only cares about it after fork choice has been
applied.
- The L2 client has been updated to take this into account and uses
`Ok(Some(attributes))` now. To the client user it will not notice the
changes as the parameters of the function do not change.
- Re-add the missing beacon block root hive test, now correctly working.

Closes lambdaclass#853
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.

Fork choice should still be applied when payload attributes are invalid

2 participants