docstring_parser icon indicating copy to clipboard operation
docstring_parser copied to clipboard

Parser doesn't parse types in reStructurted Text format

Open LostInDarkMath opened this issue 5 years ago • 4 comments

My example, which I found Here:

"""Gets and prints the spreadsheet's header columns

:param file_loc: The file location of the spreadsheet
:type file_loc: str
:param print_cols: A flag used to print the columns to the console
    (default is False)
:type print_cols: bool
:returns: a list of strings representing the header columns
:rtype: list
"""

In I parse this using your code, alle types will be ignored: TypeName == None

Is this a bug in your code or is an error in the docstring?

LostInDarkMath avatar Aug 07 '20 10:08 LostInDarkMath

IIRC we use :param file_loc str: The file location of the spreadsheet syntax

rr- avatar Aug 07 '20 14:08 rr-

Thank you for your quick answer.

Is there a chance, that a future version of your parser supports the syntax I mentioned above?

LostInDarkMath avatar Aug 07 '20 14:08 LostInDarkMath

I don't have capacity to work on it myself, but any PRs are encouraged and will be reviewed fast :)

rr- avatar Aug 07 '20 14:08 rr-

@LostInDarkMath FYI - My parser supports proper type parsing for ReST. Still in alpha - https://github.com/SamuelMarks/doctrans

SamuelMarks avatar Nov 17 '20 01:11 SamuelMarks