2024-09-16 03:49:35 +02:00
|
|
|
[lint]
|
|
|
|
# https://docs.astral.sh/ruff/rules/
|
|
|
|
extend-select = [
|
|
|
|
"A", # flake8-builtins
|
2024-09-24 01:15:14 +02:00
|
|
|
"ARG", # flake8-unused-arguments
|
2024-09-16 03:49:35 +02:00
|
|
|
"BLE", # flake8-blind-except
|
|
|
|
"C4", # flake8-comprehensions
|
|
|
|
"COM", # flake8-commas
|
2024-09-24 01:15:14 +02:00
|
|
|
"CPY001",# flake8-copyright
|
2024-09-16 03:49:35 +02:00
|
|
|
"E", # pycodestyle
|
|
|
|
"E261", # spaces before inline comments
|
|
|
|
"ERA", # eradicate
|
|
|
|
"EXE", # flake8-executable
|
|
|
|
"FBT", # flake8-boolean-trap
|
|
|
|
"I", # isort
|
2024-09-24 01:15:14 +02:00
|
|
|
"INP", # flake8-no-pep420
|
2024-09-16 03:49:35 +02:00
|
|
|
"ISC", # flake8-implicit-str-concat
|
2024-09-24 01:15:14 +02:00
|
|
|
"N", # pep8-naming
|
2024-09-16 03:49:35 +02:00
|
|
|
"PL", # Pylint
|
2024-09-24 01:15:14 +02:00
|
|
|
"RET", # flake8-return
|
|
|
|
"RSE", # flake8-raise
|
|
|
|
"RUF", # Ruff-specific rules
|
2024-09-16 03:49:35 +02:00
|
|
|
"S", # flake8-bandit
|
2024-09-24 01:15:14 +02:00
|
|
|
"SIM", # flake8-simplify
|
|
|
|
"T20", # flake8-print
|
2024-09-16 03:49:35 +02:00
|
|
|
"UP", # pyupgrade
|
|
|
|
"W", # pycodestyle
|
|
|
|
"YTT", # flake8-2020
|
|
|
|
]
|
|
|
|
ignore = [
|
|
|
|
"E501", # line lengths
|
2024-09-17 23:31:08 +02:00
|
|
|
"FBT002", # booleans as function arguments
|
2024-09-16 03:49:35 +02:00
|
|
|
"S603", # https://github.com/astral-sh/ruff/issues/4045
|
|
|
|
"S607", # makes subprocess calls in test suite more portable
|
|
|
|
]
|
|
|
|
preview = true
|
|
|
|
explicit-preview-rules = true
|
|
|
|
|
|
|
|
[lint.per-file-ignores]
|
2024-09-24 00:43:37 +02:00
|
|
|
"pyacl/__init__.py" = ["PLC0414"] # allow explicit re-exports / avoid conflict with F401
|
2024-09-24 01:15:14 +02:00
|
|
|
"tests/*.py" = [
|
|
|
|
"INP001", # tests do not need to be part of a package
|
|
|
|
"S101", # allow "assert" in test suites
|
|
|
|
"T201", # lazy printing is ok in tests
|
|
|
|
]
|
2024-09-16 03:49:35 +02:00
|
|
|
|
|
|
|
[lint.pydocstyle]
|
|
|
|
convention = "pep257"
|
2024-09-17 23:31:08 +02:00
|
|
|
|
|
|
|
[lint.isort]
|
|
|
|
force-wrap-aliases = true
|