pitrou commented on code in PR #49860:
URL: https://github.com/apache/arrow/pull/49860#discussion_r3333092732


##########
cpp/src/arrow/util/async_util.cc:
##########
@@ -466,7 +467,14 @@ Future<> 
AsyncTaskScheduler::Make(FnOnce<Status(AsyncTaskScheduler*)> initial_ta
   auto scope = START_SCOPED_SPAN_SV(span, "AsyncTaskScheduler::InitialTask"sv);
   auto scheduler = 
std::make_unique<AsyncTaskSchedulerImpl>(std::move(stop_token),
                                                             
std::move(abort_callback));
-  Status initial_task_st = std::move(initial_task)(scheduler.get());
+  Status initial_task_st;
+  try {

Review Comment:
   ```suggestion
     // GH-47642: We normally don't catch exceptions in Arrow C++ code, as the 
error
     // reporting model uses the Status object instead. Usually, an uncaught 
exception
     // will simply terminate the process, surfacing the programming error.
     // However, an exception thrown from the initial task would result in a 
much
     // harder to diagnose process hang.
     try {
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to