Skip to content

Elektron Net StartOS Release v4.0.3

Choose a tag to compare

@github-actions github-actions released this 14 Jul 02:36
Release v4.0.3 - Retire Stoic Awakening at height 150000

Mandatory update before block height 150000.

Live mainnet data showed the Stoic Awakening min-difficulty escape
(active since genesis, MinDifficultyActivationHeight = 1) firing far
more often than assumed under perfectly stable hashrate: block
discovery is a Poisson process, so a >120s gap occurs ~13.5% of the
time by pure statistical variance (e^-2), not the ~5% the original
design assumed. Worse, when an escape block lands on the last block of
a 2016-block retarget period, CalculateNextWorkRequired() inherits its
crashed nBits as the baseline for the entire next epoch, requiring
several +300%-capped periods (days) to recover - during which the
chain is trivially attackable and mines far more than the intended
1,440 blocks/day. A live diagnostic mid-cascade (tip 82858) showed the
recovery self-prolonging as opportunistic miners piled onto the cheap
difficulty window, keeping realized block times (1.48s avg) below
target even after a x4 difficulty jump.

New consensus parameter Consensus::Params::StoicAwakeningEndHeight
(-1 = never, the default for every network except mainnet) height-gates
the end of the escape in GetNextWorkRequired() and
PermittedDifficultyTransition() (src/pow.cpp), alongside the existing
fPowAllowMinDifficultyBlocks/MinDifficultyActivationHeight checks.
Mainnet sets it to 150000 (src/kernel/chainparams.cpp), chosen with
~4-5 weeks of real lead time from the tip at decision time. Blocks
below 150000 keep validating exactly as before - this is forward-only,
not retroactive. Testnet/testnet4/regtest are unaffected.

If you update before reaching height 150000, you won't notice the
switch at all: nBits simply stops changing mid-period from that height
onward, exactly like Bitcoin mainnet.

Details:
- Changelog: doc-elektron/CHANGELOG-stoic-awakening-retirement.md
- Technical diff reference: doc-elektron/BITCOIN_CORE_DIFF.md §2.4