From b8d119d1613c816ff48fcc7556a56db35afd2d8f Mon Sep 17 00:00:00 2001 From: "Samuel EF. Tinnerholm" Date: Sun, 24 May 2026 20:24:58 +0300 Subject: [PATCH] fix: add 30s timeout to SDK fetchWithRetry Fixes #207 --- sdks/typescript/pmxt/client.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sdks/typescript/pmxt/client.ts b/sdks/typescript/pmxt/client.ts index 9979d3f8..9a95f0e6 100644 --- a/sdks/typescript/pmxt/client.ts +++ b/sdks/typescript/pmxt/client.ts @@ -392,7 +392,10 @@ export abstract class Exchange { for (let attempt = 0; attempt <= delays.length; attempt++) { try { - return await fetch(input, init); + return await fetch(input, { + ...init, + signal: AbortSignal.timeout(30_000), + }); } catch (error) { lastError = error; if (attempt >= delays.length) break;