You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@arrow.apache.org by "mroeschke (via GitHub)" <gi...@apache.org> on 2023/11/09 16:21:04 UTC
[I] `pyarrow.compute.iso_calendar` returns incorrect results and segfaults for multiple repeated timestamps [arrow]
mroeschke opened a new issue, #38655:
URL: https://github.com/apache/arrow/issues/38655
### Describe the bug, including details regarding any error messages, version, and platform.
```python
In [1]: import pyarrow as pa
In [2]: pa.__version__
Out[2]: '14.0.0'
In [3]: import pyarrow.compute as pc
In [4]: from datetime import datetime
In [5]: arr = pa.array([datetime(2019, 1, 3, 5, 11)]*50)
In [6]: pc.iso_calendar(arr)
Out[6]:
<pyarrow.lib.StructArray object at 0x1500ff640>
-- is_valid: all not null
-- child 0 type: int64
[
2019,
2019,
2019,
2019,
2019,
2019,
2019,
2019,
2019,
2019,
...
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
]
-- child 1 type: int64
[
2019,
2019,
2019,
2019,
2019,
2019,
2019,
2019,
2019,
2019,
...
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
]
-- child 2 type: int64
[
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
...
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
]
In [7]: pc.iso_calendar(arr)
zsh: segmentation fault ipython
```
### Component(s)
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: issues-unsubscribe@arrow.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [C++] "iso_calendar" kernel returns incorrect results for array length > 32 [arrow]
Posted by "jorisvandenbossche (via GitHub)" <gi...@apache.org>.
jorisvandenbossche commented on issue #38655:
URL: https://github.com/apache/arrow/issues/38655#issuecomment-1809857582
Thanks! I can't reproduce the segfault, but it's of course obviously wrong anyway.
It seems the repeated values don't matter, I can also reproduce this with a date range, and it starts to happens once above 32 values:
```
arr = pa.array(pd.date_range("2019-01-01", periods=33, freq="3H"))
pc.iso_calendar(arr)
```
cc @rok
--
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: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [C++] "iso_calendar" kernel returns incorrect results for array length > 32 [arrow]
Posted by "jorisvandenbossche (via GitHub)" <gi...@apache.org>.
jorisvandenbossche closed issue #38655: [C++] "iso_calendar" kernel returns incorrect results for array length > 32
URL: https://github.com/apache/arrow/issues/38655
--
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: issues-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [C++] "iso_calendar" kernel returns incorrect results for array length > 32 [arrow]
Posted by "rok (via GitHub)" <gi...@apache.org>.
rok commented on issue #38655:
URL: https://github.com/apache/arrow/issues/38655#issuecomment-1818045697
Oh, that is interesting. I'll take a look this week.
--
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: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org