BUG: always strip .freq when putting DTI/TDI into Series/DataFrame by jbrockmendel · Pull Request #41425 · pandas-dev/pandas (original) (raw)
ATM when we put a DatetimeArray/TimedeltaArray/DatetimeIndex/TimedeltaIndex (from here on, just "DTI") into a Series or DataFrame, we drop its .freq for BlockManager-DataFrame cases, but not the other three cases (BlockManager-Series, ArrayManager-DataFrame, ArrayManager-Series).
The long-term behavior is definitely going to always drop the freq (more specifically, DTA/TDA won't have freq, xref #31218). So this PR standardizes always-dropping.
cc @mroeschke this should unblock your window PR
cc @jorisvandenbossche bc this touches ArrayManager