From cbe2265d3c203c557fb109e804a401b917dffb4b Mon Sep 17 00:00:00 2001 From: Ion Koutsouris <15728914+ion-elgreco@users.noreply.github.com> Date: Sat, 7 Sep 2024 11:17:03 +0200 Subject: [PATCH] chore: re-enable optional old casting behavior in merge --- python/deltalake/table.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/python/deltalake/table.py b/python/deltalake/table.py index fd1e2c1a6d..dc98db2a5a 100644 --- a/python/deltalake/table.py +++ b/python/deltalake/table.py @@ -1000,13 +1000,18 @@ def merge( commit_properties, custom_metadata ) - if large_dtypes: + if large_dtypes is not None: warnings.warn( "large_dtypes is deprecated", category=DeprecationWarning, stacklevel=2, ) - conversion_mode = ArrowSchemaConversionMode.PASSTHROUGH + if large_dtypes: + conversion_mode = ArrowSchemaConversionMode.LARGE + else: + conversion_mode = ArrowSchemaConversionMode.NORMAL + else: + conversion_mode = ArrowSchemaConversionMode.PASSTHROUGH from .schema import ( convert_pyarrow_dataset,