Skip to content

Commit

Permalink
apacheGH-35235: [CI][Python] Pandas upstream_devel and nightlies are …
Browse files Browse the repository at this point in the history
…failing (apache#35248)

* Closes: apache#35235

Lead-authored-by: Alenka Frim <frim.alenka@gmail.com>
Co-authored-by: Alenka Frim <AlenkaF@users.noreply.github.com>
Co-authored-by: Joris Van den Bossche <jorisvandenbossche@gmail.com>
Signed-off-by: Raúl Cumplido <raulcumplido@gmail.com>
  • Loading branch information
2 people authored and ArgusLi committed May 15, 2023
1 parent 3f89fa5 commit 91c82f2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion python/pyarrow/table.pxi
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,7 @@ cdef class ChunkedArray(_PandasConvertible):
# pandas ExtensionDtype that implements conversion from pyarrow
if hasattr(pandas_dtype, '__from_arrow__'):
arr = pandas_dtype.__from_arrow__(self)
return pandas_api.series(arr)
return pandas_api.series(arr, name=self._name)

return _array_like_to_pandas(self, options, types_mapper=types_mapper)

Expand Down
7 changes: 7 additions & 0 deletions python/pyarrow/tests/test_pandas.py
Original file line number Diff line number Diff line change
Expand Up @@ -1438,6 +1438,13 @@ def test_timestamp_to_pandas_ns(self):
def test_timestamp_to_pandas_out_of_bounds(self):
# ARROW-7758 check for out of bounds timestamps for non-ns timestamps

if Version(pd.__version__) >= Version("2.1.0.dev"):
# GH-35235: test fail due to __from_pyarrow__ being added to pandas
# https://github.com/pandas-dev/pandas/pull/52201
# Needs: https://github.com/apache/arrow/issues/33321
pytest.skip(
"Need support converting to non-nano datetime64 for pandas >= 2.0")

for unit in ['s', 'ms', 'us']:
for tz in [None, 'America/New_York']:
arr = pa.array([datetime(1, 1, 1)], pa.timestamp(unit, tz=tz))
Expand Down

0 comments on commit 91c82f2

Please sign in to comment.