From e8898c2327b69f39a134b5d6abcb6c6866d70c39 Mon Sep 17 00:00:00 2001 From: Konrad Mohrfeldt <km@roko.li> Date: Tue, 4 Feb 2025 22:35:05 +0100 Subject: [PATCH] fix: disable default timeout for file import states refs aura/tank#86 --- src/stores/files.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/stores/files.ts b/src/stores/files.ts index 25d5def..a7e70f7 100644 --- a/src/stores/files.ts +++ b/src/stores/files.ts @@ -54,7 +54,7 @@ function APIUpload(api: ExtendableAPI<TankFile>, pendingImportFileIds: Ref<Set<T requiredState: 'running' | 'done', options: { signal?: AbortSignal | null; maxWaitTimeSeconds?: number } | undefined = undefined, ) { - const maxWaitTimeSeconds = options?.maxWaitTimeSeconds ?? 5 * 60 + const maxWaitTimeSeconds = options?.maxWaitTimeSeconds ?? Number.POSITIVE_INFINITY const startTime = new Date().getTime() / 1000 let waitTime = 0 @@ -88,7 +88,7 @@ function APIUpload(api: ExtendableAPI<TankFile>, pendingImportFileIds: Ref<Set<T } } - throw new TimeoutError('Maximum wait time passed') + throw new TimeoutError('Maximum wait time for file import state reached.') } function _uploadFile( -- GitLab