-
Notifications
You must be signed in to change notification settings - Fork 144
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
Separate ticket and beacon randomness #637
Conversation
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.
LGTM
let check_for_beacon_entry = |ts: &Tipset| { | ||
let cbe = ts.blocks()[0].beacon_entries(); | ||
if let Some(entry) = cbe.last() { | ||
return Ok(Some(entry.clone())); |
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.
You could call cbe.pop()
here instead of last()
to avoid a clone
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.
it's a slice, not a vec
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.
😬
Summary of changes
Changes introduced in this pull request:
other commit not referenced in issue:
filecoin-project/lotus@ed72aa1
Reference issue to close (if applicable)
Closes #628
Other information and links