diff --git a/py/pyproject.toml b/py/pyproject.toml index 39b06b8fefd00..e53fd83056581 100644 --- a/py/pyproject.toml +++ b/py/pyproject.toml @@ -144,8 +144,33 @@ respect-gitignore = true target-version = "py39" [tool.ruff.lint] -extend-select = ["E4", "E7", "E9", "F", "I", "E501", "RUF022", "TID252"] +extend-select = ["E4", "E7", "E9", "F", "I", "E501", "RUF022", "TID252", "D"] fixable = ["ALL"] +extend-ignore = [ + "D103", # Missing docstring in public function + "D102", # Missing docstring in public method + "D100", # Missing docstring in public module + "D205", # 1 blank line required between summary line and description + "D107", # Missing docstring in `__init__` + "D101", # Missing docstring in public class + "D104", # Missing docstring in public package + "D209", # Multi-line docstring closing quotes should be on a separate line + "D202", # No blank lines allowed after function docstring (found 1) + "D105", # Missing docstring in magic method + "D415", # First line should end with a period, question mark, or exclamation point + "D212", # Multi-line docstring summary should start at the first line + "D200", # One-line docstring should fit on one line + "D411", # Missing blank line before section ("Example") + "D301", # Use `r\"\"\"` if any backslashes in a docstring + "D412", # No blank lines allowed between a section header and its content ("Example") + "D410", # Missing blank line after section ("Example") + "D419", # Docstring is empty + "D417", # Missing argument descriptions in the docstring for `__init__` + "D416", # Section name should end with a colon ("Returns") +] + +[tool.ruff.lint.pydocstyle] +convention = "google" [tool.ruff.format] docstring-code-format = true