Skip to content

[feature] clear pending liquidity

Son of Odin requested to merge clear-pending-liquidity into develop

This change aims to clear pending liquidity in pools after 1 week by committing it into the pool for the user.

The code should clear a pool every 100800 blocks (1 week) / number of pools, which is about every 5 hours. The code will dynamically adjust this based on number of available/staged pools, and if chains/LPActions are paused. And, of course, if pending liquidity is zero in a pool, it will skip that one (not process it, saving resources).

In addition, pending inbound liquidity in the pool gets resolved if the total amount in LPs and the pool are different (removing the need for an invariant).

Edited by Son of Odin

Merge request reports