-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Add warn-unreachable to strict mode #17944
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This is useful check for dead code analysis
Diff from mypy_primer, showing the effect of this PR on open source code: websockets (https://github.com/aaugustin/websockets)
+ src/websockets/legacy/protocol.py:320: error: Statement is unreachable [unreachable]
+ src/websockets/legacy/protocol.py:1076: error: Statement is unreachable [unreachable]
+ src/websockets/legacy/server.py:365: error: Statement is unreachable [unreachable]
+ src/websockets/legacy/server.py:590: error: Statement is unreachable [unreachable]
psycopg (https://github.com/psycopg/psycopg)
+ psycopg/psycopg/pq/pq_ctypes.py:133: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/pq/pq_ctypes.py:861: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/pq/pq_ctypes.py:1039: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/pq/pq_ctypes.py:1071: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/pq/__init__.py:96: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/_conninfo_attempts_async.py:97: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/sql.py:89: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/sql.py:97: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/sql.py:151: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/_queries.py:362: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/_queries.py:409: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/connection_async.py:40: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/connection_async.py:57: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/connection_async.py:307: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/connection_async.py:430: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/connection_async.py:441: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/connection_async.py:452: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/connection_async.py:463: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/types/uuid.py:42: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/types/net.py:48: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/types/net.py:182: error: Statement is unreachable [unreachable]
+ psycopg/psycopg/types/multirange.py:340: error: Statement is unreachable [unreachable]
+ tests/test_psycopg_dbapi20.py:144: error: Statement is unreachable [unreachable]
+ tests/test_cursor_async.py:42: error: Statement is unreachable [unreachable]
+ tests/test_cursor.py:43: error: Statement is unreachable [unreachable]
+ tests/pq/test_pgconn.py:42: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:138: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:504: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:505: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:552: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:576: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:579: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:594: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:609: error: Statement is unreachable [unreachable]
+ tests/test_transaction_async.py:614: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:138: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:497: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:498: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:545: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:569: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:572: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:587: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:602: error: Statement is unreachable [unreachable]
+ tests/test_transaction.py:607: error: Statement is unreachable [unreachable]
+ tests/test_pipeline_async.py:44: error: Statement is unreachable [unreachable]
+ tests/test_pipeline_async.py:45: error: Statement is unreachable [unreachable]
+ tests/test_pipeline_async.py:464: error: Statement is unreachable [unreachable]
+ tests/test_pipeline_async.py:467: error: Statement is unreachable [unreachable]
+ tests/test_pipeline.py:47: error: Statement is unreachable [unreachable]
+ tests/test_pipeline.py:48: error: Statement is unreachable [unreachable]
+ tests/test_pipeline.py:465: error: Statement is unreachable [unreachable]
+ tests/test_pipeline.py:468: error: Statement is unreachable [unreachable]
+ tests/test_cursor_server_async.py:104: error: Statement is unreachable [unreachable]
+ tests/test_cursor_server.py:101: error: Statement is unreachable [unreachable]
+ tests/test_cursor_raw_async.py:47: error: Statement is unreachable [unreachable]
+ tests/test_cursor_raw.py:50: error: Statement is unreachable [unreachable]
+ tests/test_copy_async.py:688: error: Statement is unreachable [unreachable]
+ tests/test_copy.py:674: error: Statement is unreachable [unreachable]
+ tests/test_connection_async.py:363: error: Statement is unreachable [unreachable]
+ tests/test_connection_async.py:389: error: Subclass of "str" and "bool" cannot exist: "bool" is final [unreachable]
+ tests/test_connection_async.py:390: error: Statement is unreachable [unreachable]
+ tests/test_connection_async.py:455: error: Statement is unreachable [unreachable]
+ tests/test_connection.py:366: error: Statement is unreachable [unreachable]
+ tests/test_connection.py:392: error: Subclass of "str" and "bool" cannot exist: "bool" is final [unreachable]
+ tests/test_connection.py:393: error: Statement is unreachable [unreachable]
+ tests/test_connection.py:458: error: Statement is unreachable [unreachable]
+ tests/pool/test_sched_async.py:153: error: Statement is unreachable [unreachable]
+ psycopg_pool/psycopg_pool/pool_async.py:107: error: Statement is unreachable [unreachable]
+ psycopg_pool/psycopg_pool/pool_async.py:126: error: Statement is unreachable [unreachable]
+ psycopg_pool/psycopg_pool/pool_async.py:583: error: Statement is unreachable [unreachable]
+ psycopg_pool/psycopg_pool/pool_async.py:602: error: Statement is unreachable [unreachable]
+ psycopg_pool/psycopg_pool/pool_async.py:782: error: Statement is unreachable [unreachable]
+ psycopg_pool/psycopg_pool/pool.py:731: error: Statement is unreachable [unreachable]
+ tests/crdb/test_connection_async.py:26: error: Statement is unreachable [unreachable]
+ tests/test_cursor_common_async.py:494: error: Statement is unreachable [unreachable]
+ tests/test_cursor_common.py:490: error: Statement is unreachable [unreachable]
+ tests/test_cursor_client_async.py:56: error: Statement is unreachable [unreachable]
+ tests/test_cursor_client.py:57: error: Statement is unreachable [unreachable]
+ tests/types/test_enum.py:86: error: Statement is unreachable [unreachable]
+ tests/pool/test_pool_common_async.py:71: error: Statement is unreachable [unreachable]
bidict (https://github.com/jab/bidict)
+ bidict/_base.py: note: In member "__or__" of class "BidictBase":
+ bidict/_base.py:501:13: error: Statement is unreachable [unreachable]
+ bidict/_base.py: note: In member "__ror__" of class "BidictBase":
+ bidict/_base.py:509:13: error: Statement is unreachable [unreachable]
boostedblob (https://github.com/hauntsaninja/boostedblob)
+ boostedblob/azure_auth.py:107: error: Statement is unreachable [unreachable]
pylint (https://github.com/pycqa/pylint)
+ pylint/lint/expand_modules.py:113: error: Statement is unreachable [unreachable]
+ pylint/pyreverse/dot_printer.py:159: error: Statement is unreachable [unreachable]
+ pylint/lint/message_state_handler.py:358: error: Right operand of "and" is never evaluated [unreachable]
+ pylint/lint/message_state_handler.py:359: error: Statement is unreachable [unreachable]
+ pylint/checkers/base_checker.py:174: error: Right operand of "and" is never evaluated [unreachable]
+ pylint/checkers/base_checker.py:175: error: Statement is unreachable [unreachable]
+ pylint/checkers/base_checker.py:196: error: Statement is unreachable [unreachable]
+ pylint/checkers/symilar.py:832: error: Statement is unreachable [unreachable]
+ pylint/lint/run.py:197: error: Statement is unreachable [unreachable]
+ pylint/lint/run.py:206: error: Statement is unreachable [unreachable]
+ pylint/checkers/logging.py:356: error: Subclass of "str" and "int" cannot exist: would have incompatible method signatures [unreachable]
+ pylint/checkers/imports.py:594: error: Right operand of "and" is never evaluated [unreachable]
+ pylint/checkers/imports.py:603: error: Statement is unreachable [unreachable]
+ pylint/checkers/imports.py:631: error: Statement is unreachable [unreachable]
+ pylint/checkers/imports.py:660: error: Statement is unreachable [unreachable]
+ pylint/checkers/imports.py:707: error: Statement is unreachable [unreachable]
sphinx (https://github.com/sphinx-doc/sphinx)
+ sphinx/util/requests.py: note: In member "request" of class "_Session":
+ sphinx/util/requests.py:72:13: error: Statement is unreachable [unreachable]
+ sphinx/pycode/parser.py: note: In member "visit_Expr" of class "VariableCommentPicker":
+ sphinx/pycode/parser.py:435:25: error: Statement is unreachable [unreachable]
+ sphinx/util/typing.py: note: In function "restify":
+ sphinx/util/typing.py:304:13: error: Statement is unreachable [unreachable]
+ sphinx/util/typing.py:328:27: error: Subclass of "type" and "<typing special form>" cannot exist: "_SpecialForm" is final [unreachable]
+ sphinx/util/typing.py:331:17: error: Statement is unreachable [unreachable]
+ sphinx/util/typing.py: note: In function "stringify_annotation":
+ sphinx/util/typing.py:568:13: error: Statement is unreachable [unreachable]
+ sphinx/util/nodes.py: note: In function "apply_source_workaround":
+ sphinx/util/nodes.py:151:9: error: Statement is unreachable [unreachable]
+ sphinx/util/nodes.py:158:9: error: Statement is unreachable [unreachable]
+ sphinx/util/nodes.py:177:9: error: Statement is unreachable [unreachable]
+ sphinx/util/nodes.py:186:9: error: Statement is unreachable [unreachable]
+ sphinx/util/nodes.py: note: In function "_deepcopy":
+ sphinx/util/nodes.py:741:17: error: Statement is unreachable [unreachable]
+ sphinx/util/nodes.py:743:17: error: Statement is unreachable [unreachable]
+ sphinx/util/inspect.py: note: In function "stringify_signature":
+ sphinx/util/inspect.py:774:13: error: Statement is unreachable [unreachable]
+ sphinx/domains/python/_annotations.py: note: In function "_parse_arglist":
+ sphinx/domains/python/_annotations.py:438:13: error: Statement is unreachable [unreachable]
+ sphinx/directives/__init__.py: note: In function "optional_int":
+ sphinx/directives/__init__.py:34:9: error: Statement is unreachable [unreachable]
+ sphinx/directives/__init__.py:336:13: error: Statement is unreachable [unreachable]
+ sphinx/domains/python/_object.py: note: In member "handle_signature" of class "PyObject":
+ sphinx/domains/python/_object.py:263:21: error: Subclass of "list[Node]" and "str" cannot exist: would have incompatible method signatures [unreachable]
+ sphinx/highlighting.py: note: In member "highlight_block" of class "PygmentsBridge":
+ sphinx/highlighting.py:187:13: error: Statement is unreachable [unreachable]
+ sphinx/config.py: note: In member "add" of class "Config":
+ sphinx/config.py:462:13: error: Statement is unreachable [unreachable]
+ sphinx/config.py: note: In member "filter" of class "Config":
+ sphinx/config.py:469:23: error: Subclass of "AbstractSet[Literal['', 'env', 'epub', 'gettext', 'html', 'applehelp', 'devhelp']]" and "str" cannot exist: would have incompatible method signatures [unreachable]
+ sphinx/config.py:470:13: error: Statement is unreachable [unreachable]
+ sphinx/config.py: note: In member "__getstate__" of class "Config":
+ sphinx/config.py:484:16: error: Right operand of "and" is never evaluated [unreachable]
+ sphinx/config.py:484:57: error: Subclass of "_Opt" and "tuple[Any, ...]" cannot exist: would have incompatible method signatures [unreachable]
+ sphinx/config.py:486:17: error: Statement is unreachable [unreachable]
+ sphinx/util/rst.py:72:13: error: Statement is unreachable [unreachable]
+ sphinx/util/display.py:10:5: error: Statement is unreachable [unreachable]
+ sphinx/domains/std/__init__.py: note: In member "process_doc" of class "StandardDomain":
+ sphinx/domains/std/__init__.py:795:17: error: Statement is unreachable [unreachable]
+ sphinx/theming.py: note: In function "_validate_theme_toml":
+ sphinx/theming.py:346:9: error: Statement is unreachable [unreachable]
+ sphinx/theming.py:350:9: error: Statement is unreachable [unreachable]
+ sphinx/theming.py:358:13: error: Statement is unreachable [unreachable]
+ sphinx/theming.py: note: In function "_convert_theme_toml":
+ sphinx/theming.py:375:9: error: Statement is unreachable [unreachable]
+ sphinx/transforms/__init__.py: note: In member "apply_transforms" of class "SphinxTransformer":
+ sphinx/transforms/__init__.py:97:13: error: Statement is unreachable [unreachable]
+ sphinx/transforms/__init__.py: note: In function "_reorder_index_target_nodes":
+ sphinx/transforms/__init__.py:504:9: error: Statement is unreachable [unreachable]
+ sphinx/ext/autodoc/importer.py: note: In function "import_object":
+ sphinx/ext/autodoc/importer.py:200:9: error: Statement is unreachable [unreachable]
+ sphinx/ext/autodoc/__init__.py: note: In member "_find_signature" of class "DocstringSignatureMixin":
+ sphinx/ext/autodoc/__init__.py:1252:21: error: Statement is unreachable [unreachable]
+ sphinx/ext/autodoc/__init__.py: note: In function "_get_signature":
+ sphinx/ext/autodoc/__init__.py:1539:38: error: Subclass of "str" and "MethodType" cannot exist: "MethodType" is final [unreachable]
+ sphinx/ext/autodoc/__init__.py:1539:66: error: Subclass of "str" and "FunctionType" cannot exist: "FunctionType" is final [unreachable]
+ sphinx/ext/autodoc/__init__.py:1541:13: error: Statement is unreachable [unreachable]
+ sphinx/ext/autodoc/__init__.py: note: In member "format_signature" of class "MethodDocumenter":
+ sphinx/ext/autodoc/__init__.py:2257:25: error: Statement is unreachable [unreachable]
+ sphinx/ext/autodoc/__init__.py: note: In member "import_object" of class "PropertyDocumenter":
+ sphinx/ext/autodoc/__init__.py:2766:17: error: Statement is unreachable [unreachable]
+ sphinx/environment/adapters/toctree.py: note: In function "_toctree_url_entry":
+ sphinx/environment/adapters/toctree.py:368:9: error: Statement is unreachable [unreachable]
+ sphinx/domains/cpp/_ast.py: note: In member "describe_signature" of class "ASTNestedName":
+ sphinx/domains/cpp/_ast.py:255:17: error: Statement is unreachable [unreachable]
+ sphinx/domains/cpp/_ast.py:260:21: error: Statement is unreachable [unreachable]
+ sphinx/domains/cpp/_ast.py:265:21: error: Statement is unreachable [unreachable]
+ sphinx/domains/cpp/_ast.py: note: In member "get_ptr_suffix_id" of class "ASTDeclaratorMemPtr":
+ sphinx/domains/cpp/_ast.py:2940:9: error: Statement is unreachable [unreachable]
+ sphinx/domains/cpp/_ast.py: note: In member "get_ptr_suffix_id" of class "ASTDeclaratorParen":
+ sphinx/domains/cpp/_ast.py:3033:13: error: Statement is unreachable [unreachable]
+ sphinx/domains/c/_ast.py: note: In member "describe_signature" of class "ASTNestedName":
+ sphinx/domains/c/_ast.py:139:17: error: Statement is unreachable [unreachable]
+ sphinx/domains/c/_ast.py:144:21: error: Statement is unreachable [unreachable]
+ sphinx/domains/cpp/_parser.py: note: In member "_parse_type" of class "DefinitionParser":
+ sphinx/domains/cpp/_parser.py:1597:25: error: Statement is unreachable [unreachable]
+ sphinx/domains/c/_parser.py: note: In member "_parse_initializer" of class "DefinitionParser":
+ sphinx/domains/c/_parser.py:832:13: error: Statement is unreachable [unreachable]
+ sphinx/domains/c/_parser.py: note: In member "_parse_type" of class "DefinitionParser":
+ sphinx/domains/c/_parser.py:900:25: error: Statement is unreachable [unreachable]
+ sphinx/domains/cpp/__init__.py: note: In member "add_target_and_index" of class "CPPObject":
+ sphinx/domains/cpp/__init__.py:227:13: error: Statement is unreachable [unreachable]
+ sphinx/environment/__init__.py: note: In member "setup" of class "BuildEnvironment":
+ sphinx/environment/__init__.py:262:13: error: Statement is unreachable [unreachable]
+ sphinx/registry.py: note: In member "preload_builder" of class "SphinxComponentRegistry":
+ sphinx/registry.py:150:13: error: Statement is unreachable [unreachable]
+ sphinx/registry.py: note: In member "load_extension" of class "SphinxComponentRegistry":
+ sphinx/registry.py:476:17: error: Statement is unreachable [unreachable]
+ sphinx/registry.py:478:17: error: Statement is unreachable [unreachable]
+ sphinx/application.py: note: In member "create_builder" of class "Sphinx":
+ sphinx/application.py:362:13: error: Statement is unreachable [unreachable]
+ sphinx/jinja2glue.py: note: In function "_tobool":
+ sphinx/jinja2glue.py:30:5: error: Statement is unreachable [unreachable]
+ sphinx/jinja2glue.py: note: In function "_todim":
+ sphinx/jinja2glue.py:52:9: error: Statement is unreachable [unreachable]
+ sphinx/builders/gettext.py: note: In member "add" of class "Catalog":
+ sphinx/builders/gettext.py:75:13: error: Statement is unreachable [unreachable]
+ sphinx/builders/gettext.py: note: At top level:
+ sphinx/writers/latex.py: note: In function "visit_enumerated_list":
+ sphinx/writers/latex.py:1417:17: error: Statement is unreachable [unreachable]
+ sphinx/builders/html/__init__.py: note: In member "add_sidebars" of class "StandaloneHTMLBuilder":
+ sphinx/builders/html/__init__.py:1030:32: error: Right operand of "and" is never evaluated [unreachable]
+ sphinx/builders/html/__init__.py:1032:21: error: Statement is unreachable [unreachable]
+ sphinx/testing/util.py: note: In member "__init__" of class "SphinxTestApp":
+ sphinx/testing/util.py:148:13: error: Statement is unreachable [unreachable]
+ sphinx/testing/util.py:156:13: error: Statement is unreachable [unreachable]
+ sphinx/ext/viewcode.py: note: In function "_get_full_modname":
+ sphinx/ext/viewcode.py:54:13: error: Statement is unreachable [unreachable]
+ sphinx/ext/extlinks.py: note: In function "make_link_role":
+ sphinx/ext/extlinks.py:107:17: error: Statement is unreachable [unreachable]
+ sphinx/ext/doctest.py: note: In member "get_line_number" of class "DocTestBuilder":
+ sphinx/ext/doctest.py:389:9: error: Statement is unreachable [unreachable]
+ sphinx/ext/napoleon/docstring.py: note: In member "_get_min_indent" of class "GoogleDocstring":
+ sphinx/ext/napoleon/docstring.py:553:42: error: Right operand of "or" is never evaluated [unreachable]
... (truncated 35 lines) ...
mypy (https://github.com/python/mypy)
+ mypy/nodes.py:189: error: Statement is unreachable [unreachable]
+ mypy/nodes.py:189: note: See https://mypy.rtfd.io/en/stable/_refs.html#code-unreachable for more info
+ mypy/nodes.py:3249: error: Statement is unreachable [unreachable]
+ mypy/nodes.py:4007: error: Statement is unreachable [unreachable]
+ mypy/types.py:3307: error: Statement is unreachable [unreachable]
+ mypy/types.py:3324: error: Statement is unreachable [unreachable]
+ mypy/types.py:3366: error: Statement is unreachable [unreachable]
+ mypy/server/mergecheck.py:32: error: Statement is unreachable [unreachable]
+ mypy/server/astmerge.py:305: error: Statement is unreachable [unreachable]
+ mypy/errors.py:1069: error: Statement is unreachable [unreachable]
+ mypyc/ir/pprint.py:230: error: Statement is unreachable [unreachable]
+ mypyc/test/test_cheader.py:36: error: Statement is unreachable [unreachable]
+ mypy/constraints.py:130: error: Right operand of "and" is never evaluated [unreachable]
+ mypy/constraints.py:133: error: Statement is unreachable [unreachable]
+ mypy/constraints.py:514: error: Statement is unreachable [unreachable]
+ mypy/messages.py:2133: error: Statement is unreachable [unreachable]
+ mypy/messages.py:2137: error: Statement is unreachable [unreachable]
+ mypy/checkmember.py:1104: error: Right operand of "and" is never evaluated [unreachable]
+ mypy/checkmember.py:1107: error: Right operand of "and" is never evaluated [unreachable]
+ mypy/checkmember.py:1150: error: Statement is unreachable [unreachable]
+ mypy/checkmember.py:1409: error: Statement is unreachable [unreachable]
+ mypy/semanal.py:3083: error: Statement is unreachable [unreachable]
+ mypy/semanal.py:5661: error: Right operand of "and" is never evaluated [unreachable]
+ mypy/semanal.py:5663: error: Statement is unreachable [unreachable]
+ mypy/checkexpr.py:2570: error: Statement is unreachable [unreachable]
+ mypy/checker.py:2716: error: Statement is unreachable [unreachable]
+ mypy/checker.py:4271: error: Statement is unreachable [unreachable]
+ mypy/server/deps.py:506: error: Statement is unreachable [unreachable]
+ mypy/server/astdiff.py:238: error: Statement is unreachable [unreachable]
+ mypy/plugins/functools.py:109: error: Right operand of "and" is never evaluated [unreachable]
+ mypy/plugins/functools.py:110: error: Statement is unreachable [unreachable]
+ mypy/test/update_data.py:16: error: Subclass of "DataSuiteCollector" and "DataFileCollector" cannot exist: would have incompatible method signatures [unreachable]
+ mypy/test/update_data.py:17: error: Statement is unreachable [unreachable]
+ mypy/plugins/default.py:553: error: Subclass of "TupleType" and "LiteralType" cannot exist: would have incompatible method signatures [unreachable]
+ mypy/plugins/default.py:554: error: Statement is unreachable [unreachable]
+ mypy/build.py:1068: error: Statement is unreachable [unreachable]
+ mypy/build.py:1284: error: Statement is unreachable [unreachable]
+ mypy/stubtest.py:340: error: Statement is unreachable [unreachable]
+ mypy/stubtest.py:524: error: Statement is unreachable [unreachable]
+ mypy/test/testpep561.py:181: error: Statement is unreachable [unreachable]
+ mypy/test/testmerge.py:178: error: Statement is unreachable [unreachable]
+ mypy/test/testfinegrained.py:78: error: Statement is unreachable [unreachable]
pywin32 (https://github.com/mhammond/pywin32)
+ win32/Lib/sspi.py:375:59: error: Right operand of "and" is never evaluated [unreachable]
+ com/win32comext/mapi/__init__.py:1:15: error: Subclass of "List[str]" and "str" cannot exist: would have incompatible method signatures [unreachable]
+ com/win32comext/mapi/__init__.py:3:5: error: Statement is unreachable [unreachable]
+ com/win32comext/adsi/__init__.py:4:15: error: Subclass of "List[str]" and "str" cannot exist: would have incompatible method signatures [unreachable]
+ com/win32comext/adsi/__init__.py:6:5: error: Statement is unreachable [unreachable]
+ com/win32comext/axscript/client/error.py:101:13: error: Statement is unreachable [unreachable]
+ com/win32comext/axscript/client/framework.py:1120:13: error: Statement is unreachable [unreachable]
artigraph (https://github.com/artigraph/artigraph)
+ src/arti/internal/type_hints.py:50: error: Subclass of "type" and "TypeVar" cannot exist: "TypeVar" is final [unreachable]
+ src/arti/internal/type_hints.py:51: error: Statement is unreachable [unreachable]
+ src/arti/internal/type_hints.py:58: error: Statement is unreachable [unreachable]
+ src/arti/types/python.py:68: error: Subclass of "Type" and "_ContainerMixin" cannot exist: would have incompatible method signatures [unreachable]
+ src/arti/types/python.py:69: error: Statement is unreachable [unreachable]
+ src/arti/views/__init__.py:71: error: Statement is unreachable [unreachable]
+ src/arti/views/__init__.py:78: error: Statement is unreachable [unreachable]
+ src/arti/views/__init__.py:95: error: Statement is unreachable [unreachable]
+ src/arti/types/pydantic.py:25: error: Subclass of "Type" and "_NamedMixin" cannot exist: would have incompatible method signatures [unreachable]
+ src/arti/types/pydantic.py:26: error: Statement is unreachable [unreachable]
+ src/arti/types/pyarrow.py:291: error: Subclass of "Type" and "_TimeMixin" cannot exist: would have incompatible method signatures [unreachable]
+ src/arti/types/pyarrow.py:292: error: Statement is unreachable [unreachable]
+ src/arti/types/bigquery.py:100: error: Subclass of "Type" and "_TimeMixin" cannot exist: would have incompatible method signatures [unreachable]
+ src/arti/types/bigquery.py:101: error: Statement is unreachable [unreachable]
+ tests/arti/internal/test_utils.py:158: error: Statement is unreachable [unreachable]
pip (https://github.com/pypa/pip)
+ src/pip/_internal/utils/glibc.py:69: error: Statement is unreachable [unreachable]
+ src/pip/_internal/utils/hashes.py:41: error: Statement is unreachable [unreachable]
+ src/pip/_internal/build_env.py:199: error: Statement is unreachable [unreachable]
+ src/pip/_internal/utils/unpacking.py:73: error: Statement is unreachable [unreachable]
+ src/pip/_internal/req/req_file.py:490: error: Statement is unreachable [unreachable]
+ src/pip/_internal/network/auth.py:132: error: Statement is unreachable [unreachable]
+ src/pip/_internal/network/auth.py:150: error: Statement is unreachable [unreachable]
+ src/pip/_internal/resolution/resolvelib/base.py:42: error: Statement is unreachable [unreachable]
+ src/pip/_internal/resolution/legacy/resolver.py:454: error: Statement is unreachable [unreachable]
+ src/pip/_internal/resolution/legacy/resolver.py:472: error: Statement is unreachable [unreachable]
packaging (https://github.com/pypa/packaging)
+ src/packaging/version.py:80: error: Statement is unreachable [unreachable]
+ src/packaging/version.py:86: error: Statement is unreachable [unreachable]
+ src/packaging/version.py:98: error: Statement is unreachable [unreachable]
+ src/packaging/version.py:104: error: Statement is unreachable [unreachable]
+ src/packaging/_manylinux.py:143: error: Statement is unreachable [unreachable]
+ src/packaging/specifiers.py:806: error: Statement is unreachable [unreachable]
+ src/packaging/markers.py:317: error: Statement is unreachable [unreachable]
+ src/packaging/metadata.py:335: error: Subclass of "str" and "Header" cannot exist: would have incompatible method signatures [unreachable]
+ src/packaging/metadata.py:339: error: Statement is unreachable [unreachable]
mongo-python-driver (https://github.com/mongodb/mongo-python-driver)
+ bson/binary.py:492: error: Statement is unreachable [unreachable]
+ bson/decimal128.py:226: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/periodic_executor.py:202: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/periodic_executor.py:202: error: Statement is unreachable [unreachable]
+ pymongo/auth_shared.py:118: error: Statement is unreachable [unreachable]
+ pymongo/auth_shared.py:157: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:124: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:140: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:159: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:183: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:483: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:496: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:562: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:709: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/topology.py:917: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/pool.py:336: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/pool.py:1530: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/monitor.py:510: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/mongo_client.py:2436: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/database.py:129: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/collection.py:239: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/client_session.py:878: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/client_session.py:1050: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/bulk.py:214: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/bulk.py:481: error: Statement is unreachable [unreachable]
+ pymongo/synchronous/bulk.py:618: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:124: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:140: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:159: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:183: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:483: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:496: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:562: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:711: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/topology.py:919: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/pool.py:336: error: Statement is unreachable [unreachable]
+ pymongo/asynchronous/pool.py:1536: error: Statement is unreachable [unreachable]
... (truncated 130 lines) ...``` |
This would be a breaking change so feel free to reject, and can with draw issue if so |
|
This was referenced May 7, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is useful check for dead code analysis
Closes #11223
This adds a useful check to the default list of strict arguments