viirya commented on code in PR #7510:
URL: https://github.com/apache/arrow-datafusion/pull/7510#discussion_r1320145812


##########
datafusion/core/src/physical_plan/stream.rs:
##########
@@ -169,7 +171,16 @@ impl RecordBatchReceiverStreamBuilder {
         let check = async move {
             while let Some(result) = join_set.join_next().await {
                 match result {
-                    Ok(()) => continue, // nothing to report
+                    Ok(task_result) => {
+                        match task_result {
+                            // nothing to report
+                            Ok(_) => continue,
+                            // This means a blocking task error
+                            Err(e) => {
+                                return Some(internal_err!("Spawned Task error: 
{e}"));

Review Comment:
   For example, after this, if the file doesn't exist, you will get an error:
   
   ```
   Error: Internal("Spawned Task error: Execution error: Spill file 
\"/var/folders/zq/2tdnn5955wvdcw7qfy6qhvk00000gn/T/.tmpb5EGzS/.tmptpkruZ\" does 
not exist")
   ```



-- 
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