Skip to content

Commit abf4b5a

Browse files
committed
fix(hitl): add .catch() to fire-and-forget event buffer calls in cancel route
1 parent 15360c3 commit abf4b5a

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

  • apps/sim/app/api/workflows/[id]/executions/[executionId]/cancel

apps/sim/app/api/workflows/[id]/executions/[executionId]/cancel/route.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ export async function POST(
6464
logger.info('Execution cancelled via local in-process fallback', { executionId })
6565
} else if (pausedCancelled) {
6666
logger.info('Paused execution cancelled directly in database', { executionId })
67-
void setExecutionMeta(executionId, { status: 'cancelled', workflowId })
67+
void setExecutionMeta(executionId, { status: 'cancelled', workflowId }).catch(() => {})
6868
const writer = createExecutionEventWriter(executionId)
6969
void writer
7070
.write({
@@ -75,6 +75,7 @@ export async function POST(
7575
data: { duration: 0 },
7676
})
7777
.then(() => writer.close())
78+
.catch(() => {})
7879
} else {
7980
logger.warn('Execution cancellation was not durably recorded', {
8081
executionId,

0 commit comments

Comments
 (0)