-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Add option for strict-error-codes
#13541
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
Diff from mypy_primer, showing the effect of this PR on open source code: cki-lib (https://gitlab.com/cki-project/cki-lib)
+ cki_lib/yaml.py:69: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-call]" instead)
python-sop (https://gitlab.com/dkg/python-sop)
+ sop/__init__.py:104: error: "type: ignore" comment without error code (consider "type: ignore[import]" instead)
python-chess (https://github.com/niklasf/python-chess)
+ chess/__init__.py:48: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead)
+ chess/__init__.py:3860: error: "type: ignore" comment without error code (consider "type: ignore[union-attr]" instead)
+ chess/__init__.py:3867: error: "type: ignore" comment without error code (consider "type: ignore[union-attr]" instead)
+ chess/__init__.py:4026: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead)
+ chess/svg.py:430: error: "type: ignore" comment without error code (consider "type: ignore[union-attr]" instead)
+ chess/svg.py:432: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead)
+ chess/syzygy.py:1027: error: "type: ignore" comment without error code (consider "type: ignore[arg-type, no-any-return]" instead)
+ chess/syzygy.py:1030: error: "type: ignore" comment without error code (consider "type: ignore[arg-type, no-any-return]" instead)
+ chess/syzygy.py:1033: error: "type: ignore" comment without error code (consider "type: ignore[arg-type, no-any-return]" instead)
+ chess/syzygy.py:1036: error: "type: ignore" comment without error code (consider "type: ignore[arg-type, no-any-return]" instead)
+ chess/polyglot.py:352: error: "type: ignore" comment without error code (consider "type: ignore[union-attr]" instead)
+ chess/polyglot.py:419: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead)
+ chess/engine.py:50: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead)
+ chess/engine.py:103: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined, no-any-return]" instead)
+ chess/engine.py:162: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead)
+ chess/engine.py:166: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead)
+ chess/engine.py:270: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead)
+ chess/engine.py:378: error: "type: ignore" comment without error code (consider "type: ignore[assignment, misc]" instead)
+ chess/engine.py:986: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead)
+ chess/engine.py:1013: error: "type: ignore" comment without error code (consider "type: ignore[union-attr]" instead)
+ chess/engine.py:1016: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead)
+ chess/engine.py:1220: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead)
+ chess/engine.py:1757: error: "type: ignore" comment without error code (consider "type: ignore[literal-required]" instead)
+ chess/engine.py:1775: error: "type: ignore" comment without error code (consider "type: ignore[literal-required]" instead)
+ chess/engine.py:1895: error: "type: ignore" comment without error code (consider "type: ignore[index, operator]" instead)
+ chess/engine.py:1898: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead)
+ chess/pgn.py:38: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead)
+ chess/pgn.py:302: error: "type: ignore" comment without error code (consider "type: ignore[index]" instead)
+ chess/pgn.py:480: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead)
+ chess/pgn.py:484: error: "type: ignore" comment without error code (consider "type: ignore[union-attr]" instead)
+ chess/pgn.py:793: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-call]" instead)
+ chess/pgn.py:805: error: "type: ignore" comment without error code (consider "type: ignore[union-attr]" instead)
+ chess/pgn.py:808: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead)
porcupine (https://github.com/Akuli/porcupine)
+ porcupine/menubar.py:354: error: "type: ignore" comment without error code (consider "type: ignore[assignment, misc]" instead) [ignore-without-code]
+ porcupine/pluginloader.py:184: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ porcupine/plugins/pastebin.py:187: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ porcupine/plugins/find.py:52: error: "type: ignore" comment without error code (consider "type: ignore[misc, return-value]" instead) [ignore-without-code]
+ porcupine/plugins/directory_tree.py:412: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ porcupine/plugins/langserver.py:697: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ porcupine/plugins/run/no_terminal.py:118: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
psycopg (https://github.com/psycopg/psycopg)
+ psycopg/psycopg/pq/_pq_ctypes.pyi:101: error: "type: ignore" comment without error code (consider "type: ignore[valid-type]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/_pq_ctypes.pyi:109: error: "type: ignore" comment without error code (consider "type: ignore[type-var]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/pq_ctypes.py:84: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/pq_ctypes.py:826: error: "type: ignore" comment without error code (consider "type: ignore[call-arg]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/pq_ctypes.py:828: error: "type: ignore" comment without error code (consider "type: ignore[operator]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/pq_ctypes.py:867: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/pq_ctypes.py:979: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/pq_ctypes.py:993: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/__init__.py:75: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined, no-redef]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/__init__.py:82: error: "type: ignore" comment without error code (consider "type: ignore[import, no-redef]" instead) [ignore-without-code]
+ psycopg/psycopg/_cmodule.py:19: error: "type: ignore" comment without error code (consider "type: ignore[import, no-redef]" instead) [ignore-without-code]
+ psycopg/psycopg/_cmodule.py:20: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ psycopg/psycopg/_cmodule.py:22: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ psycopg/psycopg/_transform.py:151: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ psycopg/psycopg/cursor.py:781: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ psycopg/psycopg/cursor_async.py:143: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ psycopg/psycopg/types/range.py:199: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ psycopg/psycopg/types/range.py:208: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ psycopg/psycopg/types/range.py:262: error: "type: ignore" comment without error code (consider "type: ignore[return-value]" instead) [ignore-without-code]
+ psycopg/psycopg/types/composite.py:244: error: "type: ignore" comment without error code (consider "type: ignore[misc, no-redef]" instead) [ignore-without-code]
+ psycopg/psycopg/types/array.py:124: error: "type: ignore" comment without error code (consider "type: ignore[return-value]" instead) [ignore-without-code]
+ psycopg/psycopg/types/array.py:226: error: "type: ignore" comment without error code (consider "type: ignore[return-value]" instead) [ignore-without-code]
+ psycopg/psycopg/types/array.py:284: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ psycopg/psycopg/types/multirange.py:105: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ psycopg/psycopg/types/multirange.py:113: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ psycopg/psycopg/types/multirange.py:157: error: "type: ignore" comment without error code (consider "type: ignore[return-value]" instead) [ignore-without-code]
+ tests/test_server_cursor_async.py:23: error: "type: ignore" comment without error code (consider "type: ignore[comparison-overlap]" instead) [ignore-without-code]
+ tests/test_server_cursor_async.py:29: error: "type: ignore" comment without error code (consider "type: ignore[comparison-overlap]" instead) [ignore-without-code]
+ tests/test_server_cursor.py:20: error: "type: ignore" comment without error code (consider "type: ignore[comparison-overlap]" instead) [ignore-without-code]
+ tests/test_server_cursor.py:24: error: "type: ignore" comment without error code (consider "type: ignore[comparison-overlap]" instead) [ignore-without-code]
+ tests/test_module.py:20: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ tests/fix_pq.py:13: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ tests/adapters_example.py:51: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ psycopg/psycopg/types/shapely.py:46: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ psycopg/psycopg/types/shapely.py:51: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ psycopg/psycopg/pq/_debug.py:106: error: "type: ignore" comment without error code (consider "type: ignore[return-value]" instead) [ignore-without-code]
+ tests/types/test_enum.py:351: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
artigraph (https://github.com/artigraph/artigraph)
+ src/arti/internal/__init__.py:23: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/internal/patches.py:13: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/internal/utils.py:36: error: "type: ignore" comment without error code (consider "type: ignore[arg-type, return-value]" instead) [ignore-without-code]
+ src/arti/internal/utils.py:331: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ src/arti/internal/utils.py:387: error: "type: ignore" comment without error code (consider "type: ignore[arg-type, misc]" instead) [ignore-without-code]
+ src/arti/internal/type_hints.py:89: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/internal/type_hints.py:140: error: "type: ignore" comment without error code (consider "type: ignore[valid-type]" instead) [ignore-without-code]
+ src/arti/internal/type_hints.py:141: error: "type: ignore" comment without error code (consider "type: ignore[index]" instead) [ignore-without-code]
+ src/arti/internal/type_hints.py:148: error: "type: ignore" comment without error code (consider "type: ignore[valid-type]" instead) [ignore-without-code]
+ src/arti/internal/type_hints.py:253: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/internal/dispatch.py:34: error: "type: ignore" comment without error code (consider "type: ignore[misc, no-any-return]" instead) [ignore-without-code]
+ src/arti/internal/dispatch.py:86: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ src/arti/types/__init__.py:219: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined, no-any-return]" instead) [ignore-without-code]
+ src/arti/types/python.py:65: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/types/python.py:183: error: "type: ignore" comment without error code (consider "type: ignore[index]" instead) [ignore-without-code]
+ src/arti/types/python.py:246: error: "type: ignore" comment without error code (consider "type: ignore[operator]" instead) [ignore-without-code]
+ src/arti/storage/__init__.py:22: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/storage/__init__.py:24: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/storage/__init__.py:87: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ src/arti/io/__init__.py:52: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ src/arti/producers/__init__.py:274: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/producers/__init__.py:308: error: "type: ignore" comment without error code (consider "type: ignore[override]" instead) [ignore-without-code]
+ src/arti/graphs/__init__.py:66: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ src/arti/graphs/__init__.py:105: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ tests/arti/dummies.py:125: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/dummies.py:133: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/dummies.py:142: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ src/arti/types/pydantic.py:21: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ src/arti/types/pyarrow.py:26: error: "type: ignore" comment without error code (consider "type: ignore[no-any-return]" instead) [ignore-without-code]
+ src/arti/types/pyarrow.py:239: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/types/pyarrow.py:304: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ src/arti/types/pyarrow.py:353: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ docs/examples/spend/demo.py:39: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ docs/examples/spend/demo.py:60: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ docs/examples/spend/demo.py:78: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ tests/arti/test_fingerprints.py:59: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ tests/arti/views/test_views.py:26: error: "type: ignore" comment without error code (consider "type: ignore[misc, valid-type]" instead) [ignore-without-code]
+ tests/arti/views/test_views.py:29: error: "type: ignore" comment without error code (consider "type: ignore[misc, valid-type]" instead) [ignore-without-code]
+ tests/arti/views/test_views.py:33: error: "type: ignore" comment without error code (consider "type: ignore[misc, valid-type]" instead) [ignore-without-code]
+ tests/arti/views/test_views.py:43: error: "type: ignore" comment without error code (consider "type: ignore[misc, valid-type]" instead) [ignore-without-code]
+ tests/arti/views/test_views.py:54: error: "type: ignore" comment without error code (consider "type: ignore[misc, valid-type]" instead) [ignore-without-code]
+ tests/arti/types/test_python_adapters.py:189: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ tests/arti/storage/test_storage.py:49: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ tests/arti/storage/test_storage.py:77: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/storage/test_storage.py:84: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/storage/test_storage.py:96: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ tests/arti/storage/test_local_storage.py:59: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:34: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:58: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:77: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:89: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:90: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:104: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:118: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:129: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:143: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:155: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:170: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:181: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:191: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:253: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:269: error: "type: ignore" comment without error code (consider "type: ignore[override, type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:376: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:383: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:388: error: "type: ignore" comment without error code (consider "type: ignore[type-arg, valid-type]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:398: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:419: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:421: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:429: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:431: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:443: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:448: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:453: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:457: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-def]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:462: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:471: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:475: error: "type: ignore" comment without error code (consider "type: ignore[assignment, no-untyped-def, type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:480: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:484: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-def, type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:489: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:493: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-def, type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:498: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:502: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-def, type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:507: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:511: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-def, type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:516: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:520: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:527: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:528: error: "type: ignore" comment without error code (consider "type: ignore[assignment]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:531: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-def, type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:538: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:542: error: "type: ignore" comment without error code (consider "type: ignore[no-untyped-def, type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:550: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:554: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:562: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:566: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:571: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:583: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:593: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:594: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:602: error: "type: ignore" comment without error code (consider "type: ignore[no-redef]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:604: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:627: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ tests/arti/producers/test_producer.py:631: error: "type: ignore" comment without error code (consider "type: ignore[arg-type]" instead) [ignore-without-code]
+ tests/arti/internal/test_utils.py:43: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined, no-any-return]" instead) [ignore-without-code]
+ tests/arti/internal/test_utils.py:65: error: "type: ignore" comment without error code (consider "type: ignore[index]" instead) [ignore-without-code]
+ tests/arti/internal/test_utils.py:67: error: "type: ignore" comment without error code (consider "type: ignore[index]" instead) [ignore-without-code]
+ tests/arti/internal/test_utils.py:69: error: "type: ignore" comment without error code (consider "type: ignore[attr-defined]" instead) [ignore-without-code]
+ tests/arti/internal/test_utils.py:77: error: "type: ignore" comment without error code (consider "type: ignore[comparison-overlap]" instead) [ignore-without-code]
+ tests/arti/internal/test_utils.py:78: error: "type: ignore" comment without error code (consider "type: ignore[comparison-overlap]" instead) [ignore-without-code]
+ tests/arti/internal/test_utils.py:292: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ tests/arti/internal/test_utils.py:294: error: "type: ignore" comment without error code (consider "type: ignore[misc]" instead) [ignore-without-code]
+ tests/arti/internal/test_type_hints.py:20: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/internal/test_type_hints.py:29: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/internal/test_type_hints.py:115: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/internal/test_type_hints.py:116: error: "type: ignore" comment without error code (consider "type: ignore[type-arg]" instead) [ignore-without-code]
+ tests/arti/internal/test_type_hints.py:149: error: "type: ignore" comment without error code (con
... (truncated 157 lines) ... |
Thanks for working on this! I'm in favour of showing error codes by default (#13542), but I'm against enabling ignore-without-code as part of See #11633 (comment) for what I think should fall under |
Makes sense. Do you think there is a value in adding just a |
I know Jukka is hesitant to add more command line flags, e.g. see #11633 (comment) I think if we end up with an error code that we want enabled in |
Part of the effort to nudge users into using specific type ignores. See #13541 This PR enables `show-error-codes` by default. Without knowing the code, users will always choose to use a bare `type: ignore` instead.
Description
This PR adds a
--strict-error-codes
option which will enable theignore-without-code
error code in strict mode. Additional error codes may be added in the future. However, I don't believe any of the other once currently disabled by default are suitable (redundant-expr
,truthy-bool
,unused-awaitable
).Rational
Since the release,
ignore-without-code
has been added to an increasing number of repos by default and even mypy itself recently #13534. I believe it's beneficial for everyone if we try to nudge users into providing more specific type ignores instead of the bare one.