This repository has been archived by the owner on May 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 23
Close keep when seizing signer bonds #259
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
We can use this flag to inspect keeps the client is attached to in case the client did not receive an event - temporary network glitch etc
Seizing signer bonds closes keep so that it does no longer respond to sign requests. This implicates another change - seizing bonds is not possible when signing is still in progress and it hasn't timed out yet.
We call markAsClosed from other keep contract functions, not closeKeep
nkuba
suggested changes
Feb 28, 2020
Comment on lines
382
to
383
freeMembersBonds(); | ||
markAsClosed(); |
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.
Maybe we should change the order of these two? markAsClosed
has current status verification.
markAsClosed();
freeMembersBonds();
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 was switching them back and forward, could not decide on which order is better 😆
There is no difference in terms of functionality but this order can be clearer from the code perspective - markAsClose contains the verifications that no signing is currently in progress; also, we have the same order when we seize member bonds.
@nkuba Ready! |
dimpar
reviewed
Mar 2, 2020
dimpar
approved these changes
Mar 2, 2020
nkuba
approved these changes
Mar 2, 2020
4 tasks
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Closes: #236
Refs: #237
When signer bonds are seized, keep is automatically closed and it will no longer respond to signing requests.
close
function has been exposed onIBondedECDSAKeep
interface. I have also changedisActive
flag frominternal
topublic
- it may be helpful to evaluate if the client should unsubscribe from keep events in case it lost keep closed event because of a temporary network/subscription glitch.