cdkrot commented on code in PR #42949:
URL: https://github.com/apache/spark/pull/42949#discussion_r1331900167


##########
python/pyspark/sql/connect/client/artifact.py:
##########
@@ -243,11 +244,15 @@ def _create_requests(
         self, *path: str, pyfile: bool, archive: bool, file: bool
     ) -> Iterator[proto.AddArtifactsRequest]:
         """Separated for the testing purpose."""
-        return self._add_artifacts(
-            chain(
-                *(self._parse_artifacts(p, pyfile=pyfile, archive=archive, 
file=file) for p in path)
+        try:
+            yield from self._add_artifacts(
+                chain(
+                    *(self._parse_artifacts(p, pyfile=pyfile, archive=archive, 
file=file) for p in path)
+                )
             )
-        )
+        except Exception as e:
+            logger.error(f"Failed to submit addArtifacts request: {e}")

Review Comment:
   > Could you be more specific on what Exception can be thrown here? From your 
PR description, it looks like a GPRC error.
   
   Doesn't matter, any exception thrown here would be suppressed by grpc and 
only generic exception "Exception iterating requests" will be visible.



-- 
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: reviews-unsubscr...@spark.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to