Skip to content

Conversation

@AlexWaygood
Copy link
Member

Summary

Test Plan

@AlexWaygood AlexWaygood added the ty Multi-file analysis & type inference label Nov 17, 2025
@astral-sh-bot
Copy link

astral-sh-bot bot commented Nov 17, 2025

Diagnostic diff on typing conformance tests

Changes were detected when running ty on typing conformance tests
--- old-output.txt	2025-11-17 15:02:43.074318663 +0000
+++ new-output.txt	2025-11-17 15:02:46.551350726 +0000
@@ -435,13 +435,10 @@
 generics_defaults.py:81:1: error[type-assertion-failure] Argument does not have asserted type `Unknown`
 generics_defaults.py:81:29: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[bool, bool]`?
 generics_defaults.py:81:46: error[too-many-positional-arguments] Too many positional arguments to class `Class_ParamSpec`: expected 1, got 2
-generics_defaults.py:91:26: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_defaults.py:94:1: error[type-assertion-failure] Argument does not have asserted type `@Todo(unsupported nested subscript in type[X])`
 generics_defaults.py:95:1: error[type-assertion-failure] Argument does not have asserted type `@Todo(specialized non-generic class)`
 generics_defaults.py:127:32: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `T4@func1`
 generics_defaults.py:131:1: error[type-assertion-failure] Argument does not have asserted type `Any`
-generics_defaults.py:142:12: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
-generics_defaults.py:152:12: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_defaults.py:155:49: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `tuple[int | float, bool]`?
 generics_defaults.py:156:58: error[invalid-type-form] List literals are not allowed in this context in a type expression: Did you mean `list[bytes]`?
 generics_defaults.py:170:1: error[type-assertion-failure] Argument does not have asserted type `(Foo7[int], /) -> Foo7[int]`
@@ -575,16 +572,13 @@
 generics_typevartuple_args.py:27:77: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `tuple[@Todo(PEP 646), ...]`
 generics_typevartuple_args.py:31:1: error[type-assertion-failure] Argument does not have asserted type `tuple[()]`
 generics_typevartuple_args.py:32:1: error[type-assertion-failure] Argument does not have asserted type `tuple[int, str]`
-generics_typevartuple_basic.py:12:14: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_typevartuple_basic.py:16:26: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `tuple[@Todo(PEP 646), ...]`
-generics_typevartuple_basic.py:23:13: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_typevartuple_basic.py:42:34: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `tuple[@Todo(PEP 646), ...]`, found `Height`
 generics_typevartuple_basic.py:65:27: error[unknown-argument] Argument `covariant` does not match any known parameter of function `__new__`
 generics_typevartuple_basic.py:66:27: error[too-many-positional-arguments] Too many positional arguments to function `__new__`: expected 2, got 4
 generics_typevartuple_basic.py:67:27: error[unknown-argument] Argument `bound` does not match any known parameter of function `__new__`
 generics_typevartuple_basic.py:75:50: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `tuple[@Todo(PEP 646), ...]`
 generics_typevartuple_basic.py:84:1: error[type-assertion-failure] Argument does not have asserted type `tuple[int]`
-generics_typevartuple_basic.py:106:14: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_typevartuple_callable.py:29:57: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `tuple[@Todo(PEP 646), ...]`
 generics_typevartuple_callable.py:33:54: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `tuple[int | float | complex, str, int]`
 generics_typevartuple_callable.py:37:34: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `tuple[str]`
@@ -592,11 +586,8 @@
 generics_typevartuple_callable.py:42:1: error[type-assertion-failure] Argument does not have asserted type `tuple[str]`
 generics_typevartuple_callable.py:45:43: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `tuple[@Todo(PEP 646), ...]`
 generics_typevartuple_callable.py:49:1: error[type-assertion-failure] Argument does not have asserted type `tuple[int | float, str, int | float | complex]`
-generics_typevartuple_concat.py:22:13: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_typevartuple_concat.py:47:42: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `tuple[@Todo(PEP 646), ...]`
 generics_typevartuple_concat.py:52:1: error[type-assertion-failure] Argument does not have asserted type `tuple[int, bool, str]`
-generics_typevartuple_overloads.py:16:13: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
-generics_typevartuple_specialization.py:16:13: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_typevartuple_specialization.py:46:5: error[type-assertion-failure] Argument does not have asserted type `tuple[int, int | float, bool]`
 generics_typevartuple_specialization.py:47:5: error[type-assertion-failure] Argument does not have asserted type `tuple[str, @Todo(specialized non-generic class)]`
 generics_typevartuple_specialization.py:50:23: error[invalid-type-form] Tuple literals are not allowed in this context in a type expression: Did you mean `tuple[()]`?
@@ -604,7 +595,6 @@
 generics_typevartuple_specialization.py:51:5: error[type-assertion-failure] Argument does not have asserted type `tuple[int]`
 generics_typevartuple_specialization.py:52:5: error[type-assertion-failure] Argument does not have asserted type `tuple[str, @Todo(specialized non-generic class)]`
 generics_typevartuple_specialization.py:52:37: error[invalid-type-form] Tuple literals are not allowed in this context in a type expression: Did you mean `tuple[()]`?
-generics_typevartuple_specialization.py:59:14: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_typevartuple_specialization.py:93:5: error[type-assertion-failure] Argument does not have asserted type `tuple[str, int]`
 generics_typevartuple_specialization.py:94:5: error[type-assertion-failure] Argument does not have asserted type `tuple[int | float]`
 generics_typevartuple_specialization.py:95:5: error[type-assertion-failure] Argument does not have asserted type `tuple[Any, *tuple[Any, ...]]`
@@ -618,7 +608,6 @@
 generics_typevartuple_specialization.py:157:5: error[type-assertion-failure] Argument does not have asserted type `tuple[*tuple[int, ...], int]`
 generics_typevartuple_specialization.py:158:5: error[type-assertion-failure] Argument does not have asserted type `tuple[*tuple[int, ...], str]`
 generics_typevartuple_specialization.py:159:5: error[type-assertion-failure] Argument does not have asserted type `tuple[*tuple[int, ...], str]`
-generics_typevartuple_unpack.py:17:13: error[invalid-argument-type] `@Todo(starred expression)` is not a valid argument to `Generic`
 generics_upper_bound.py:37:1: error[type-assertion-failure] Argument does not have asserted type `list[int]`
 generics_upper_bound.py:38:1: error[type-assertion-failure] Argument does not have asserted type `set[int]`
 generics_upper_bound.py:43:1: error[type-assertion-failure] Argument does not have asserted type `list[int] | set[int]`
@@ -993,5 +982,5 @@
 typeddicts_usage.py:28:17: error[missing-typed-dict-key] Missing required key 'name' in TypedDict `Movie` constructor
 typeddicts_usage.py:28:18: error[invalid-key] Invalid key for TypedDict `Movie`: Unknown key "title"
 typeddicts_usage.py:40:24: error[invalid-type-form] The special form `typing.TypedDict` is not allowed in type expressions. Did you mean to use a concrete TypedDict or `collections.abc.Mapping[str, object]` instead?
-Found 995 diagnostics
+Found 984 diagnostics
 WARN A fatal error occurred while checking some files. Not all project files were analyzed. See the diagnostics list above for details.

@astral-sh-bot
Copy link

astral-sh-bot bot commented Nov 17, 2025

mypy_primer results

Changes were detected when running on open source projects
anyio (https://github.com/agronholm/anyio)
- src/anyio/_core/_sockets.py:385:56: error[invalid-argument-type] Argument to function `setup_raw_socket` is incorrect: Expected `tuple[str, int] | tuple[str, int, int, int]`, found `tuple[str | Unknown, int, @Todo]`
- Found 82 diagnostics
+ Found 81 diagnostics

kornia (https://github.com/kornia/kornia)
- kornia/utils/draw.py:376:5: error[invalid-assignment] Not enough values to unpack: Expected 5
- kornia/utils/draw.py:379:5: error[invalid-assignment] Not enough values to unpack: Expected 5
- kornia/utils/draw.py:382:5: error[invalid-assignment] Not enough values to unpack: Expected 3
- Found 764 diagnostics
+ Found 761 diagnostics

spack (https://github.com/spack/spack)
- lib/spack/spack/llnl/util/link_tree.py:116:20: error[invalid-return-type] Return type does not match returned value: expected `tuple[str, str, str]`, found `tuple[str, @Todo]`
- lib/spack/spack/llnl/util/link_tree.py:151:20: error[invalid-return-type] Return type does not match returned value: expected `tuple[str, str, str]`, found `tuple[str, @Todo]`
- lib/spack/spack/spec.py:5647:69: error[invalid-assignment] Not enough values to unpack: Expected 3
- Found 7910 diagnostics
+ Found 7907 diagnostics

pytest-robotframework (https://github.com/detachhead/pytest-robotframework)
+ pytest_robotframework/_internal/robot/utils.py:231:25: warning[redundant-cast] Value is already of type `list[object] | None`
- Found 169 diagnostics
+ Found 170 diagnostics

black (https://github.com/psf/black)
- src/black/cache.py:144:17: error[invalid-assignment] Object of type `dict[str | Unknown, tuple[@Todo] | Unknown]` is not assignable to `dict[str, tuple[int | float, int, str]]`
- Found 64 diagnostics
+ Found 63 diagnostics

pytest (https://github.com/pytest-dev/pytest)
- src/_pytest/reports.py:302:12: error[invalid-return-type] Return type does not match returned value: expected `tuple[str, int, str]`, found `tuple[@Todo, str]`
- src/_pytest/terminal.py:1589:23: error[invalid-argument-type] Argument to bound method `append` is incorrect: Expected `tuple[int, str, int | None, str]`, found `tuple[int, @Todo]`
- Found 440 diagnostics
+ Found 438 diagnostics

poetry (https://github.com/python-poetry/poetry)
- src/poetry/utils/env/mock_env.py:34:13: error[invalid-assignment] Object of type `tuple[@Todo, Literal["final"], Literal[0]]` is not assignable to `tuple[int, int, int] | tuple[int, int, int, str, int]`
+ src/poetry/utils/env/mock_env.py:34:13: error[invalid-assignment] Object of type `tuple[*tuple[int | str, ...], Literal["final"], Literal[0]]` is not assignable to `tuple[int, int, int] | tuple[int, int, int, str, int]`
+ tests/puzzle/test_solver.py:614:9: error[invalid-assignment] Object of type `list[Unknown | str]` is not assignable to `list[Literal["a", "b", "download-package", "install-package"]]`
- Found 976 diagnostics
+ Found 977 diagnostics

freqtrade (https://github.com/freqtrade/freqtrade)
- freqtrade/commands/data_commands.py:172:21: error[invalid-assignment] Not enough values to unpack: Expected 6
- freqtrade/commands/data_commands.py:226:21: error[invalid-assignment] Not enough values to unpack: Expected 4
- Found 610 diagnostics
+ Found 608 diagnostics

discord.py (https://github.com/Rapptz/discord.py)
- discord/app_commands/transformers.py:584:13: error[invalid-assignment] Not enough values to unpack: Expected 3
- discord/ext/commands/converter.py:1241:13: error[invalid-assignment] Not enough values to unpack: Expected 3
- Found 461 diagnostics
+ Found 459 diagnostics

apprise (https://github.com/caronc/apprise)
- tests/test_plugin_email.py:634:5: error[invalid-assignment] Object of type `tuple[@Todo, @Todo]` is not assignable to attribute `EMAIL_TEMPLATES` of type `tuple[tuple[Literal["Google Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Yandex"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Hotmail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Outlook"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Office 365"], Pattern[str], dict[Unknown | str, Unknown | int | str]], tuple[Literal["Yahoo Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Fast Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Fast Mail Extended Addresses"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Zoho Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["SendGrid"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["163.com"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Foxmail.com"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Comcast.net"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Local Mail Server"], Pattern[str], dict[Unknown | str, Unknown | str | None]], tuple[Literal["Custom"], Pattern[str], dict[Unknown | str, Unknown | None]]]`
+ tests/test_plugin_email.py:634:5: error[invalid-assignment] Object of type `tuple[tuple[Literal["Testing Lookup"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Google Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Yandex"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Hotmail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Outlook"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Office 365"], Pattern[str], dict[Unknown | str, Unknown | int | str]], tuple[Literal["Yahoo Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Fast Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Fast Mail Extended Addresses"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Zoho Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["SendGrid"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["163.com"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Foxmail.com"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Comcast.net"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Local Mail Server"], Pattern[str], dict[Unknown | str, Unknown | str | None]], tuple[Literal["Custom"], Pattern[str], dict[Unknown | str, Unknown | None]]]` is not assignable to attribute `EMAIL_TEMPLATES` of type `tuple[tuple[Literal["Google Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Yandex"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Hotmail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Outlook"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Microsoft Office 365"], Pattern[str], dict[Unknown | str, Unknown | int | str]], tuple[Literal["Yahoo Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Fast Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Fast Mail Extended Addresses"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Zoho Mail"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["SendGrid"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["163.com"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Foxmail.com"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Comcast.net"], Pattern[str], dict[Unknown | str, Unknown | int | str | tuple[Unknown | str]]], tuple[Literal["Local Mail Server"], Pattern[str], dict[Unknown | str, Unknown | str | None]], tuple[Literal["Custom"], Pattern[str], dict[Unknown | str, Unknown | None]]]`

pandera (https://github.com/pandera-dev/pandera)
- tests/pandas/test_dtypes.py:170:1: error[invalid-assignment] Object of type `list[Unknown | tuple[dict[Unknown | <class 'int'> | <class 'Int'> | ... omitted 8 union elements, Unknown | str], list[Unknown | int]] | tuple[dict[Unknown | <class 'INT8'> | <class 'INT16'> | <class 'INT32'> | <class 'INT64'>, Unknown | str], list[Unknown | int | None]] | ... omitted 14 union elements]` is not assignable to `list[tuple[dict[Unknown, Unknown], list[Unknown]]]`
+ tests/pandas/test_dtypes.py:170:1: error[invalid-assignment] Object of type `list[Unknown | tuple[dict[Unknown | <class 'int'> | <class 'Int'> | ... omitted 8 union elements, Unknown | str], list[Unknown | int]] | tuple[dict[Unknown | <class 'INT8'> | <class 'INT16'> | <class 'INT32'> | <class 'INT64'>, Unknown | str], list[Unknown | int | None]] | ... omitted 15 union elements]` is not assignable to `list[tuple[dict[Unknown, Unknown], list[Unknown]]]`

vision (https://github.com/pytorch/vision)
+ test/test_datasets.py:698:9: error[invalid-assignment] Invalid subscript assignment with key of type `Literal["trainval"]` and value of type `tuple[int, ...]` on object of type `dict[str, tuple[int, int, int] | tuple[int, int] | tuple[int]]`
- torchvision/datasets/utils.py:268:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[str, str | None, str | None]`, found `tuple[@Todo, @Todo]`

strawberry (https://github.com/strawberry-graphql/strawberry)
- strawberry/federation/schema.py:80:9: error[invalid-assignment] Object of type `list[Unknown | NewType]` is not assignable to `Iterable[type]`
+ strawberry/federation/schema.py:80:9: error[invalid-assignment] Object of type `list[Unknown | type | NewType]` is not assignable to `Iterable[type]`

openlibrary (https://github.com/internetarchive/openlibrary)
- openlibrary/i18n/__init__.py:209:13: error[invalid-assignment] Not enough values to unpack: Expected 6
- openlibrary/plugins/worksearch/code.py:301:59: error[invalid-argument-type] Argument to bound method `q_to_solr_params` is incorrect: Expected `list[tuple[str, str]]`, found `list[Unknown | tuple[str, Unknown | int] | tuple[str, str]]`
+ openlibrary/plugins/worksearch/code.py:301:59: error[invalid-argument-type] Argument to bound method `q_to_solr_params` is incorrect: Expected `list[tuple[str, str]]`, found `list[Unknown | tuple[str, str] | tuple[str, Unknown | int]]`
- openlibrary/utils/isbn.py:112:12: error[invalid-return-type] Return type does not match returned value: expected `tuple[str | None, str | None, str | None]`, found `tuple[str | None, @Todo]`
- Found 943 diagnostics
+ Found 941 diagnostics

scikit-build-core (https://github.com/scikit-build/scikit-build-core)
- src/scikit_build_core/build/wheel.py:98:20: error[no-matching-overload] No overload of bound method `__init__` matches arguments
- Found 44 diagnostics
+ Found 43 diagnostics

prefect (https://github.com/PrefectHQ/prefect)
+ src/prefect/blocks/core.py:86:1: error[invalid-assignment] Object of type `tuple[<class 'list'>, <class 'dict'>, <class 'tuple'>, *tuple[typing.Union | <class 'UnionType'>, ...]]` is not assignable to `tuple[type, ...]`
- Found 3234 diagnostics
+ Found 3235 diagnostics

egglog-python (https://github.com/egraphs-good/egglog-python)
- python/egglog/builtins.py:1061:31: error[invalid-argument-type] `@Todo` is not a valid argument to `Generic`
- python/egglog/thunk.py:36:13: error[invalid-argument-type] `@Todo` is not a valid argument to `Generic`
- python/egglog/thunk.py:83:18: error[invalid-argument-type] `@Todo` is not a valid argument to `Generic`
- Found 1491 diagnostics
+ Found 1488 diagnostics

bokeh (https://github.com/bokeh/bokeh)
- src/bokeh/models/__init__.py:108:1: error[invalid-assignment] Object of type `tuple[Literal["Model"], @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo]` is not assignable to `tuple[@Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo]`
- src/bokeh/models/annotations/__init__.py:44:1: error[invalid-assignment] Object of type `tuple[@Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo]` is not assignable to `tuple[@Todo, @Todo, @Todo]`
- Found 634 diagnostics
+ Found 632 diagnostics

jax (https://github.com/google/jax)
- jax/_src/pallas/fuser/block_spec.py:839:10: error[invalid-return-type] Return type does not match returned value: expected `Sequence[BlockSpec]`, found `list[Unknown | NoBlockSpec]`
+ jax/_src/pallas/fuser/block_spec.py:839:10: error[invalid-return-type] Return type does not match returned value: expected `Sequence[BlockSpec]`, found `list[Unknown | NoBlockSpec | BlockSpec]`
- jax/_src/pallas/hlo_interpreter.py:395:33: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `Sequence[tuple[int, int, int]]`, found `list[tuple[@Todo, int] | Unknown]`
+ jax/_src/pallas/hlo_interpreter.py:395:33: error[invalid-argument-type] Argument to function `pad` is incorrect: Expected `Sequence[tuple[int, int, int]]`, found `list[tuple[*tuple[int | Unknown, ...], int] | Unknown]`
- jax/experimental/mosaic/gpu/utils.py:1965:10: error[invalid-return-type] Return type does not match returned value: expected `tuple[Unknown, Unknown, Unknown, Unknown]`, found `tuple[@Todo, Unknown]`
- jax/experimental/pallas/ops/gpu/all_gather_mgpu.py:91:6: error[unsupported-operator] Operator `%` is unsupported between objects of type `@Todo | int` and `int | None`
+ jax/experimental/pallas/ops/gpu/all_gather_mgpu.py:91:6: error[unsupported-operator] Operator `%` is unsupported between objects of type `int` and `int | None`
- jax/experimental/pallas/ops/gpu/reduce_scatter_mgpu.py:106:6: error[unsupported-operator] Operator `%` is unsupported between objects of type `Unknown | Literal[1]` and `int | None`
+ jax/experimental/pallas/ops/gpu/reduce_scatter_mgpu.py:106:6: error[unsupported-operator] Operator `%` is unsupported between objects of type `int` and `int | None`
- jax/experimental/slab/slab.py:248:3: error[invalid-assignment] Not enough values to unpack: Expected 3
- Found 2639 diagnostics
+ Found 2637 diagnostics

zulip (https://github.com/zulip/zulip)
- zerver/actions/message_send.py:1135:13: error[invalid-assignment] Object of type `dict[str, Unknown | None]` is not assignable to `UserData`
+ zerver/actions/message_send.py:1135:13: error[invalid-assignment] Object of type `dict[str, Unknown | int | None]` is not assignable to `UserData`

sympy (https://github.com/sympy/sympy)
- sympy/parsing/latex/__init__.py:117:12: error[index-out-of-bounds] Index 3 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:118:30: error[index-out-of-bounds] Index 2 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:120:59: error[index-out-of-bounds] Index 3 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:125:12: error[index-out-of-bounds] Index 7 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:126:30: error[index-out-of-bounds] Index 2 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:128:53: error[index-out-of-bounds] Index 3 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:133:43: error[index-out-of-bounds] Index 3 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:135:30: error[index-out-of-bounds] Index 5 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:136:12: error[index-out-of-bounds] Index 7 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:139:37: error[index-out-of-bounds] Index 2 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:140:30: error[index-out-of-bounds] Index 6 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:140:47: error[index-out-of-bounds] Index 4 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- sympy/parsing/latex/__init__.py:141:65: error[index-out-of-bounds] Index 5 is out of bounds for tuple `tuple[@Todo, @Todo]` with length 2
- Found 14599 diagnostics
+ Found 14586 diagnostics

rotki (https://github.com/rotki/rotki)
- rotkehlchen/chain/evm/decoding/thegraph/balances.py:139:43: error[invalid-argument-type] Argument to bound method `append` is incorrect: Expected `tuple[ChecksumAddress, ChecksumAddress, ChecksumAddress, int]`, found `tuple[@Todo, Unknown]`
- Found 2132 diagnostics
+ Found 2131 diagnostics

core (https://github.com/home-assistant/core)
- homeassistant/components/esphome/light.py:337:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int]`, found `tuple[@Todo, Unknown]`
- homeassistant/components/esphome/light.py:358:20: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int, int]`, found `tuple[@Todo, Unknown, Unknown]`
- homeassistant/components/esphome/light.py:363:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int, int]`, found `tuple[@Todo, Unknown, Unknown]`
- homeassistant/components/flux_led/util.py:98:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int]`, found `tuple[@Todo, int]`
- homeassistant/components/flux_led/util.py:99:12: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int]`, found `tuple[@Todo, int]`
- homeassistant/components/flux_led/util.py:114:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int, int]`, found `tuple[@Todo, int, int]`
- homeassistant/components/flux_led/util.py:115:12: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int, int]`, found `tuple[@Todo, int, int]`
- homeassistant/components/knx/light.py:375:24: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int] | None`, found `tuple[@Todo, Unknown & ~None]`
- homeassistant/components/rfxtrx/__init__.py:212:50: warning[unused-ignore-comment] Unused blanket `type: ignore` directive
- homeassistant/components/rfxtrx/entity.py:24:39: warning[unused-ignore-comment] Unused blanket `type: ignore` directive
- homeassistant/components/shelly/light.py:226:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int]`, found `tuple[@Todo, int]`
- homeassistant/components/shelly/light.py:400:16: error[invalid-return-type] Return type does not match returned value: expected `tuple[int, int, int, int]`, found `tuple[@Todo, Unknown]`
+ homeassistant/components/zwave_js/discovery.py:1389:17: error[invalid-argument-type] Argument is incorrect: Expected `type[ZWaveBaseEntity]`, found `type`
- Found 14477 diagnostics
+ Found 14466 diagnostics

scipy (https://github.com/scipy/scipy)
- scipy/interpolate/tests/test_bsplines.py:1802:9: error[invalid-assignment] Not enough values to unpack: Expected 4
- scipy/interpolate/tests/test_bsplines.py:1814:9: error[invalid-assignment] Not enough values to unpack: Expected 4
- scipy/interpolate/tests/test_bsplines.py:1827:9: error[invalid-assignment] Not enough values to unpack: Expected 4
- scipy/interpolate/tests/test_bsplines.py:1837:9: error[invalid-assignment] Not enough values to unpack: Expected 4
- scipy/interpolate/tests/test_bsplines.py:1851:9: error[invalid-assignment] Not enough values to unpack: Expected 4
- scipy/interpolate/tests/test_bsplines.py:1862:9: error[invalid-assignment] Not enough values to unpack: Expected 3
- scipy/interpolate/tests/test_bsplines.py:1874:9: error[invalid-assignment] Not enough values to unpack: Expected 3
- Found 6708 diagnostics
+ Found 6701 diagnostics

No memory usage changes detected ✅

@codspeed-hq
Copy link

codspeed-hq bot commented Nov 17, 2025

CodSpeed Performance Report

Merging #21499 will not alter performance

Comparing alex/starred-tuples (ecda934) with main (d063c71)

Summary

✅ 22 untouched
⏩ 30 skipped1

Footnotes

  1. 30 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@AlexWaygood AlexWaygood changed the title [ty] Fix Todo type for starred elements in tuple expressions [ty] Fix Todo type for starred elements in tuple/list/set expressions Nov 17, 2025
@astral-sh-bot
Copy link

astral-sh-bot bot commented Nov 17, 2025

ecosystem-analyzer results

Lint rule Added Removed Changed
invalid-assignment 3 20 5
invalid-return-type 0 16 1
index-out-of-bounds 0 13 0
invalid-argument-type 1 6 2
unsupported-operator 0 0 2
unused-ignore-comment 0 2 0
redundant-cast 1 0 0
Total 5 57 10

Full report with detailed diff (timing results)

@AlexWaygood
Copy link
Member Author

- src/bokeh/models/annotations/__init__.py:44:1: error[invalid-assignment] Object of type `tuple[@Todo, @Todo, @Todo, @Todo, @Todo, @Todo, @Todo]` is not assignable to `tuple[@Todo, @Todo, @Todo]`

Well I definitely won't mourn that diagnostic going away

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ecosystem-analyzer ty Multi-file analysis & type inference

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants