openwallet-foundation/bifold-wallet

Pool timeout during issue-credential - No retry mechanism

pocbot opened this issue · 0 comments

We use Aries Bifold v0.4 with the Indicio Test network (as well as their public mediator here: https://indicio-tech.github.io/mediator/).
From time to time (it seems to be more recurrent for some members of our team, but we still don't know why), we observe a pool time out in the logs during an issue-credential (v1) ceremony, generally at the end when there are apparently some checks being performed, which require an access to the Indicio Test Network. When this happens, the verifiable credential is simply lost (not persisted in the Wallet) and there is no retry mechanism.
The pool timeout happens when resolving a credential definition for instance, with the below logs

"message": "Unable to retrieve credential definition with id Y6M1iZ93Jswzcw6UDLsCBS:3:CL:5480:Y6M1iZ93Jswzcw6UDLsCBS: notFound unable to resolve credential definition: Pool timeout: Request was interrupted",\n    "stack": "AnonCredsError: Unable to retrieve credential definition with id Y6M1iZ93Jswzcw6UDLsCBS:3:CL:5480:Y6M1iZ93Jswzcw6UDLsCBS: notFound unable to resolve credential definition: Pool timeout: Request was interrupted\n    at ?anon_0_ (address at index.android.bundle:1:5301565)\n    at next (native)\n    at asyncGeneratorStep (address at index.android.bundle:1:596644)\n    at _next (address at index.android.bundle:1:596914)\n    at tryCallOne (/root/react-native/packages/react-native/ReactAndroid/hermes-engine/.cxx/Release/l3usn2e1/arm64-v8a/lib/InternalBytecode/InternalBytecode.js:53:16)\n    at anonymous (/root/react-native/packages/react-native/ReactAndroid/hermes-engine/.cxx/Release/l3usn2e1/arm64-v8a/lib/InternalBytecode/InternalBytecode.js:139:27)\n    at apply (native)\n    at anonymous (address at index.android.bundle:1:278551)\n    at _callTimer (address at index.android.bundle:1:277500)\n    at _callReactNativeMicrotasksPass (address at index.android.bundle:1:277664)\n    at callReactNativeMicrotasks (address at index.android.bundle:1:279642)\n    at __callReactNativeMicrotasks (address at index.android.bundle:1:165882)\n    at anonymous (address at index.android.bundle:1:164975)\n    at __guard (address at index.android.bundle:1:165723)\n    at flushedQueue (address at index.android.bundle:1:164886)"\n  },\n  "senderKey": "z6MksVNPmDm47FqUmumgQoyJ1EPzwyuQy82xNGwt14evChmB",\n  "recipientKey": "z6Mknw7ohpNvUz48AjxnFJyhSxTv46qseXc5byiBvgagpop7",\n  "connectionId": "c8f791a1-977d-4a42-b01e-d7e5899bf51c"\n}'

2023-12-13T15:56:29.308Z [ERROR]  'ERROR: Failed to process message', '{\n  "error": {\n    "name": "AnonCredsError",\n    "message": "Unable to retrieve credential definition with id Y6M1iZ93Jswzcw6UDLsCBS:3:CL:5480:Y6M1iZ93Jswzcw6UDLsCBS: notFound unable to resolve credential definition: Pool timeout: Request was interrupted",\n    "stack": "AnonCredsError: Unable to retrieve credential definition with id Y6M1iZ93Jswzcw6UDLsCBS:3:CL:5480:Y6M1iZ93Jswzcw6UDLsCBS: notFound unable to resolve credential definition: Pool timeout: Request was interrupted\n    at ?anon_0_ (address at index.android.bundle:1:5301565)\n    at next (native)\n    at asyncGeneratorStep (address at index.android.bundle:1:596644)\n    at _next (address at index.android.bundle:1:596914)\n    at tryCallOne (/root/react-native/packages/react-native/ReactAndroid/hermes-engine/.cxx/Release/l3usn2e1/arm64-v8a/lib/InternalBytecode/InternalBytecode.js:53:16)\n    at anonymous (/root/react-native/packages/react-native/ReactAndroid/hermes-engine/.cxx/Release/l3usn2e1/arm64-v8a/lib/InternalBytecode/InternalBytecode.js:139:27)\n    at apply (native)\n    at anonymous (address at index.android.bundle:1:278551)\n    at _callTimer (address at index.android.bundle:1:277500)\n    at _callReactNativeMicrotasksPass (address at index.android.bundle:1:277664)\n    at callReactNativeMicrotasks (address at index.android.bundle:1:279642)\n    at __callReactNativeMicrotasks (address at index.android.bundle:1:165882)\n    at anonymous (address at index.android.bundle:1:164975)\n    at __guard (address at index.android.bundle:1:165723)\n    at flushedQueue (address at index.android.bundle:1:164886)"\n  }\n}'

Any idea where the issue could come from?
Should a retry mechanism be considered such that a credential exchange is not definitely failed because of a network issue?

Thanks in advance for your support, and most of all for this amazing project!