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

fix: separate out validators who are awaiting activation queue #124

Merged
merged 1 commit into from
Aug 9, 2024

Conversation

wadealexc
Copy link
Contributor

@wadealexc wadealexc commented Aug 9, 2024

@jbrower95 jbrower95 self-requested a review August 9, 2024 14:42
@wadealexc
Copy link
Contributor Author

image

simulated what this looks like for the status command

Copy link
Contributor

@jbrower95 jbrower95 left a comment

Choose a reason for hiding this comment

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

Since this changes "status", just need to see that what the web app reports is similar to this

@wadealexc
Copy link
Contributor Author

This also changes credentials - credentials is fetching different validators now.

@@ -197,7 +201,7 @@ func SortByStatus(validators map[string]Validator) ([]Validator, []Validator, []
return withdrawnValidators[i].Index < withdrawnValidators[j].Index
})

return inactiveValidators, activeValidators, withdrawnValidators
return awaitingActivationQueueValidators, inactiveValidators, activeValidators, withdrawnValidators
Copy link
Contributor

Choose a reason for hiding this comment

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

if you're gonna add a new return group to this function signature, i would probably put it at the end right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

i was going for "lifecycle" here, since the left-most validators would occur earliest and then progress left to right

@@ -444,7 +466,8 @@ func SelectAwaitingCredentialValidators(
validatorInfo := validatorInfos[i]

if (validatorInfo.Status == ValidatorStatusInactive) &&
(validator.Validator.ExitEpoch == FAR_FUTURE_EPOCH) {
(validator.Validator.ExitEpoch == FAR_FUTURE_EPOCH) &&
(validator.Validator.ActivationEpoch != FAR_FUTURE_EPOCH) {
Copy link
Contributor

Choose a reason for hiding this comment

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

this is the actual change, yeah?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes

@wadealexc wadealexc merged commit 6a48990 into master Aug 9, 2024
3 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