On pandas 0.23 (correct): ``` In [2]: pd.to_timedelta('NaT', box=False) Out[2]: numpy.timedelta64('NaT','ns') ``` But on pandas 0.24: ``` In [2]: pd.to_timedelta('NaT', box=False) Out[2]: numpy.datetime64('NaT') ``` The result is a datetime, not a timedelta.
Activity
jreback commentedon Jan 27, 2019
looks like a bug; note that box parameter is going away in any event
shoyer commentedon Jan 27, 2019
I hope there's a deprecation cycle planned? (We use
box
downstream in xarray.)jreback commentedon Jan 27, 2019
yes there is an issue about this
gfyoung commentedon Jan 27, 2019
xref #24416
jbrockmendel commentedon Jan 27, 2019
I’m pretty sure one of my recent PRs broke this, will make a fix shortly.
jbrockmendel commentedon Dec 10, 2019
@shoyer we're about to remove the
box=False
option forto_timedelta
in #30177, will this break things for xarray?