Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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 federated block-signing server implementation #4
base: dvep
Are you sure you want to change the base?
Add federated block-signing server implementation #4
Changes from 1 commit
c4d3a12
cdae6ed
a93c459
daf40f3
bf079d1
0107ee1
826ca7f
79a9dcd
b3a0ab9
1da1bbb
bf28ee6
2817b6a
fef2e4e
2722026
c4500a8
910b875
0c5d845
6bb86db
cb96642
45a9dbd
8efa38a
8862190
3c70538
cbae6d7
9c375ba
ba4cc36
8cc00bc
8a98f08
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
daf40f3
Could this simply be that we are being given the same block by several federation members? I haven't gotten to the end yet, but if that is the case, we should be sure to not punish peers when this function returns
false
.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.
I don't think this particular
return false
will have any effect. Right now the only time the return value is checked is when the leader of the round checks their own block proposal. And barring hash collisions that should never trigger this code path. We don't use it for punishing peers.The check is more along the lines of "is this proposal one we're willing to sign?" And a
return false
just terminates participation in the round.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.
I modified the other call to
AcceptBlockProposal
so it checks the return value too. Since returning here (true or false) means we aren't signing the block proposal and the round terminates (for this peer), I thinkreturn false
is correct. It saves a few cycles in that case.