Skip to content

Commit

Permalink
Revert "fix: improve datetime detection in pandas dataframes"
Browse files Browse the repository at this point in the history
This reverts commit 602d2c1.
  • Loading branch information
juba committed Sep 5, 2024
1 parent 602d2c1 commit 28ae063
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pyobsplot/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def pd_to_arrow(df: pd.DataFrame) -> bytes:
"""
# Convert dates to timestamps
for col in df.columns:
if pd.api.types.is_datetime64_any_dtype(df[col]):
if df[col].dtype == "object":
try:
df[col] = pd.to_datetime(df[col])
except ValueError:
Expand Down

0 comments on commit 28ae063

Please sign in to comment.