Skip to content

Commit

Permalink
DEPR: remove Index.summary (#29807)
Browse files Browse the repository at this point in the history
  • Loading branch information
jbrockmendel authored and gfyoung committed Nov 24, 2019
1 parent a522b5c commit 35029d2
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 20 deletions.
1 change: 1 addition & 0 deletions doc/source/whatsnew/v1.0.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -376,6 +376,7 @@ or ``matplotlib.Axes.plot``. See :ref:`plotting.formatters` for more.

**Other removals**

- Removed the previously deprecated :meth:`Index.summary` (:issue:`18217`)
- Removed the previously deprecated :meth:`Series.get_value`, :meth:`Series.set_value`, :meth:`DataFrame.get_value`, :meth:`DataFrame.set_value` (:issue:`17739`)
- Changed the the default value of `inplace` in :meth:`DataFrame.set_index` and :meth:`Series.set_axis`. It now defaults to False (:issue:`27600`)
- Removed support for nested renaming in :meth:`DataFrame.aggregate`, :meth:`Series.aggregate`, :meth:`DataFrameGroupBy.aggregate`, :meth:`SeriesGroupBy.aggregate`, :meth:`Rolling.aggregate` (:issue:`18529`)
Expand Down
13 changes: 0 additions & 13 deletions pandas/core/indexes/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1132,19 +1132,6 @@ def _summary(self, name=None):
name = type(self).__name__
return f"{name}: {len(self)} entries{index_summary}"

def summary(self, name=None):
"""
Return a summarized representation.
.. deprecated:: 0.23.0
"""
warnings.warn(
"'summary' is deprecated and will be removed in a future version.",
FutureWarning,
stacklevel=2,
)
return self._summary(name)

# --------------------------------------------------------------------
# Conversion Methods

Expand Down
7 changes: 0 additions & 7 deletions pandas/tests/indexes/test_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1385,13 +1385,6 @@ def test_summary_bug(self):
assert "~:{range}:0" in result
assert "{other}%s" in result

# GH18217
def test_summary_deprecated(self):
ind = Index(["{other}%s", "~:{range}:0"], name="A")

with tm.assert_produces_warning(FutureWarning):
ind.summary()

def test_format(self, indices):
self._check_method_works(Index.format, indices)

Expand Down

0 comments on commit 35029d2

Please sign in to comment.