100,000 ṩ/vB is excessive as a sanity check on feerate #29661

issue murchandamus openend this issue on March 15, 2024
  1. murchandamus commented at 2:20 pm on March 15, 2024: contributor

    Are we sure that 100,000 ṩ/vB is not a bit high especially for a default that can be overridden? It seems to me that we would probably want at least one if not two magnitudes lower, especially if we are looking at a complete package and therefore already consider children bumping parents in the appropriate context?

    Originally posted by @murchandamus in #28950

    Reviewing #28950 I was reminded that our default maxfeerate is 100,000 sat/vB. We have only seen blocks with minimum feerates of over 1000 sat/vB once in a brief time-frame around Christmas 2017.

    100,000 sat/vB seems too high to appropriately fulfill its function as a safeguard against accidental fee overpayment. I would suggest to reduce it to 5000 sat/vB in the GUI, and perhaps even to 1000 when building a transaction from the command line where it is easy to override the maxfeerate when such a high feerate is actually warranted (e.g. when creating a small child transaction bumping a large parent).

  2. bitcoin deleted a comment on Mar 19, 2024
  3. bitcoin deleted a comment on Mar 19, 2024
  4. willcl-ark added the label Wallet on Mar 20, 2024
  5. ismaelsadeeq commented at 1:46 pm on March 25, 2024: member

    I think its lower than that but correct me if I am wrong here.

    The default limit is defined in https://github.com/bitcoin/bitcoin/blob/53f4607cc8c67366662f49cb312d2e4ff8b6523a/src/node/transaction.h#L27

    1 COIN represents 1 BTC. https://github.com/bitcoin/bitcoin/blob/53f4607cc8c67366662f49cb312d2e4ff8b6523a/src/consensus/amount.h#L15

    The calculation of CFeerate(COIN/10) initializes nSatoshiPerK as = 100000000 / 10 = 10000000, which represents satoshis per 1000 virtualbytes. https://github.com/bitcoin/bitcoin/blob/53f4607cc8c67366662f49cb312d2e4ff8b6523a/src/policy/feerate.h#L42

    Default -maxfeerate is 10,000,000 ṩ/kvB

    To convert 10,000,000 ṩ/kvB to ṩ/vB:

    10,000,000 ṩ/kvB ÷ 1000 = 10,000 ṩ/vB

    So its lower than 100,000  ṩ/vB

  6. murchandamus commented at 8:21 pm on March 26, 2024: contributor

    Thanks, you are right. I misread the help text for the RPC argument maxfeerate as stating the current default, but it was describing an upper bound.

    0            {"maxfeerate", RPCArg::Type::AMOUNT, RPCArg::Default{FormatMoney(DEFAULT_MAX_RAW_TX_FEE_RATE.GetFeePerK())},
    1             "Reject transactions whose fee rate is higher than the specified value, expressed in " + CURRENCY_UNIT +
    2                 "/kvB.\nFee rates larger than 1BTC/kvB are rejected.\nSet to 0 to accept any fee rate."},
    
  7. murchandamus closed this on Mar 26, 2024

  8. maflcko commented at 9:00 am on March 27, 2024: member
    Maybe the docs should be clarified to say that fee rates larger than 1BTC/kvB are always unconditionally rejected, or that this RPC parameter can not be set to fee rates larger than 1BTC/kvB?

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: 2024-09-28 22:12 UTC

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