RPC: Fix currency unit string in the help text #11173

pull AkioNak wants to merge 1 commits into bitcoin:master from AkioNak:use_currency_unit_constant changing 3 files +6 −6
  1. AkioNak commented at 5:38 AM on August 28, 2017: contributor
    1. The RPC help text should use the constant CURRENCY_UNIT defined in policy/feerate.cpp instead of the literal 'BTC'. In the following 2 RPC commands, 'BTC' is written directly in the help text. This commit changes them to use that constant.

      1. estimatesmartfee
      2. estimaterawfee
    2. Some RPC command use 'satoshis' as the unit. It should be written as 'satoshis' instead of 'Satoshis' in the RPC help text. So, this commit fixes this typo in getblocktemplate.

  2. laanwj added the label Docs and Output on Aug 28, 2017
  3. MarcoFalke commented at 9:00 PM on August 31, 2017: member

    utACK 54cd27b

  4. jnewbery commented at 8:43 PM on September 1, 2017: member

    For both feerate help strings, I think the following text is more precise:

    "(numeric, optional) estimated fee rate (in " + CURRENCY_UNIT + "-per-kilobyte)\n"

  5. AkioNak commented at 1:54 PM on September 2, 2017: contributor

    @jnewbery Thank you for your comment. In other RPCs, there are 2 patterns for the notation of fee rate unit like this case:

    1. ... in " + CURRENCY_UNIT + "/kB" ... (In most cases)
    2. ... (" + CURRENCY_UNIT + " per KB)" ... (getmempoolinfo - mempoolminfee, fundrawtransaction - feeRate)

    So I think case 1. is better than using -per-kilobyte for these help strings of this PR. And case 2, I think it is better to modify per KB to /kB because KB implies KiB or Kibibyte (2^10 byte) and they just display the unit.

  6. AkioNak force-pushed on Sep 4, 2017
  7. AkioNak force-pushed on Sep 4, 2017
  8. AkioNak commented at 9:37 AM on September 4, 2017: contributor

    @jnewbery I fixed the feerate help strings.

  9. meshcollider commented at 11:42 AM on September 4, 2017: contributor

    /kB is better than -per-kilobyte imo but I prefer @jnewbery's string with the brackets overall with that small adjustment.

    Also please squash commits into 1

  10. jnewbery commented at 4:02 PM on September 4, 2017: member

    New help strings look good to me. Please squash commits and I'll re-review.

  11. Fix currency/fee-rate unit string in the help text
    1. The RPC help text should use the constant CURRENCY_UNIT defined in
      policy/feerate.cpp instead of the literal 'BTC'. In the following
      2 RPC commands, 'BTC' is written directly in the help text.
        1) estimatesmartfee
        2) estimaterawfee
      And also, for these help strings, the notation
      'fee-per-kilobyte (in BTC)' is somewhat ambiguous.
    
      To write more precisely, this commit changes to 'fee rate in BTC/kB'
      with using the constant CURRENCY_UNIT.
    
    2. Some RPC command use 'satoshis' as the unit. It should be written
      as 'satoshis' instead of 'Satoshis' in the RPC help text.
    
      So, this commit fixes this typo in getblocktemplate.
    
    3. The phrase that '... feerate (BTC per KB) ...'  is used to explain
      the fee rate in the help text of following 2 RPC commands.
        1) getmempoolinfo
        2) fundrawtransaction
      But they are different from other similar help text of the RPCs.
      And also, 'KB' implies Kibibyte (2^10 byte).
    
      To unify and to clarify, this commit changes these phrase to
      '... fee rate in BTC/kB ...'.
      (BTC references the constant 'CURRENCY_UNIT')
    47ba2c312a
  12. AkioNak force-pushed on Sep 5, 2017
  13. AkioNak commented at 3:47 AM on September 5, 2017: contributor

    @jnewbery @MeshCollider I squashed the commits.

  14. jnewbery commented at 7:49 PM on September 5, 2017: member

    Tested ACK 47ba2c312a440baff5ebc911e3bb014643f4e9c3

  15. MarcoFalke commented at 9:46 PM on September 5, 2017: member

    re-utACK 47ba2c3

  16. MarcoFalke merged this on Sep 5, 2017
  17. MarcoFalke closed this on Sep 5, 2017

  18. MarcoFalke referenced this in commit 4eb1f39d42 on Sep 5, 2017
  19. AkioNak deleted the branch on Oct 10, 2017
  20. PastaPastaPasta referenced this in commit bd2cd32da3 on Sep 20, 2019
  21. PastaPastaPasta referenced this in commit 43b09909e6 on Sep 23, 2019
  22. PastaPastaPasta referenced this in commit d7283dd785 on Sep 24, 2019
  23. PastaPastaPasta referenced this in commit 1096d21749 on Dec 22, 2019
  24. PastaPastaPasta referenced this in commit 3e8052a1d9 on Jan 2, 2020
  25. PastaPastaPasta referenced this in commit 09c77015e4 on Jan 4, 2020
  26. PastaPastaPasta referenced this in commit d9ddee9c19 on Jan 4, 2020
  27. PastaPastaPasta referenced this in commit 4b289a80cd on Jan 10, 2020
  28. PastaPastaPasta referenced this in commit ac302f66e9 on Jan 10, 2020
  29. PastaPastaPasta referenced this in commit 9f672f82a1 on Jan 10, 2020
  30. PastaPastaPasta referenced this in commit 1d40b61047 on Jan 12, 2020
  31. ckti referenced this in commit 587c097e5c on Mar 28, 2021
  32. DrahtBot locked this on Sep 8, 2021

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-04-22 18:15 UTC

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