Skip to content
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

BUG: to_datetime with empty string #55771

Merged

Conversation

jbrockmendel
Copy link
Member

@jbrockmendel jbrockmendel commented Oct 31, 2023

  • closes #xxxx (Replace xxxx with the GitHub issue number)
  • Tests added and passed if fixing a bug or adding a new feature
  • All code checks passed.
  • Added type annotations to new arguments/methods/functions.
  • Added an entry in the latest doc/source/whatsnew/vX.X.X.rst file if fixing a bug or adding a new feature.

Surfaced while imlpementing #55564

@jbrockmendel jbrockmendel requested a review from WillAyd as a code owner October 31, 2023 01:54
stacklevel=find_stack_level(),
)
warnings.warn(
"In a future version of pandas, parsing datetimes with mixed time "
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So if we call _array_to_datetime_object we always know there are mixed timezone components? The comments on line 614-617 doesn't seem to suggest so?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

correct. we only get here through the array_to_datetime path with not is_same_offsets

@mroeschke mroeschke added the Datetime Datetime data dtype label Oct 31, 2023
@mroeschke mroeschke added this to the 2.2 milestone Oct 31, 2023
@mroeschke mroeschke merged commit b0a0c68 into pandas-dev:main Oct 31, 2023
37 of 38 checks passed
@mroeschke
Copy link
Member

Thanks @jbrockmendel

@jbrockmendel jbrockmendel deleted the bug-array_to_datetime-nat-string branch October 31, 2023 20:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Datetime Datetime data dtype
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants