ChainSafe / fil-actor-states

State handling crates for the Filecoin Actors
Apache License 2.0
3 stars 2 forks source link

[Fix] Don't consume on reward state on this_epoch_baseline_power. #282

Closed ruseinov closed 5 months ago

ruseinov commented 5 months ago

Summary of changes Changes introduced in this pull request:

Reference issue to close (if applicable)

Closes

Other information and links

    let (min, max) = reward_state.deal_provider_collateral_bounds(
        policy,
        size,
        power_claim.raw_byte_power,
        reward_state. this_epoch_baseline_power(), // <--- This needs to be non-consuming. 
        supply.into(),
    );
ruseinov commented 5 months ago

Create a follow-up to look into TokenAmount conversions, we need to receive a pointer there as we need to clone atto anyway, then we can further enhance the interface of deal_provider_collateral_bounds.