summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Bruhin <me@the-compiler.org>2022-03-14 10:04:36 +0100
committerFlorian Bruhin <me@the-compiler.org>2022-03-14 10:04:36 +0100
commitdb720b145436000208212f5fc2fff60a3d09e849 (patch)
treee7d62664990c1824226bc8869ad6d47ad325a39c
parentb2a80886268994545eb0d8b871b49d4c85b7af93 (diff)
downloadqutebrowser-db720b145436000208212f5fc2fff60a3d09e849.tar.gz
qutebrowser-db720b145436000208212f5fc2fff60a3d09e849.zip
Let mypy check for blanket ignores
-rw-r--r--.mypy.ini1
-rw-r--r--scripts/dev/misc_checks.py5
2 files changed, 1 insertions, 5 deletions
diff --git a/.mypy.ini b/.mypy.ini
index 289f3eb87..501ab747e 100644
--- a/.mypy.ini
+++ b/.mypy.ini
@@ -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
diff --git a/scripts/dev/misc_checks.py b/scripts/dev/misc_checks.py
index 400a7990e..37c59d98f 100644
--- a/scripts/dev/misc_checks.py
+++ b/scripts/dev/misc_checks.py
@@ -199,11 +199,6 @@ def check_spelling(args: argparse.Namespace) -> Optional[bool]:
"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.",
),