Skip to content

Fix numpy warning #35085

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

Merged
merged 6 commits into from
Jul 6, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pandas/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ def nselect_method(request):
# Missing values & co.
# ----------------------------------------------------------------
@pytest.fixture(
params=[None, np.nan, pd.NaT, float("nan"), np.float("NaN"), pd.NA], ids=str
params=[None, np.nan, pd.NaT, float("nan"), float("nan"), pd.NA], ids=str
)
Copy link
Member

Choose a reason for hiding this comment

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

i dont think we want to float("nan")s in here. maybe this should be np.float64("nan")? best guess is the point of having this in addition to np.nan is bc nan is not a singleton like pd.NaT.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is equivalent to what we had before, since np.float was an alias for float. You're saying that isn't what we want?

Copy link
Member

Choose a reason for hiding this comment

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

just speculating; im pretty confident we dont want two identical objects in here

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah I missed that we already had float('"nan").

def nulls_fixture(request):
"""
Expand Down