ruff/crates
Shunsuke Shibayama ef564094a9
[ty] support del statement and deletion of except handler names (#18593)
## Summary

This PR closes https://github.com/astral-sh/ty/issues/238.

Since `DefinitionState::Deleted` was introduced in #18041, support for
the `del` statement (and deletion of except handler names) is
straightforward.

However, it is difficult to determine whether references to attributes
or subscripts are unresolved after they are deleted. This PR only
invalidates narrowing by assignment if the attribute or subscript is
deleted.

## Test Plan

`mdtest/del.md` is added.

---------

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2025-06-12 07:44:42 -07:00
..
ruff [ty] Track the origin of the `environment.python` setting for better error messages (#18483) 2025-06-06 13:36:41 +01:00
ruff_annotate_snippets Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_benchmark [ty] Add --config-file CLI arg (#18083) 2025-05-27 08:00:38 +02:00
ruff_cache Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_db Update pre-commit dependencies (#18581) 2025-06-09 08:08:17 +02:00
ruff_dev Remove `Message::to_rule` (#18447) 2025-06-05 12:48:29 -04:00
ruff_diagnostics Add a `ViolationMetadata::rule` method (#18234) 2025-05-28 09:27:09 -04:00
ruff_formatter Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_graph [ty] Fix `--python` argument for Windows, and improve error messages for bad `--python` arguments (#18457) 2025-06-05 08:19:15 +01:00
ruff_index Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_linter [`ruff`] Handle extra arguments to `deque` (`RUF037`) (#18614) 2025-06-12 09:07:17 -04:00
ruff_macros Remove `Message::to_rule` (#18447) 2025-06-05 12:48:29 -04:00
ruff_notebook Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_options_metadata [ty] Document configuration schema (#17950) 2025-05-09 10:47:45 +02:00
ruff_python_ast `SourceOrderVisitor` should visit the `Identifier` part of the `PatternKeyword` node (#18635) 2025-06-12 08:20:14 +02:00
ruff_python_ast_integration_tests `SourceOrderVisitor` should visit the `Identifier` part of the `PatternKeyword` node (#18635) 2025-06-12 08:20:14 +02:00
ruff_python_codegen Implement template strings (#17851) 2025-05-30 15:00:56 -05:00
ruff_python_formatter Treat `ty: ` comments as pragma comments (#18532) 2025-06-07 16:02:43 +02:00
ruff_python_index Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_python_literal Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_python_parser Implement template strings (#17851) 2025-05-30 15:00:56 -05:00
ruff_python_resolver Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_python_semantic Implement template strings (#17851) 2025-05-30 15:00:56 -05:00
ruff_python_stdlib Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_python_trivia Treat `ty: ` comments as pragma comments (#18532) 2025-06-07 16:02:43 +02:00
ruff_python_trivia_integration_tests Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_server Remove `Message::to_rule` (#18447) 2025-06-05 12:48:29 -04:00
ruff_source_file Switch to Rust 2024 edition (#18129) 2025-05-16 13:25:28 +02:00
ruff_text_size Add rustfmt.toml file (#18197) 2025-05-19 11:40:58 -04:00
ruff_wasm Bump 0.11.13 (#18484) 2025-06-05 15:18:38 -05:00
ruff_workspace Remove `Message::to_rule` (#18447) 2025-06-05 12:48:29 -04:00
ty [ty] Update mypy_primer doc (#18638) 2025-06-11 20:50:37 -07:00
ty_ide [ty] Add some "inside string" tests for `object.<CURSOR>` completions 2025-06-12 07:50:49 -04:00
ty_project [ty] Infer the Python version from `--python=<system installation>` on Unix (#18550) 2025-06-11 14:32:33 +00:00
ty_python_semantic [ty] support del statement and deletion of except handler names (#18593) 2025-06-12 07:44:42 -07:00
ty_server [ty] Fix stale documents on Windows (#18544) 2025-06-09 16:39:11 +02:00
ty_test [ty] Pull types on synthesized Python files created by mdtest (#18539) 2025-06-12 10:32:17 +01:00
ty_vendored [ty] Generate the top and bottom materialization of a type (#18594) 2025-06-12 12:06:16 +05:30
ty_wasm [ty] Add infrastructure for AST garbage collection (#18445) 2025-06-05 11:43:18 -04:00