BaseGauge.sol creates double-length gaps between voting periods due to incorrect calculation of the next period start time, reducing protocol efficiency and voting participation. It creates potentially long periods when this functionality is blocked.
This calculation is used in multiple places in code.
In BaseGauge.sol, several functions calculate the next period start using:
This creates an unnecessary extra period gap. Adding 2 instead of 1 doubles the waiting time between periods.
Example:
Current time: 100
Period duration: 30
Current calculation (+ 2): ((100/30) + 2) * 30 = 150 (50 blocks gap)
Correct calculation (+ 1): ((100/30) + 1) * 30 = 120 (20 blocks gap)
The + 2 creates an unnecessary extra period of delay between votes.
Creates unnecessary gaps between voting periods
Reduces voting participation opportunities
Decreases protocol efficiency
Affects both RAACGauge (7 day periods) and RWAGauge (30 day periods)
Manual review
Change the period start calculation to use + 1 instead of + 2:
This maintains necessary period separation while eliminating unnecessary gaps.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.