-
Notifications
You must be signed in to change notification settings - Fork 126
fix(deps): support pandas 3.0 (prerelease) #998
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
base: main
Are you sure you want to change the base?
Conversation
Summary of ChangesHello @tswast, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request primarily focuses on updating the project's dependency configuration to support the upcoming pandas 3.0 release. This involves removing an outdated version constraint for pandas and making minor, targeted adjustments to existing test cases to ensure compatibility with changes in pandas' handling of missing data and specific BigQuery date parsing behaviors. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
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.
Code Review
This pull request updates the pandas dependency to allow for version 3.0 by removing the upper version constraint. The accompanying changes in the system tests, which involve updating the representation of missing values to pandas.NA and adjusting a datetime test value, appear to be necessary for compatibility with the newer pandas version. Overall, the changes look good, but I have one suggestion to clarify a comment in the test suite for better maintainability.
| # CSV loader in BigQuery currently requires leading 0s | ||
| # for TIMESTAMP but not DATETIME. See internal issue | ||
| # b/467399807. | ||
| datetime.datetime(1000, 1, 1), |
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.
The comment on lines 347-349 is a bit confusing. It states that the CSV loader's requirement for leading zeros applies to TIMESTAMP but not DATETIME. However, this change is made to datetime_col, which is defined as a DATETIME column in the table schema on line 374. Could you please clarify why this change is needed for a DATETIME column, or update the comment for future reference? This would help maintainers understand the reason for this specific test value.
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.
Correct. I use year >= 1000 so that no leading zeros are required.
|
Local tests pass with pandas 3.0.0rc0. Details |
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
Fixes #<issue_number_goes_here> 🦕