Skip to content

Add TRIO110 rule#8537

Merged
charliermarsh merged 5 commits intoastral-sh:mainfrom
karpetrosyan:add-trio-110-suppor
Nov 7, 2023
Merged

Add TRIO110 rule#8537
charliermarsh merged 5 commits intoastral-sh:mainfrom
karpetrosyan:add-trio-110-suppor

Conversation

@karpetrosyan
Copy link
Contributor

@karpetrosyan karpetrosyan commented Nov 7, 2023

Summary

Adds TRIO110 from the flake8-trio plugin.
Relates to: #8451

@github-actions
Copy link
Contributor

github-actions bot commented Nov 7, 2023

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

✅ ecosystem check detected no linter changes.

Copy link
Member

@charliermarsh charliermarsh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, thank you!

}
}

pub(crate) fn unneeded_sleep(checker: &mut Checker, while_stmt: &ast::StmtWhile) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general, we prefer passing in the typed node (ast::StmtWhile instead of the individual properties of it, like body). That way, users can't accidentally pass an AST node of the wrong type.

@charliermarsh charliermarsh force-pushed the add-trio-110-suppor branch 4 times, most recently from fa98de6 to cdd9910 Compare November 7, 2023 21:19
@charliermarsh charliermarsh enabled auto-merge (squash) November 7, 2023 21:21
@charliermarsh charliermarsh merged commit 0126f74 into astral-sh:main Nov 7, 2023
@charliermarsh charliermarsh added rule Implementing or modifying a lint rule preview Related to preview mode features labels Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

preview Related to preview mode features rule Implementing or modifying a lint rule

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants