-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BUG: read_csv raising for arrow engine and parse_dates #53295
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
# Conflicts: # doc/source/whatsnew/v2.0.2.rst
@@ -1137,6 +1137,9 @@ def unpack_if_single_element(arg): | |||
return arg | |||
|
|||
def converter(*date_cols, col: Hashable): | |||
if len(date_cols) == 1 and date_cols[0].dtype.kind in "Mm": |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if I understood your comment in the OP correctly, but does this also fix parse_dates
for numpy dtypes too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only NumPy dtypes as far as I know, we fixed this for Arrow dtypes a couple of weeks ago.
Can you share a MRE of the issue you're having? I'm wondering if #50056 fixes/causes the issue. |
Nope, still raises after your PR is in Edit: The main issue is that arrow infers as datetime and we try to infer again, which raises. |
Thanks @phofl |
Owee, I'm MrMeeseeks, Look at me. There seem to be a conflict, please backport manually. Here are approximate instructions:
And apply the correct labels and milestones. Congratulations — you did some good work! Hopefully your backport PR will be tested by the continuous integration and merged soon! Remember to remove the If these instructions are inaccurate, feel free to suggest an improvement. |
Will backport later today or tomorrow |
) (cherry picked from commit aaf5037)
The first one is a bit less common, can think about the second one if you like |
That'd be great, I think there were a couple issues opened about nans in string columns not being read properly related to the second. |
doc/source/whatsnew/vX.X.X.rst
file if fixing a bug or adding a new feature.Not sure if this is an actual regression, but ties a bit into the dtype backend and would be nice if this works, since this raises for every parse_date case with numpy dtype backend (and I want to advertise the engine in my pyarrow blog...)