-
Notifications
You must be signed in to change notification settings - Fork 453
feat: remove semver + minor optimizations #1654
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
base: release-dev/slashing-ux-improvements
Are you sure you want to change the base?
Conversation
ProtocolRegistry + one-click pause allProtocolRegistry + remove semver
7cc2203 to
e23d5c9
Compare
ProtocolRegistry + remove semver42af1f1 to
ecc69cf
Compare
fb163fb to
54b1047
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We may not want to update the Eigen token
| import "../mixins/SemVerMixin.sol"; | ||
|
|
||
| contract Eigen is OwnableUpgradeable, ERC20VotesUpgradeable, SemVerMixin { | ||
| contract Eigen is OwnableUpgradeable, ERC20VotesUpgradeable { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we don't want to remove the Eigen semver? cc @nadir-akhtar
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes to the Eigen token aren't unthinkable (e.g. we merged in a couple event emissions earlier this year), so long as they don't impact token functionality and we inform stakeholders prior to performing the upgrade.
I would err on the side of not making the change unless there's a pressing need. But, if we want to remove it for consistency, we can entertain the option.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets discuss
fbcb025 to
d60643a
Compare
d60643a to
be7c1dc
Compare
squash feat: split alm wip wip wip wip wip wip wip unit tests passing remove extsload wip tests passing chore: git mv storage to folder wip ci docs todo cleanup ci ci rename `secondHalf` rm extsload move storage add protocol registry to zeus squash feat: split alm wip wip wip wip wip wip wip unit tests passing remove extsload wip tests passing chore: git mv storage to folder wip ci wip wip wip wip wip remove extsload wip tests passing wip passing perf: wrap modifier logic to save codesize chore: forge fmt refactor: remove semver (#1641) **Motivation:** We want to consolidate semver logic into a single purpose built contract. **Modifications:** - Removed `SemVerMixin` import from all contracts. **Result:** More codesize savings. make fmt refactor: expand `ProtocolRegistry` to list all contracts + pause rm gas snapshots rm extsload rebase
be7c1dc to
d17a568
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes to remove SemVerMixin look good from a correctness standpoint.
That said, taking a step back, I'm not sure removing SemVerMixin for the 300 bytes return is ideal. It's a strange property for some contracts to have a version attributed to them, and for others not to.
If we're to make a change here, I recommend we have some replacement, e.g. a registry with either a global protocol version or versions for each contract. That way, we don't have a strange situation where some contracts have version while others don't.
| ) external onlyWhenNotPaused(PAUSED_MODIFY_ALLOCATIONS) { | ||
| // Check that the caller is allowed to modify allocations on behalf of the operator | ||
| // We do not use a modifier to avoid `stack too deep` errors | ||
| require(_checkCanCall(operator), InvalidCaller()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Curious to know what the need for these changes to the PermissionControllerMixin and related contracts was in this PR is, as it seems unrelated to the SemVerMixin. We lose some granularity in error specification here -- not the worst situation as InvalidPermissions is fairly explanatory for a given function, but recommend we save this for a different PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
srry squashed, commit history not as useful now
Motivation:
We want to reduce codesize throughout our core contracts.
Modifications:
SemVerMixinfrom every contract that doesn't inheritSignatureUtilsMixin.Result:
~300 bytes of codesize saved per contract.