-
Notifications
You must be signed in to change notification settings - Fork 94
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
refactor: replace darglint
with pydoclint
#749
base: main
Are you sure you want to change the base?
Changes from 15 commits
a21358f
f5c328c
d74bf35
5c257bb
7b71b80
5b33dec
674161b
de85464
e7308d4
7f04b43
687fba8
4d4b089
16f4dc3
e671998
95e3681
60c5cd4
d28ae27
b30d6bf
455b60d
91c4223
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,9 +11,14 @@ ignore = D205,D212,D415,E203,W503 | |
# https://black.readthedocs.io/en/stable/the_black_code_style.html#line-length | ||
max-line-length = 88 | ||
|
||
# This is for pydocstyle - to allow docstrings in __init__ functions | ||
# This rule was used for easier migration from darglint | ||
# TODO: remove this rule | ||
allow-init-docstring=True | ||
|
||
per-file-ignores = | ||
# For tests, disable type annotation and docstring linting. | ||
tests/*: ANN D DAR | ||
tests/*: ANN D DOC | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Would you consider adding an
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I can subdue these errors with this However, I don't know if it is wise to ignore the linter errors. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You might need to remove There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. that doesn't help:
What version of Python do you have? I am using Python 3.11, the CI/CD uses Python v3.8 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm using 3.11, so not sure what problem you're having. The DAR errors shouldn't be showing up at all, given that the flake8 config no longer includes them in the
|
||
# Select other tools to enable. | ||
|
||
|
@@ -25,7 +30,7 @@ per-file-ignores = | |
|
||
# D enables docstrings warnings from pydocstyle. | ||
|
||
# DAR enables docstring style linting via darglint. | ||
# DOC enables docstring style linting via pydoclint. | ||
|
||
# F are errors reported by pyflakes, a tool which parses source files | ||
# and finds invalid Python code. | ||
|
@@ -35,4 +40,4 @@ per-file-ignores = | |
|
||
# W and E are warnings and errors reported by pycodestyle, which checks | ||
# your Python code against some of the style conventions in PEP 8. | ||
select = ABS,ANN,DAR,BLK,D,E,F,I,W | ||
select = ABS,ANN,DOC,BLK,D,E,F,I,W |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to remove this rule within the scope of this PR ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would make the diff gigantic and much harder to review.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmmm