Skip to content

TST: Add test for feather I/O with historical out-of-bounds datetime values #60209

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

jasonmokk
Copy link
Contributor

@jasonmokk jasonmokk commented Nov 6, 2024

This PR adds a unit test to pandas/tests/io/test_feather.py to verify that out-of-bounds datetime values (historical dates outside of standard datetime64[ns] range) are correctly handled when saved to and loaded from Feather files. Addresses GH #47832.

@jasonmokk jasonmokk closed this Nov 6, 2024
@jasonmokk jasonmokk reopened this Nov 6, 2024
@jasonmokk jasonmokk force-pushed the test-out-of-bounds-datetime-to-feather branch 5 times, most recently from 8c0c6ac to 1320034 Compare November 6, 2024 02:22
Copy link
Member

@rhshadrach rhshadrach left a comment

Choose a reason for hiding this comment

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

Thanks for the PR

@rhshadrach rhshadrach added IO Parquet parquet, feather Needs Tests Unit test(s) needed to prevent regressions labels Nov 6, 2024
@jasonmokk jasonmokk force-pushed the test-out-of-bounds-datetime-to-feather branch from 1320034 to 5cd403a Compare November 6, 2024 16:33
@jasonmokk jasonmokk requested a review from rhshadrach November 6, 2024 16:35
Copy link
Member

@rhshadrach rhshadrach left a comment

Choose a reason for hiding this comment

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

I missed that we have check_round_trip. We can simplify the test with that.

@jasonmokk jasonmokk force-pushed the test-out-of-bounds-datetime-to-feather branch from 5cd403a to 7985a21 Compare November 6, 2024 17:26
TST: feather I/O with historical out-of-bounds datetime values

TST: feather I/O with historical out-of-bounds datetime values

TST: feather I/O with historical out-of-bounds datetime values
@jasonmokk jasonmokk force-pushed the test-out-of-bounds-datetime-to-feather branch from 7985a21 to 14dc724 Compare November 6, 2024 17:28
Copy link
Member

@rhshadrach rhshadrach left a comment

Choose a reason for hiding this comment

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

lgtm

Copy link
Member

@jorisvandenbossche jorisvandenbossche left a comment

Choose a reason for hiding this comment

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

Thanks!

@jorisvandenbossche jorisvandenbossche added this to the 3.0 milestone Nov 7, 2024
@jorisvandenbossche jorisvandenbossche merged commit 909c6da into pandas-dev:main Nov 7, 2024
51 checks passed
@jasonmokk jasonmokk deleted the test-out-of-bounds-datetime-to-feather branch November 7, 2024 17:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
IO Parquet parquet, feather Needs Tests Unit test(s) needed to prevent regressions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BUG: Out of bound dates can be saved to feather but not loaded
4 participants