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

Use signed_root For Block ID Purposes in Blocks/State - (Spec PR #816) #518

Closed
schroedingerscode opened this issue Mar 25, 2019 · 3 comments
Labels
enhancement 🕵️‍♀️ New feature or request

Comments

@schroedingerscode
Copy link
Contributor

Description

As an implementor, I want to use the signed_root function instead of hash_tree_root when calculating block root, so that block signatures are the same when producing and processing a block.

Acceptance Criteria

  • get_temporary_block_header returns a block header with signature := EMPTY_SIGNATURE.
  • cache_state uses signed_root instead of hash_tree_root of latest block header when storing the latest block roots.
  • process_block_header uses signed_root instead of hash_tree_root of latest block header when verifying the previous block root.
  • build_empty_block_for_next_slot uses signed_root instead of hash_tree_root of previous block header when storing the previous block root.

Additional Information

See ethereum/consensus-specs#816

@schroedingerscode schroedingerscode added the enhancement 🕵️‍♀️ New feature or request label Mar 25, 2019
@schroedingerscode schroedingerscode added this to the Beacon Chain v0.5.1 Spec milestone Mar 25, 2019
@schroedingerscode schroedingerscode changed the title Use signed_root For Block ID Purposes in Blocks/State Use signed_root For Block ID Purposes in Blocks/State - (Spec PR #816) Mar 27, 2019
@vitorpy
Copy link
Contributor

vitorpy commented Apr 1, 2019

Working on this.

@schroedingerscode
Copy link
Contributor Author

schroedingerscode commented Apr 1, 2019

Hey @vitorpy, it looks like this task is dependent on ethereum/consensus-specs#711, which is a task we chose not to track in Artemis. It's quite possible writing this one up was missed, because it's sandwiched between "contains no substantive changes" labels. Give me a few mins to chat with the team, and we'll get back to ya.

Update: Had a quick chat, and we will track that massive Spec 711 PR, but finishing it in its entirety will take some time, probably more than it's worth you waiting on this task. Luckily, it looks like get_temporary_block_header can exist in isolation. So if you feel like implementing that too (probably in BeaconStateUtil), then you should be able to make progress on this and everything should co-exist nicely.

As always, feel free to hit us up here or on Gitter if you have any questions. signed_root has taken on kind of a mind of its own, because all the ways to implement it in Java are terrible.

@jrhea jrhea closed this as completed May 8, 2019
@jrhea jrhea mentioned this issue May 8, 2019
26 tasks
@akhila-raju
Copy link
Contributor

build_empty_block_for_next_slot is a function created in a test class which won't be implemented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement 🕵️‍♀️ New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants