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

test: integration with slashingRegistryCoordinator #388

Open
wants to merge 8 commits into
base: test/slashing-release
Choose a base branch
from

Conversation

8sunyuan
Copy link
Collaborator

@8sunyuan 8sunyuan commented Feb 7, 2025

Edge case fixed:
The AllocationManager has a try/catch in the deregisterFromOperatorSets implementation. This was put in place to allow operators to force deregister from an AVS. However this can lead to a weird state where an operator is registered in AVS contracts but deregistered from EigenLayer. Checks for this are added for forceDeregistration by the AVS to avoid reverts. In addition, AVSSync (updateOperatorsForQuorum, updateOperator) will now also include these operators to be force deregistered.

Refactored integration tests to only use the SlashingRegistryCoordinator and defines a OperatorSetUser contract.
The SlashingRegistryCoordinator and the Registry contracts do not depend on the ServiceManager base contract.
Interactions with the core protocol are integrated with UAM and setting the avsAccountIdentifier as the unique account identifier address for the AVS. For existing AVSs, this will be the address of your ServiceManager contract.

Note that integration tests with the RegistryCoordinator and legacy quorums will require some fork integration testing refactor and testing the legacy interfaces. This is still a TODO that should be added.

stakeRegistry.updateOperatorsStake(operators, operatorIds, quorumNumber);
for (uint256 j = 0; j < operators.length; ++j) {
// whether the operator is registered in the core EigenLayer contract AllocationManager
bool registeredInCore = allocationManager.isMemberOfOperatorSet(
Copy link
Contributor

Choose a reason for hiding this comment

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

only do this call if it's an m2 quorum imo

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