[flake8_use_pathlib]: Replace os.symlink with Path.symlink_to (PTH211) (#18337)

Co-authored-by: Micha Reiser <micha@reiser.io>
This commit is contained in:
Viktor Merkurev 2025-05-28 15:39:05 +05:00 committed by GitHub
parent 66ba1d8775
commit b60ba75d09
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 132 additions and 14 deletions

View file

@ -934,6 +934,7 @@ pub fn code_to_rule(linter: Linter, code: &str) -> Option<(RuleGroup, Rule)> {
(Flake8UsePathlib, "207") => (RuleGroup::Stable, rules::flake8_use_pathlib::rules::Glob),
(Flake8UsePathlib, "208") => (RuleGroup::Stable, rules::flake8_use_pathlib::violations::OsListdir),
(Flake8UsePathlib, "210") => (RuleGroup::Stable, rules::flake8_use_pathlib::rules::InvalidPathlibWithSuffix),
(Flake8UsePathlib, "211") => (RuleGroup::Preview, rules::flake8_use_pathlib::violations::OsSymlink),
// flake8-logging-format
(Flake8LoggingFormat, "001") => (RuleGroup::Stable, rules::flake8_logging_format::violations::LoggingStringFormat),