rehevkor5 commented on code in PR #34225:
URL: https://github.com/apache/spark/pull/34225#discussion_r1110226166


##########
python/pyspark/sql/dataframe.py:
##########
@@ -784,7 +824,7 @@ def foreach(self, f):
         """
         self.rdd.foreach(f)
 
-    def foreachPartition(self, f):
+    def foreachPartition(self, f: Callable[[Iterator[Row]], None]) -> None:

Review Comment:
   Shouldn't this be `Iterable[Row]` instead of `Iterator[Row]`, so that it 
matches https://github.com/apache/spark/blob/master/python/pyspark/rdd.py#L1750 
?



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to