superfluid-finance / superfluid-sentinel

MIT License
24 stars 13 forks source link

[SENTINEL] Check sender balance only once per block #246

Closed d10r closed 1 year ago

d10r commented 1 year ago

When multiple outgoing streams are open, don't query sender balance once for each of them.

ngmachado commented 1 year ago

This issue happens from the current queue system where each task is processed separately.

I'm hesitant to implement logic that stop estimations based on individual block numbers. This approach would introduce more complexity and we still end up making multiple checks to RPC.

Objective

Deduplicating tasks within the queues. For example, if an account/token is already queued for estimation, we shouldn't add another estimation for that same account/token."

Tasks

Related:

https://github.com/superfluid-finance/superfluid-sentinel/issues/255