tadeja commented on PR #55264: URL: https://github.com/apache/arrow/pull/55264#issuecomment-6747488898
Review of array.pyi: With [commit a02f4bd More cases for test_array.py](https://github.com/apache/arrow/pull/55264/commits/a02f4bdd7999e0f6496c0a9ddf73eda248d16637) showed the errors also on CI here: https://github.com/apache/arrow/actions/runs/42661113858/job/129312629352?pr=55264#step:6:4733 and https://github.com/apache/arrow/actions/runs/42661114025/job/129312631543?pr=55264#step:6:4736 <details><summary>Details</summary> <p> ```console + mypy pyarrow-stubs/tests/test_array.py:51: error: Argument "safe" to "cast" of "Array" has incompatible type "None"; expected "bool" [arg-type] pyarrow-stubs/tests/test_array.py:53: error: Missing positional argument "target_type" in call to "cast" of "Array" [call-arg] pyarrow-stubs/tests/test_array.py:55: error: Argument 1 to "view" of "Array" has incompatible type "str"; expected "DataType" [arg-type] pyarrow-stubs/tests/test_array.py:56: error: Unexpected keyword argument "element_size_limit" for "to_string" of "Array" [call-arg] pyarrow-stubs/tests/test_array.py:56: note: "to_string" defined in "pyarrow.__lib.array" pyarrow-stubs/tests/test_array.py:57: error: Expression is of type "Any", not "Tensor" [assert-type] pyarrow-stubs/tests/test_array.py:57: error: "Int64Array" has no attribute "to_tensor" [attr-defined] pyarrow-stubs/tests/test_array.py:68: error: Argument 1 to "diff" of "Array" has incompatible type "StringArray"; expected "Int64Array" [arg-type] pyarrow-stubs/tests/test_array.py:76: error: Invalid index type "signedinteger[_64Bit]" for "Int64Array"; expected type "int | slice[Any, Any, Any]" [index] pyarrow-stubs/tests/test_array.py:79: error: Argument 1 to "from_arrays" of "ListArray" has incompatible type "ndarray[tuple[Any, ...], dtype[Any]]"; expected "Int32Array | list[int] | list[int | None]" [arg-type] pyarrow-stubs/tests/test_array.py:84: error: Unused "type: ignore" comment [unused-ignore] pyarrow-stubs/tests/test_array.py:111: error: Too many positional arguments for "from_arrays" of "ListArray" [call-arg] pyarrow-stubs/tests/test_array.py:111: note: "from_arrays" defined in "pyarrow.__lib.array" pyarrow-stubs/tests/test_array.py:114: error: Argument 2 to "from_arrays" of "LargeListArray" has incompatible type "list[int]"; expected "Array" [arg-type] pyarrow-stubs/tests/test_array.py:117: error: Argument 3 to "from_arrays" of "ListViewArray" has incompatible type "list[int]"; expected "Array" [arg-type] pyarrow-stubs/tests/test_array.py:120: error: Argument 3 to "from_arrays" of "LargeListViewArray" has incompatible type "list[int]"; expected "Array" [arg-type] pyarrow-stubs/tests/test_array.py:123: error: Argument 1 to "from_arrays" of "FixedSizeListArray" has incompatible type "list[int]"; expected "Array" [arg-type] pyarrow-stubs/tests/test_array.py:147: error: Argument 3 to "from_buffers" of "DictionaryArray" has incompatible type "list[Buffer | None]"; expected "list[Buffer]" [arg-type] pyarrow-stubs/tests/test_array.py:188: error: Unused "type: ignore" comment [unused-ignore] pyarrow-stubs/tests/test_array.py:190: error: Unused "type: ignore" comment [unused-ignore] pyarrow-stubs/tests/test_array.py:200: error: Unused "type: ignore" comment [unused-ignore] pyarrow-stubs/tests/test_array.py:202: error: Unused "type: ignore" comment [unused-ignore] pyarrow-stubs/tests/test_array.py:203: error: Unused "type: ignore" comment [unused-ignore] Found 21 errors in 1 file (checked 22 source files) ``` </p> </details> Errors are there handled within the subsequent commit pair [3ee3376 Review array.pyi](https://github.com/apache/arrow/pull/55264/commits/3ee33762b13da2095d785c124c3ed0c6c5f222f7) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
