decentralized-identity / decentralized-identity/ion
ion-bitcoin should retry if connection to bitcoin client fails since it's verifying blocks
- Dominant language
- HTML
- Stars
- 1.2k
- Forks
- 166
- PR merge metrics
- No merged PRs in 30d
Description
When an ION node is restarted, the bitcoin client needs to validate the last blocks, When ion-bitcoin connects it receives this error message and fails:
Sending jRPC request: id: 4pbh1drk2u5, method: getaddressinfo
Error: Fetch failed [500]: {"result":null,"error":{"code":-28,"message":"Verifying blocks..."},"id":"4pbh1drk2u5"}
at BitcoinClient. (/ion/node_modules/@decentralized-identity/sidetree/dist/lib/bitcoin/BitcoinClient.js:670:31)
at Generator.next ()
at fulfilled (/ion/node_modules/@decentralized-identity/sidetree/dist/lib/bitcoin/BitcoinClient.js:5:58)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
Sidetree-Bitcoin node initialization failed with error: {"stack":"Error: Fetch failed [500]: {\"result\":null,\"error\":{\"code\":-28,\"message\":\"Verifying blocks...\"},\"id\":\"4pbh1drk2u5\"}\n\n at BitcoinClient. (/ion/node_modules/@decentralized-identity/sidetree/dist/lib/bitcoin/BitcoinClient.js:670:31)\n at Generator.next ()\n at fulfilled (/ion/node_modules/@decentralized-identity/sidetree/dist/lib/bitcoin/BitcoinClient.js:5:58)\n at processTicksAndRejections (internal/process/task_queues.js:97:5)","message":"Fetch failed [500]: {\"result\":null,\"error\":{\"code\":-28,\"message\":\"Verifying blocks...\"},\"id\":\"4pbh1drk2u5\"}\n"}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! ion@1.0.0 bitcoin: `node dist/src/bitcoin.js`
it should not fail, but retry later instead until veryfing is done and the requests will be accepted by the bitcoin service
npm ERR! Exit status 1
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.