warmupPeriod = 24h
Freshly staked tokens do not count for a day
Without a warmup, the attack is one transaction long: flash-borrow two million VERD, stake, call the turbo endpoint, unstake, repay. The tier is worth an hour of privileged throughput and the capital was rented for one block.
A 24-hour warmup makes that impossible, because no flash loan survives a block boundary. A top-up extends the clock only on the new tokens — a matured balance is never dragged back into warmup by a later deposit.
This only needs to defeat cheap capital. Somebody who genuinely holds two million VERD for a day is not an attacker, they are a customer, and the warmup is the price of admission rather than an obstacle.
MAX_WARMUP 7 daysrewards need no warmup
cooldownPeriod = 7d
Unstaking takes a week, and stops paying immediately
requestUnstake moves your principal out of totalStaked and into totalPendingUnstake in the same call. From that second it earns nothing and dilutes nobody — the tokens are held by the contract but are no longer staked.
That ordering matters. If exiting principal kept earning through a week of cooldown, every staker would be paying the people who already left, and the last one out would pay the most.
Up to 16 unstake requests can be in flight at once, each with its own claim time and its own index.
MAX_COOLDOWN 30 dayswarming tokens exit first
rewardRate · periodFinish
Rewards stream, they do not land
With instant pro-rata distribution, anyone watching for a notifyReward call could deposit immediately before it and take a slice of a month’s revenue for a few seconds of exposure. The stakers who carried the month would fund it.
So rewards use the Synthetix streaming accumulator: notifyReward(amount, duration) sets a per-second rate and every staker accrues against the seconds they were actually in. Reward becomes proportional to time held, which is the thing we are trying to pay for.
It also explains why rewards need no warmup while tiers do: you cannot capture a stream you were not in. Leftover from an unfinished period rolls into the next rate rather than being stranded.
per-second accrualsolvency checked on notify