Skip to content
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

clightning: add trustedcoin plugin #533

Closed
wants to merge 5 commits into from

Conversation

neverupdate
Copy link
Contributor

Adds the trustedcoin plugin to allow using clightning without bitcoind, and an option to disable the bcli plugin in clightning, so trustedcoin can be used instead.

I didn't remove the clightning dependency on the bitcoind service though, but that could also be done.

@MatthewCroughan
Copy link

I actually did this exact same thing a week ago and never up-streamed it. Our results are basically identical! Bravo.

Can you split the commit messages up like so?:

trustedcoin: add pkg
trustedcoin: add module
readme: reference trustedcoin source
clightning-plugins: add trustedcoin
clightning: add useBcli option to module

Since nix-bitcoin is a library like nixpkgs, it makes sense to make the commit messages granular like this,

@neverupdate
Copy link
Contributor Author

Should be good now!

@MatthewCroughan
Copy link

I suppose the only thing lacking, is a test. Because this plugin disables the bcli and doesn't require the bitcoin daemon in how it's recommended to be used, it is quite a tricky one to test that mode, without modifying the testing infrastructure.

@erikarvstedt
Copy link
Collaborator

erikarvstedt commented Aug 28, 2022

Does it ever make sense to use trustedcoin with only bcli disabled?
With this setting, trustedcoin uses bitcoind-rpc as its main data source and falls back to public explorers when bitcoind-rpc fails.
But bitcoind-rpc should never fail with nix-bitcoin. Or might this be relevant during the initial block downloading in bitcoind?

Wouldn't it be better to add an option clightning.useBitcoind to disable bitcoind altogether when using clightning with trustedcoin? (I'd be happy to help implementing this.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants