Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: achow101 on January 20, 2016, 09:12:20 PM



Title: Remove a watch only address from Bitcoin Core
Post by: achow101 on January 20, 2016, 09:12:20 PM
Anyone know how to remove a watch only address from Bitcoin Core? I have a watch only address in my Bitcoin Core wallet that I don't want there but I can't figure out how to delete it. There is no RPC command for it that I could find and pywallet doesn't seem to be able to remove it.


Title: Re: Remove a watch only address from Bitcoin Core
Post by: unamis76 on January 20, 2016, 10:14:08 PM
This (http://bitcoin.stackexchange.com/questions/35431/how-do-you-delete-an-account-in-bitcoin-core) didn't help?

Quote
However, you can use the rpc call setaccount to change the account associated with the address. The first argument to setaccount should the the address you're changing; the second shound be the account you're moving it to. (If you want to move it to the default account, put "" as the second argument.)

Note that this does not change the balance of the account; balances are tracked internally. If you want to keep this consistent, run getreceivedbyaddress, then move that balance to the new account.

You can also use PyWallet to delete addresses permanently. Use the --multidelete option, and pass it a path to a file. That file should contain key as the first line, followed by each address you want to delete, each on a new line.


Title: Re: Remove a watch only address from Bitcoin Core
Post by: achow101 on January 20, 2016, 10:41:53 PM
This (http://bitcoin.stackexchange.com/questions/35431/how-do-you-delete-an-account-in-bitcoin-core) didn't help?

Quote
However, you can use the rpc call setaccount to change the account associated with the address. The first argument to setaccount should the the address you're changing; the second shound be the account you're moving it to. (If you want to move it to the default account, put "" as the second argument.)

Note that this does not change the balance of the account; balances are tracked internally. If you want to keep this consistent, run getreceivedbyaddress, then move that balance to the new account.

You can also use PyWallet to delete addresses permanently. Use the --multidelete option, and pass it a path to a file. That file should contain key as the first line, followed by each address you want to delete, each on a new line.
Nope. It doesn't delete the address and it didn't remove the address from my GUI. Besides, accounts are deprecated in Bitcoin Core.

I don't particularly care about this wallet so it doesn't matter that much to me if I delete the wallet and start over since I only use it for testing and armory. Although there are no coins in that wallet, I just want to avoid deleting it if possible.


Title: Re: Remove a watch only address from Bitcoin Core
Post by: cr1776 on January 21, 2016, 01:20:28 AM
You may have to use something like pywallet to edit it.  I don't believe you can do it in Core.

An alternative, of course, would be to export all the keys, delete that one and import, but pywallet seems cleaner.


Title: Re: Remove a watch only address from Bitcoin Core
Post by: achow101 on January 21, 2016, 01:27:53 AM
You may have to use something like pywallet to edit it.  I don't believe you can do it in Core.

An alternative, of course, would be to export all the keys, delete that one and import, but pywallet seems cleaner.
I don't think pywallet works here. Watch only was only added in 0.10.0 which was released in Early 2015. Pywallet hasn't been updated since Sep 2014. Also, I tried it and it didn't work.


Title: Re: Remove a watch only address from Bitcoin Core
Post by: cr1776 on January 21, 2016, 01:34:18 AM
You may have to use something like pywallet to edit it.  I don't believe you can do it in Core.

An alternative, of course, would be to export all the keys, delete that one and import, but pywallet seems cleaner.
I don't think pywallet works here. Watch only was only added in 0.10.0 which was released in Early 2015. Pywallet hasn't been updated since Sep 2014. Also, I tried it and it didn't work.

Hmmmm.  I'm not sure then, I would've thought it would work okay. 

You could always export them all then, clear it, and just reimport the ones you want. :-)