-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: bouncer btc client mutex for vault swaps #5436
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #5436 +/- ##
======================================
- Coverage 72% 72% -0%
======================================
Files 490 490
Lines 87053 86929 -124
Branches 87053 86929 -124
======================================
- Hits 62423 62234 -189
- Misses 21675 21731 +56
- Partials 2955 2964 +9 ☔ View full report in Codecov by Sentry. |
1714311
to
59cf85a
Compare
I was playing around with this on Friday, and it looks like the Bitcoin nodes have a This would also solve the (still remaining) issue that we can only select a single utxo. I'll see if it works on localnet and if yes, will push it. |
- lockUnspents: true to ensure we don't try to double-spend - changePosition: 2 on vault swaps to ensure a valid transaction
* fix: bouncer lock utxos after selection * refactor: use mutex instead of locking * feat: use bitcoin node's input selection. * chore: set correct timeouts for LP-API bouncer test * fix: additional btc tx options: - lockUnspents: true to ensure we don't try to double-spend - changePosition: 2 on vault swaps to ensure a valid transaction --------- Co-authored-by: Daniel <daniel@chainflip.io>
* fix: bouncer lock utxos after selection * refactor: use mutex instead of locking * feat: use bitcoin node's input selection. * chore: set correct timeouts for LP-API bouncer test * fix: additional btc tx options: - lockUnspents: true to ensure we don't try to double-spend - changePosition: 2 on vault swaps to ensure a valid transaction --------- Co-authored-by: Daniel <daniel@chainflip.io>
Pull Request
Closes: PRO-1832
Checklist
Please conduct a thorough self-review before opening the PR.
Summary
Using the btc client mutex around selecting inputs and sending transaction to avoid double spending error.