raulcd opened a new issue, #35235: URL: https://github.com/apache/arrow/issues/35235
### Describe the bug, including details regarding any error messages, version, and platform. The following pandas testing jobs have started failing: * [test-conda-python-3.8-pandas-nightly](https://github.com/ursacomputing/crossbow/actions/runs/4738231715/jobs/8411873705) * [test-conda-python-3.9-pandas-upstream_devel](https://github.com/ursacomputing/crossbow/actions/runs/4738226848/jobs/8411863885) There are a couple of test failures: ``` =================================== FAILURES =================================== _____ TestConvertDateTimeLikeTypes.test_timestamp_to_pandas_out_of_bounds ______ self = <pyarrow.tests.test_pandas.TestConvertDateTimeLikeTypes object at 0x7fdc7d41bb40> def test_timestamp_to_pandas_out_of_bounds(self): # ARROW-7758 check for out of bounds timestamps for non-ns timestamps 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)) table = pa.table({'a': arr}) msg = "would result in out of bounds timestamp" with pytest.raises(ValueError, match=msg): arr.to_pandas() with pytest.raises(ValueError, match=msg): table.to_pandas() with pytest.raises(ValueError, match=msg): # chunked array table.column('a').to_pandas() # just ensure those don't give an error, but do not # check actual garbage output arr.to_pandas(safe=False) table.to_pandas(safe=False) > table.column('a').to_pandas(safe=False) opt/conda/envs/arrow/lib/python3.8/site-packages/pyarrow/tests/test_pandas.py:1461: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ pyarrow/array.pxi:837: in pyarrow.lib._PandasConvertible.to_pandas ??? pyarrow/table.pxi:469: in pyarrow.lib.ChunkedArray._to_pandas ??? opt/conda/envs/arrow/lib/python3.8/site-packages/pandas/core/dtypes/dtypes.py:848: in __from_arrow__ array = array.cast(pyarrow.timestamp(unit=self._unit), safe=True) pyarrow/table.pxi:551: in pyarrow.lib.ChunkedArray.cast ??? opt/conda/envs/arrow/lib/python3.8/site-packages/pyarrow/compute.py:400: in cast return call_function("cast", [arr], options, memory_pool) pyarrow/_compute.pyx:572: in pyarrow._compute.call_function ??? pyarrow/_compute.pyx:367: in pyarrow._compute.Function.call ??? pyarrow/error.pxi:144: in pyarrow.lib.pyarrow_internal_check_status ??? _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > ??? E pyarrow.lib.ArrowInvalid: Casting from timestamp[s, tz=America/New_York] to timestamp[ns] would result in out of bounds timestamp: -62135596800 pyarrow/error.pxi:100: ArrowInvalid __________________ test_chunked_array_to_pandas_preserve_name __________________ @pytest.mark.pandas def test_chunked_array_to_pandas_preserve_name(): # https://issues.apache.org/jira/browse/ARROW-7709 import pandas as pd import pandas.testing as tm for data in [ pa.array([1, 2, 3]), pa.array(pd.Categorical(["a", "b", "a"])), pa.array(pd.date_range("2012", periods=3)), pa.array(pd.date_range("2012", periods=3, tz="Europe/Brussels")), pa.array([1, 2, 3], pa.timestamp("ms")), pa.array([1, 2, 3], pa.timestamp("ms", "Europe/Brussels"))]: table = pa.table({"name": data}) result = table.column("name").to_pandas() > assert result.name == "name" E AssertionError: assert None == 'name' E + where None = 0 2012-01-01 00:00:00+01:00\n1 2012-01-02 00:00:00+01:00\n2 2012-01-03 00:00:00+01:00\ndtype: datetime64[ns, Europe/Brussels].name opt/conda/envs/arrow/lib/python3.8/site-packages/pyarrow/tests/test_table.py:348: AssertionError ``` This is happening on the 12.0.0 maintenance branch, meaning there has been something introduced on Pandas. ### Component(s) Continuous Integration, Python -- 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]
