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

splice: first pass on splice_out command #6777

Closed
wants to merge 1 commit into from

Conversation

ddustin
Copy link
Collaborator

@ddustin ddustin commented Oct 15, 2023

Added splice_out RPC command and a simple test of it as well.

Added splice_out RPC command and a simple test of it as well.

ChangeLog-Added: splice_out command added for doing a splice out more easily.
@ddustin ddustin mentioned this pull request Oct 15, 2023
71 tasks
@ddustin
Copy link
Collaborator Author

ddustin commented Oct 30, 2023

Should use wallet_utxo_boost from PR #6780

Copy link
Collaborator

@niftynei niftynei left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs to be one level up, in a plugin. Let's circle up about it soon and get moving that direction instead.

Nice and short tho!

l1, l2 = node_factory.line_graph(2, fundamount=1000000, wait_for_announce=True, opts={'experimental-splicing': None})

l1.rpc.splice_out(l1.get_channel_id(l2), 100000)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: check that the money moved!

if (cc->auto_complete) {
subd_send_msg(channel->owner,
take(towire_channeld_splice_update(NULL, psbt)));
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: less vertical space please

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

actually let's regroup about this and talk about how to make it better!


psbt_append_output(psbt, b32script, *amount);

weight = wally_psbt_weight(psbt);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think you're going to want to add the signature witness byte weight as well, or at least an estimate for it.

@ddustin ddustin added this to the v24.02 milestone Dec 14, 2023
@ddustin
Copy link
Collaborator Author

ddustin commented Jan 7, 2024

Working on a generic splice json / script protocol that can handle doing any kind of splice.

Then splice-out, splice-in, etc will use that RPC and pass it the correct json to do it.

First PR in that larger project here: #6980

@ddustin ddustin closed this Jan 7, 2024
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.

2 participants