Skip to content

Commit

Permalink
Mark PERF403 as a preview rule (#7396)
Browse files Browse the repository at this point in the history
  • Loading branch information
charliermarsh authored Sep 15, 2023
1 parent 3112202 commit 6163c99
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion crates/ruff/src/codes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -898,7 +898,7 @@ pub fn code_to_rule(linter: Linter, code: &str) -> Option<(RuleGroup, Rule)> {
(Perflint, "203") => (RuleGroup::Unspecified, rules::perflint::rules::TryExceptInLoop),
(Perflint, "401") => (RuleGroup::Unspecified, rules::perflint::rules::ManualListComprehension),
(Perflint, "402") => (RuleGroup::Unspecified, rules::perflint::rules::ManualListCopy),
(Perflint, "403") => (RuleGroup::Unspecified, rules::perflint::rules::ManualDictComprehension),
(Perflint, "403") => (RuleGroup::Preview, rules::perflint::rules::ManualDictComprehension),

// flake8-fixme
(Flake8Fixme, "001") => (RuleGroup::Unspecified, rules::flake8_fixme::rules::LineContainsFixme),
Expand Down
1 change: 1 addition & 0 deletions crates/ruff_workspace/src/configuration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -853,6 +853,7 @@ mod tests {
];

const PREVIEW_RULES: &[Rule] = &[
Rule::ManualDictComprehension,
Rule::TooManyPublicMethods,
Rule::SliceCopy,
Rule::UndocumentedWarn,
Expand Down

0 comments on commit 6163c99

Please sign in to comment.