-
Notifications
You must be signed in to change notification settings - Fork 924
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
Channel gossip rework #8136
Open
rustyrussell
wants to merge
26
commits into
ElementsProject:master
Choose a base branch
from
rustyrussell:channel-gossip-rework
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Channel gossip rework #8136
rustyrussell
wants to merge
26
commits into
ElementsProject:master
from
rustyrussell:channel-gossip-rework
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_in_ versions complain if used, _out_ don't (since we don't know if they are going to use it). This was the wrong choice, and thus causes a BROKEN log message when we update CLN_NEXT_VERSION. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
…do_stress any more. In d18f564 "pytest: stop using deprecated commando_rune commands." we stopped using deprecated commands in these tests, but we didn't remove the 'allow-deprecated-apis' flag. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
…utput. Somehow we missed this when we added libplugin support. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
When we update the CLN_NEXT_VERSION, these will only be available with --i-promise-to-fix-broken-api-user. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
We now have to explicitly enable various deprecated commando commands, and now when deprecations are disabled, we honour missing MPP option in bolt12 invoices. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
We haven't printed this since v24.08. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Removed: listconfigs raw listing (deprecated v23.08, disabled by default in v24.11).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Removed: connection/disconnection/block_added notification raw fields (deprecated v23.08, disabled by default in v24.11).
Changelog-Removed: accept-htlc-tlv-types (deprecated v23.08, disabled by default in v24.11). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
… sockets. Changelog-Removed: --bind-addr and --addr on onion addresses and local sockets (deprecated v23.08, disabled by default in v24.11). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Removed: Config: `announce-addr-dns` (deprecated v23.08, disabled in v24.11).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Removed: allowing 0/1 instead of false/true for plugin options (deprecated v23.08, disabled by default in v24.11).
…t values. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Removed: default settings for flag options in plugins which aren't "false".
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Removed: plugins which didn't accept string JSON RPC fields (deprecated v23.08, disabled by default in v24.11).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Removed: RPC `listchannels` no longer includes private local channels (deprecated v23.08, disabled by default in v24.11).
…fore sending announcement_signatures. We have a replacement quote which is suitable here, but it comes in a later BOLT commit. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
…ices. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Unfortunately a spec typo means the data fields are missing (PR pending), so we still patch those in. The message "your_peer_storage" got renamed to "peer_storage_retrieval", and the option "want_peer_backup_storage" was removed. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
…ound `channel_announcement` handling (ElementsProject#1220)" Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Since we included the spec for it, this is a good time to implement it. I also asked chatgpt to write some unit tests. I had to mangle them a bit, but it probably saved me a few minutes. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Calling the funding tx an anchor is pre-spec terminology, which is now confusing; let's rename the variable. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
In this case a "are we closed onchain". Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
bb22533
to
4a98198
Compare
We want a more fine-grained approach, so we now have: 1. update_channel_update() - returns true if it changed. 2. channel_should_enable() - should this channel be marked enabled. 3. arm_refresh_timer() - start a refresh timer for the channel_update. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This message was too verbose (even for trace!) Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
They can all call get_block_height(); the extra argument confused me and I thought they were called before the block height was actually updated. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
… wait until 6 deep. The spec used to say you had to wait for channel to be ready, *and* 6 depth before exchanging signatures. Now the 6 depth requirement is only on the actual announcing of the channel: you can send sigs any time. This means our state machine goes from: NOT_USABLE -> NOT_DEEP_ENOUGH -> NEED_PEER_SIGS -> ANNOUNCED to: NOT_USABLE -> NEED_PEER_SIGS -> NOT_DEEP_ENOUGH -> ANNOUNCED However, this revealed that our state machine is insufficient, so rework it to be more general and understandable. In particular, check for unexpected state transitions, and thus document them. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Changed: Protocol: We now exchange `announcement_signatures` as soon as we're ready, rather than waiting for 6 blocks (as per recent BOLT update)
4a98198
to
49de315
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
(Based on #8135)
I tried modifying our state machine to allow us to send (as allowed in the latest spec revisions) announcement_signatures before 6 blocks have passed. However, our state machine did not capture the entire state, so it proved fragile. The result is a rework on the state machine to be more robust.