-
Notifications
You must be signed in to change notification settings - Fork 37.7k
doc: Include wallet path to relevant RPC calls #19349
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
If only one wallet is loaded then this is not true - to not break clients pre multiwallet - see |
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ConflictsReviewers, this pull request conflicts with the following ones:
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. |
Oh thanks! I'll correct the commit message. I did not realise I had several wallets loaded when I encountered the issue. I think we should still update the doc as this is the way forward. |
This comment has been minimized.
This comment has been minimized.
Yes, I think so too. The examples only have to work against the current version anyway, there is no need for compatibility there. Edit: Do we want to do a similar thing ( |
Happy to give it a whack but I don't think we should stop merging this PR because of this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -118,10 +118,20 @@ std::string HelpExampleCli(const std::string& methodname, const std::string& arg | |||
return "> bitcoin-cli " + methodname + " " + args + "\n"; | |||
} | |||
|
|||
std::string HelpExampleRpc(const std::string& methodname, const std::string& args) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just add const std::string& path = {}
argument here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, thanks!
Since the addition of multiwallet support and if there are more than one loaded wallet, the url should have the wallet name in the path: `http://localhost:8332/wallet/testwallet`. This patch corrects the documentation. Note that for `unloadwallet` the wallet name can be passed in two manners: as an argument or in the url path. Hence, I added an example to show both ways.
If we drop those examples, how should one guess that |
🐙 This pull request conflicts with the target branch and needs rebase. Want to unsubscribe from rebase notifications on this pull request? Just convert this pull request to a "draft". |
For wallet-related RPC calls, the url must have the wallet
name in the path:
http://localhost:8332/wallet/testwallet
.This patch corrects the documentation.
Note that for
unloadwallet
2 forms are accepted: wallet name in the path andwallet name as an argument. Hence, I added an example to show both ways.