@lanzafame pointed out that the Client Power is currently using the Market Balance of an address to calculate power (
|
resp, err := lotusRpcClient.Call(ctx, "Filecoin.StateMarketBalance", tipSetList) |
), rather than the deal bytes. This means the client voting power is based on how much FIL they have spent on deals, not how many total bytes worth of deals they have submitted. This is incorrect. Instead, I believe we need to pull data from the StateMarketDeals endpoint (
https://docs.filecoin.io/reference/json-rpc/state#statemarketdeals), and loop over all the deals for a wallet address to calculate the total deal bytes for that address.
This should only be the deal bytes of CURRENT deals. Expired deals should not be counted.
@lanzafame pointed out that the Client Power is currently using the Market Balance of an address to calculate power (
on-chain-voting/power-snapshot/utils/lotus_rpc.go
Line 147 in 9427514
This should only be the deal bytes of CURRENT deals. Expired deals should not be counted.