ITADN

Type ignore comments with ty-namespaced codes are not recognized as blanket type ignores

#11345Opencorrectmost 创建于 2026-03-25
bug
C
correctmostcommented
**Describe the bug** ty 0.0.25 added support for type ignore comments that use namespaced codes and look like this: `type: ignore[ty:unresolved-reference]` (https://github.com/astral-sh/ruff/pull/24096). When these namespaced codes are used, Pyright fails to treat the comment as a blanket type ignore. **Code or Screenshots** ```python a[1] # type: ignore[name-defined, ty:unresolved-reference] ``` ``` error: "a" is not defined (reportUndefinedVariable) ``` **VS Code extension or command-line** 1.1.408 (command-line version)
0 条评论