-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Allow short docstrings in pydoclint #13086
Comments
Possibly related to #5860 EDIT: I should probably elaborate. The proposal to restrict docstring diagnostics based on docstring complexity (what you describe) is distinct to what I linked (which is a proposal to limited based on function complexity). However, they face overlapping design challenges, so it might make sense to link them. |
@valentincalomme or @augustelalande, would you be able to elaborate a bit more about why this config option is desirable? I don't feel like #13302 gives a great description of what the config option is for right now, but I'm not sure how to improve it as I don't fully feel like I understand why it would be useful. |
@AlexWaygood for me it is desirable in the very simple scenario where I want to add a "one-liner" docstring, just to explain briefly what my method does. I dont' want pydoclint to complain that I am missing descriptions for the parameters. Actually, a good description is how
Right now, the |
I, too, always use def square(x: float) -> float:
"""Square the given number."""
... I mean I guess it is a little weird to tie the requirement to document all parameters to the number of lines in the docstring, but I found this heuristic to work well. |
Maybe a better rule would actually be:
Instead of
|
As of
ruff==0.6.2
,pydoclint
rules (DOC) doesn't allow any settings. If prioritization is required, I would personally really value having the--skip-checking-short-docstrings
setting (see: https://jsh9.github.io/pydoclint/config_options.html)This is currently blocking me from using the rule altogether.
The text was updated successfully, but these errors were encountered: