@@ -26,21 +26,20 @@ exclude = [
2626 " src/plugins/analysis/input_vectors/internal" , # FixMe: runs inside a bionic docker container with python 3.6
2727]
2828line-length = 120
29- target-version = " py38 "
29+ target-version = " py310 "
3030
3131[tool .ruff .lint ]
3232select = [
33- " F" , # Pyflakes
34- " E" , # pycodestyle Error
35- " W" , # pycodestyle Warning
36- " C90" , # mccabe
37- " I" , # isort
38- " N" , # pep8-naming
39- " UP" , # pyupgrade
33+ # see https://docs.astral.sh/ruff/rules
34+ " ERA" , # eradicate
35+ " YTT" , # flake8-2020
36+ " ANN" , # flake8-annotations
37+ " S" , # flake8-bandit (security)
4038 " B" , # flake8-bugbear
4139 " A" , # flake8-builtins
4240 " C4" , # flake8-comprehensions
4341 " EXE" , # flake8-executable
42+ " FIX" , # flake8-fixme
4443 " FA" , # flake8-future-annotations
4544 " ISC" , # flake8-implicit-str-concat
4645 " PIE" , # flake8-pie
@@ -49,26 +48,36 @@ select = [
4948 " Q" , # flake8-quotes
5049 " RET" , # flake8-return
5150 " SIM" , # flake8-simplify
52- " TCH " , # flake8-type-checking
51+ " TC " , # flake8-type-checking
5352 " ARG" , # flake8-unused-arguments
5453 " PTH" , # flake8-use-pathlib
55- " ERA" , # eradicate
56- " PL" , # Pylint
54+ " I" , # isort
55+ " C90" , # mccabe
56+ " N" , # pep8-naming
5757 " PERF" , # Perflint
58+ " E" , # pycodestyle Error
59+ " W" , # pycodestyle Warning
60+ " F" , # Pyflakes
61+ " PLC" , # Pylint
62+ " PLE" , # Pylint Error
63+ " PLR" , # Pylint Refactor
64+ " PLW" , # Pylint Warning
65+ " UP" , # pyupgrade
66+ " FURB" , # refurb (FURB code optimzations)
5867 " RUF" , # Ruff-specific rules
5968]
6069ignore = [
6170 " A003" ,
71+ " ANN204" , # type annotation for special methods (e.g. __init__)
6272 " PERF203" ,
6373 " PERF401" ,
6474 " RUF001" ,
6575 " RUF002" ,
6676 " RUF003" ,
6777 " RUF015" ,
68- # pydantic only supports these from python>=3.9
69- " UP006" ,
70- " UP007" ,
71- # rules may cause conflicts when used with the formatter
78+ " FIX001" , # line contains fixme
79+ " FIX004" , # line contains hack
80+ # rules may cause conflicts when used with the formatter:
7281 " ISC001" ,
7382 " Q001" ,
7483]
0 commit comments