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

Implement TreeHash for Option #8

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

macladson
Copy link
Member

As far as I know, there is no standardized way of implementing Optional values in SSZ.
This will change with The Verge as the current spec uses optional values. The exact specification has not been agreed upon however the current Kaustinen testnet is using Union[None, T].

Another method which could be considered is: https://eips.ethereum.org/EIPS/eip-6475

This PR implements TreeHash for Option<T> using the Union[None, T] method.

There is no expectation of this PR in its current state being merged, although it is here as a reference as this feature will be necessary at some point in the future.

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.

1 participant