Skip to content

Commit

Permalink
fix pandas df in update
Browse files Browse the repository at this point in the history
  • Loading branch information
atl1502 committed Mar 24, 2024
1 parent 16575a2 commit f149792
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions dataprofiler/profilers/order_column_profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
from abc import abstractmethod
from typing import Protocol, Type, TypeVar, cast

import pandas as pd
import polars as pl
from polars import Series

Expand Down Expand Up @@ -482,6 +483,9 @@ def update(self, df_series: Series) -> OrderColumn:
:return: updated OrderColumn
:rtype: OrderColumn
"""
# TODO remove onces profiler builder is updated
if type(df_series) == pd.Series:
df_series = pl.from_pandas(df_series) # type: ignore
if len(df_series) == 0:
return self

Expand Down

0 comments on commit f149792

Please sign in to comment.