ueshin commented on a change in pull request #34227:
URL: https://github.com/apache/spark/pull/34227#discussion_r726546695



##########
File path: python/pyspark/pandas/frame.py
##########
@@ -10974,7 +10979,7 @@ def quantile(psser: "Series") -> Column:
             # |[2, 3, 4]|[6, 7, 8]|
             # +---------+---------+
 
-            cols_dict = OrderedDict()  # type: OrderedDict
+            cols_dict: OrderedDict = OrderedDict()

Review comment:
       `OrderedDict` seems not a generic type in Python<3.9.
   
   ```py
   >>> d: OrderedDict[str, str]
   Traceback (most recent call last):
     File "<stdin>", line 1, in <module>
   TypeError: 'type' object is not subscriptable
   ```
   
   I guess `Dict[str, List[Column]]` should be fine?
   Otherwise, as this is related to runtime, I'd leave it as is for now, just 
in case.




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