-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
move linting rules from pyproject.toml to ruff.toml (#6350)
Co-authored-by: Igor Radovanovic <74266147+IgorWounds@users.noreply.github.com>
- Loading branch information
1 parent
4105ec4
commit 9dce734
Showing
2 changed files
with
51 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
line-length = 122 | ||
target-version = "py38" | ||
# This is an introductory addition of ruff. We should look to adding: | ||
# D: pydocstyle, PD: pandas-vet | ||
# All options here: https://github.com/charliermarsh/ruff#supported-rules | ||
select = [ | ||
"E", | ||
"W", | ||
"F", | ||
"Q", | ||
"S", | ||
"UP", | ||
"I", | ||
"PLC", | ||
"PLE", | ||
"PLR", | ||
"PLW", | ||
"SIM", | ||
"T20", | ||
] | ||
# These ignores should be seen as temporary solutions to problems that will NEED fixed | ||
ignore = ["PLR2004", "PLR0913", "PLR0915"] | ||
exclude = [ | ||
"^openbb_platform/platform/core/openbb_core/app/static/package/.*", | ||
"^openbb_platform/openbb/package/.*", | ||
] | ||
|
||
[per-file-ignores] | ||
"**/tests/*" = ["S101"] | ||
"*init*.py" = ["F401"] | ||
"website/*" = ["T201"] | ||
"*integration/*" = ["S101"] | ||
|
||
[lint.isort] | ||
combine-as-imports = true | ||
force-wrap-aliases = true | ||
|
||
[lint.pylint] | ||
max-args = 8 | ||
max-branches = 25 | ||
max-returns = 9 | ||
max-statements = 30 | ||
|
||
[lint.pydocstyle] | ||
convention = "numpy" | ||
|
||
[lint.flake8-import-conventions.aliases] | ||
"matplotlib.pyplot" = "plt" | ||
numpy = "np" | ||
pandas = "pd" | ||
seaborn = "sns" |