diff --git a/doc/source/conf.py b/doc/source/conf.py index a500289b27ab1..695a954f78cfb 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -246,3 +246,12 @@ 'GH'), 'wiki': ('https://github.com/pydata/pandas/wiki/%s', 'wiki ')} + +# remove the docstring of the flags attribute (inherited from numpy ndarray) +# because these give doc build errors (see GH issue 5331) +def remove_flags_docstring(app, what, name, obj, options, lines): + if what == "attribute" and name.endswith(".flags"): + del lines[:] + +def setup(app): + app.connect("autodoc-process-docstring", remove_flags_docstring)