-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Consider Any in selftype when checking overloads
#20185
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
base: master
Are you sure you want to change the base?
Consider Any in selftype when checking overloads
#20185
Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
…rloads will pick the first overload again...
This comment has been minimized.
This comment has been minimized.
e7b431b to
75e4e22
Compare
This comment has been minimized.
This comment has been minimized.
e096bf9 to
75e4e22
Compare
|
Okay, this is worse than I hoped... The new errors are correct but rather unhelpful - numpy stubs apparently rely on this behaviour... For example, the following: x: np.ndarray
reveal_type(x)
reveal_type(x * 100)only reveals and the "compare erased types" logic does not kick in because there are |
|
Diff from mypy_primer, showing the effect of this PR on open source code: colour (https://github.com/colour-science/colour)
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "floating" matches argument type "Buffer" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: Possible overload variants:
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, int | floating[_16Bit] | unsignedinteger[_8Bit] | signedinteger[_8Bit] | numpy.bool[builtins.bool], /) -> floating[_16Bit]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, integer[Any] | floating[Any], /) -> floating[Any]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, float, /) -> floating[_16Bit]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, complex, /) -> complexfloating[Any, Any]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "floating" matches argument type "_SupportsArray[dtype[Any]]" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "floating" matches argument type "_NestedSequence[_SupportsArray[dtype[Any]]]" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "floating" matches argument type "str" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "floating" matches argument type "_NestedSequence[complex | bytes | str]" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, int | floating[_16Bit] | unsignedinteger[_8Bit] | signedinteger[_8Bit] | numpy.bool[builtins.bool] | floating[_32Bit], /) -> floating[_32Bit]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, float, /) -> floating[_32Bit]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "float64" matches argument type "Buffer" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, float | floating[_64Bit] | floating[_32Bit] | floating[_16Bit] | integer[Any] | numpy.bool[builtins.bool], /) -> float64
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, complexfloating[_64Bit, _64Bit], /) -> complex128
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def [_NBit1: NBitBase, _NBit2: NBitBase] __mul__(self, complexfloating[_NBit1, _NBit2], /) -> complexfloating[_NBit1 | _64Bit, _NBit2 | _64Bit]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: def __mul__(self, complex, /) -> float64 | complex128
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "float64" matches argument type "_SupportsArray[dtype[Any]]" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "float64" matches argument type "_NestedSequence[_SupportsArray[dtype[Any]]]" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "float64" matches argument type "str" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: error: No overload variant of "__mul__" of "float64" matches argument type "_NestedSequence[complex | bytes | str]" [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:364: note: Both left and right operands are unions
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:368: error: Unsupported operand types for / ("Buffer" and "float") [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:368: error: Unsupported operand types for / ("_SupportsArray[dtype[Any]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:368: error: Unsupported operand types for / ("_NestedSequence[_SupportsArray[dtype[Any]]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:368: error: Unsupported operand types for / ("str" and "float") [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:368: error: Unsupported operand types for / ("_NestedSequence[complex | bytes | str]" and "float") [operator]
+ colour/models/rgb/transfer_functions/rimm_romm_rgb.py:368: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/io/image.py:350: error: Incompatible return value type (got "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]", expected "ndarray[tuple[Any, ...], dtype[signedinteger[_8Bit] | signedinteger[_16Bit] | signedinteger[_32Bit] | signedinteger[_64Bit] | unsignedinteger[_8Bit] | unsignedinteger[_16Bit] | unsignedinteger[_32Bit] | unsignedinteger[_64Bit] | floating[_16Bit] | floating[_32Bit] | float64]]") [return-value]
+ colour/models/rgb/transfer_functions/sony.py:126: error: Unsupported operand types for <= ("int" and "Buffer") [operator]
+ colour/models/rgb/transfer_functions/sony.py:126: error: Unsupported operand types for <= ("int" and "_SupportsArray[dtype[Any]]") [operator]
+ colour/models/rgb/transfer_functions/sony.py:126: error: Unsupported operand types for <= ("int" and "_NestedSequence[_SupportsArray[dtype[Any]]]") [operator]
+ colour/models/rgb/transfer_functions/sony.py:126: error: Unsupported operand types for <= ("int" and "complex") [operator]
+ colour/models/rgb/transfer_functions/sony.py:126: error: Unsupported operand types for <= ("int" and "_NestedSequence[complex | bytes | str]") [operator]
+ colour/models/rgb/transfer_functions/sony.py:126: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/sony.py:126: error: Unsupported operand types for >= ("str" and "int") [operator]
+ colour/models/rgb/transfer_functions/sony.py:127: error: Unsupported operand types for + ("Buffer" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:127: error: Unsupported operand types for + ("_SupportsArray[dtype[Any]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:127: error: Unsupported operand types for + ("_NestedSequence[_SupportsArray[dtype[Any]]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:127: error: Unsupported operand types for + ("_NestedSequence[complex | bytes | str]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:127: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/sony.py:127: error: Unsupported operand types for + ("str" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:128: error: Unsupported operand types for * ("Buffer" and "int") [operator]
+ colour/models/rgb/transfer_functions/sony.py:128: error: Unsupported operand types for * ("_SupportsArray[dtype[Any]]" and "int") [operator]
+ colour/models/rgb/transfer_functions/sony.py:128: error: Unsupported operand types for * ("_NestedSequence[_SupportsArray[dtype[Any]]]" and "int") [operator]
+ colour/models/rgb/transfer_functions/sony.py:128: error: Unsupported operand types for * ("_NestedSequence[complex | bytes | str]" and "int") [operator]
+ colour/models/rgb/transfer_functions/sony.py:128: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/sony.py:128: error: Unsupported operand types for + ("str" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:128: note: Left operand is of type "int | complex | str"
+ colour/models/rgb/transfer_functions/sony.py:399: error: Unsupported operand types for <= ("float" and "Buffer") [operator]
+ colour/models/rgb/transfer_functions/sony.py:399: error: Unsupported operand types for <= ("float" and "_SupportsArray[dtype[Any]]") [operator]
+ colour/models/rgb/transfer_functions/sony.py:399: error: Unsupported operand types for <= ("float" and "_NestedSequence[_SupportsArray[dtype[Any]]]") [operator]
+ colour/models/rgb/transfer_functions/sony.py:399: error: Unsupported operand types for <= ("float" and "complex") [operator]
+ colour/models/rgb/transfer_functions/sony.py:399: error: Unsupported operand types for <= ("float" and "_NestedSequence[complex | bytes | str]") [operator]
+ colour/models/rgb/transfer_functions/sony.py:399: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/sony.py:399: error: Unsupported operand types for >= ("str" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:400: error: Unsupported operand types for + ("Buffer" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:400: error: Unsupported operand types for + ("_SupportsArray[dtype[Any]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:400: error: Unsupported operand types for + ("_NestedSequence[_SupportsArray[dtype[Any]]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:400: error: Unsupported operand types for + ("_NestedSequence[complex | bytes | str]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:400: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/sony.py:400: error: Unsupported operand types for + ("str" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:401: error: Unsupported operand types for * ("Buffer" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:401: error: Unsupported operand types for * ("_SupportsArray[dtype[Any]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:401: error: Unsupported operand types for * ("_NestedSequence[_SupportsArray[dtype[Any]]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:401: error: Unsupported operand types for * ("_NestedSequence[complex | bytes | str]" and "float") [operator]
+ colour/models/rgb/transfer_functions/sony.py:401: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/sony.py:401: error: Unsupported operand types for * ("str" and "float") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for > ("float" and "Buffer") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for > ("float" and "_SupportsArray[dtype[Any]]") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for > ("float" and "_NestedSequence[_SupportsArray[dtype[Any]]]") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for > ("float" and "complex") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for > ("float" and "_NestedSequence[complex | bytes | str]") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | bytes | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for < ("bytes" and "float") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for < ("str" and "float") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for * ("Buffer" and "float") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for * ("_SupportsArray[dtype[Any]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for * ("_NestedSequence[_SupportsArray[dtype[Any]]]" and "float") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for * ("_NestedSequence[complex | bytes | str]" and "float") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for * ("bytes" and "float") [operator]
+ colour/models/rgb/transfer_functions/red.py:525: error: Unsupported operand types for * ("str" and "float") [operator]
+ colour/models/rgb/transfer_functions/panasonic_v_log.py:128: error: Unsupported operand types for * ("float" and "Buffer") [operator]
+ colour/models/rgb/transfer_functions/panasonic_v_log.py:128: error: Unsupported operand types for * ("float" and "_SupportsArray[dtype[Any]]") [operator]
+ colour/models/rgb/transfer_functions/panasonic_v_log.py:128: error: Unsupported operand types for * ("float" and "_NestedSequence[_SupportsArray[dtype[Any]]]") [operator]
+ colour/models/rgb/transfer_functions/panasonic_v_log.py:128: error: Unsupported operand types for * ("float" and "str") [operator]
+ colour/models/rgb/transfer_functions/panasonic_v_log.py:128: error: Unsupported operand types for * ("float" and "_NestedSequence[complex | bytes | str]") [operator]
+ colour/models/rgb/transfer_functions/panasonic_v_log.py:128: note: Right operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/canon.py:166: error: No overload variant of "__gt__" of "ndarray" matches argument type "Buffer" [operator]
+ colour/models/rgb/transfer_functions/canon.py:166: note: Possible overload variants:
+ colour/models/rgb/transfer_functions/canon.py:166: note: def __gt__(self, _SupportsArray[dtype[numpy.bool[builtins.bool] | number[Any, int | float | complex]]] | _NestedSequence[_SupportsArray[dtype[numpy.bool[builtins.bool] | number[Any, int | float | complex]]]] | complex | _NestedSequence[complex], /) -> ndarray[tuple[Any, ...], dtype[numpy.bool[builtins.bool]]]
+ colour/models/rgb/transfer_functions/canon.py:166: note: def __gt__(self, _SupportsArray[dtype[object_]] | _NestedSequence[_SupportsArray[dtype[object_]]], /) -> ndarray[tuple[Any, ...], dtype[numpy.bool[builtins.bool]]]
+ colour/models/rgb/transfer_functions/canon.py:166: error: Unsupported operand types for > ("ndarray[tuple[Any, ...], dtype[floating[_16Bit] | floating[_32Bit] | float64]]" and "_NestedSequence[complex | bytes | str]") [operator]
+ colour/models/rgb/transfer_functions/canon.py:166: note: Left operand is of type "Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]"
+ colour/models/rgb/transfer_functions/canon.py:166: error: Unsupported operand types for < ("str" and "ndarray[tuple[Any, ...], dtype[floating[_16Bit] | floating[_32Bit] | float64]]") [operator]
+ colour/models/rgb/transfer_functions/canon.py:167: error: Unsupported operand type for unary - ("Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | complex | str | _NestedSequence[complex | bytes | str]") [operator]
+ colour/models/rgb/transfer_functions/canon.py:168: error: Unsupported operand types for * ("float" and "Buffer") [operator]
+ colour/models/rgb/transfer_functions/canon.py:168: error: Unsupported operand types for * ("float" and "_SupportsArray[dtype[Any]]") [operator]
+ colour/models/rgb/transfer_functions/canon.py:168: error: Unsupported operand types for * ("float" and "_NestedSequence[_SupportsArray[dtype[Any]]]") [operator]
+ colour/models/rgb/transfer_functions/canon.py:168: error: Unsupported operand types for * ("float" and "str") [operator]
+ colour/models/rgb/transfer_functions/canon.py:168: error: Unsupported operand types for * ("float" and "_NestedSequence[complex | bytes | str]") [operator]
... (truncated 113 lines) ...
steam.py (https://github.com/Gobot1234/steam.py)
- steam/ext/commands/help.py:35: error: Redundant cast to "CommandKwargs[Any]" [redundant-cast]
pandas (https://github.com/pandas-dev/pandas)
+ pandas/core/util/hashing.py:350: error: Unused "type: ignore" comment [unused-ignore]
+ pandas/io/formats/format.py:1607: error: Item "Sequence[float]" of "ndarray[tuple[Any, ...], dtype[Any]] | Sequence[float]" has no attribute "round" [union-attr]
+ pandas/io/formats/format.py:1618: error: No overload variant of "__getitem__" of "Sequence" matches argument type "ndarray[tuple[Any, ...], dtype[numpy.bool[builtins.bool]]]" [call-overload]
+ pandas/io/formats/format.py:1618: note: Possible overload variants:
+ pandas/io/formats/format.py:1618: note: def __getitem__(self, int, /) -> float
+ pandas/io/formats/format.py:1618: note: def __getitem__(self, slice[Any, Any, Any], /) -> Sequence[float]
+ pandas/io/formats/format.py:1620: error: No overload variant of "__getitem__" of "Sequence" matches argument type "ndarray[tuple[Any, ...], dtype[numpy.bool[builtins.bool]]]" [call-overload]
+ pandas/io/formats/format.py:1620: note: Possible overload variants:
+ pandas/io/formats/format.py:1620: note: def __getitem__(self, int, /) -> float
+ pandas/io/formats/format.py:1620: note: def __getitem__(self, slice[Any, Any, Any], /) -> Sequence[float]
pandas-stubs (https://github.com/pandas-dev/pandas-stubs)
+ tests/test_timefuncs.py:1660: error: Expression is of type "Series[Any]", not "Series[Timestamp]" [assert-type]
+ tests/test_frame.py:1089: error: Expression is of type "Any", not "ndarray[tuple[Any, ...], dtype[Any]]" [assert-type]
+ tests/series/test_agg.py:14: error: Expression is of type "Any", not "float" [assert-type]
+ tests/series/test_agg.py:15: error: Expression is of type "Any", not "float" [assert-type]
+ tests/series/test_agg.py:16: error: Expression is of type "Any", not "float" [assert-type]
+ tests/series/arithmetic/test_truediv.py:99: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_truediv.py:102: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_sub.py:235: error: Expression is of type "Any", not "Series[Timedelta]" [assert-type]
+ tests/series/arithmetic/test_mul.py:78: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_mul.py:79: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_mul.py:80: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_mul.py:81: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_add.py:83: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_add.py:84: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_add.py:85: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/series/arithmetic/test_add.py:86: error: Expression is of type "Any", not "Series[Any]" [assert-type]
+ tests/scalars/test_scalars.py:1814: error: Expression is of type "Any", not "PeriodIndex" [assert-type]
+ tests/indexes/arithmetic/test_truediv.py:59: error: Expression is of type "Any", not "Index[Any]" [assert-type]
+ tests/indexes/arithmetic/test_mul.py:58: error: Expression is of type "Any", not "Index[Any]" [assert-type]
+ tests/indexes/arithmetic/test_mul.py:60: error: Expression is of type "Any", not "Index[Any]" [assert-type]
+ tests/indexes/arithmetic/test_mul.py:61: error: Expression is of type "Any", not "Index[Any]" [assert-type]
+ tests/indexes/arithmetic/test_add.py:57: error: Expression is of type "Any", not "Index[Any]" [assert-type]
+ tests/indexes/arithmetic/test_add.py:58: error: Expression is of type "Any", not "Index[Any]" [assert-type]
+ tests/indexes/arithmetic/test_add.py:59: error: Expression is of type "Any", not "Index[Any]" [assert-type]
+ tests/indexes/arithmetic/test_add.py:60: error: Expression is of type "Any", not "Index[Any]" [assert-type]
+ tests/indexes/arithmetic/test_add.py:111: error: Expression is of type "Any", not "Never" [assert-type]
+ tests/series/test_series.py:1992: error: Expression is of type "ndarray[Any, Any]", not "ndarray[tuple[int], dtype[Any]]" [assert-type]
+ tests/series/test_series.py:3516: error: Expression is of type "Any", not "Series[float]" [assert-type]
pandera (https://github.com/pandera-dev/pandera)
- tests/pandas/test_dtypes.py:343: error: Need type annotation for "series" [var-annotated]
+ tests/pandas/test_dtypes.py:345: error: Unused "type: ignore" comment [unused-ignore]
static-frame (https://github.com/static-frame/static-frame)
+ static_frame/core/rank.py:106: error: Unused "type: ignore" comment [unused-ignore]
xarray (https://github.com/pydata/xarray)
+ xarray/tests/test_typed_ops.py:28: error: Unused "type: ignore" comment [unused-ignore]
+ xarray/tests/test_typed_ops.py:79: error: Unused "type: ignore" comment [unused-ignore]
freqtrade (https://github.com/freqtrade/freqtrade)
- freqtrade/optimize/backtesting.py:1533: error: Incompatible return value type (got "list[list[Any]]", expected "list[tuple[Any, ...]] | None") [return-value]
- freqtrade/plugins/pairlist/VolatilityFilter.py:156: error: "ndarray[tuple[Any, ...], dtype[Any]]" has no attribute "fillna" [attr-defined]
- freqtrade/plugins/pairlist/VolatilityFilter.py:158: error: "ndarray[tuple[Any, ...], dtype[Any]]" has no attribute "rolling" [attr-defined]
|
See the added testcase. If the overload result is ambiguous due to
Anyin selftype, mypy should not arbitrary pick the first overload. Let's see what primer says first.