You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/05/28 07:53:34 UTC

[GitHub] [spark] HyukjinKwon commented on a change in pull request #32690: [SPARK-35510][PYTHON] Fix and reenable test_stats_on_non_numeric_columns_should_be_discarded_if_numeric_only_is_true

HyukjinKwon commented on a change in pull request #32690:
URL: https://github.com/apache/spark/pull/32690#discussion_r641345680



##########
File path: python/pyspark/pandas/tests/test_stats.py
##########
@@ -375,15 +375,20 @@ def test_stats_on_non_numeric_columns_should_be_discarded_if_numeric_only_is_tru
         self.assert_eq(len(psdf.kurtosis(numeric_only=True)), len(pdf.kurtosis(numeric_only=True)))
         self.assert_eq(len(psdf.skew(numeric_only=True)), len(pdf.skew(numeric_only=True)))
 
-        # TODO(SPARK-35510): This fails with Python 3.9. We should fix and reenable it.
-        # self.assert_eq(
-        #     len(psdf.quantile(q=0.5, numeric_only=True)),
-        #     len(pdf.quantile(q=0.5, numeric_only=True)),
-        # )
-        # self.assert_eq(
-        #     len(psdf.quantile(q=[0.25, 0.5, 0.75], numeric_only=True)),
-        #     len(pdf.quantile(q=[0.25, 0.5, 0.75], numeric_only=True)),
-        # )
+        # Boolean was excluded because of a behavior change in NumPy
+        # https://github.com/numpy/numpy/pull/16273#discussion_r641264085 which pandas inherits
+        # but this behavior is inconsistent in pandas context.
+        # Boolean column in quantile tests are excluded for now.

Review comment:
       ```suggestion
           # Boolean column in quantile tests are excluded for now.
           # TODO(SPARK-35555): track and match the behavior of quantile to pandas'
   ```




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

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



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