Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 17 lines (10 sloc) 0.345 kb
ae00f6d @mitsuhiko Tweaked autodoc to skip :internal: methods.
authored
1 import re
2 import inspect
3
4
5 _internal_mark_re = re.compile(r'^\s*:internal:\s*$(?m)')
6
7
8 def skip_member(app, what, name, obj, skip, options):
9 docstring = inspect.getdoc(obj)
10 if skip:
11 return True
12 return _internal_mark_re.search(docstring or '') is not None
13
14
15 def setup(app):
16 app.connect('autodoc-skip-member', skip_member)
Something went wrong with that request. Please try again.