diff --git a/pandas/core/indexes/interval.py b/pandas/core/indexes/interval.py index 1c86235f9eaa1..8da6907750ac7 100644 --- a/pandas/core/indexes/interval.py +++ b/pandas/core/indexes/interval.py @@ -1055,7 +1055,7 @@ def equals(self, other) -> bool: if not isinstance(other, IntervalIndex): if not is_interval_dtype(other): return False - other = Index(getattr(other, ".values", other)) + other = Index(other) return ( self.left.equals(other.left) diff --git a/pandas/core/internals/managers.py b/pandas/core/internals/managers.py index 01b2c36e9adf3..1fce2594062d5 100644 --- a/pandas/core/internals/managers.py +++ b/pandas/core/internals/managers.py @@ -669,12 +669,6 @@ def is_numeric_mixed_type(self): self._consolidate_inplace() return all(block.is_numeric for block in self.blocks) - @property - def is_datelike_mixed_type(self): - # Warning, consolidation needs to get checked upstairs - self._consolidate_inplace() - return any(block.is_datelike for block in self.blocks) - @property def any_extension_types(self): """Whether any of the blocks in this manager are extension blocks""" diff --git a/pandas/core/series.py b/pandas/core/series.py index 33565bbedade6..01b68550391e6 100644 --- a/pandas/core/series.py +++ b/pandas/core/series.py @@ -701,7 +701,7 @@ def __array__(self, dtype=None) -> np.ndarray: Returns ------- numpy.ndarray - The values in the series converted to a :class:`numpy.ndarary` + The values in the series converted to a :class:`numpy.ndarray` with the specified `dtype`. See Also diff --git a/pandas/tests/frame/indexing/test_indexing.py b/pandas/tests/frame/indexing/test_indexing.py index 40ecda7d74952..cbb9dd09bbede 100644 --- a/pandas/tests/frame/indexing/test_indexing.py +++ b/pandas/tests/frame/indexing/test_indexing.py @@ -2179,7 +2179,7 @@ def test_type_error_multiindex(self): dg = df.pivot_table(index="i", columns="c", values=["x", "y"]) with pytest.raises(TypeError, match="is an invalid key"): - str(dg[:, 0]) + dg[:, 0] index = Index(range(2), name="i") columns = MultiIndex(