Skip to content

Respect MAX_LEADER_SCHEDULE_STAKES constant#8584

Merged
brooksprumo merged 1 commit intoanza-xyz:masterfrom
brooksprumo:leader-schedule-stakes/6
Oct 21, 2025
Merged

Respect MAX_LEADER_SCHEDULE_STAKES constant#8584
brooksprumo merged 1 commit intoanza-xyz:masterfrom
brooksprumo:leader-schedule-stakes/6

Conversation

@brooksprumo
Copy link
Copy Markdown

Problem

The MAX_LEADER_SCHEDULE_STAKES constant is not respected. We actually store 6 epochs-worth of stakes, not 5.

(The broader goal/context is to reduce the number of epochs in the epoch stakes cache, which eventually gets serialized into the snapshot.)

Note that MAX_LEADER_SCHEDULE_STAKES = 5 was arbitrarily chosen. Here's its origin: solana-labs#7668 (comment).

Summary of Changes

Actually respect the constant.

@brooksprumo brooksprumo self-assigned this Oct 20, 2025
@brooksprumo brooksprumo force-pushed the leader-schedule-stakes/6 branch from c283622 to 6e0d961 Compare October 20, 2025 23:16
@codecov-commenter
Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.1%. Comparing base (453b75f) to head (6e0d961).
⚠️ Report is 10 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##           master    #8584     +/-   ##
=========================================
- Coverage    83.1%    83.1%   -0.1%     
=========================================
  Files         846      846             
  Lines      368602   368604      +2     
=========================================
- Hits       306674   306671      -3     
- Misses      61928    61933      +5     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@brooksprumo brooksprumo marked this pull request as ready for review October 21, 2025 00:23
@brooksprumo brooksprumo requested a review from jstarry October 21, 2025 00:23
@brooksprumo brooksprumo added this pull request to the merge queue Oct 21, 2025
Merged via the queue into anza-xyz:master with commit e6661f4 Oct 21, 2025
43 checks passed
@brooksprumo brooksprumo deleted the leader-schedule-stakes/6 branch October 21, 2025 12:37
rustopian pushed a commit to rustopian/agave that referenced this pull request Nov 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants