Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 7b504fe

Browse files
jklymakMeeseeksDev[bot]
authored andcommitted
Backport PR #12630: Fix RcParams.__len__
1 parent b97cb0a commit 7b504fe

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

lib/matplotlib/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -908,6 +908,9 @@ def __iter__(self):
908908
"""Yield sorted list of keys."""
909909
yield from sorted(dict.__iter__(self))
910910

911+
def __len__(self):
912+
return dict.__len__(self)
913+
911914
def find_all(self, pattern):
912915
"""
913916
Return the subset of this RcParams dictionary whose keys match,

0 commit comments

Comments
 (0)