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

[pydocstyle] Document which rules are disabled by which conventions? #8573

Closed
alanhdu opened this issue Nov 9, 2023 · 2 comments · Fixed by #8638
Closed

[pydocstyle] Document which rules are disabled by which conventions? #8573

alanhdu opened this issue Nov 9, 2023 · 2 comments · Fixed by #8638
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@alanhdu
Copy link
Contributor

alanhdu commented Nov 9, 2023

On https://docs.astral.sh/ruff/settings/#pydocstyle-convention, it says

Enabling a convention will force-disable any rules that are not included in the specified convention

But I can't seem to find documentation about which rules are included in which conventions! Maybe I totally missed it, but I only found this information by going to the source code and finding

pub const fn rules_to_be_ignored(self) -> &'static [Rule] {

Is there some place this is documented? If not, how easy/hard would it be to add some documentation? I'd be happy to contribute a patch if the best way is to just add some markdown at

/// Enabling a convention will force-disable any rules that are not
, but maybe there's some clever way to auto-generate that information from the code to ensure it stays in sync?

@alanhdu alanhdu changed the title Document which pydocstyle rules are disabled by which conventions? [pydocstyle] Document which rules are disabled by which conventions? Nov 9, 2023
@charliermarsh
Copy link
Member

The list originally comes from pydocstyle. Perhaps we could enumerate the conventions in the FAQ, as part of the "Does Ruff support NumPy- or Google-style docstrings?" section?

@charliermarsh charliermarsh added the documentation Improvements or additions to documentation label Nov 9, 2023
@charliermarsh charliermarsh self-assigned this Nov 12, 2023
@charliermarsh
Copy link
Member

Adding this real quick.

charliermarsh added a commit that referenced this issue Nov 12, 2023
Enumerates all rules defined in each convention in the FAQ. These lists
mirror
[pydocstyle](https://www.pydocstyle.org/en/latest/error_codes.html#default-conventions).

Closes #8573.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants