NumpyDoc Checking for conformity to the doc spec?

296 Views Asked by At

The Numpy project provides a specification for the the formatting of their documentation to support readability and automated extraction (link). They also provide Numpydoc, as an extension to Sphinx, to support extraction of some additional keywords.

Before starting to write an extension to docutils, does a library exist to help introspect existing docstrings and identify non-conformity to the Numpy standard.

Image a more mature library with extensive documentation that wanted to adopt the Numpy documentation spec. One approach would be to introspect the library and generate a report describing the state of the doc strings.

This is reconnaissance question before starting to implement this as an extension to docutils or numpydoc. Have I missed an existing solution or does an elegant solution exist?

1

There are 1 best solutions below

1
On

The closest thing I've come across is doccheck by @robert-t-mcgibbon:

Check that all docstrings satisfy Numpy format

This is a small script that goes through functions, methods and classes in a package and looks for inconsistencies between the signatures and (Numpy format) docstring.