Skip to content

test: remove usages of MAX_BIP125_RBF_SEQUENCE constant from functional tests - #35442

Draft
rkrux wants to merge 13 commits into
bitcoin:masterfrom
rkrux:rbfsequence-test
Draft

rkrux wants to merge 13 commits into
bitcoin:masterfrom
rkrux:rbfsequence-test

Conversation

@rkrux

@rkrux rkrux commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

Partially fixes #32661.

Depends on #35433 from which the
first 11 commits are added here and will be removed when this PR is
undrafted. Only the last 2 commits are specific to this PR.

This is in line with the removal and deprecation of BIP 125 RBF signalling
from the codebase.

rkrux added 13 commits June 2, 2026 15:47
With the nodes running fullrbf, wallet doesn't need to opt into RBF. This patch
switches the default of wallet rbf to false. Users still have the option to
optin RBF via the individual transaction (and PSBT) creation RPCs - for now.
Post deprecation of -walletrbf startup option and removal of the same
option from the wallet_bumpfee.py test, the second node in this test
is no longer a rbf node, so update its name to reflect so.

Also update the rbf_node_address correspondingly.
Tested RPCs: createrawtransaction, fundrawtransaction, createpsbt, bumpfee
walletcreatefundedpsbt, send, sendtoaddress, sendmany, sendall, psbtbumpfee.
…tests

Remove the usage in all the tests where used except the ones where the
sequence is set to unique values to avoid creating duplicate transactions
simultaneously.
… one

Its usage is preserved only in wallet_deprecated_rbf.py and thus the constant
is moved there. This will be removed as well in the next release when BIP 125
deprecated stuff is removed.
@DrahtBot DrahtBot added the Tests label Jun 2, 2026
@DrahtBot

DrahtBot commented Jun 2, 2026 •

Copy link
Copy Markdown
Contributor

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

External sites

Reviews

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

Conflicts

Reviewers, this pull request conflicts with the following ones:

  • #35543 (test: introduce ExtendedPrivateKey and ExtendedPublicKey classes by rkrux)
  • #35472 (test: add coverage for feebumper uncomputable cluster error path by 151henry151)
  • #35433 (wallet: deprecate replaceable argument from transaction (and psbt) creation (and modification) RPCs by rkrux)
  • #35302 (Silent Payments: Sending (take 2) by Eunovo)
  • #35100 (rpc: Merge joinpsbts locktimes correctly by nervana21)
  • #32468 (rpc: generateblock to allow multiple outputs by polespinasa)
  • #29278 (Wallet: Add maxfeerate wallet startup option by ismaelsadeeq)

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

LLM Linter (✨ experimental)

Possible places where named args for integral literals may be used (e.g. func(x, /*named_arg=*/0) in C++, and func(x, named_arg=0) in Python):

  • walletcreatefundedpsbt(..., False) in test/functional/rpc_psbt.py
  • walletcreatefundedpsbt(..., True) in test/functional/rpc_psbt.py

2026-06-02 13:47:25

@maflcko

maflcko commented Jun 8, 2026

Copy link
Copy Markdown
Member

Not sure if a small test-only fixup needs a separate pull request. Can those two commits not just be included in the prior pull?

Also, it seems more important to remove MAX_BIP125_RBF_SEQUENCE from the real source code, so that the risk of pre-existing and future fingerprint vectors in this source code is reduced.

@rkrux

rkrux commented Jun 10, 2026

Copy link
Copy Markdown
Contributor Author

it seems more important to remove MAX_BIP125_RBF_SEQUENCE from the real source code, so that the risk of pre-existing and future fingerprint vectors in this source code is reduced.

Yes, it is more important but it can't be done cleanly until the feature is removed completely post deprecation.
Whereas it can be done easily in functional tests because all the tests have been updated to not rely on this deprecated feature anymore.

Can those two commits not just be included in the prior pull?

I will look into it.

@rkrux

rkrux commented Jun 10, 2026

Copy link
Copy Markdown
Contributor Author

I will look into it.

I didn't want to increase the scope of the previous PR, that's why raised this
separate PR here. I have pushed the last two test related commits in #35433
now but might remove them later if I notice they are making the review of that
PR tougher for others.

@rkrux

rkrux commented Jun 10, 2026

Copy link
Copy Markdown
Contributor Author

Actually, no.

The first two commits here are from #35405 due to which these two commits
can't be appended cleanly in #35433. I'll wait on the resolution of #35405.

@pablomartin4btc

pablomartin4btc commented Jun 12, 2026 •

Copy link
Copy Markdown
Member

I'll wait on the resolution of #35405.

Perhaps you can add that to the description too ("Depends on #35405 - first 2 commits - and #35433 - 9 commits"). Sorry, I'm late to the party and trying to follow the review order from the issue's pending list.

Comment on lines +24 to +25
Moreover, the default value of -walletrbf startup option has been
switched to 0 in PR #35405.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that needs to be updated according to https://github.com/bitcoin/bitcoin/pull/35405/changes#r3340846939. Just for reference, I know this is still a draft.

@DrahtBot

Copy link
Copy Markdown
Contributor

🐙 This pull request conflicts with the target branch and needs rebase.

@DrahtBot

Copy link
Copy Markdown
Contributor

⌛ There hasn't been much activity lately and the patch still needs rebase. What is the status here?

  • Is it still relevant? ➡️ Please solve the conflicts to make it ready for review and to ensure the CI passes.
  • Is it no longer relevant? ➡️ Please close.
  • Did the author lose interest or time to work on this? ➡️ Please close it and mark it with one of the labels 'Up for grabs' or 'Insufficient Review', so that it can be picked up in the future.

@rkrux

rkrux commented Oct 26, 2026

Copy link
Copy Markdown
Contributor Author

Re #35442 (comment): Waiting on #35433 to get merged and then will see how to progress on this PR.

@rreview

rreview commented Oct 26, 2026

Copy link
Copy Markdown

Ralph found major issues at 7e4a0c5.

Default sendall inputs disable locktime activation (src/wallet/rpc/spend.cpp:1452, head)

When sendall selects inputs automatically and the deprecated replaceable override is not enabled, the new default makes rbf false and the automatic-input branch assigns SEQUENCE_FINAL. Final sequences disable nLockTime, so a caller-supplied nonzero locktime is ineffective. The same sequence prevents FinishTransaction from applying anti-fee-sniping; the existing default-path wallet_sendall test expects that behavior. The public sendall RPC is the triggering input path; no external application caller was checked.

Full report

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

wallet, node: Redundant opt-in RBF wallet config and RPC parameters

5 participants