freewil / node-bitcoin

UNMAINTAINED - See: https://github.com/ruimarinho/bitcoin-core - Communicate with bitcoind via JSON-RPC
The Unlicense
324 stars 89 forks source link

Unhandled rejection Error: walletpassphrase <passphrase> <timeout> #33

Closed reggi closed 8 years ago

reggi commented 8 years ago

I'm getting an error that just mentions the walletpassphrase docs and doesn't actually tell me what happened, any ideas?

Unhandled rejection Error: walletpassphrase <passphrase> <timeout>
Stores the wallet decryption key in memory for <timeout> seconds.
    at /Users/thomas/Desktop/bitcoin-cracker/node_modules/bitcoin/lib/jsonrpc.js:130:19
    at Array.forEach (native)
    at IncomingMessage.<anonymous> (/Users/thomas/Desktop/bitcoin-cracker/node_modules/bitcoin/lib/jsonrpc.js:127:15)
    at emitNone (events.js:85:20)
    at IncomingMessage.emit (events.js:179:7)
    at endReadableNT (_stream_readable.js:913:12)
    at _combinedTickCallback (internal/process/next_tick.js:74:11)
    at process._tickDomainCallback (internal/process/next_tick.js:122:9)
reggi commented 8 years ago

I believe It's because I was passing in an empty string.

freewil commented 8 years ago

Yeah, I was going to guess either an empty/null/undefined string or you were calling the cmd too often before the timeout.