You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the balances table just contains one balance row per (owner, token) pair, and it is updated continuously as balances change on-chain. I would like to propose changing it to record balance history by doing the following:
Rename balances to balance_changes and add a column for height.
When querying balances from the node via RPC, be specific about which height is requested (see this PR for an update to namada_sdk that makes this possible).
Instead of updating rows in balances, insert a new row to balance_changes whenever a new balance is queried.
(if needed) Introduce a new view named balances which takes the place of the current balances table and provides the most recent balance by height for each (owner, token).
I am working on this in my fork and expect to have a PR soon that implements these changes.
The text was updated successfully, but these errors were encountered:
Currently the
balances
table just contains one balance row per(owner, token)
pair, and it is updated continuously as balances change on-chain. I would like to propose changing it to record balance history by doing the following:balances
tobalance_changes
and add a column forheight
.namada_sdk
that makes this possible).balances
, insert a new row tobalance_changes
whenever a new balance is queried.balances
which takes the place of the currentbalances
table and provides the most recent balance by height for each(owner, token)
.I am working on this in my fork and expect to have a PR soon that implements these changes.
The text was updated successfully, but these errors were encountered: