Open
Description
Pandas version checks
-
I have checked that this issue has not already been reported.
-
I have confirmed this bug exists on the latest version of pandas.
-
I have confirmed this bug exists on the main branch of pandas.
Reproducible Example
import pandas as pd
df = pd.DataFrame({"date": ['2022-01-01', '2023-01-01']}).astype({"date": "datetime64[ns]"})
print(df.date.diff())
df = pd.DataFrame({"date": ['2022-01-01', '2023-01-01']}).astype({"date": "datetime64[s]"})
print(df.date.diff())
Issue Description
I'm expecting the difference to be 365 days on both, however on the second example the difference ends up coming in nanoseconds as opposed to seconds.
Expected Behavior
Expecting the diff to be 365 days on both
Installed Versions
Replace this line with the output of pd.show_versions()