-
-
Notifications
You must be signed in to change notification settings - Fork 19.4k
CLEAN: Enforce pdep6 #59007
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
CLEAN: Enforce pdep6 #59007
Conversation
6bdc2ec to
ed66194
Compare
ed66194 to
abd4b9f
Compare
| # Upcast so that we can add .5 | ||
| df = df.astype({"c": "float64"}) |
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.
manually adding this in so we can keep running the rest of the test
abd4b9f to
9379c7b
Compare
9379c7b to
45cafc2
Compare
pandas/core/internals/blocks.py
Outdated
|
|
||
| @final | ||
| def coerce_to_target_dtype(self, other, warn_on_upcast: bool = False) -> Block: | ||
| def coerce_to_target_dtype(self, other, raise_on_upcast: bool = False) -> Block: |
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.
Are there any usages of this method, outside this file, that does not set this to raise_on_upcast=False?
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.
there's no usage of this method at all outside this file
i've removed the default =False anyway, better to be explicit about this one
mroeschke
left a comment
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.
Code changes look good. Could you add something in the whatsnew (section or one-liner, up to you) about this enforcement?
|
Thanks @MarcoGorelli |
a few bits still need thinking over