diff --git a/python/pyspark/sql/types.py b/python/pyspark/sql/types.py index 05ecb5b388757..3f1e9ee83f101 100644 --- a/python/pyspark/sql/types.py +++ b/python/pyspark/sql/types.py @@ -2171,6 +2171,7 @@ def _infer_type( obj, infer_dict_as_struct=infer_dict_as_struct, infer_array_from_first_element=infer_array_from_first_element, + prefer_timestamp_ntz=prefer_timestamp_ntz, ) except TypeError: raise PySparkTypeError(