replace by fee – Prioritize transaction with low fee [regtest]


send '{"bcrt1qgz8qhrqyglh7zu3alssydsfa7wk2auucftfnv3": 0.2}' null "unset" 1.1
  "txid": "d040ebe603f80bdf1a92877efeb2b4a27c32766202aeecf3a969b665a0d4c6d8",
  "complete": true

Bump fee:

bumpfee d040ebe603f80bdf1a92877efeb2b4a27c32766202aeecf3a969b665a0d4c6d8


  "txid": "14f13ad9e757752fce52be3f60a08ff697db646863e68f43e76bd1e70eb4504f",
  "origfee": 0.00000228,
  "fee": 0.00001268,
  "errors": [

Prioritize Tx1:

prioritisetransaction "d040ebe603f80bdf1a92877efeb2b4a27c32766202aeecf3a969b665a0d4c6d8" 0.0 2536

Mine a block:

generatetoaddress 1 "bcrt1qh3v7u6qv46q26srjtjux3cg2g35qlyjf8fqgej"

Why does Tx2 get included in the block even though I tried to prioritize Tx1:

getblock "7901e58c61d7e4ed0a07aaef382b5ca6c2f3ec146ed093f443c5e322d4ba3848" 2

If this is related to mempool conflicts and the way they are managed in Bitcoin Core, how can I test below scenario using regtest:

  1. User broadcasts Tx1 which is relayed and now in the mempool of a node used by mining pools.
  2. User replaces it using RBF with Tx2, this transaction is not yet relayed to mempool of nodes used by mining pools.
  3. Next block is mined and Tx1 is included in the block