Skip to content

Commit 81788a6

Browse files
committed
CLN: remove outdated _item_cache in comment
1 parent 025b2b2 commit 81788a6

File tree

2 files changed

+0
-6
lines changed

2 files changed

+0
-6
lines changed

pandas/core/internals/managers.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1898,10 +1898,6 @@ def _consolidate_check(self) -> None:
18981898
self._known_consolidated = True
18991899

19001900
def _consolidate_inplace(self) -> None:
1901-
# In general, _consolidate_inplace should only be called via
1902-
# DataFrame._consolidate_inplace, otherwise we will fail to invalidate
1903-
# the DataFrame's internal structures. The exception is for newly-created
1904-
# BlockManager objects not yet attached to a DataFrame.
19051901
if not self.is_consolidated():
19061902
self.blocks = _consolidate(self.blocks)
19071903
self._is_consolidated = True

pandas/tests/internals/test_internals.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -735,8 +735,6 @@ def test_reindex_items(self):
735735
mgr = create_mgr("a: f8; b: i8; c: f8; d: i8; e: f8; f: bool; g: f8-2")
736736

737737
reindexed = mgr.reindex_axis(["g", "c", "a", "d"], axis=0)
738-
# reindex_axis does not consolidate_inplace, as that risks failing to
739-
# invalidate internal caches
740738
assert not reindexed.is_consolidated()
741739

742740
tm.assert_index_equal(reindexed.items, Index(["g", "c", "a", "d"]))

0 commit comments

Comments
 (0)