wealdtech/ethdo

`Failed to unlock account` error on `ethdo validator exit`

Closed this issue · 7 comments

I am trying to import a validator key keystore and generate an exit message for it:

./ethdo wallet create --wallet=wallet
./ethdo account import --account=wallet/account --keystore=keystore.json --keystore-passphrase=12345678 --passphrase=pass --allow-weak-passphrases
./ethdo validator exit --validator=wallet/account --passphrase=pass --connection="https://RPC" --json --verbose --debug

But this results in an error:

Error: failed to process: failed to unlock account

Am I doing something wrong?

Complete log:

Increasing timeout to 2m0s
Failed to read offline preparation file: stat offline-preparation.json: no such file or directory
Populating chain info from beacon node
Genesis validators root obtained from chain info
Using genesis validators root 0x043db0d9a83813551ee2f33450d23797757d430911a9320530ad8a0eabc43efb
Fork version obtained from chain info
Using fork version 0x02001020
Domain is 0x04000000c2ce3aa85707d491e3dd033a53971deb9bed9d4813d74c99369642f5
Error: failed to process: failed to unlock account

I'm on latest ethdo version:

> ./ethdo version  
1.28.0

It also appears that in docs:

$ ethdo validator exit --account=Validators/1 --passphrase="my validator secret"

Should be:

$ ethdo validator exit --validator=Validators/1 --passphrase="my validator secret"
mcdee commented

Thank you for reporting this issue. It has been addressed in 5dcdf9c and will be available in the next release.

Thanks a lot for a quick fix!

Tested the just released version 1.28.1, now getting an a bit different error:

Error: failed to process: failed to parse validator account: failed to unlock account

Repeating the exact commands from the initial message.

mcdee commented

Apologies, could you give this a go with 1.28.3 and see if it is behaving?

Working now, thank you!

I had the same problem with the latest version

./ethdo validator exit --base-dir=/data/wallet --json --account=withdrawal-validator/0 --passphrase="XXXXXX" --debug > /data/withdrawal.json
Increasing timeout to 2m0s
Failed to read offline preparation file: stat offline-preparation.json: no such file or directory
Populating chain info from beacon node
Genesis validators root obtained from chain info
Using genesis validators root 0x043db0d9a83813551ee2f33450d23797757d430911a9320530ad8a0eabc43efb
Fork version obtained from chain info
Using fork version 0x03001020
Domain is 0x04000000628941ef21d1fe8c7134720add10bb91e3b02c007e0046d2472c6695
Error: failed to process: unknown validator

I'm on latest ethdo version:

> ./ethdo version
1.28.4

That's probably a different issue as I was getting "failed to unlock account", not "unknown validator" error.

Make sure that a validator with such public key actually exists on the network you are trying to generate an exit on.

I don't see --connection being specified in your command, try specifying a Consensus Node address in it for an appropriate network.