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(contracts): add initial stake deposit contract #567

Merged
merged 1 commit into from
Mar 11, 2024

Conversation

kevinhalliday
Copy link
Contributor

Add initial OmniStake contract.

task: https://app.asana.com/0/1206208509925075/1206566996089588

@kevinhalliday kevinhalliday requested a review from ttarsi as a code owner March 11, 2024 21:39
require(msg.value > 1 ether, "OmniStake: deposit amt too low");
require(msg.value < type(uint64).max, "OmniStake: deposit amt too high");
emit Deposit(msg.sender, msg.value);
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Put in some reasonable checks for now. Minimum of 1 ether makes sense - we may want to go higher.
Max can be informed by consensus chain. Went with max uint64, because we use uint64 in most places.

Right now our avs uses uint96 for amounts (because this is what we get from eigen layer).

@kevinhalliday kevinhalliday merged commit 221dbf2 into main Mar 11, 2024
6 checks passed
@kevinhalliday kevinhalliday deleted the kh/omni-staking branch March 11, 2024 22:18
Zodomo added a commit that referenced this pull request Dec 20, 2024
Added _initial_ support for user stake delegation to the `Staking`
contract, and updated related Go. I also added support for delegating on
behalf of other users. The omni CLI delegate command was only updated
for the new delegate function interface, so CLI still only supports
self-delegation, for now.

It has yet to be determined what contract changes, if any, are necessary
for unstaking. This contract should not be upgraded yet until the entire
scope is known.

issue: #567
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