From 78401cf9bd99c54ac160c9d58aac0782c9d8bb91 Mon Sep 17 00:00:00 2001 From: SuLe Date: Sat, 2 May 2026 05:28:56 +0800 Subject: [PATCH] handle rejected sql file cancel --- src/components/sql-file/SqlFileExecutionDialog.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/sql-file/SqlFileExecutionDialog.vue b/src/components/sql-file/SqlFileExecutionDialog.vue index 82e5815d1..bec8047ed 100644 --- a/src/components/sql-file/SqlFileExecutionDialog.vue +++ b/src/components/sql-file/SqlFileExecutionDialog.vue @@ -298,7 +298,10 @@ async function cancelExecution() { cancelling.value = true; if (!executionStarted.value) return; try { - await cancelSqlFileExecution(executionId.value); + const cancelled = await cancelSqlFileExecution(executionId.value); + if (!cancelled) { + throw new Error("Cancel request was not accepted"); + } } catch (e: any) { cancelRequested.value = false; cancelling.value = false;