-
- Notifications
You must be signed in to change notification settings - Fork 19.1k
Open
Labels
BugNeeds TriageIssue that has not been reviewed by a pandas team memberIssue that has not been reviewed by a pandas team member
Description
Pandas version checks
-
I have checked that this issue has not already been reported.
-
I have confirmed this bug exists on the latest version of pandas.
-
I have confirmed this bug exists on the main branch of pandas.
Reproducible Example
ser = pd.Series([np.nan]) >>> ser.astype(bool) 0 True
This is correct inasmuch as bool(np.nan)
is True, but I think it's a bit surprising. Analogous to how we deprecated and later disallowed .astype("int64")
when NaNs are present, should we deprecate allowing this for bool?
xref #43018
Metadata
Metadata
Assignees
Labels
BugNeeds TriageIssue that has not been reviewed by a pandas team memberIssue that has not been reviewed by a pandas team member