[
https://issues.apache.org/jira/browse/ARROW-2741?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Wes McKinney resolved ARROW-2741.
---------------------------------
Resolution: Fixed
Issue resolved by pull request 2164
[https://github.com/apache/arrow/pull/2164]
> [Python] pa.array from np.datetime[D] and type=pa.date64 produces invalid
> results
> ---------------------------------------------------------------------------------
>
> Key: ARROW-2741
> URL: https://issues.apache.org/jira/browse/ARROW-2741
> Project: Apache Arrow
> Issue Type: Bug
> Components: Python
> Affects Versions: 0.9.0
> Reporter: Uwe L. Korn
> Assignee: Uwe L. Korn
> Priority: Major
> Labels: pull-request-available
> Fix For: 0.10.0
>
> Time Spent: 20m
> Remaining Estimate: 0h
>
> {code}
> In [1]: import pyarrow as pa
> In [2]: import numpy as np
> In [3]: pa.array(np.array(['2015-01-01', '2015-01-01'],
> dtype='datetime64[D]'))
> Out[3]:
> <pyarrow.lib.Date32Array object at 0x11571bae8>
> [
> datetime.date(2015, 1, 1),
> datetime.date(2015, 1, 1)
> ]
> In [4]: pa.array(np.array(['2015-01-01', '2015-01-01'],
> dtype='datetime64[D]'), type=pa.date64())
> Out[4]:
> <pyarrow.lib.Date64Array object at 0x10965d138>
> [
> datetime.date(2015, 1, 1),
> datetime.date(1970, 1, 1)
> ]
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)