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

Do not process block validation responses for the wrong reward cycle #5612

Merged
merged 3 commits into from
Dec 23, 2024

Conversation

jferrant
Copy link
Collaborator

@jferrant jferrant commented Dec 23, 2024

@obycode discovered that the recent stall was due to the WRONG signer (one from prior reward cycle) processing a block validation response and attempting to broadcast when it thought it had enough signatures. The block proposal itself was already reward cycle gated but not the block validationr esponse. This caused some inifite looping in a signer that tried to broadcast a signed block that met its own reward cycle threshold but not the actual reward cycle threshold of the current reward cycle.

This should be fixed in the event parity check but that would require changes to the node. This is just a hotfix for the signers only.

This only became an issue now because of a change I made to the signer db: we no longer query the db based on reward_cycle (this never was a problem before because when we would go to query for a block using its signer signature hash, we would also pass in our own reward cycle. This would then never return a matching block info and then the block validation request would not apply)

Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
obycode
obycode previously approved these changes Dec 23, 2024
Copy link
Contributor

@obycode obycode left a comment

Choose a reason for hiding this comment

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

LGTM!

Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
Copy link
Contributor

@obycode obycode left a comment

Choose a reason for hiding this comment

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

👍

@wileyj wileyj merged commit eb86527 into master Dec 23, 2024
1 check passed
@blockstack-devops
Copy link
Contributor

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@stacks-network stacks-network locked as resolved and limited conversation to collaborators Dec 31, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants