8000 Small `__getstate__` cleanups. · matplotlib/matplotlib@1f30016 · GitHub
[go: up one dir, main page]

Skip to content

Commit 1f30016

Browse files
committed
Small __getstate__ cleanups.
Remove outdated comment in `AxesBase.__getstate__` (we don't cache the renderer on it anymore). Remove unnecessary `SubplotSpec 10000 .__getstate__` (it has become unnecessary now that SubplotSpec doesn't hold onto layoutbox/poslayoutbox anymore.)
1 parent 21b76ae commit 1f30016

File tree

2 files changed

+0
-5
lines changed

2 files changed

+0
-5
lines changed

lib/matplotlib/axes/_base.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -682,8 +682,6 @@ def __init__(self, fig, rect,
682682
which='major')
683683

684684
def __getstate__(self):
685-
# The renderer should be re-created by the figure, and then cached at
686-
# that point.
687685
state = super().__getstate__()
688686
# Prune the sharing & twinning info to only contain the current group.
689687
state["_shared_axes"] = {

lib/matplotlib/gridspec.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -623,9 +623,6 @@ def num2(self):
623623
def num2(self, value):
624624
self._num2 = value
625625

626-
def __getstate__(self):
627-
return {**self.__dict__}
628-
629626
def get_gridspec(self):
630627
return self._gridspec
631628

0 commit comments

Comments
 (0)
0