We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1d23f66 commit f1cf9c3Copy full SHA for f1cf9c3
numpydoc/docscrape.py
@@ -511,7 +511,7 @@ def methods(self):
511
return [name for name,func in inspect.getmembers(self._cls)
512
if ((not name.startswith('_')
513
or name in self.extra_public_methods)
514
- and callable(func))]
+ and callable(func) and not isinstance(func, type))]
515
516
@property
517
def properties(self):
numpydoc/tests/test_docscrape.py
@@ -603,6 +603,10 @@ def spammity(self):
603
"""Spammity index"""
604
return 0.95
605
606
+ class Ignorable(object):
607
+ """local class, to be ignored"""
608
+ pass
609
+
610
for cls in (ClassDoc, SphinxClassDoc):
611
doc = cls(Dummy, config=dict(show_class_members=False))
612
assert 'Methods' not in str(doc), (cls, str(doc))
0 commit comments