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

set current epoch based on hotshot block height #2505

Open
alysiahuggins opened this issue Jan 29, 2025 · 0 comments · May be fixed by #2510
Open

set current epoch based on hotshot block height #2505

alysiahuggins opened this issue Jan 29, 2025 · 0 comments · May be fixed by #2510
Assignees

Comments

@alysiahuggins
Copy link
Contributor

alysiahuggins commented Jan 29, 2025

The StakeTable smart contract needs to be aware of epochs (which are managed in the consensus layer).
In HotShot, 1 epoch = x hotshot blocks. Since the Light Client contract gets the latest finalized state from espresso once every 3-6 hours, we'll use that state to get the hotshotblock and then calculate the epoch in the Stake Table smart contract.

Assumptions

  • the hotshotblocks per epoch doesn't change (and when/if it changes we'll upgrade the contract)
  • the light client contract will be maintained and receive the latest state from espresso at least once a day
@alysiahuggins alysiahuggins self-assigned this Jan 29, 2025
@alysiahuggins alysiahuggins changed the title set configurable blocks per epoch set current epoch based on hotshot block height Jan 29, 2025
@alysiahuggins alysiahuggins linked a pull request Jan 30, 2025 that will close this issue
@alysiahuggins alysiahuggins linked a pull request Jan 30, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant