rust-lightning icon indicating copy to clipboard operation
rust-lightning copied to clipboard

Don't panic trying to spend outputs with the wrong scripts

Open TheBlueMatt opened this issue 2 years ago • 3 comments

We currently panic in spend_spendable_outputs if the script doesn't match, which is a bit strange given we tell users explicitly they should override the coop close scripts. Instead we should have an error enum.

We should also much more clearly document how to handle spendable outputs events with overridden shutdown scripts. It's mentioned in the spendable enum variant itself but this isn't at all discoverable looking at the event.

TheBlueMatt avatar Apr 28 '23 05:04 TheBlueMatt

Turned out to be complicated and 116 has too much else going on.

TheBlueMatt avatar Jun 04 '23 19:06 TheBlueMatt

Oops left this comment on the wrong issue. Anyway, we should do this, and while its not complicated, it doesn't have to happen in 116.

TheBlueMatt avatar Jun 05 '23 23:06 TheBlueMatt

Also when we do this we need to de-dup the descriptors rather than erroring on dups.

TheBlueMatt avatar Sep 26 '23 19:09 TheBlueMatt