Support round expiration and sweep vtxos (#70)

* sweeper base implementation

* sweeper service final implementation

* fixes

* fix CSV script

* RoundSwept event fix & test

* remove Vtxos after a sweep transaction

* ARK_ROUND_LIFETIME config

* remove TxBuilder.GetLifetime

* refactor sweeper

* use GetTransaction blocktime

* polish and comments

* fix linting

* pair programming fixes

* several fixes

* clean Println

* fixes

* linter fixes

* remove infrastructure deps from application layer

* Fixes

---------

Co-authored-by: altafan <18440657+altafan@users.noreply.github.com>
This commit is contained in:
Louis Singer
2024-02-08 16:58:04 +01:00
committed by GitHub
parent 58aa36b7e7
commit 287db4e08a
35 changed files with 1403 additions and 114 deletions

View File

@@ -229,7 +229,7 @@ func validateNodeTransaction(
return ErrInvalidTaprootScript
}
isSweepLeaf, aspKey, seconds, err := decodeSweepScript(tapLeaf.Script)
isSweepLeaf, aspKey, seconds, err := DecodeSweepScript(tapLeaf.Script)
if err != nil {
return fmt.Errorf("invalid sweep script: %w", err)
}