Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-1738

[Python] Wrong datetime conversion when pa.array with unit

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.7.1
    • Fix Version/s: 0.8.0
    • Component/s: Python
    • Labels:
      None

      Description

      import pyarrow as pa
      import datetime
      
      pa.array([datetime.datetime.now()], type=pa.timestamp('s')) # OverflowError 
      pa.array([datetime.datetime.now()], type=pa.timestamp('ms')) # OverflowError 
      pa.array([datetime.datetime.now()], type=pa.timestamp('us')) # correct 
      pa.array([datetime.datetime.now()], type=pa.timestamp('ns')) # 1970-01-18 11:11:02.181293587
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Licht-T Licht Takeuchi
                Reporter:
                Licht-T Licht Takeuchi
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: