jalpan-randeri commented on a change in pull request #26585:
[WIP][SPARK-25351][SQL][Python] Handle Pandas category type when converting
from Python with Arrow
URL: https://github.com/apache/spark/pull/26585#discussion_r366772889
##########
File path: python/pyspark/serializers.py
##########
@@ -298,7 +298,10 @@ def create_array(s, t):
if t is not None and pa.types.is_timestamp(t):
s = _check_series_convert_timestamps_internal(s,
self._timezone)
try:
- array = pa.Array.from_pandas(s, mask=mask, type=t,
safe=self._safecheck)
+ if str(s.dtype) == 'category':
+ array = pa.array(s.get_values())
Review comment:
@BryanCutler
Hi bryan,
I need help here, since you identified this, looping you in.
this change has been blocked for a long time
can you provide some insight/guidance here?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]