Page MenuHomePhabricator

Pass rpc/mining RPC argument descriptions to RPCHelpMan
ClosedPublic

Authored by nakihito on Apr 13 2020, 18:41.

Details

Summary

PR14796 changes the help text of the dummy argument in
prioritisetransaction from optional to required. PR14785 was added to
prevent this.

Merge #14875: RPCHelpMan: Support required arguments after optional ones

fa9a5bc1a0 RPCHelpMan: Support required arguments after optional ones (MarcoFalke)

Pull request description:

There was a requirement that required arguments could not be positioned after an optional argument, but the deprecation of priority made the second argument to `prioritisetransaction` optional. So support that in `RPCHelpMan`.

Also format all named arguments in the same way (without the wrapping `"` even for strings), since the extended description already mentions the type and it feels odd to special case strings.

Tree-SHA512: c125145afb4a63abc995aaf0a89489efc0f470a720727a1ca6ee0bfd2bcbc59e87c38128dd1e0cdf03dbb5b18e84867887c3dabf6ec8378e66cb1f4cecb9e407

Partial backport of Core PR14796 and PR14875

Test Plan
mkdir master
mkdir patched

On master:

ninja
./bitcoind
./bitcoin-cli help > RPCs
./getrpchelps.sh RPCs master

On the patched branch:

ninja
./bitcoind
./getrpchelps.sh RPCs patched
./checkrpc.sh RPCs master patched D5714diff

Verify the changes in D5714diff.

Scripts:


D5714diff:

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Owners added a reviewer: Restricted Owners Package.Apr 13 2020, 18:41

[Bot Message]
One or more PR numbers were detected in the summary.
Links to those PRs have been inserted into the summary for reference.

nakihito edited the test plan for this revision. (Show Details)
This revision is now accepted and ready to land.Apr 14 2020, 11:50