@@ -67,7 +67,6 @@ select = [
67
67
" RSE" , # flake8-raise
68
68
" RUF" , # Ruff-specific and unused-noqa
69
69
" S" , # flake8-bandit
70
- " SIM" , # flake8-simplify
71
70
" SLOT" , # flake8-slots
72
71
" TRY" , # tryceratops
73
72
" UP" , # pyupgrade
@@ -78,11 +77,6 @@ select = [
78
77
" W" , # pycodestyle Warning
79
78
# Only include flake8-annotations rules that are autofixable. Otherwise leave this to mypy+pyright
80
79
" ANN2" ,
81
- # Don't include TC rules that create a TYPE_CHECKING block or stringifies annotations
82
- " TC004" , # Move import `{qualified_name}` out of type-checking block. Import is used for more than type hinting.
83
- " TC005" , # Found empty type-checking block
84
- # "TC008", # TODO: Enable when out of preview
85
- " TC010" , # Invalid string member in `X | Y`-style union type
86
80
# Most refurb rules are in preview and can be opinionated,
87
81
# consider them individually as they come out of preview (last check: 0.8.4)
88
82
" FURB105" , # Unnecessary empty string passed to `print`
@@ -117,6 +111,26 @@ select = [
117
111
# "PYI061", # TODO: Enable when out of preview
118
112
" PYI062" , # Duplicate literal member `{}`
119
113
" PYI064" , # `Final[Literal[{literal}]]` can be replaced with a bare Final
114
+ # flake8-simplify, excluding rules that can reduce performance or readability due to long line formatting
115
+ " SIM101" , # Multiple `isinstance` calls for `{name}`, merge into a single call
116
+ " SIM103" , # Return the condition `{condition}` directly
117
+ " SIM107" , # Don't use return in `try-except` and `finally`
118
+ " SIM109" , # Use `{replacement}` instead of multiple equality comparisons
119
+ " SIM112" , # Use capitalized environment variable `{expected}` instead of `{actual}`
120
+ " SIM113" , # Use `enumerate()` for index variable `{index}` in `for` loop
121
+ " SIM114" , # Combine `if` branches using logical `or` operator
122
+ " SIM115" , # Use a context manager for opening files
123
+ " SIM118" , # Use key `{operator}` dict instead of key `{operator} dict.keys()`
124
+ " SIM2" , # flake8-simplify conditional ordering rules
125
+ " SIM300" , # Yoda condition detected
126
+ " SIM401" , # Use `{contents}` instead of an if block
127
+ " SIM910" , # Use `{expected}` instead of `{actual}` (dict-get-with-none-default)
128
+ " SIM911" , # Use `{expected}` instead of `{actual}` (zip-dict-keys-and-values)
129
+ # Don't include TC rules that create a TYPE_CHECKING block or stringifies annotations
130
+ " TC004" , # Move import `{qualified_name}` out of type-checking block. Import is used for more than type hinting.
131
+ " TC005" , # Found empty type-checking block
132
+ # "TC008", # TODO: Enable when out of preview
133
+ " TC010" , # Invalid string member in `X | Y`-style union type
120
134
]
121
135
extend-safe-fixes = [
122
136
" UP036" , # Remove unnecessary `sys.version_info` blocks
0 commit comments