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

[SNOW-1320248]: Fix inplace=True on Series objects derived from Series. #2307

Merged
merged 7 commits into from
Sep 17, 2024

Conversation

sfc-gh-rdurrani
Copy link
Contributor

  1. Which Jira issue is this PR addressing? Make sure that there is an accompanying issue to your PR.

    Fixes SNOW-1320248

  2. Fill out the following pre-review checklist:

    • I am adding a new automated test(s) to verify correctness of my new code
      • If this test skips Local Testing mode, I'm requesting review from @snowflakedb/local-testing
    • I am adding new logging messages
    • I am adding a new telemetry message
    • I am adding new credentials
    • I am adding a new dependency
    • If this is a new feature/behavior, I'm adding the Local Testing parity changes.
  3. Please describe how your code solves the related issue.

This PR fixes the inplace argument for Series functions where the Series is derived from another Series object (e.g. series = series.iloc[:4]; series.fillna(14, inplace=True))

@sfc-gh-rdurrani sfc-gh-rdurrani added the NO-PANDAS-CHANGEDOC-UPDATES This PR does not update Snowpark pandas docs label Sep 17, 2024
CHANGELOG.md Outdated Show resolved Hide resolved
Copy link
Contributor

@sfc-gh-helmeleegy sfc-gh-helmeleegy left a comment

Choose a reason for hiding this comment

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

LGTM, thanks Rehan!

Copy link
Contributor

@sfc-gh-nkrishna sfc-gh-nkrishna left a comment

Choose a reason for hiding this comment

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

LGTM, please resolve other comments

Copy link
Contributor

@sfc-gh-joshi sfc-gh-joshi left a comment

Choose a reason for hiding this comment

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

Can you check if this is a bug in OSS Modin, and file an issue there if so?

Co-authored-by: Hazem Elmeleegy <[email protected]>
@sfc-gh-rdurrani sfc-gh-rdurrani enabled auto-merge (squash) September 17, 2024 20:17
@sfc-gh-rdurrani
Copy link
Contributor Author

Can you check if this is a bug in OSS Modin, and file an issue there if so?

I was able to confirm that the bug is not reproducible on OSS Modin on Ray in the latest version installable from pip, so I think this is a snowpark only issue!

In [1]: import modin.pandas as pd
d
In [2]: df = pd.read_csv("/Users/rdurrani/Downloads/test.csv")
2024-09-17 13:17:51,513	INFO worker.py:1749 -- Started a local Ray instance.

In [3]: s = df['Fare'].copy().iloc[:4]
   ...: s.fillna(14, inplace=True)

In [4]: s
Out[4]:
0    7.8292
1    7.0000
2    9.6875
3    8.6625
Name: Fare, dtype: float64

@sfc-gh-rdurrani sfc-gh-rdurrani merged commit 6a3a77b into main Sep 17, 2024
35 checks passed
@sfc-gh-rdurrani sfc-gh-rdurrani deleted the rdurrani-SNOW-1320248 branch September 17, 2024 21:09
@github-actions github-actions bot locked and limited conversation to collaborators Sep 17, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
NO-PANDAS-CHANGEDOC-UPDATES This PR does not update Snowpark pandas docs snowpark-pandas
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants