NiklasRosenstein / pydoc-markdown

Create Python API documentation in Markdown format.
http://niklasrosenstein.github.io/pydoc-markdown/
Other
453 stars 102 forks source link

SmartProcessor doesn't identify sphinx docstrings with arg or argument keywords #221

Closed gmarks2149 closed 2 years ago

gmarks2149 commented 2 years ago

Environment

Describe the bug

If the smart processor is used to identify the docstring for a docstring using the sphinx style, it won't properly recognize the sphinx style if the keywords used to describe the parameters are the "arg" or "argument" keywords. This is the case only if none of the other indicator keywords are present in the docstring.

Example

def find(name: str):
    """Find something

    :arg name: The name to find
    """
    pass

Produces this output...

``` python
def find(name: str)

Find something

:arg name: The name to find



**Expected behavior**

The smart processor should identify this a sphinx style docstring and process it correctly accordingly.