commit 8eaa49c812b86b1009fe2e5f9fb1579180bee8df
parent 545ccef072d8e7439bfed0e740972fa4801ac451
Author: Florian Dold <florian@dold.me>
Date: Fri, 20 Mar 2026 15:59:35 +0100
wallet-core: only give up when there's an actual error
Diffstat:
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/packages/taler-wallet-core/src/pay-merchant.ts b/packages/taler-wallet-core/src/pay-merchant.ts
@@ -2349,6 +2349,8 @@ async function waitPaymentResult(
const ctx = new PayMerchantTransactionContext(wex, proposalId);
wex.taskScheduler.startShepherdTask(ctx.taskId);
+ logger.info(`waiting for payment result on ${ctx.transactionId}`);
+
return await genericWaitForStateVal<ConfirmPayResult>(wex, {
filterNotification(notif) {
return (
@@ -2388,7 +2390,12 @@ async function waitPaymentResult(
}
}
- if (txRes.retryRecord) {
+ if (txRes.retryRecord && txRes.retryRecord.retryInfo.retryCounter > 0) {
+ logger.info(
+ `stopping waiting for payment result, got retry record: ${j2s(
+ txRes.retryRecord,
+ )}`,
+ );
return {
type: ConfirmPayResultType.Pending,
lastError: txRes.retryRecord.lastError,