From 26d19655db60faf4941fd093d1d4a4a00a99ede5 Mon Sep 17 00:00:00 2001 From: Evan Rittenhouse Date: Thu, 15 Jun 2023 17:09:00 -0500 Subject: [PATCH] Add Applicability to flake8_tidy_imports (#5131) ## Summary Fixes some of https://github.com/astral-sh/ruff/issues/4184 --- .../src/rules/flake8_tidy_imports/rules/relative_imports.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/crates/ruff/src/rules/flake8_tidy_imports/rules/relative_imports.rs b/crates/ruff/src/rules/flake8_tidy_imports/rules/relative_imports.rs index 6531cebd7ee86..6b8227be282c5 100644 --- a/crates/ruff/src/rules/flake8_tidy_imports/rules/relative_imports.rs +++ b/crates/ruff/src/rules/flake8_tidy_imports/rules/relative_imports.rs @@ -100,8 +100,7 @@ fn fix_banned_relative_import( range: TextRange::default(), }; let content = generator.stmt(&node.into()); - #[allow(deprecated)] - Some(Fix::unspecified(Edit::range_replacement( + Some(Fix::suggested(Edit::range_replacement( content, stmt.range(), )))