bdk-cli icon indicating copy to clipboard operation
bdk-cli copied to clipboard

Test watch-only LND wallet and signing PSBT

Open notmandatory opened this issue 3 years ago • 3 comments

This issue is to do a proof of concept test with BDK to confirm BDK can create a watch-only wallet to monitor the LND UTXOs and generate a PSBT that can be signed by LND. This idea is based on a discussion I had with @nicolasburtey and @bodymindarts about doing a BDK based wallet microservice for Galoy, initially for batching payments.

Goal of this test:

  • [ ] Setup regtest bitcoind with LND and BDK-CLI
  • [ ] Create LND on-chain wallet and load with test coins
  • [ ] Setup BDK-CLI wallet to watch LND on-chain wallet (xpub descriptor)
  • [ ] Create batch spending PSBT with BDK-CLI
  • [ ] Sign and spend BDK-CLI generated PSBT with LND on-chain wallet

notmandatory avatar May 02 '22 17:05 notmandatory

thanks @notmandatory still on my todo to create the ticket. I guess some of the early context is here already, will write down the full spec of a potential batching service shortly.

nicolasburtey avatar May 02 '22 18:05 nicolasburtey

could @sandipndev and @krtk6160 you look at this maybe?

nicolasburtey avatar May 05 '22 00:05 nicolasburtey

I am interested in having this test too.. I am currently working on the final part of regtest-node feature where bdk-cli will be able to spawn a bitcoind and have rpc controller access to it.. In the same PR I am planning to include the integration test framework similar to #79. This will allow us to do programmatic integration testing for bdk-cli and whatever backend combinations we wanna use in rust code. Maybe LND will need a separate handler..

So @sandipndev @krtk6160 if you guys wanna mingle on this hit me up in discord. The approach of my current testframework will also depend on what you guys will need on this specific case..

And ideally we should have this test and all other similar types in CI too..

That will serve two purpose

  • Give example demo of how to use bdk-cli in various scenarios..
  • Ensure bdk-cli (in turn bdk) behaviors are maintained..

rajarshimaitra avatar May 11 '22 07:05 rajarshimaitra