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

Save GenesisValidatorsRoot from WaitForChainStart #7855

Merged
merged 7 commits into from
Nov 20, 2020

Conversation

0xKiwi
Copy link
Contributor

@0xKiwi 0xKiwi commented Nov 18, 2020

What type of PR is this?
Feature change

What does this PR do? Why is it needed?
This PR adds GenesisValidatorsRoot and SaveGenesisValidatorsRoot to the DB. It also changes WaitForChainStart to save the received GenesisValidatorsRoot to DB.

@0xKiwi 0xKiwi requested a review from a team as a code owner November 18, 2020 19:30
bkt := tx.Bucket(genesisInfoBucket)
enc := bkt.Get(genesisValidatorsRootKey)
if len(enc) != 0 {
return fmt.Errorf("cannot overwite existing genesis validators root: %#x", enc)
Copy link
Contributor

@shayzluf shayzluf Nov 18, 2020

Choose a reason for hiding this comment

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

i think it should be fatal log as well

Copy link
Contributor

Choose a reason for hiding this comment

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

The fatal log should be by the caller of this function

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Ready For Review A pull request ready for code review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants