rpc: Properly make RPCResult::Type::ANY non-test-only #35842

pull maflcko wants to merge 5 commits into bitcoin:master from maflcko:2607-rpc-any-result changing 4 files +42 −36
  1. maflcko commented at 5:53 AM on July 30, 2026: member

    Commit 6a1a66c180cba5f2d4189e89327de23505c7f4dd attempted to properly render RPC results of the type ANY.

    However, the commit is incomplete.

    Fix it, by properly rendering all ANY types.

    Moreover, a few trivial refactors after #34683 are included here.

  2. refactor: Use std::visit in ApplyArgFallback
    This is more explicit and comes with compile-time checks to ensure all default types are covered.
    000031be12
  3. DrahtBot renamed this:
    rpc: Properly make RPCResult::Type::ANY non-test-only
    rpc: Properly make RPCResult::Type::ANY non-test-only
    on Jul 30, 2026
  4. DrahtBot added the label RPC/REST/ZMQ on Jul 30, 2026
  5. DrahtBot commented at 5:53 AM on July 30, 2026: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--006a51241073e994b41acfe9ec718e94-->

    Code Coverage & Benchmarks

    For details see: https://corecheck.dev/bitcoin/bitcoin/pulls/35842.

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline and AI policy for information on the review process. A summary of reviews will appear here.

    <!--5faf32d7da4f0f540f40219e4f7537a3-->

  6. rpc: Properly make RPCResult::Type::ANY non-test-only
    This will render all ANY results.
    
    However, the one in the help RPC should still be hidden. This is done by
    applying HelpElisionSkip and also skipping over empty result sections in
    ToDescriptionString.
    
    Also, run clang-format. Can be reviewed via --ignore-all-space
    fa7b26bf6d
  7. maflcko force-pushed on Jul 30, 2026
  8. DrahtBot added the label CI failed on Jul 30, 2026
  9. maflcko commented at 6:33 AM on July 30, 2026: member

    Rendered diff:

    diff --git a/echo b/echo
    index 58d7d21..4f5d878 100644
    --- a/echo
    +++ b/echo
    @@ -17,3 +17,6 @@ Arguments:
     8. arg7     (string, optional)
     9. arg8     (string, optional)
     10. arg9    (string, optional)
    +
    +Result:
    +xxx    (any) Returns whatever was passed in
    diff --git a/echojson b/echojson
    index 15a45f8..7976600 100644
    --- a/echojson
    +++ b/echojson
    @@ -17,3 +17,6 @@ Arguments:
     8. arg7     (string, optional)
     9. arg8     (string, optional)
     10. arg9    (string, optional)
    +
    +Result:
    +xxx    (any) Returns whatever was passed in
    
  10. refactor: Remove stale NOLINTNEXTLINE above GetAddressInfoBaseFields
    There is no recursion.
    fad55b7fcc
  11. refactor: Use self.Arg<bool> in getopenrpcinfo
    This is clearer, because it does not encode the default value in the
    source code syntax. Also, using named args is clearer than positional
    args.
    
    Also, run clang-format on the new code.
    fa79cb3526
  12. refactor: Use CLIENT_NAME in buildOpenRPCDoc
    This refactor follow other uses of CLIENT_NAME, such as in RPCMethod stop().
    fa9bc46d39

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-07-31 20:50 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me