-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[Bug] No constant BLOCK_TIME
with Bullshark
#2427
Comments
This is a known concept of our BFT protocol, as blocks time can't necessarily be fixed due to the inherent properties of certificate generation and commits. These rewards are based on estimates and are not necessarily required to be exactly matching with the observed network block times. In addition, we already have a concept of minimum block times (based on minimum elapsed timestamp between certificates), that we can tune to ensure blocks aren't generated too quickly. |
@raychu86 The I would suggest (as described in HackerOne report 2315260):
In this way, we can keep the |
Update: We are still tracking this issue and plan to run some additional modeling/testing before implementing a change (if a change is deemed necessary). |
https://hackerone.com/reports/2315256
Summary:
In Bullshark the commit interval is not guaranteed. However,
BLOCK_TIME
is defined as10
in SnarkVM.Proof-of-Concept (PoC)
In Bullshark, the commit interval is not guaranteed:
This means that the commit interval in Bullshark is not constant. Therefore, the real block_interval may vary.
It means that we cannot directly calculate block height from a timestamp. This has a direct impact on calculating
coinbase_reward
inanchor_block_reward_at_height
function. It seems thatBLOCK_TIME
should be removed.Impact
In
anchor_block_reward_at_height
function. We calculateblock_height_at_year_10
using the definedBLOCK_TIME
:However, the real block time is unstable and unpredictable. We originally expected the coinbase_reward to decrease to 0 in 10 years. If the real average block time is 5, the coinbase_reward will decrease to 0 in the 5th year.
The text was updated successfully, but these errors were encountered: