dashpay / dash

Dash - Reinventing Cryptocurrency
https://www.dash.org
MIT License
1.49k stars 1.2k forks source link

regtest mode for macOS doesn't work as expected. #2053

Closed thenakulchawla closed 6 years ago

thenakulchawla commented 6 years ago

I have been trying to generate blocks using the regtest mode,

dashd -regtest -daemon dash-cli -regtest generate 1

I keep getting the error:

error code: -12 error message: Error: Keypool ran out, please call keypoolrefill first

Unable to resolve this. All documentation online talks about -testnet, nothing to look for -regtest. Please help.

UdjinM6 commented 6 years ago

You probably use encrypted wallet.dat and used all addresses from keypool already. Either unlock your wallet via walletpassphrase rpc to let wallet generate new address for you or use generatetoaddress rpc to mine to a specific address.

thenakulchawla commented 6 years ago

Nothing that I do works, even in linux. Here is a screenshot. There is no wallet.dat file inside ~/.dashcore

screen shot 2018-05-02 at 7 42 12 pm
thephez commented 6 years ago

@nakulchawla09 I know this is a basic question, but is your dashd running with the disablewallet option? That would disable any wallet-related RPC calls. Based on a quick try, a locked wallet would return different error that would indicate you needed to unlock it. For keypoolrefill on a locked wallet, I got:

error code: -13 error message: Error: Please enter the wallet passphrase with walletpassphrase first.

FYI - walletinfo is not a valid RPC - try getwalletinfo. You can see the full list here.