[VS Incentives]: Implement trackVolume
helper
#6090
Labels
F: volume-splitting
feat: Volume-splitting incentives
trackVolume
helper
#6090
Background
Second step of the volume tracking implementation outlined in this design doc. As a core part of the volume tracking process, I propose we implement the
trackVolume
abstraction and call it in every swap function in the pool manager module.Since the process for actually calling this helper in the swap functions will require heavy testing, it is separated out into another issue/PR to keep PRs small and easy to review
Suggested Design
addVolume(input sdk.NewCoin)
function, which should fetch the existing volume from state (treat as empty if not found), add the input amount to the total, and then set back into state. The key should probably look something like:Testing Strategy
Tests should follow closely to how swap tests (and especially swap fee tests) are currently conducted.
Test fields:
Test outline:
Acceptance Criteria
The text was updated successfully, but these errors were encountered: