jorisvandenbossche commented on code in PR #44195:
URL: https://github.com/apache/arrow/pull/44195#discussion_r1901843314
##########
python/pyarrow/pandas_compat.py:
##########
@@ -174,7 +174,11 @@ def get_column_metadata(column, name, arrow_type,
field_name):
}
string_dtype = 'object'
- if name is not None and not isinstance(name, str):
+ if (
+ name is not None
+ and not (isinstance(name, float) and np.isnan(name))
Review Comment:
Yes, since this was essentially to support some missing values in the column
names (but restricted to None), also allowing np.nan keeps somewhat the same
behaviour when switching from object dtype to string dtype
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]