-
Notifications
You must be signed in to change notification settings - Fork 998
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
release v0.7.1
#1176
release v0.7.1
#1176
Conversation
Fix #1146 block state root issue
Bls G2 padding issue
Fuzzing utilities package / SSZ decoding for spec
generate coverage reports in make test, open as html site
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The block state-roots are fixed now, but for review I went through all of it again, and think it's better to not rely on the zero-values for 1 special case: when we overwrite the latest-header, we also implicitly change the state-root to zero. And then there is an undocumented dependency where the next process_slot
has to be the very first thing to touch the state, as it hashes it to produce the state-root to put into latest-header. Also, there is a zero-check, but it's not incorrect to not overwrite when it's non-zero. Instead, it should be equal. All in all correct, and we can just merge v0.7.1, but it could be cleaner. What do you think @JustinDrake, would you like to pick this up?
@@ -23,3 +26,13 @@ def get_state_root(spec, state, slot) -> bytes: | |||
""" | |||
assert slot < state.slot <= slot + spec.SLOTS_PER_HISTORICAL_ROOT | |||
return state.latest_state_roots[slot % spec.SLOTS_PER_HISTORICAL_ROOT] | |||
|
|||
|
|||
def state_transition_and_sign_block(spec, state, block): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Verified we are not outputting any blocks in the tests not produced by this function. appyl_empty_block
is not used for output anywhere. But we may want to remove its return in the future, so we don't accidentally get a block with faulty state root in there.
@@ -2,3 +2,4 @@ | |||
pytest>=3.6,<3.7 | |||
../config_helpers | |||
flake8==3.7.7 | |||
pytest-cov |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yay for coverage reports. Don't forget to make install_test
to enable it. Good for changelog.
A few critical fixes:
state_root
in blocks in tests (Invalid sanity test block state root #1146)Additional changes: