5

Right-clicking on an unconfirmed transaction pops up a contextual menu that has the option "Abandon transaction". It is usually grayed out. How much time needs to pass for Bitcoin Core to allow one to choose "Abandon transaction"?

When I run abandontransaction on my transaction, it says:

Transaction not eligible for abandonment (code -5)

2 Answers 2

4

From the source:

src/wallet/wallet.cpp:1290:

return wtx && !wtx->isAbandoned() && GetTxDepthInMainChain(*wtx) == 0 && !wtx->InMempool();

Basically, it's abandoned if it's dropped out of one's own node's mempool.

2
  • @MichaelFolkson Sure, the TXN could be in someone's mempool. (And technically a miner could mine the pre-RBF transaction…)
    – Geremia
    Sep 24 at 22:19
  • 2
    The last sentence would be more precise if it were something like: “it can be abandoned only if it has been dropped from your own node’s mempool”.
    – Murch
    Sep 26 at 15:03
2

The option to abandon a transaction is only available if a) it has not been abandoned before, b) neither the transaction or a conflicting transaction is confirmed, and c) the transaction is not in your own node’s mempool.

Note that even when you abandon a transaction it might still be retained by other nodes. The only way to be sure that your original transaction cannot be mined in the future is to create a conflicting transaction that spends some of the same inputs and get it confirmed in the blockchain. This is exactly the intent behind abandontransaction. You inform your wallet that you are no longer pursuing confirmation for the abandoned transaction which instructs the wallet to permit reuse of the inputs used in it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.