pub struct RewardDistributorCommitment {
pub epoch_start: u64,
pub clawback_puzzle_hash: HexId,
pub rewards_base_units: u64,
pub recoverable_base_units: Option<u64>,
}Expand description
One clawback commitment slot for a distributor epoch — SPEC §7.4 clause 5.
§recoverable_base_units is NOT rewards_base_units
Committed is not recoverable: SPEC §7.4 clause 4 / §7.5 return only
withdrawal_share_bps / 10000 of the committed value on clawback (the
remainder is forfeited to the reserve — see
GetRewardDistributorResult::withdrawal_share_bps). Reporting only
rewards_base_units and letting a caller label it “recoverable” would
overstate every clawback by the forfeit fraction — exactly the
one-balance-figure money-honesty failure SPEC §7.4 clause 5 forbids,
relocated from a single total into a single per-slot figure. So the
responder reports recoverable_base_units itself, taken from
dig-rewards-coin >= 0.10.0 Commitment::recoverable_base_units() -> Option<u64>, decided on ChainObservation::peak_timestamp (the same
chain clock as chain_peak_timestamp). See the field for its three
states.
Only the holder of the key for clawback_puzzle_hash may claw this slot
back — not an operator role, not the manager singleton, and not the
launcher (SPEC §7.4 clause 3). This field is the proof of entitlement; a
reader must not mistake it for a display label.
This type does not enforce any of the above: the field is a bare pub
value with no constructor or validation, so nothing here checks that the
responder reported what the chain would do.
Fields§
§epoch_start: u64The epoch this commitment slot funds.
clawback_puzzle_hash: HexIdThe chain’s clawback_ph (SPEC / chia-sdk-types
RewardDistributorCommitmentSlotValue): the puzzle hash whose key
holder alone may claw this slot back.
rewards_base_units: u64The committed amount, in base units.
recoverable_base_units: Option<u64>The amount recoverable on clawback, in base units, as of
chain_peak_timestamp — SPEC §4.6. Three states, all distinct:
Some(n)withn > 0:nbase units are recoverable now.Some(0): a genuine zero share that the chain ACCEPTS.None: the chain REFUSES the clawback (the epoch has started).
None is encoded as the key present with JSON null (never an omitted
key); an omitted key decodes to None. An adapter MUST NOT map None
to 0 or Some(0) to None: either recreates the “not recoverable
reads as zero” lie (#3439).
This figure carries a clock, but it is still NOT an eligibility
claim: entitlement is key-holding against clawback_puzzle_hash and
nothing else (SPEC §7.4 cl. 3).