-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
API: .equals for Extension Arrays #27081
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
actually we define |
+1 on adding We might only need to add |
+1 for `.equals`, and making `__eq__` abstract so that the expected
array-like `__eq__` must be implemented.
…On Thu, Jun 27, 2019 at 2:13 PM Joris Van den Bossche < ***@***.***> wrote:
+1 on adding equals and such a default implementation.
We might only need to add __eq__ as a required abstract method, to ensure
people implement it (otherwise the default python one will always return
True or False based on identity, and thus give wrong results for such an
equals method)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#27081?email_source=notifications&email_token=AAKAOIVGP7LWBI23LK4Q53LP4UGMFA5CNFSM4H36BQPKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODYYDB7Y#issuecomment-506474751>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAKAOIRFMUGIIV7TO5FSW4DP4UGMFANCNFSM4H36BQPA>
.
|
Removing the milestone as I think this is not 0.25.0 critical? |
no this is slightly non trivial |
Should the __eq__ on ExtensionScalarOpsMixin be changed to take care nan, or should ExtensionArray expose a .equals() that does that? I believe DecimalArray is the only class that inherits ExtensionScalarOpsMixin so to cover all EA's I think a .equals() on EA is more appropriate? |
Hi, As this is labeled |
Adding __eq__ to ExtensionArray Abstract method doc string. Adding ne implementation to EA base class. Also removing other implementations. Updating EA equals method and adding tests. pandas-devGH-27081
We don't have a good method of testing for equality between EA's
These happen to work with Series now because the null checks are handled at a higher level.
we could provide a default implementation that should just work in the presence of NA.
actually we should also implement a default
__eq__
The text was updated successfully, but these errors were encountered: