BUG: Index.get_indexer_not_unique inconsistent return types vs get_indexer · Issue #16819 · pandas-dev/pandas (original) (raw)

See https://pandas.pydata.org/pandas-docs/stable/generated/pandas.Index.get_indexer_non_unique.html where the return value of Index.get_indexer_non_unique indexer is stated to be ndarray whereas actually this is converted into a Index before it is returned

indexer, missing = self._engine.get_indexer_non_unique(tgt_values)
return Index(indexer), missing