Description
This piece of code in pyspark.pandas.frame is going to fail on runtime, when is_name_like_tuple evaluates to True
if is_name_like_tuple(column): if len(column) != len(self.columns.levels):
with
'Index' object has no attribute 'levels'
To be honest, I am not sure what is intended behavior (initially, I suspected that we should have
if len(column) != self.columns.nlevels
but nlevels is hard-coded to one, and wouldn't be consistent with Pandas at all.