Nubits wallet crashing as coins unpark

I find as long as I don’t import the unpark address the wallet works. The coins are still in parked status, with 0.0 min left. Maybe it has something to do with these coin being parked with the 0.3.0 wallet? How do I get the parked coins back?

Discussing this with the team. Save the problem wallet for now.

The history of the coins are:

  1. a number of NBT goes to address A
  2. 5 NBT from address A is parked for 11.4 days, the unpark address being B
  3. 11.4 days is up. Coins are still parked. Wallet hangs if it has B, even B is the only address it has. It doesn’t if only has A.

I will save the wallet with A and B and use a new wallet without A or B.

@sigmike is looking into this further.

Thanks. Let me know if I can help.

What error message do you get?

Try running unpark in the debug console of the NuBits wallet.

What error message do you get?

The same one in the top message above.

I am waiting for the wallet to sync before trying unpark. It has been stuck at block 40975 for almost an hour now (8 connections).
btw unparking is not automatic?

Yes it’s automatic. It’s done at random interval. The unpark command triggers the same process in a slightly different way so the result may help me understand what’s going on. Because I haven’t found a way to reproduce the problem yet.

OK the wallet is sync’ed. 1) I first tried with wallet with only address A. I get

[
]

from the unpark command on the console.

On the main GUI of the wallet the “parked” line still has 5. Pressing the park button of the wallet I see an empty display.

  1. Then I restarted the wallet with the a wallet that has addresses A and B, disconnected from the LAN, and imported private key of address B. Then I reconnect with the internet, a few seconds later the wallet hangs. This shows that it is impossible to run unpark with a wallet that has address B while online.

  2. Kill the wallet process. I unconnected the LAN, start a wallet with address A, import address B. I can see parked coins in "park’ GUI. Run unpark. The wallet immediately hangs.

Hope this helps. I can send you the keys. They have only $5 so it’s no big deal.

Have you tried the same process with he daemon? It’s a few extra steps but I can assist through chat in trying it.

Is the following what you wanted?

  1. start wallet with address A (See above post for nu.conf)

D:…\nu\daemon>nud unpark
[
]

D:…\nu\daemon>nud importprivkey xxxx…xx

D:…\nu\daemon>nud unpark

  1. The wallet hangs.

xxxx…xx is the private key of address B

Maybe it is relevant: as reported here, when I parked the coins the premium I would get was less than the tx fee.

You are importing the NuBits private key into the NuShares wallet. That’s certainly the cause of the 2 problems (this one and Got unexpected NSR in my wallet).

Try importing the private key with nud -unit=B importprivkey xxx, or inside the NuBits debug console.

I realize we didn’t make the NuBits and NuShares private key different so there’s no check to prevent that. We will fix that.

That can explain the NSR. But the crash had happened before I took the suggestion and tried to import the key with nud here. So it doesn’t explain why the wallet crashes.

Anyway I have added the -unit=B option to every step in the above post and still get the same result.

new development:
After the above post I started the client with an empty B wallet, my S wallet received 5.002NSR. 5.002 is the parked amount plus premium. Why didn’t this happen before? Something has changed. Something has triggered an transaction. Might be what I did in my above post.

Then I quit the wallet and moved walletS.dat to walletS1.dat and restarted. I now have fresh B and S wallets. I import the privkey to the B wallet from the console. The wallet doesn’t crash this time. A few seconds later I receive 5.002NBT in the B wallet! This means that the S wallet and the B wallet are somehow connected.

Finally I started with the original B and S wallets. Now I have my parked NBT back. Nothing crashes. The reason of original crash, before there were no priv key funny business, is still unexplained.

@sigmike Please check your PM.

You probably still had the NuBits address in your NuShares wallet. When you imported the address into the NuBits wallet, I guess the unpark worked despite the crash. So at the next start the NuShares wallet saw the unpark transaction and believed it was its, hence the incoming 5.002 NSR. We will fix this behavior too.

I am glad it’s over although the original crash remain unexplained. Maybe it was something in the 0.3.0 wallet.

I suspect I won’t be the last person who get confused with the similar interface of NBT and NSR wallets. How about changing font and color of NSR interface. Make NSR dark background or something…

Additional visual differentiation of the wallet “sides” is a good thing, so when we start to look at the UI again in the near future, we’ll see what we can do. If anyone in the community wants to provide mockups of how they envision this differentiation, we’d be more than happy to take a look and work to incorporate it if there’s consensus that it is an improvement.