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

Add more unified getters for common block properties #74

Merged
merged 3 commits into from
Sep 23, 2023

Conversation

pk910
Copy link
Contributor

@pk910 pk910 commented Sep 23, 2023

Added more unified getters for common block properties to the VersionedSignedBeaconBlock struct:

  • ProposerIndex
  • ExecutionBlockNumber
  • ExecutionTransactions
  • Graffiti
  • RandaoReveal
  • ETH1Data
  • Deposits
  • VoluntaryExits
  • BLSToExecutionChanges
  • Withdrawals
  • BlobKzgCommitments

Fixed VersionedSignedBeaconBlock.ExecutionBlockHash(), which was using the bellatrix struct regardless of the actual block type and therefore fails with a nil pointer for non-bellatrix blocks

Copy link
Contributor

@mcdee mcdee left a comment

Choose a reason for hiding this comment

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

Thank you for this; only one change requested.

}
}

func (v *VersionedSignedBeaconBlock) Graffiti() ([]byte, error) {
Copy link
Contributor

Choose a reason for hiding this comment

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

The return value should be [32]byte to match the underlying data type.

@pk910
Copy link
Contributor Author

pk910 commented Sep 23, 2023

fixed :)

@pk910 pk910 requested a review from mcdee September 23, 2023 19:17
@mcdee mcdee merged commit 813e947 into attestantio:master Sep 23, 2023
2 checks passed
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.

2 participants