Skip to content

Commit

Permalink
Fixup deprecation warning from pandas (dask#8564)
Browse files Browse the repository at this point in the history
  • Loading branch information
phofl authored Mar 27, 2024
1 parent e72d2b2 commit 30d5df7
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion distributed/shuffle/_arrow.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,11 @@ def convert_shards(
):
continue
reconciled_dtypes[column] = find_common_type([actual, dtype])
return df.astype(reconciled_dtypes, copy=False)

from dask.dataframe._compat import PANDAS_GE_300

kwargs = {} if PANDAS_GE_300 else {"copy": False}
return df.astype(reconciled_dtypes, **kwargs)


def buffers_to_table(data: list[tuple[int, bytes]]) -> pa.Table:
Expand Down

0 comments on commit 30d5df7

Please sign in to comment.