Skip to content
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

Make cudf.pandas proxy types explictly call our custom pickling logic #17929

Open
wants to merge 7 commits into
base: branch-25.04
Choose a base branch
from

Conversation

Matt711
Copy link
Contributor

@Matt711 Matt711 commented Feb 6, 2025

Description

Apart of #17490.

We employ custom pickling logic for our cudf.pandas wrapped types. The logic lets us serialize and de-serialize wrapped types by serializing and de-serializing the underlying wrapped types (ie. the type of _fsproxy_wrapped). This pickling logic is defined in _FinalProxy, which is the base class of all of our "final" proxy types.

The failures in the integration tests occurred because this pickling logic wasn't used for the proxy numpy array type. This is because the "final" proxy array type inherits from an additional base class: ProxyNDarrayBase (which contains logic to inherit from np.ndarray ). And it comes before _FinalProxy in the classes MRO, so the custom pickling is not used.

Note: This may be a bug for any other proxy type with multiple base classes.

Checklist

  • I am familiar with the Contributing Guidelines.
  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@Matt711 Matt711 requested a review from a team as a code owner February 6, 2025 15:51
@Matt711 Matt711 requested review from vyasr and mroeschke February 6, 2025 15:51
@Matt711 Matt711 added the bug Something isn't working label Feb 6, 2025
@github-actions github-actions bot added Python Affects Python cuDF API. cudf.pandas Issues specific to cudf.pandas labels Feb 6, 2025
@Matt711 Matt711 added the non-breaking Non-breaking change label Feb 6, 2025
@Matt711
Copy link
Contributor Author

Matt711 commented Feb 6, 2025

I'll continue once #17936 is merged. That will help ensure that the tests are passing with the changes in this PR.

@Matt711 Matt711 changed the title Fix numpy-proxying failures in the third-party integrations tests Make cudf.pandas proxy types explictly call our custom pickling logic Feb 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working cudf.pandas Issues specific to cudf.pandas non-breaking Non-breaking change Python Affects Python cuDF API.
Projects
Status: In Progress
Development

Successfully merging this pull request may close these issues.

1 participant