Skip to content

REF: dispatch TDBlock.to_native_types to TDA._format_native_types #33270

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

Conversation

jbrockmendel
Copy link
Member

No description provided.

@jbrockmendel jbrockmendel added the Refactor Internal refactoring of code label Apr 5, 2020
Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

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

this is changing the output format from the truncated (e.g. 1 days to, to the full, e.g. 1 days 00:00:00.000000).

I don't think that is actually desiriable as this affects the display in csv and in a series/dataframe.

I guess this is not really tested aside from the tests you changed.

We correctly handle this for datetimes, so must be some slightly differing path.

@jreback jreback added the Timedelta Timedelta data type label Apr 5, 2020
@jbrockmendel
Copy link
Member Author

If we don't want to change the DataFrame/to_csv behavior, we could add the "0 days" back in to the TDI/TDA behavior. That only requires changing 2 tests (both of which are directly testing Timedelta64Formatter)

@jreback
Copy link
Contributor

jreback commented Apr 5, 2020

i think that would be better to add back to TDIFormatter

@jbrockmendel
Copy link
Member Author

updated

@jreback jreback added this to the 1.1 milestone Apr 6, 2020
@jreback jreback merged commit 8dd3d87 into pandas-dev:master Apr 6, 2020
@jreback
Copy link
Contributor

jreback commented Apr 6, 2020

nice!

@jbrockmendel jbrockmendel deleted the block-to_native_types-tdblock branch April 6, 2020 23:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactor Internal refactoring of code Timedelta Timedelta data type
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants