-
Notifications
You must be signed in to change notification settings - Fork 51
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
setaccount creates new address on first rename #34
Comments
Please review the documentation first about using setaccount and getnewaddress. |
There isn't any documentation for the RPC commands in this repo? From the bitcoin documentation: As I've provided in my steps to reproduce above I am using these commands as documented. The issue is creating a new address then renaming it the first time creates 2 new address instead of just re-assigning the account for the address. using set account again doesn't create another address. There seems to be a bug that the wallet isn't registering the existence of the newly created address when using the setaccount command for the first time. |
Please use: |
my apologies there was a type in my initial issues. It should be Steps to reproduce: the result will be the original address with label myNewAddressLabel1 and a new address with label myNewAddressLabel |
May I know what are you trying to achieve? |
@nisanb I'm trying to control a wallet via the RPC interface. My pull request #45 fixes this issue as well as some other RPC related bugs. The setaccount function was a bit confusing as there shouldn't be any reason to create a new address when changing the account of an existing address. The original issue for this bitcoin/bitcoin#29 was supposed to fix a bug around getaccountaddress but for some reason, they added code in the setaccount function to generate a new address if the account didn't exist |
When using the setaccount command on an exiting address for the first time a new address is created with the same account rather than changing the account of the original address.
Steps to reproduce:
in the Linda debug console run
getnewaddress myNewAddressLabel
setaccount myNewAddressLabel1
the result will be the original address with label myNewAddressLabel1 and a new address with label myNewAddressLabel
The text was updated successfully, but these errors were encountered: