Closed
Description
In [1]: from numpydoc.docscrape import NumpyDocString
...: from numpy import array
...: len(NumpyDocString(array.__doc__)['Parameters'])
Out[1]: 1
(should be 6)
Again due to a dedent issue:
$ git diff
diff --git a/numpydoc/docscrape.py b/numpydoc/docscrape.py
index d79992c..3db20fe 100644
--- a/numpydoc/docscrape.py
+++ b/numpydoc/docscrape.py
@@ -219,6 +219,7 @@ class NumpyDocString(Mapping):
yield name, self._strip(data[2:])
def _parse_param_list(self, content, single_element_is_type=False):
+ content = dedent_lines(content)
r = Reader(content)
params = []
while not r.eof():
Fixes it.
Not quite sure why it is not found in tests...
Metadata
Metadata
Assignees
Labels
No labels