Skip to content

Conversation

petarjuki7
Copy link
Member

Issue Addressed

#558
Makes sure if a cluster is liquidated that it doesn't get processed.

Closes #576

Copy link
Member

@dknopik dknopik left a comment

Choose a reason for hiding this comment

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

LGTM

@dknopik dknopik added ready-for-merge v1.0.0 First Mainnet-release labels Sep 8, 2025
@mergify mergify bot merged commit 1c036c8 into sigp:release-v0.3.0 Sep 8, 2025
15 checks passed
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR addresses issue #558 by filtering out liquidated clusters from validator processing to prevent liquidated clusters from being processed in validator operations.

  • Adds check for liquidated clusters in validator-cluster lookup operations
  • Introduces new error type ClusterLiquidated for handling liquidated cluster scenarios
  • Updates voting pubkeys method to filter out validators from liquidated clusters

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment on lines +808 to +809
.clusters()
.get_by(public_key)
Copy link

Copilot AI Sep 10, 2025

Choose a reason for hiding this comment

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

The get_by(public_key) call is incorrect. The clusters collection should be accessed using the cluster_id from the validator metadata, not the public key directly. This will likely fail to find clusters since public keys are not cluster identifiers.

Suggested change
.clusters()
.get_by(public_key)
.metadata()
.get_by(public_key)
.and_then(|metadata| metadata.cluster_id)
.and_then(|cluster_id| state.clusters().get_by(&cluster_id))

Copilot uses AI. Check for mistakes.

petarjuki7 added a commit to petarjuki7/anchor that referenced this pull request Sep 16, 2025
sigp#558
Makes sure if a cluster is liquidated that it doesn't get processed.

Closes sigp#576
diegomrsantos pushed a commit to diegomrsantos/anchor that referenced this pull request Sep 17, 2025
sigp#558
Makes sure if a cluster is liquidated that it doesn't get processed.

Closes sigp#576
jking-aus pushed a commit to jking-aus/anchor that referenced this pull request Oct 8, 2025
sigp#558
Makes sure if a cluster is liquidated that it doesn't get processed.

Closes sigp#576
petarjuki7 added a commit to petarjuki7/anchor that referenced this pull request Oct 16, 2025
sigp#558
Makes sure if a cluster is liquidated that it doesn't get processed.

Closes sigp#576
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-merge v1.0.0 First Mainnet-release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants