Skip to content

ledger: full reward calculation per Shelley spec Sec 10 #1959

@wolf31o2

Description

@wolf31o2

Summary

Promote the Q3 reward-state persistence groundwork (#1902) and Koios-backed parity checks (#1903) to a full reward calculation implementation that matches the Shelley ledger specification, Section 10.

What Needs to Happen

  1. Implement the full reward formula per Shelley spec Sec 10:
    • Pool performance (apparent vs. expected blocks)
    • Pledge influence factor (a0)
    • Pool cost and margin
    • Stake distribution at the snapshot boundary
    • Reserves and treasury splits
  2. Wire the calculation into the epoch transition path so rewards are computed at the right boundary using the right snapshot ("Go" snapshot, two epochs old).
  3. Persist computed rewards per stake credential and per pool.
  4. Use the validated implementation to drive Blockfrost reward and account endpoints (correctness across /accounts/{stake_address}/rewards, etc.).
  5. Validate rewards across multiple epochs against Haskell node and Koios on preview, preprod, and mainnet.

Depends On

Roadmap

Q1 2027 — mainnet block production readiness, reward calculation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    Status

    Todo

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions