-
Notifications
You must be signed in to change notification settings - Fork 1.2k
fix: multiple help string for RPC result #6886
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
Changes from all commits
cc1a8fd
b174fe0
b216d13
3b4095c
7d6b606
72284b5
661db51
6e89094
690ff3a
9af4c55
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -43,7 +43,20 @@ static RPCHelpMan gobject_count() | |||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {"mode", RPCArg::Type::STR, RPCArg::DefaultHint{"json"}, "Output format: json (\"json\") or string in free form (\"all\")"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| RPCResult{"for mode = json", | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "objects_total", "Total number of all governance objects"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "proposals", "Number of governance proposals"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "triggers", "Number of triggers"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "other", "Total number of unknown governance objects"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "erased", "Number of removed (expired) objects"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "votes", "Total number of votes"}, | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResult{"for mode = all", RPCResult::Type::STR, "", "Human-friendly summary string for proposals and votes"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
|
coderabbitai[bot] marked this conversation as resolved.
|
||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -71,7 +84,7 @@ static RPCHelpMan gobject_deserialize() | |||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {"hex_data", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "data in hex string form"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{RPCResult::Type::STR, "", "JSON string of the deserialized governance object"}, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -96,7 +109,12 @@ static RPCHelpMan gobject_check() | |||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {"hex_data", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "data in hex string format"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{"if object is valid", | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::STR, "Object status", "OK"}, | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
|
Comment on lines
+112
to
+117
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fix misleading field description. The description parameter should describe what the field contains, not show the literal value. Line 115 currently has Apply this diff: {
- {RPCResult::Type::STR, "Object status", "OK"},
+ {RPCResult::Type::STR, "Object status", "Validation status (\"OK\" if valid)"},
}📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -145,7 +163,7 @@ static RPCHelpMan gobject_prepare() | |||||||||||||||||||||||||
| {"outputHash", RPCArg::Type::STR_HEX, RPCArg::Default{""}, "the single output to submit the proposal fee from"}, | ||||||||||||||||||||||||||
| {"outputIndex", RPCArg::Type::NUM, RPCArg::Default{0}, "The output index."}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| {RPCResult{"if object valid", RPCResult::Type::STR_HEX, "", "The collateral transaction id (txid)"}}, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -254,7 +272,16 @@ static RPCHelpMan gobject_list_prepared() | |||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {"count", RPCArg::Type::NUM, RPCArg::Default{10}, "Maximum number of objects to return."}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{ | ||||||||||||||||||||||||||
| RPCResult::Type::ARR, "", "list of governance objects", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| // TODO: list fields of output for RPC help instead ELISION | ||||||||||||||||||||||||||
| {RPCResult::Type::ELISION, "", ""} | ||||||||||||||||||||||||||
| }}, | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -303,7 +330,7 @@ static RPCHelpMan gobject_submit() | |||||||||||||||||||||||||
| {"data-hex", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "data in hex string form"}, | ||||||||||||||||||||||||||
| {"fee-txid", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "txid of the corresponding proposal fee transaction"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{RPCResult::Type::STR_HEX, "hash", "Hash of the submitted governance object"}, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -484,6 +511,23 @@ static bool CheckWalletOwnsKey(const CWallet& wallet, const CKeyID& keyid) | |||||||||||||||||||||||||
| return wallet.IsMine(script) == isminetype::ISMINE_SPENDABLE; | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| namespace { | ||||||||||||||||||||||||||
| const RPCResult vote_results{ | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::STR, "overall", "Total number of successful and failed votes"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::OBJ, "detail", "Detailed information for each vote", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::OBJ, "protx", "ProTx of masternode for voting", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::STR, "result", "Result of voting: {success|failed}"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::STR, "errorMessage", /*optional=*/true, "Error message if failed"}, | ||||||||||||||||||||||||||
| }}, | ||||||||||||||||||||||||||
| }}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| }; | ||||||||||||||||||||||||||
| } // anonymous namespace | ||||||||||||||||||||||||||
|
knst marked this conversation as resolved.
|
||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| static RPCHelpMan gobject_vote_many() | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| return RPCHelpMan{"gobject vote-many", | ||||||||||||||||||||||||||
|
|
@@ -494,7 +538,7 @@ static RPCHelpMan gobject_vote_many() | |||||||||||||||||||||||||
| {"vote", RPCArg::Type::STR, RPCArg::Optional::NO, "vote, possible values: [funding|valid|delete|endorsed]"}, | ||||||||||||||||||||||||||
| {"vote-outcome", RPCArg::Type::STR, RPCArg::Optional::NO, "vote outcome, possible values: [yes|no|abstain]"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| vote_results, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -547,7 +591,7 @@ static RPCHelpMan gobject_vote_alias() | |||||||||||||||||||||||||
| {"vote-outcome", RPCArg::Type::STR, RPCArg::Optional::NO, "vote outcome, possible values: [yes|no|abstain]"}, | ||||||||||||||||||||||||||
| {"protx-hash", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "masternode's proTxHash"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| vote_results, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -669,7 +713,18 @@ static RPCHelpMan gobject_list_helper(const bool make_a_diff) | |||||||||||||||||||||||||
| {"signal", RPCArg::Type::STR, RPCArg::Default{"valid"}, "cached signal, possible values: [valid|funding|delete|endorsed|all]"}, | ||||||||||||||||||||||||||
| {"type", RPCArg::Type::STR, RPCArg::Default{"all"}, "object type, possible values: [proposals|triggers|all]"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| RPCResult{"If request is valid", | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ, "hash", "Object details", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| // TODO: list fields of output for RPC help instead ELISION | ||||||||||||||||||||||||||
| {RPCResult::Type::ELISION, "", ""} | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResult{"If request is invalid", | ||||||||||||||||||||||||||
| RPCResult::Type::STR, "", "Error string" | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
|
knst marked this conversation as resolved.
|
||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -715,7 +770,15 @@ static RPCHelpMan gobject_get() | |||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {"governance-hash", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "object id"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| RPCResult{ | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| // TODO: list fields of output for RPC help instead ELISION | ||||||||||||||||||||||||||
| {RPCResult::Type::ELISION, "", ""} | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -811,7 +874,12 @@ static RPCHelpMan gobject_getcurrentvotes() | |||||||||||||||||||||||||
| {"txid", RPCArg::Type::STR_HEX, RPCArg::Default{""}, "masternode collateral txid"}, | ||||||||||||||||||||||||||
| {"vout", RPCArg::Type::STR, RPCArg::Default{""}, "masternode collateral output index, required if <txid> present"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{ | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ_DYN, "", "Keys are hashes of vote, values are votes", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::STR, "votes", "Human-friendly presentation of vote"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -877,7 +945,7 @@ static RPCHelpMan gobject() | |||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {"command", RPCArg::Type::STR, RPCArg::Optional::NO, "The command to execute"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{RPCResult::Type::NONE, "", ""}, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -899,7 +967,7 @@ static RPCHelpMan voteraw() | |||||||||||||||||||||||||
| {"time", RPCArg::Type::NUM, RPCArg::Optional::NO, ""}, | ||||||||||||||||||||||||||
| {"vote-sig", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, ""}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{RPCResult::Type::STR, "", "Result of voting"}, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -49,7 +49,9 @@ static RPCHelpMan masternode_connect() | |||||||||||||||||||||||||
| {"address", RPCArg::Type::STR, RPCArg::Optional::NO, "The address of the masternode to connect"}, | ||||||||||||||||||||||||||
| {"v2transport", RPCArg::Type::BOOL, RPCArg::DefaultHint{"set by -v2transport"}, "Attempt to connect using BIP324 v2 transport protocol"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{ | ||||||||||||||||||||||||||
| RPCResult::Type::STR, "status", "Returns 'successfully connected' if successful" | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -85,7 +87,28 @@ static RPCHelpMan masternode_count() | |||||||||||||||||||||||||
| return RPCHelpMan{"masternode count", | ||||||||||||||||||||||||||
| "Get information about number of masternodes.\n", | ||||||||||||||||||||||||||
| {}, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{ | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "total", "Total number of Masternodes"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "enabled", "Number of enabled Masternodes"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::OBJ, "details", "Breakdown of masternodes by type", | ||||||||||||||||||||||||||
| {{RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::OBJ, "regular", "Details for regular masternodes", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "total", "Total number of regular Masternodes"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "enabled", "Number of enabled regular Masternodes"} | ||||||||||||||||||||||||||
| }}, | ||||||||||||||||||||||||||
| {RPCResult::Type::OBJ, "evo", "Details for Evo nodes", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "total", "Total number of Evo nodes"}, | ||||||||||||||||||||||||||
| {RPCResult::Type::NUM, "enabled", "Number of enabled Evo nodes"} | ||||||||||||||||||||||||||
| }}, | ||||||||||||||||||||||||||
| }}, | ||||||||||||||||||||||||||
| }} | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -157,7 +180,13 @@ static RPCHelpMan masternode_status() | |||||||||||||||||||||||||
| return RPCHelpMan{"masternode status", | ||||||||||||||||||||||||||
| "Print masternode status information\n", | ||||||||||||||||||||||||||
| {}, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{ | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| // TODO: implement proper type validator instead ELISION | ||||||||||||||||||||||||||
| {RPCResult::Type::ELISION, "", ""} | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -232,7 +261,12 @@ static RPCHelpMan masternode_winners() | |||||||||||||||||||||||||
| {"count", RPCArg::Type::NUM, RPCArg::Default{10}, "number of last winners to return"}, | ||||||||||||||||||||||||||
| {"filter", RPCArg::Type::STR, RPCArg::Default{""}, "filter for returned winners"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{ | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ_DYN, "", "Keys are block heights (as strings); values describe the payees for that height", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {RPCResult::Type::STR, "payee", "Payee for the height"} | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
|
Comment on lines
+264
to
+269
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Clarify that values are comma-separated payment strings, not single payees. The description at line 267 says Apply this diff to clarify: - {RPCResult::Type::STR, "payee", "Payee for the height"}
+ {RPCResult::Type::STR, "payments", "Comma-separated list of payment addresses (masternode payout, operator reward if applicable, and superblock payees if triggered)"}📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -454,7 +488,7 @@ static RPCHelpMan masternode_help() | |||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| {"command", RPCArg::Type::STR, RPCArg::Optional::NO, "The command to execute"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{RPCResult::Type::NONE, "", ""}, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
@@ -491,7 +525,13 @@ static RPCHelpMan masternodelist_helper(bool is_composite) | |||||||||||||||||||||||||
| {"mode", RPCArg::Type::STR, RPCArg::DefaultHint{"json"}, "The mode to run list in"}, | ||||||||||||||||||||||||||
| {"filter", RPCArg::Type::STR, RPCArg::Default{""}, "Filter results. Partial match by outpoint by default in all modes, additional matches in some modes are also available"}, | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCResults{}, | ||||||||||||||||||||||||||
| RPCResult{ | ||||||||||||||||||||||||||
| RPCResult::Type::OBJ, "", "", | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
| // TODO: implement proper type validator instead ELISION | ||||||||||||||||||||||||||
| {RPCResult::Type::ELISION, "", ""} | ||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||
| }, | ||||||||||||||||||||||||||
| RPCExamples{""}, | ||||||||||||||||||||||||||
| [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue | ||||||||||||||||||||||||||
| { | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correct
protx listdiffhelp structureThe new help mixes up field names (
removedMnsvs actualremovedMNs) and repeatsaddedMNswhereupdatedMNsshould be, so callers now see keys that don’t exist. Please align the schema with the actual payload.Suggested fix:
📝 Committable suggestion
🤖 Prompt for AI Agents