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

Give feedback notifications on closing negotiation when we use feerange #4784

Merged
merged 4 commits into from
Sep 15, 2021

Conversation

rustyrussell
Copy link
Contributor

This will get more useful as more of the network upgrades.

@rustyrussell rustyrussell added this to the v0.10.2 milestone Sep 13, 2021
@rustyrussell rustyrussell force-pushed the guilt/close-feedback branch 2 times, most recently from 2b53587 to b365190 Compare September 13, 2021 05:05
```
Global errors:
 - Node /tmp/ltests-odpd7qtt/test_close_twice_1/lightning-1/ has memory leaks: [
    {
        "backtrace": [
            "ccan/ccan/tal/tal.c:442 (tal_alloc_)",
            "ccan/ccan/tal/tal.c:471 (tal_alloc_arr_)",
            "lightningd/peer_control.c:1673 (param_feerate_range)",
            "common/param.c:43 (make_callback)",
            "common/param.c:140 (parse_by_name)",
            "common/param.c:259 (param_arr)",
            "common/param.c:344 (param)",
            "lightningd/peer_control.c:1706 (json_close)",
            "lightningd/jsonrpc.c:643 (command_exec)",
            "lightningd/jsonrpc.c:778 (rpc_command_hook_final)",
            "lightningd/plugin_hook.c:280 (plugin_hook_call_)",
            "lightningd/jsonrpc.c:866 (plugin_hook_call_rpc_command)",
            "lightningd/jsonrpc.c:965 (parse_request)",
            "lightningd/jsonrpc.c:1056 (read_json)",
            "ccan/ccan/io/io.c:59 (next_plan)",
            "ccan/ccan/io/io.c:407 (do_plan)",
            "ccan/ccan/io/io.c:417 (io_ready)",
            "ccan/ccan/io/poll.c:445 (io_loop)",
            "lightningd/io_loop_with_timers.c:24 (io_loop_with_timers)",
            "lightningd/lightningd.c:1123 (main)"
        ],
        "label": "lightningd/peer_control.c:1673:u32[]",
        "parents": [
            "lightningd/channel.c:372:struct channel"
        ],
        "value": "0x56428b886208"
    }
]
```

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
… feerate!).

Noted by @t-bast, this is how it should work, and this tests that it does.

See also: ElementsProject#4777
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
@cdecker
Copy link
Member

cdecker commented Sep 14, 2021

ACK 2655e16

They share some code, but not much: command_find_channel is made
non-static.  Rest is move-only.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This allows cmdline users to have more idea what's going on.

Inspired-by: ElementsProject#4777
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Changelog-Added: `close` now notifies about the feeranges each side uses.
@rustyrussell
Copy link
Contributor Author

Rebased to fix generated merge conflicts.

Ack 20dbce5

@cdecker cdecker merged commit d970cc0 into ElementsProject:master Sep 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants