2024-05-12 10:16:47 +03:00
|
|
|
[tool.ruff]
|
|
|
|
|
|
|
|
exclude = [
|
|
|
|
# Ruff recommended:
|
|
|
|
".bzr",
|
|
|
|
".direnv",
|
|
|
|
".eggs",
|
|
|
|
".git",
|
|
|
|
".git-rewrite",
|
|
|
|
".hg",
|
|
|
|
".ipynb_checkpoints",
|
|
|
|
".mypy_cache",
|
|
|
|
".nox",
|
|
|
|
".pants.d",
|
|
|
|
".pyenv",
|
|
|
|
".pytest_cache",
|
|
|
|
".pytype",
|
|
|
|
".ruff_cache",
|
|
|
|
".svn",
|
|
|
|
".tox",
|
|
|
|
".venv",
|
|
|
|
".vscode",
|
|
|
|
"__pypackages__",
|
|
|
|
"_build",
|
|
|
|
"buck-out",
|
|
|
|
"build",
|
|
|
|
"dist",
|
|
|
|
"node_modules",
|
|
|
|
"site-packages",
|
|
|
|
"venv",
|
|
|
|
|
|
|
|
# Project specific:
|
|
|
|
"docs/samples",
|
|
|
|
"e2e-tests/",
|
|
|
|
"*/tests/*"
|
|
|
|
]
|
|
|
|
|
|
|
|
# Same as Black.
|
|
|
|
line-length = 88
|
|
|
|
indent-width = 4
|
|
|
|
|
|
|
|
[tool.ruff.lint]
|
|
|
|
select = ["E", "F", "I", "D", "N", "W",
|
|
|
|
# To be added:
|
|
|
|
# "SIM", "UP", "ANN", "B"
|
|
|
|
]
|
2024-05-12 15:05:41 +03:00
|
|
|
ignore = ["E203", "D100", "D202", "D407", "ANN101", "ANN102", "ANN204"]
|
2024-05-12 10:16:47 +03:00
|
|
|
|
|
|
|
fixable = ["ALL"]
|
|
|
|
|
2024-05-12 13:12:55 +03:00
|
|
|
# Allow unused variables when underscore-prefixed.
|
|
|
|
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
|
2024-05-12 10:16:47 +03:00
|
|
|
|
|
|
|
[tool.ruff.format]
|
|
|
|
# Like Black, use double quotes for strings.
|
|
|
|
quote-style = "double"
|
|
|
|
|
|
|
|
# Like Black, indent with spaces, rather than tabs.
|
|
|
|
indent-style = "space"
|
|
|
|
|
|
|
|
# Like Black, respect magic trailing commas.
|
|
|
|
skip-magic-trailing-comma = false
|
|
|
|
|
|
|
|
# Like Black, automatically detect the appropriate line ending.
|
|
|
|
line-ending = "auto"
|
|
|
|
|
|
|
|
[tool.ruff.lint.pydocstyle]
|
|
|
|
convention = "numpy"
|