keep-network / keep-core

The smart contracts and reference client behind the Keep network
https://keep.network
MIT License
118 stars 73 forks source link

SPV deposit sweep maintainer logic #3649

Closed tomaszslabon closed 1 year ago

tomaszslabon commented 1 year ago

Refs: https://github.com/keep-network/keep-core/issues/3615. This PR adds implementation of deposit sweep proofs in SPV maintainer. The SPV maintainer periodically checks if there are unproven deposit sweep transactions. If there are such transactions, it assembles the proof and submits it.

Example command:

KEEP_ETHEREUM_PASSWORD="password" ./keep-client maintainer --spv --spv.historyDepth 200000 --config maintainer.toml 
pdyraga commented 1 year ago

We agreed to implement unit tets for this code in a separate PR so that we can work on the remaining SPV maintainer logic in parallel.

The remaining work is captured on the tasks list in https://github.com/keep-network/keep-core/issues/3615.

I tested this code locally and it submitted deposit sweep SPV proof successfully.