HyukjinKwon commented on a change in pull request #34750:
URL: https://github.com/apache/spark/pull/34750#discussion_r759803234
##########
File path: python/pyspark/pandas/series.py
##########
@@ -5847,7 +5866,9 @@ def compare(
)
)
else:
- if not self.index.equals(other.index):
+ if get_option("compute.eager_check") and not
self.index.equals(other.index):
+ raise ValueError("Can only compare identically-labeled Series
objects")
+ elif len(self.index) != len(other.index):
Review comment:
qq: what happen if we don't compare the length? does it not make sense
at all?
##########
File path: python/pyspark/pandas/series.py
##########
@@ -5847,7 +5866,9 @@ def compare(
)
)
else:
- if not self.index.equals(other.index):
+ if get_option("compute.eager_check") and not
self.index.equals(other.index):
+ raise ValueError("Can only compare identically-labeled Series
objects")
+ elif len(self.index) != len(other.index):
Review comment:
qq: what happen if we don't compare the length? does the output not make
sense at all?
--
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]