-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
Update mypy version from 1.11.2 to 1.13.0 #60260
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
Conversation
Man Group London Hackathon 2024 |
Removed type ignores
Fix typing error casting `._values` to a `DataFrame` in `pandas.core.generic`
Removed a missed type ignore
`nanops.nanmedian` typing fix
Fix indexing typing error
New err mypy
Fix column typeerror
type ignore common.py
fix line too long
Fixed type:ignore from type-arg to type-var
Call overload err
@@ -738,7 +740,7 @@ def nanmedian(values, *, axis: AxisInt | None = None, skipna: bool = True, mask= | |||
|
|||
Returns | |||
------- | |||
result : float | |||
result : float | ndarray |
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.
can you comment in PR a example returning an array
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.
Sure, the following code would be an example of when the function would return an array, and not a float
:
import pandas as pd
import numpy as np
pd.core.nanops.nanmedian(
np.array([
[1, 2, 3],
[2, 3, 4]
],
axis=1)
)
This code would output,
array([2., 3.])
Correct typing fixes
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.
doc/source/whatsnew/vX.X.X.rst
file if fixing a bug or adding a new feature.