Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

javadoc: @returns get parsed incorrectly #82

Open
thughes opened this issue Nov 18, 2019 · 2 comments
Open

javadoc: @returns get parsed incorrectly #82

thughes opened this issue Nov 18, 2019 · 2 comments

Comments

@thughes
Copy link

thughes commented Nov 18, 2019

Example:

def method(self):
    """Short description

    @returns: some return val
    """
    pass

Gets converted to:

def method(self):
    """Short description

    Returns:
        s: some return val
    """
    pass
@dadadel
Copy link
Owner

dadadel commented Nov 19, 2019

Hi @thughes
Indeed it seems that when "return' is written with an ending "s" it pyment will consider it as a kind of parameter. This should be addressed.

@introt
Copy link

introt commented Jun 12, 2021

The current pip version (0.3.3?) exhibits the behavior reported above, while the current git version adds another, indented @returns: line as well!

@param name: param desc
@returns: return desc
"""

Turns into this:

:param name: param desc
   @returns: return desc
:returns: s: return desc
"""

That extra line's indentation is also wrong: https://docutils.sourceforge.io/docs/ref/rst/restructuredtext.html#field-lists, but that's

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants