Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

TST: add regression test for GH#54409 (tz-aware NaT indexing with loc) #62245

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
jbrockmendel merged 1 commit into pandas-dev:main from skalwaghe-56:test-fix-54409
Sep 10, 2025

Conversation

Copy link
Contributor

@skalwaghe-56 skalwaghe-56 commented Sep 3, 2025


This adds a regression test for GH#54409, where .loc failed when
indexing a tz-aware DateTimeIndex with only NaT. The bug is already
fixed on main, and this test ensures it does not regress.

Copy link
Contributor Author

@jbrockmendel Kindly request you to check it :)

Copy link
Contributor Author

@jbrockmendel Its ready for the review!

Copy link
Contributor Author

Hey, @jbrockmendel Rebased and all checks passed!

@jorisvandenbossche jorisvandenbossche added Testing pandas testing functions or related to the test suite Indexing Related to indexing on series/frames, not to indexes themselves labels Sep 5, 2025
Copy link
Contributor Author

@jorisvandenbossche Let me know if these changes looks good to you!

@skalwaghe-56 skalwaghe-56 force-pushed the test-fix-54409 branch 2 times, most recently from 00f7437 to 93aef61 Compare September 8, 2025 14:01
Copy link
Contributor Author

@jorisvandenbossche Kindly request you to check and let me know!

@skalwaghe-56 skalwaghe-56 force-pushed the test-fix-54409 branch 4 times, most recently from 5b7f988 to 6dc98c0 Compare September 9, 2025 10:00
@jbrockmendel jbrockmendel merged commit 9c4b72f into pandas-dev:main Sep 10, 2025
38 checks passed
Copy link
Member

thanks @skalwaghe-56

@skalwaghe-56 skalwaghe-56 deleted the test-fix-54409 branch September 11, 2025 01:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
Indexing Related to indexing on series/frames, not to indexes themselves Testing pandas testing functions or related to the test suite
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

BUG: loc fails with tz_aware DateTimeIndex

AltStyle によって変換されたページ (->オリジナル) /