Skip to content

Commit 89c182e

Browse files
ShahanaFarooquirustyrussell
authored andcommitted
rpc: Removing category and verbose from json_command struct
1 parent 58e3ea5 commit 89c182e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+125
-361
lines changed

cli/lightning-cli.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,9 +183,7 @@ static void human_help(char *buffer, const jsmntok_t *result)
183183
/* Contains all commands objects, which have the following structure :
184184
* {
185185
* "command": "The command name and usage",
186-
* "category": "The command category",
187-
* "description": "The command's description",
188-
* "verbose": "The command's detailed description"
186+
* "description": "The command's description"
189187
* }
190188
*/
191189
const jsmntok_t * help_array = json_get_member(buffer, result, "help");

cln-grpc/proto/node.proto

Lines changed: 0 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

cln-grpc/src/convert.rs

Lines changed: 0 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

cln-rpc/src/model.rs

Lines changed: 0 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

contrib/msggen/msggen/schema.json

Lines changed: 3 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -12568,9 +12568,7 @@
1256812568
"additionalProperties": true,
1256912569
"required": [
1257012570
"command",
12571-
"category",
12572-
"description",
12573-
"verbose"
12571+
"description"
1257412572
],
1257512573
"properties": {
1257612574
"command": {
@@ -12579,23 +12577,11 @@
1257912577
"The command."
1258012578
]
1258112579
},
12582-
"category": {
12583-
"type": "string",
12584-
"description": [
12585-
"The category for this command (useful for grouping)."
12586-
]
12587-
},
1258812580
"description": {
1258912581
"type": "string",
1259012582
"description": [
1259112583
"A one-line description of the purpose of this command."
1259212584
]
12593-
},
12594-
"verbose": {
12595-
"type": "string",
12596-
"description": [
12597-
"A full description of this command (including whether it's deprecated)."
12598-
]
1259912585
}
1260012586
}
1260112587
}
@@ -12636,9 +12622,7 @@
1263612622
"help": [
1263712623
{
1263812624
"command": "pay bolt11 [amount_msat] [label] [riskfactor] [maxfeepercent] [retry_for] [maxdelay] [exemptfee] [localinvreqid] [exclude] [maxfee] [description] [dev_use_shadow]",
12639-
"category": "plugin",
12640-
"description": "Send payment specified by {bolt11}",
12641-
"verbose": "Attempt to pay the {bolt11} invoice."
12625+
"description": "Send payment specified by {bolt11}"
1264212626
}
1264312627
],
1264412628
"format-hint": "simple"
@@ -12656,9 +12640,7 @@
1265612640
"help": [
1265712641
{
1265812642
"command": "dev subcommand=crash|rhash|slowcmd",
12659-
"category": "developer",
12660-
"description": "Developer command test multiplexer",
12661-
"verbose": "dev rhash {secret}\n\tShow SHA256 of {secret}\ndev crash\n\tCrash lightningd by calling fatal()\ndev slowcmd {msec}\n\tTorture test for slow commands, optional {msec}\n"
12643+
"description": "Developer command test multiplexer"
1266212644
}
1266312645
],
1266412646
"format-hint": "simple"

contrib/pyln-grpc-proto/pyln/grpc/node_pb2.py

Lines changed: 108 additions & 108 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

contrib/pyln-testing/pyln/testing/grpc2py.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2617,10 +2617,8 @@ def stop2py(m):
26172617

26182618
def help_help2py(m):
26192619
return remove_default({
2620-
"category": m.category, # PrimitiveField in generate_composite
26212620
"command": m.command, # PrimitiveField in generate_composite
26222621
"description": m.description, # PrimitiveField in generate_composite
2623-
"verbose": m.verbose, # PrimitiveField in generate_composite
26242622
})
26252623

26262624

doc/schemas/lightning-help.json

Lines changed: 3 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,7 @@
3232
"additionalProperties": true,
3333
"required": [
3434
"command",
35-
"category",
36-
"description",
37-
"verbose"
35+
"description"
3836
],
3937
"properties": {
4038
"command": {
@@ -43,23 +41,11 @@
4341
"The command."
4442
]
4543
},
46-
"category": {
47-
"type": "string",
48-
"description": [
49-
"The category for this command (useful for grouping)."
50-
]
51-
},
5244
"description": {
5345
"type": "string",
5446
"description": [
5547
"A one-line description of the purpose of this command."
5648
]
57-
},
58-
"verbose": {
59-
"type": "string",
60-
"description": [
61-
"A full description of this command (including whether it's deprecated)."
62-
]
6349
}
6450
}
6551
}
@@ -100,9 +86,7 @@
10086
"help": [
10187
{
10288
"command": "pay bolt11 [amount_msat] [label] [riskfactor] [maxfeepercent] [retry_for] [maxdelay] [exemptfee] [localinvreqid] [exclude] [maxfee] [description] [dev_use_shadow]",
103-
"category": "plugin",
104-
"description": "Send payment specified by {bolt11}",
105-
"verbose": "Attempt to pay the {bolt11} invoice."
89+
"description": "Send payment specified by {bolt11}"
10690
}
10791
],
10892
"format-hint": "simple"
@@ -120,9 +104,7 @@
120104
"help": [
121105
{
122106
"command": "dev subcommand=crash|rhash|slowcmd",
123-
"category": "developer",
124-
"description": "Developer command test multiplexer",
125-
"verbose": "dev rhash {secret}\n\tShow SHA256 of {secret}\ndev crash\n\tCrash lightningd by calling fatal()\ndev slowcmd {msec}\n\tTorture test for slow commands, optional {msec}\n"
107+
"description": "Developer command test multiplexer"
126108
}
127109
],
128110
"format-hint": "simple"

lightningd/chaintopology.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -755,7 +755,6 @@ static struct command_result *json_feerates(struct command *cmd,
755755

756756
static const struct json_command feerates_command = {
757757
"feerates",
758-
"bitcoin",
759758
json_feerates,
760759
"Return feerate estimates, either satoshi-per-kw ({style} perkw) or satoshi-per-kb ({style} perkb)."
761760
};
@@ -782,7 +781,6 @@ static struct command_result *json_parse_feerate(struct command *cmd,
782781

783782
static const struct json_command parse_feerate_command = {
784783
"parsefeerate",
785-
"bitcoin",
786784
json_parse_feerate,
787785
"Return current feerate in perkw + perkb for given feerate string."
788786
};

lightningd/channel_control.c

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2198,7 +2198,6 @@ static struct command_result *json_splice_signed(struct command *cmd,
21982198

21992199
static const struct json_command splice_init_command = {
22002200
"splice_init",
2201-
"channels",
22022201
json_splice_init,
22032202
"Init a channel splice to {channel_id} for {relative_amount} satoshis with {initialpsbt}. "
22042203
"Returns updated {psbt} with (partial) contributions from peer"
@@ -2207,7 +2206,6 @@ AUTODATA(json_command, &splice_init_command);
22072206

22082207
static const struct json_command splice_update_command = {
22092208
"splice_update",
2210-
"channels",
22112209
json_splice_update,
22122210
"Update {channel_id} currently active negotiated splice with {psbt}. "
22132211
""
@@ -2220,7 +2218,6 @@ AUTODATA(json_command, &splice_update_command);
22202218

22212219
static const struct json_command splice_signed_command = {
22222220
"splice_signed",
2223-
"channels",
22242221
json_splice_signed,
22252222
"Send our {signed_psbt}'s tx sigs for {channel_id}."
22262223
};
@@ -2274,7 +2271,6 @@ static struct command_result *json_dev_feerate(struct command *cmd,
22742271

22752272
static const struct json_command dev_feerate_command = {
22762273
"dev-feerate",
2277-
"developer",
22782274
json_dev_feerate,
22792275
"Set feerate for {id} to {feerate}",
22802276
.dev_only = true,
@@ -2331,7 +2327,6 @@ static struct command_result *json_dev_quiesce(struct command *cmd,
23312327

23322328
static const struct json_command dev_quiesce_command = {
23332329
"dev-quiesce",
2334-
"developer",
23352330
json_dev_quiesce,
23362331
"Initiate quiscence protocol with peer",
23372332
.dev_only = true,

0 commit comments

Comments
 (0)