-
Notifications
You must be signed in to change notification settings - Fork 702
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
Drop Pending Stakers 1 - introduced ScheduledStaker txs #2323
Changes from 35 commits
6079eb0
c6736b6
944f309
0106d75
9a9897c
d17f2a2
4c4c011
905e55e
89094cd
5dd8dd8
698af90
0c631c6
c3e3670
9606b77
ce87dea
fd33fde
6ea5add
b820cae
8260546
73d5c2f
84321ef
c353c33
d296e52
9bd9d60
a99a5f7
c07e2c8
5bb301b
e6463b7
43839ee
15d7871
5e10688
0e40da4
a5b3875
a7daf81
fb85fe1
bfc29a1
9b97b59
0684a8a
d914f34
89ce3c2
fa9269c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,8 @@ import ( | |
) | ||
|
||
var ( | ||
_ DelegatorTx = (*AddDelegatorTx)(nil) | ||
_ DelegatorTx = (*AddDelegatorTx)(nil) | ||
_ ScheduledStaker = (*AddDelegatorTx)(nil) | ||
Comment on lines
+22
to
+23
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. no change to existing tx format |
||
|
||
errDelegatorWeightMismatch = errors.New("delegator weight is not equal to total stake weight") | ||
errStakeMustBeAVAX = errors.New("stake must be AVAX") | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -48,9 +48,13 @@ type Staker interface { | |
// PublicKey returns the BLS public key registered by this transaction. If | ||
// there was no key registered by this transaction, it will return false. | ||
PublicKey() (*bls.PublicKey, bool, error) | ||
StartTime() time.Time | ||
EndTime() time.Time | ||
Weight() uint64 | ||
PendingPriority() Priority | ||
CurrentPriority() Priority | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This could probably could be renamed Priority() instead of current priority. But I'd wait for that to keep PR scope small |
||
} | ||
|
||
type ScheduledStaker interface { | ||
Staker | ||
StartTime() time.Time | ||
PendingPriority() Priority | ||
} | ||
Comment on lines
+56
to
+60
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is the main change of the PR, the rest is just unlocking compilation + small nits |
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.
in next PR we'll change the signature of this function to use txs.Staker instead of txs.ScheduledStaker.