Added splicing plumbing - #736
Conversation
8489f30 to
dbf8e9b
Compare
dbf8e9b to
6de2272
Compare
6de2272 to
2b9b71d
Compare
| ) -> clnpb.DecodeResponse: | ||
| if description is not None: | ||
| raise ValueError("CLN's Decode RPC does not accept a description") | ||
| return self.decode(bolt11) |
There was a problem hiding this comment.
[ISSUE] Shouldn't we rather remove the decodepay method, or are we keeping it for backwards compatibility?
There was a problem hiding this comment.
It was meant for backward compatibility. It was removed in CLN and the updated python bindings, but I wasn't sure if anyone depends on it. But if you are ok with removing it, let's do it
| @@ -1,4 +1,18 @@ | |||
| mod canonical; | |||
| #[allow(dead_code)] | |||
There was a problem hiding this comment.
[ISSUE] Is this dead-code or should it be a cfg(experimental-splicing) guard?
There was a problem hiding this comment.
Was genuine dead-code, but it's removed now
| @@ -0,0 +1,2406 @@ | |||
| use super::canonical::canonical_json_bytes; | |||
There was a problem hiding this comment.
[ISSUE] This file feels very LLM-generated to be honest, which is fine, but LLMs tend to just open code anything, and this feels like it could be much more concise if we didn't reimplement the PSBT serialization / deserialization ourselves. It'd be a win for maintainability.
There was a problem hiding this comment.
Fair point. I refactored this to use the rust-psbt crate instead. It’s part of the rust-bitcoin project, which we already depend on in GL.
Also, after the initial discussion with the VLS team, we decided not to expose the raw splice session state from GL. That should let us trim some of the redundant splice-state fields once the final design settles.
| } | ||
|
|
||
| #[derive(Clone, Debug, PartialEq, Eq, Serialize, Deserialize)] | ||
| pub struct NormalizedRpcAuth { |
There was a problem hiding this comment.
[ISSUE] Having some trouble understanding the RpcAuth related things in the splice persistence stuff. What is this for?
There was a problem hiding this comment.
The idea was to keep explicit receipts for user intents for policy evaluation/audit breadcrumbs. But upon second look, it's too much fluff with little gain. Removed
|
Sorry for the |
59a5c30 to
b543a5b
Compare
b543a5b to
4b3fa1b
Compare
Rationale
This PR prepares Greenlight for splicing support without waiting for the VLS side of things. This establishes the CLN API, binding, persistence, and policy boundaries needed for later signer integration.
What Changed
Trade-offs
experimental-splicingCargo feature but cannot complete until VLS provides the required signing proofs.Handling PBSTs
Greenlight links each splice PSBT to its splice session during
SpliceInitand records whether funding and signing were authorized. The signer rejects it unless the link and signing approval are present. Unrelated PSBTs remain outside splice handling and follow the existing signer policy.