rr-/docstring_parser

Fails to parse return type containing spaces

rob-blackbourn opened this issue · 0 comments

Hi,

There are problems handling return types with spaces:

        """
        Returns:
            Optional[Mapping[str, List[int]]]: A description
        """

Due to line 98 of google.py:

and ":" not in text.split()[0]

Changing this to and ":" not in text would be the smallest change. Obviously this would create a false positive if a type was not specified and a colon was used in the description.

I made a pull request.

Rob