raghumdani opened a new issue, #46361: URL: https://github.com/apache/arrow/issues/46361
### Describe the bug, including details regarding any error messages, version, and platform. Hi there, Pyarrow is unable to parse a valid timestamp value when a custom mask is specified. ### Repro Script ```python from pyarrow.compute import strptime strptime('2024/10/27 20:43:05.495', '%Y/%m/%d %H:%M:%S.%f', 'us') ``` ### Error Message ``` Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Users/_/.local/share/mise/installs/python/3.12.7/lib/python3.12/site-packages/pyarrow/compute.py", line 269, in wrapper return func.call(args, options, memory_pool) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "pyarrow/_compute.pyx", line 407, in pyarrow._compute.Function.call File "pyarrow/error.pxi", line 155, in pyarrow.lib.pyarrow_internal_check_status File "pyarrow/error.pxi", line 92, in pyarrow.lib.check_status pyarrow.lib.ArrowInvalid: Failed to parse string: '2024/10/27 20:43:05.495' as a scalar of type timestamp[us] ``` However, strptime on python3.10 can parse above timestamp ```python from datetime import datetime datetime.strptime('2024/10/27 20:43:05.495', '%Y/%m/%d %H:%M:%S.%f') >>> datetime.datetime(2024, 10, 27, 20, 43, 5, 495000) ``` Please let me know if I am missing something. Platform: MacOS Pyarrow Version: 20.0.0 Python version: 3.10 ### 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-unsubscr...@arrow.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org