Description
>>> import decimal as d >>> import pyspark.pandas as ps >>> import numpy as np >>> ps.utils.default_session().conf.set('spark.sql.execution.arrow.pyspark.enabled', True) >>> ps.Series([d.Decimal(1.0), d.Decimal(2.0), d.Decimal(np.nan)]) 0 1 1 2 2 None dtype: object >>> ps.utils.default_session().conf.set('spark.sql.execution.arrow.pyspark.enabled', False) >>> ps.Series([d.Decimal(1.0), d.Decimal(2.0), d.Decimal(np.nan)]) 21/07/02 15:01:07 ERROR Executor: Exception in task 6.0 in stage 13.0 (TID 51) net.razorvine.pickle.PickleException: problem construction object: java.lang.reflect.InvocationTargetException ...
As the code is shown above, we cannot create a Series with `Decimal('NaN')` when Arrow disabled. We ought to fix that.