Author

Topic: Odd importprivkey behavior? (Read 3169 times)

newbie
Activity: 30
Merit: 0
April 07, 2013, 01:35:30 PM
#6
If a new private key is added it ends up in the address book first. Well, we see only its address.

When the next new block is received and processed that new address is scanned against the new block (transaction list) and the address moves to "receive coins".

Still a rescan is needed if that address has old coins sitting around as without a rescan you will never see them.


hero member
Activity: 520
Merit: 500
February 06, 2013, 03:11:12 PM
#5
I've haven't used that function previous to 0.7.1, so I don't know if it's new. Same thing happened to me. Just had to restart bitcoin-qt before it showed up in the right spot. I figure that it adds it to the wallet.dat file, but doesn't re-import it to the program. Or something. It's on my growing list of user unfriendly features of Bitcoin-qt.
newbie
Activity: 28
Merit: 0
February 05, 2013, 07:16:41 PM
#4
This is a semi-old thread, but I wanted to report to you all what happened to me.

I imported a private key, and as stated in the OP, it showed up in my "Address Book", not my "Receive Coins" list. Well, what I did was shut down the Bitcoin-QT client and re-opened it. When I re-opened it, it told me the wallet was out of sync, and after it finished getting IN sync (hahaha) it showed up in my "Receive Coins" list like I expected it to from the get-go.

I haven't tested sending money to it and sending money out of it, but I'll do that later on when I have enough coins to lost in case something goes wrong.
member
Activity: 77
Merit: 10
January 05, 2013, 12:20:10 PM
#3
There's definitely something quirky.  I tried previously in the GUI and had to restart it sometimes to get the newly imported addresses to appear.
legendary
Activity: 1890
Merit: 1086
Ian Knowles - CIYAM Lead Developer
January 05, 2013, 10:56:26 AM
#2
Actually in playing around with the "raw tx's" API and then using "importprivkey" for an "offline" generated address I experienced a similar problem (didn't see the address in the "receive" list but did see the unspent output in the "listunspent" list).

I resolved my problem by sending another tx from the unspent output to another address that *was* in my "receive" list but still don't quite understand why the problem happened.
legendary
Activity: 3472
Merit: 4801
January 04, 2013, 12:12:24 PM
#1
I'm not sure if this is:

  • A known issue with 0.7.1
  • Something I did wrong
  • Something I'm misunderstanding

In the Debug window Console, I entered:
Code:
importprivkey 5Kb8kLf9zgWQnogidDA76MzPL6TsZZY36hWXMssSzNydYXYB9KF "This is a test"

Issue 1
After the client finished scanning the blockchain, the "This is a test" label showed up in the "Address Book" tab in my client?  I expected to see it in my "Receive coins" tab.

I selected the "This is a test" row from the "Address Book" and clicked the "Delete" button on the bottom of the window.  The "This is a test" row disappeared from the window as expected.

In the Debug window Console, I then entered:
Code:
dumpprivkey 1CC3X2gu58d6wXUWMffpuzN9JAfTUWu4Kj

I received the previously imported 5Kb8kLf9zgWQnogidDA76MzPL6TsZZY36hWXMssSzNydYXYB9KF key as output.  I assumed that this means that the private key and address are still in my wallet even though the address no longer shows up in either the "Address Book" window nor the "Receive coins" window.  I figured maybe the client was recognizing the address the way it does a change address.

In the Debug window Console, I then entered:
Code:
listreceivedbyaddress 0 true

Issue 2
I expected this to list ALL addresses in my wallet.  However, I didn't see the 1CC3X2gu58d6wXUWMffpuzN9JAfTUWu4Kj in the list at all?

Any explanations as to what is going on here would be appreciated.
Jump to: