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

Fix various issues with replace API and add support in datetime and timedelta columns #17331

Merged
merged 8 commits into from
Nov 15, 2024

Conversation

galipremsagar
Copy link
Contributor

Description

This PR:

  • Adds support for find_and_replace in DateTimeColumn and TimeDeltaColumn, such that when .replace is called on a series or dataframe with these columns, we don't error and replace the values correctly.
  • Fixed various type combination edge cases that were previously incorrectly handled and updated stale tests associated with them.
  • Added a small parquet file in pytests that has multiple rows that uncovered these bugs.

Checklist

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

@galipremsagar galipremsagar self-assigned this Nov 15, 2024
@galipremsagar galipremsagar requested a review from a team as a code owner November 15, 2024 00:04
@galipremsagar galipremsagar requested a review from vyasr November 15, 2024 00:04
@github-actions github-actions bot added the Python Affects Python cuDF API. label Nov 15, 2024
@galipremsagar galipremsagar added bug Something isn't working non-breaking Non-breaking change labels Nov 15, 2024
python/cudf/cudf/core/column/datetime.py Outdated Show resolved Hide resolved
python/cudf/cudf/core/column/datetime.py Outdated Show resolved Hide resolved
python/cudf/cudf/core/column/numerical.py Outdated Show resolved Hide resolved
python/cudf/cudf/core/column/numerical.py Outdated Show resolved Hide resolved
python/cudf/cudf/core/column/numerical.py Show resolved Hide resolved
python/cudf/cudf/core/column/timedelta.py Outdated Show resolved Hide resolved
Co-authored-by: Vyas Ramasubramani <vyas.ramasubramani@gmail.com>
Copy link
Contributor

@vyasr vyasr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whoops I'm sorry I clicked on the wrong button in my first review! Some small changes requested.

@galipremsagar galipremsagar requested a review from vyasr November 15, 2024 00:50
Copy link
Contributor

@vyasr vyasr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving pending resolution of the one open thread about a new utility function.

@galipremsagar
Copy link
Contributor Author

Approving pending resolution of the one open thread about a new utility function.

Done 👍

@galipremsagar galipremsagar added the 5 - Ready to Merge Testing and reviews complete, ready to merge label Nov 15, 2024
@galipremsagar
Copy link
Contributor Author

/merge

@rapids-bot rapids-bot bot merged commit d475dca into rapidsai:branch-24.12 Nov 15, 2024
102 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
5 - Ready to Merge Testing and reviews complete, ready to merge bug Something isn't working non-breaking Non-breaking change Python Affects Python cuDF API.
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants