Skip to content

WARN: Clarify datetime warning when can't parse in accordance with dayfirst #47528

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

Merged
merged 9 commits into from
Jun 28, 2022

Conversation

MarcoGorelli
Copy link
Member

@MarcoGorelli MarcoGorelli commented Jun 28, 2022

(also, typing swapped_day_and_month whilst I'm here as I hadn't done that when introducing the original warning message)

@MarcoGorelli MarcoGorelli force-pushed the fix-datetime-warning branch from b0f0959 to 7d06940 Compare June 28, 2022 12:19
@MarcoGorelli MarcoGorelli force-pushed the fix-datetime-warning branch from 63152e3 to 3d65a64 Compare June 28, 2022 12:37
@mroeschke mroeschke added Datetime Datetime data dtype Warnings Warnings that appear or should be added to pandas labels Jun 28, 2022
@mroeschke mroeschke added this to the 1.5 milestone Jun 28, 2022
@mroeschke mroeschke merged commit fd1f643 into pandas-dev:main Jun 28, 2022
@mroeschke
Copy link
Member

Thanks @MarcoGorelli

yehoshuadimarsky pushed a commit to yehoshuadimarsky/pandas that referenced this pull request Jul 13, 2022
…yfirst (pandas-dev#47528)

* try improving

* WARN: clarify warning message from to_datetime when dayfirst cant be respected

* add test to count number of warnings emitted

* fix whatsnew note

* fixup test to use set

* update tests

* inconsistently-parsed -> inconsistently parsed

* remove date_string from .format call

* fixup other tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Datetime Datetime data dtype Warnings Warnings that appear or should be added to pandas
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BUG: UserWarning about lacking infer_datetime_format with pd.to_datetime
2 participants