celo-org / staked-celo

GNU Lesser General Public License v3.0
8 stars 2 forks source link

Aggregate unvoting #56

Open m-chrzan opened 2 years ago

m-chrzan commented 2 years ago

Currently, a separate Account.withdraw per group call is necessary for every Manager.withdraw. It could be possible to aggregate requests from multiple Manager.withdraw calls, and then actually unvote in a single Account.withdraw per group for all withdrawals in a given time frame (similar to how a single activateAndVote is necessary for multiple deposits).

This could lead to gas savings (a single set of Account.withdraws per period of time, rather than per withdrawal), and could allow for a simpler backend of the stCELO web app.