-
-
Notifications
You must be signed in to change notification settings - Fork 18.1k
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
DEPR: downcast inferring round floats to ints #53108
Conversation
@@ -145,6 +145,10 @@ def pytest_collection_modifyitems(items, config) -> None: | |||
"(Series|DataFrame).bool is now deprecated and will be removed " | |||
"in future version of pandas", | |||
), | |||
( | |||
"pandas.core.generic.NDFrame.clip", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add this one to the whatsnew as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will update
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated + green
@@ -261,6 +261,8 @@ Deprecations | |||
- Deprecated logical operation between two non boolean :class:`Series` with different indexes always coercing the result to bool dtype. In a future version, this will maintain the return type of the inputs. (:issue:`52500`, :issue:`52538`) | |||
- Deprecated allowing ``downcast`` keyword other than ``None``, ``False``, "infer", or a dict with these as values in :meth:`Series.fillna`, :meth:`DataFrame.fillna` (:issue:`40988`) | |||
- Deprecated constructing :class:`SparseArray` from scalar data, pass a sequence instead (:issue:`53039`) | |||
- Deprecated downcasting behavior in :meth:`Series.interpolate`, :meth:`Series.fillna`, :meth:`DataFrame.interpolate`, :meth:`DataFrame.fillna`, with downcast="infer" and floating dtypes; in a future version these will not cast all-round floats to integer dtype, explicitly cast the result instead (:issue:`40988`) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the keyword doing now? Only casting from int64 -> int8?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just object dtype
I guess we can do this and then follow up by deprecating the keyword entirely? its a bit roundabout, but gives anyone who objects lots of chances to do so |
@phofl gentle ping |
Closing in favor of #53656 |
doc/source/whatsnew/vX.X.X.rst
file if fixing a bug or adding a new feature.xref #40988