Missing parameter description results in Nonetype error down the line instead of checking for that, warning the user, and passing a safe return for further use (safe is not None).
"""
My numpydoc string documented function foo
Parameters
------------
param : str # if I don't add a description below I get that None error
Description to prevent Nonetype error.
Returns
--------
ret : str # Interestingly if I omit elements of this I get specific warnings telling me what is wrong
# I can also omit the description and get a pointed warning but no None error.
"""
Expected behavior
Code would display a warning or error noting that the parameter's description is missing similar to how it works in returns validation.
Describe the bug
Missing parameter description results in Nonetype error down the line instead of checking for that, warning the user, and passing a safe return for further use (safe is not None).
To Reproduce
(copied from comment on https://github.com/mkdocstrings/mkdocstrings/pull/397)
Expected behavior
Code would display a warning or error noting that the parameter's description is missing similar to how it works in returns validation.
This: https://github.com/mkdocstrings/pytkdocs/blob/master/src/pytkdocs/parsers/docstrings/numpy.py#L104
Should have an added check like this: https://github.com/mkdocstrings/pytkdocs/blob/master/src/pytkdocs/parsers/docstrings/numpy.py#L196
System (please complete the following information):
pytkdocs
version: 0.16.0Additional context
Discovered while trying to get to the bottom of https://github.com/mkdocstrings/mkdocstrings/pull/397.