jonatack
commented at 1:17 PM on March 24, 2023:
member
CI builds currently fail when IsDeprecatedRPCEnabled() is called from wallet RPCs with "Undefined reference to IsDeprecatedRPCEnabled in libbitcoin_wallet".
Fix the issue by moving IsDeprecatedRPCEnabled() from rpc/server to rpc/util, thereby moving it from node to common to be picked up by libbitcoin_wallet (see doc/design/librairies.md and src/Makefile.am).
This move allows us to drop the redundant rpcEnableDeprecated() method. Per the comment in src/interfaces/chain.h::L107 from #15639 we would like to remove these, and this function doesn't seem constrained by the mentioned HTTP port requirement, nor needed if IsDeprecatedRPCEnabled is in common rather than node.
This allows having only one call for this functionality and avoids developer confusion and head-scratching.
If it is preferred to keep all of them, this pull could alternatively document the use of these different methods for future developers doing a deprecation.
DrahtBot
commented at 1:17 PM on March 24, 2023:
contributor
<!--e57a25ab6845829454e8d69fc972939a-->
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
<!--021abf342d371248e50ceaed478a90ca-->
Reviews
See the guideline for information on the review process.
If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.
<!--174a7506f384e20aa4161008e828411d-->
Conflicts
Reviewers, this pull request conflicts with the following ones:
#27757 (rpc: remove deprecated "warning" field from {create,load,restore,unload}wallet by theStack)
#27101 (Support JSON-RPC 2.0 when requested by client by pinheadmz)
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.
DrahtBot added the label Refactoring on Mar 24, 2023
maflcko
commented at 1:34 PM on March 24, 2023:
member
lgtm
Maybe explain that this moves it from node to common?
jonatack force-pushed on Mar 24, 2023
jonatack
commented at 2:37 PM on March 24, 2023:
member
maflcko
commented at 4:54 PM on March 30, 2023:
member
Actually, on a second though. Any reason why you can't just call rpcEnableDeprecated?
jonatack
commented at 7:11 PM on March 30, 2023:
member
Any reason why you can't just call rpcEnableDeprecated?
Good question. Looking at it, maybe we can remove it? Per this comment in src/interfaces/chain.h::L107 from #15639 we would like to remove these, and this function doesn't seem constrained by the mentioned HTTP port requirement or needed if IsDeprecatedRPCEnabled is in common rather than node (the first commit here). @ryanofsky wdyt?
//! * The handleRpc, registerRpcs, rpcEnableDeprecated methods and other RPC
//! methods can go away if wallets listen for HTTP requests on their own
//! ports instead of registering to handle requests on the node HTTP port.
DrahtBot added the label Needs rebase on Apr 12, 2023
jonatack renamed this: move-only: IsDeprecatedRPCEnabled to rpc/util to fix CI builds when called from wallet Move IsDeprecatedRPCEnabled to be callable from wallet, rm redundant rpcEnableDeprecated on Apr 21, 2023
move-only: IsDeprecatedRPCEnabled to rpc/util to fix builds when called from wallet
CI builds confusingly fail with "undefined reference to IsDeprecatedRPCEnabled
in libbitcoin_wallet" compiler errors when this function is called from wallet
RPCs.
Fix this by moving IsDeprecatedRPCEnabled() from rpc/server to rpc/util,
thereby moving it from node to common to be picked up by libbitcoin_wallet
(see doc/design/librairies.md and src/Makefile.am).
1a1f3518ed
jonatack force-pushed on Apr 21, 2023
rpc: switch wallet deprecation to IsDeprecatedRPCEnabled1c42fc48b8
Per the comment in src/interfaces/chain.h::L107, it looks like we want to remove
these, and this function doesn't seem constrained by the HTTP port requirement:
//! * The handleRpc, registerRpcs, rpcEnableDeprecated methods and other RPC
//! methods can go away if wallets listen for HTTP requests on their own
//! ports instead of registering to handle requests on the node HTTP port.
Further, rpcEnableDeprecated() is unneeded if IsDeprecatedRPCEnabled() is in
common rather than node and thereby callable from the wallet, and it is
confusingly redundant to keep it.
9ed9b50068
jonatack force-pushed on Apr 21, 2023
DrahtBot added the label CI failed on Apr 21, 2023
jonatack renamed this: Move IsDeprecatedRPCEnabled to be callable from wallet, rm redundant rpcEnableDeprecated Move IsDeprecatedRPCEnabled to rpc/util, rm redundant rpcEnableDeprecated on Apr 21, 2023
DrahtBot removed the label Needs rebase on Apr 21, 2023
DrahtBot removed the label CI failed on Apr 21, 2023
jonatack
commented at 6:02 PM on April 21, 2023:
member
Rebased 😃
brunoerg approved
brunoerg
commented at 6:32 PM on May 8, 2023:
contributor
crACK9ed9b50068a3cbcf48264d814ffe73e0b9ed10b4
nit: s/librairies/libraries in 1a1f3518ed4eb2b18c63d98fbdca10a2cda8bf1e message
maflcko
commented at 6:36 AM on May 9, 2023:
member
Is gArgs guaranteed to be identical in different processes? If not, it would be good to explain why this behavior change is intentional. If yes, it would be good to explain as well.
DrahtBot added the label Needs rebase on Jun 16, 2023
DrahtBot
commented at 7:42 PM on June 16, 2023:
contributor
<!--cf906140f33d8803c4a75a2196329ecb-->
🐙 This pull request conflicts with the target branch and needs rebase.
fanquake
commented at 10:03 AM on August 1, 2023:
member
Needs a rebase, if still relevant, and the question above also needs addressing.
achow101
commented at 4:20 PM on September 20, 2023:
member
Closing this as it has not had any activity in a while. If you are interested in continuing work on this, please leave a comment so that it can be reopened.
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-14 21:13 UTC
This site is hosted by @0xB10C More mirrored repositories can be found on mirror.b10c.me