-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Added dtype test concat function #44927
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
GustavoGB
commented
Dec 16, 2021
- closes Incorrect dtype for concat with empty float and datetime columns #32934
- tests added / passed
- Ensure all linting tests pass, see here for how to run them
- whatsnew entry
Hello @GustavoGB! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found: There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2021-12-16 19:37:58 UTC |
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.
I think test_datetimes would be a better place for this test?
pandas/tests/dtypes/test_concat.py
Outdated
|
||
|
||
def test_concat_float_datetime(): | ||
|
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.
Please add gh reference at the top, like GH#issue_number
pandas/tests/dtypes/test_concat.py
Outdated
df_time = pd.DataFrame({"A": pd.array(["2000"], dtype="datetime64[ns]")}) | ||
df_float = pd.DataFrame({"A": pd.array([1.0], dtype="float64")}) | ||
|
||
assert pd.concat([df_time.iloc[:0], df_float.iloc[:0]])["A"].dtype == object |
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.
Could you please check the whole DataFrame?
df_time = pd.DataFrame({"A": pd.array(["2000"], dtype="datetime64[ns]")}) | ||
df_float = pd.DataFrame({"A": pd.array([1.0], dtype="float64")}) | ||
|
||
assert pd.concat([df_time, df_float])["A"].dtype == object |
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.
Please test the whole DataFrame not only the dtype
This pull request is stale because it has been open for thirty days with no activity. Please update and respond to this comment if you're still interested in working on this. |
Thanks for the pull request, but it appears to have gone stale. If interested in continuing, please merge in main, address the comments and we can reopen |