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

FEAT: eject operator #105

Merged
merged 4 commits into from
May 17, 2024
Merged

FEAT: eject operator #105

merged 4 commits into from
May 17, 2024

Conversation

ChainDev931105
Copy link
Contributor

Context

Closes: #104


Reviewers

@ChainDev931105 ChainDev931105 requested a review from a team May 16, 2024 21:02
@@ -124,6 +130,13 @@ contract LagrangeService is Initializable, OwnableUpgradeable, ILagrangeService
emit OperatorDeregistered(_operator);
}

/// Owner can eject the operator from the service.
/// note This function is available only on testnet.
function ejectOperator(address operator) external onlyOwner onlyTestnet {
Copy link
Contributor

Choose a reason for hiding this comment

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

please update the function name like unsubscribeByAdmin, the chainID should be indicated


modifier onlyWhitelisted() {
require(operatorWhitelist[msg.sender], "Operator is not whitelisted");
_;
}

modifier onlyTestnet() {
Copy link
Contributor

Choose a reason for hiding this comment

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

onlyHoleskyTestnet, for the strict match

@@ -91,6 +91,14 @@ contract LagrangeCommittee is Initializable, OwnableUpgradeable, ILagrangeCommit
delete operatorsStatus[operator];
}

// Unsubscribe chain by admin
function unsubscribeByAdmin(address operator, uint32 chainID) external onlyService {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
function unsubscribeByAdmin(address operator, uint32 chainID) external onlyService {
function unsubscribeByAdmin(address[] operators, uint32 chainID) external onlyService {

@ChainDev931105 ChainDev931105 merged commit 0efe7ad into develop May 17, 2024
3 checks passed
@ChainDev931105 ChainDev931105 deleted the feat/op_eject branch May 17, 2024 19:31
ChainDev931105 added a commit that referenced this pull request Jul 30, 2024
* fix: clean up and add LICENSE (#78)

* clean up code

* clean build

* update license

* add audit reports

* fix committee.test.js (#79)

* revert epoch (#85)

* adjust operator count (#84)

* add workflow (#89)

* feat: update the BLS key and signer address (#88)

* allow to update the bls keys and signer address

* add tests

---------

Co-authored-by: Master Engineer <104206186+mastereng12@users.noreply.github.com>

* FEAT: Allow to update epoch period (#93)

* epoch_modifi draft

* update epoch formula

* fix reviewed issues

* fix reviewed issues

* fix naming of getEpochNumber

* epoch period modify unit test (#97)

* CHORE: Epoch period modify simulation (#98)

* simulation test for epoch period modify

* fix issue in redeloy script

* format

* fix: avoid to remove all bls pub keys (#102)

* fix the remove bls keys

* more tests

* Workflow with solhint (#101)

* solhint cli

* update solhint checkpoints

* Update contracts/protocol/VoteWeigher.sol

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

---------

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

* FEAT: eject operator (#105)

* feat eject operator

* fix reviewed errors

* strengthen test

* unsubscribe multiple operators

* FEAT: Deploy to Sepolia (#106)

* deploy sepolia

* testnet deploy script

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

* add eigen sepolia addresses

---------

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

* add fork test for rotate and revert (#107)

* Docker workflow (#109)

* push-docker yml

* add permission makefile

* push-docker-test

* install forge build

* remove test yml

* CHORE: Script for register chain (#108)

* add register chain script

* update epoch period

* update min/max weight

* update genersis block

* add basescript

* script eject op

* [FIX] Register operator sleep (#110)

* fix register-operator sleep

* remove test yml

* archive mode geth (#112)

* fix: geth docker cmd (#113)

* archive mode geth

* fix

* [Fix] audited issues (#115)

* fix audit issues

* add audit report

* Make epoch period flexible (#118)

* epoch period flexible

* test for epoch period flex

* add simulation test for flex period

* fix epoch period for prior blocks

* flow auto release (#127)

* add issue templates (#130)

* Script - Transfer ownership (#121)

* forge install: safe-smart-account

499b17ad0191b575fcadc5cb5b8e3faeae5391ae

* script transfer ownership

* Override for testnet committee - L1 Block Number (#123)

* testnet l1bias override

* fix annoying function naming

* feat: bls key ownership check (#138)

* bls key ownership check

* unit test & inherit checker

* optimize epoch number search

* fork test bls own check

* update storage hash

---------

Co-authored-by: ChainDev931105 <ethanackerland@gmail.com>

* epic sequencer bls key (#140)

* Revert "epic sequencer bls key (#140)" (#141)

This reverts commit 1e57449.

* fix deploy-register (#142)

* fix

* [FIX] Audit Issues - Main (#149)

* Update README.md (#136)

* [FIX] script redeploy testnet (#144)

* fix script redeploy testnet

* fix get_updated_l1_block

* solc version 0.8.20, blsKeyChecker issue

* digest hash add version field

* hardhat solidity version update

---------

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

---------

Co-authored-by: Master Engineer <104206186+mastereng12@users.noreply.github.com>
Co-authored-by: ChainDev <76214877+ChainDev931105@users.noreply.github.com>
Co-authored-by: Kashish Shah <kashish@lagrange.dev>
Co-authored-by: ChainDev931105 <ethanackerland@gmail.com>
ChainDev931105 added a commit that referenced this pull request Aug 26, 2024
* fix: clean up and add LICENSE (#78)

* clean up code

* clean build

* update license

* add audit reports

* fix committee.test.js (#79)

* revert epoch (#85)

* adjust operator count (#84)

* add workflow (#89)

* feat: update the BLS key and signer address (#88)

* allow to update the bls keys and signer address

* add tests

---------

Co-authored-by: Master Engineer <104206186+mastereng12@users.noreply.github.com>

* FEAT: Allow to update epoch period (#93)

* epoch_modifi draft

* update epoch formula

* fix reviewed issues

* fix reviewed issues

* fix naming of getEpochNumber

* epoch period modify unit test (#97)

* CHORE: Epoch period modify simulation (#98)

* simulation test for epoch period modify

* fix issue in redeloy script

* format

* fix: avoid to remove all bls pub keys (#102)

* fix the remove bls keys

* more tests

* Workflow with solhint (#101)

* solhint cli

* update solhint checkpoints

* Update contracts/protocol/VoteWeigher.sol

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

---------

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

* FEAT: eject operator (#105)

* feat eject operator

* fix reviewed errors

* strengthen test

* unsubscribe multiple operators

* FEAT: Deploy to Sepolia (#106)

* deploy sepolia

* testnet deploy script

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

* add eigen sepolia addresses

---------

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>

* add fork test for rotate and revert (#107)

* Docker workflow (#109)

* push-docker yml

* add permission makefile

* push-docker-test

* install forge build

* remove test yml

* CHORE: Script for register chain (#108)

* add register chain script

* update epoch period

* update min/max weight

* update genersis block

* add basescript

* script eject op

* [FIX] Register operator sleep (#110)

* fix register-operator sleep

* remove test yml

* archive mode geth (#112)

* fix: geth docker cmd (#113)

* archive mode geth

* fix

* [Fix] audited issues (#115)

* fix audit issues

* add audit report

* Make epoch period flexible (#118)

* epoch period flexible

* test for epoch period flex

* add simulation test for flex period

* fix epoch period for prior blocks

* flow auto release (#127)

* add issue templates (#130)

* Script - Transfer ownership (#121)

* forge install: safe-smart-account

499b17ad0191b575fcadc5cb5b8e3faeae5391ae

* script transfer ownership

* Override for testnet committee - L1 Block Number (#123)

* testnet l1bias override

* fix annoying function naming

* feat: bls key ownership check (#138)

* bls key ownership check

* unit test & inherit checker

* optimize epoch number search

* fork test bls own check

* update storage hash

---------

Co-authored-by: ChainDev931105 <ethanackerland@gmail.com>

* epic sequencer bls key (#140)

* Revert "epic sequencer bls key (#140)" (#141)

This reverts commit 1e57449.

* fix deploy-register (#142)

* update readme

---------

Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com>
Co-authored-by: Master Engineer <104206186+mastereng12@users.noreply.github.com>
Co-authored-by: Kashish Shah <kashish@lagrange.dev>
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.

Implement the operator ejection feature by admin for only testnet
2 participants