Skip to content

Commit a917c69

Browse files
committed
fix: handle exceptions in CSV writing to ensure proper completion signaling
1 parent 36a87f3 commit a917c69

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

FurLab.CLI/Commands/Query/Run/QueryRunCommand.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -472,10 +472,13 @@ await AnsiConsole.Status()
472472
csvExporter.WriteLogEntry(logFilePath, logEntry);
473473
}
474474
}
475-
finally
475+
catch (Exception ex)
476476
{
477-
writerCompleted.SetResult();
477+
writerCompleted.TrySetException(ex);
478+
return;
478479
}
480+
481+
writerCompleted.TrySetResult();
479482
});
480483

481484
var resultsTable = new Table()

0 commit comments

Comments
 (0)