-
Notifications
You must be signed in to change notification settings - Fork 906
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
Compulsory modern features, and open-by-channel-type APIs #6864
Compulsory modern features, and open-by-channel-type APIs #6864
Conversation
a27ffb5
to
0279935
Compare
@cdecker this broke the GRPC generation, and I cannot figure out why :( I note that
|
0279935
to
4560689
Compare
Ok, so it turns out that The longer term solution for this would be to have a protobuf-like IDL that allows us to specify the API as a flat namespace of messages that may nest each other, and then generate the JSON Schema from that. That'd also remove the need for unreadable, context-related, names such as |
c3de546
to
2de145d
Compare
Fixed a couple of source lints, and added the missing enum, as well as the override. |
c6764c1
to
2b7667f
Compare
5917f15
to
86f4ee1
Compare
86f4ee1
to
1e39eb6
Compare
Note that this needs rustyrussell/lnprototest#115 so I've changed the upstream for lnprototest temporarily! |
1e39eb6
to
38529e3
Compare
Otherwise it fails because lnprototest expects us to allow a non-static-channel channel type. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
It fails because this is an array of enum values, which is a combination we hadn't seen before. Replacing this with a manually managed enum, since it is likely we'll want to reuse it in the future.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
As suggested in lightning/bolts#1092. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Changed: Protocol: `option_data_loss_protect` is now required (advertized by all but 11 nodes)
As suggested in lightning/bolts#1092. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Changed: Protocol: `option_gossip_queries` is now required (advertized by all but 11 nodes)
… offered minimum_depth=0. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Fixed: `channel_type` reflects option_zeroconf if explicitly negotiated.
We use an array of bit numbers. We could use an array of names, but the JSON typing is then harder. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
…meter. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
… force channel type. And add request schemas for openchannel_init and fundchannel_start. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Added: JSON-RPC: `fundchannel_start` and `openchannel_init` now take an optional `channel_type` parameter.
And add a request schema for multifundchannel. Changelog-Added: JSON-RPC: `fundchannel` and `multifundchannel` now take an optional `channel_type` parameter. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
We're about to make static_remotekey compulsory, but we still want to do tests for pre-existing channels. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
As suggested in lightning/bolts#1092. We still support channels opened without it, but you can no longer open new ones without it. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Changed: Protocol: `option_gossip_queries` is now required (advertized by all but 16 nodes)
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Let's tell the caller what channel_type they got! Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Added: JSON-RPC: `fundchannel`, `multifundchannel`, `fundchannel_start` and `openchannel_init`: new field `channel_type`.
…turned from fund/openchannel Could have done this in an earlier commit, but that would be a messy rebase. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
38529e3
to
bbd3f59
Compare
For example, lnprototest got the error 'You gave bad parameters: Did not support channel_type ' which doesn't make it clear that it's rejecting the empty channel type. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
bbd3f59
to
5241a03
Compare
I thought we made static_remotekey, gossip_queries and dataloss_protect required already, but we didn't. However, we still need to handle old channels without static_remotekey, which lead me to finally implement the open-by-channel-type explicit API.