Let mypy check for blanket ignores

This commit is contained in:
Florian Bruhin 2022-03-14 10:04:36 +01:00
parent b2a8088626
commit db720b1454
2 changed files with 1 additions and 5 deletions

View File

@ -20,6 +20,7 @@ strict_equality = True
### Other strictness flags
warn_unreachable = True
disallow_any_unimported = True
enable_error_code = ignore-without-code
### Output
show_error_codes = True

View File

@ -198,11 +198,6 @@ def check_spelling(args: argparse.Namespace) -> Optional[bool]:
re.compile(r'(?i)# noqa(?!: )'),
"Don't use a blanket 'noqa', use something like 'noqa: X123' instead.",
),
(
re.compile(r'# type: ignore[^\[]'),
("Don't use a blanket 'type: ignore', use something like "
"'type: ignore[error-code]' instead."),
),
(
re.compile(r'# type: (?!ignore(\[|$))'),
"Don't use type comments, use type annotations instead.",