Skip to content

Conversation

@felixvd
Copy link

@felixvd felixvd commented May 12, 2022

I've encountered some cases that don't tell the user what to fix. This catches the exception and localizes the error.

It also supports multi-line comments.

Example:

def myfunc():
    """Text
    
    :param myparam1: text followed by an empty line (will throw an error)
    
    :param myparam2: more text
        with an extra line (will work fine)
    :param myparam3 which has no closing colon (will throw an error)`
    """
    pass

Copy link

@a-t-0 a-t-0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dear Felix, thank you for your work. I was trying to review your code and thought it would be easier to understand if you could include a test case that demonstrates how your adaptations change the behaviour of pyment. (I noted your example on the support for multiline in the comment with the pull request). Would you perhaps be willing and able to write two of such tests?

  • Possibly one to demonstrate how your adaptation yields more helpful error messages.
  • And perhaps one that demonstrates the support for multiline descriptions?

Note, I have no affiliations with pyment, however I noticed it has not been updated in almost 1.2 years, so I thought it would be nice to show some interaction to perhaps get the ball rolling (again).

@jgarte
Copy link
Contributor

jgarte commented Mar 12, 2025

Hi, what's the status on this PR?

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

Successfully merging this pull request may close these issues.

3 participants