Skip to content

Commit 14b00fb

Browse files
Avasamhoel-bagard
authored andcommitted
Enable some Ruff TC rules (flake8-type-checking) (python#13333)
1 parent c5b63ad commit 14b00fb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Diff for: pyproject.toml

+5
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,11 @@ select = [
5353
"W", # pycodestyle Warning
5454
# Only include flake8-annotations rules that are autofixable. Otherwise leave this to mypy+pyright
5555
"ANN2",
56+
# Don't include TC rules that create a TYPE_CHECKING block or stringifies annotations
57+
"TC004", # Move import `{qualified_name}` out of type-checking block. Import is used for more than type hinting.
58+
"TC005", # Found empty type-checking block
59+
# "TC008", # TODO: Enable when out of preview
60+
"TC010", # Invalid string member in `X | Y`-style union type
5661
# Most refurb rules are in preview and can be opinionated,
5762
# consider them individually as they come out of preview (last check: 0.8.4)
5863
"FURB105", # Unnecessary empty string passed to `print`

0 commit comments

Comments
 (0)