ruff
72c9f7e4 - Include actual conditions in E712 diagnostics (#10254)

Commit
1 year ago
Include actual conditions in E712 diagnostics (#10254) ## Summary Changes the generic recommendation to replace ```python if foo == True: ... ``` with `if cond:` to `if foo:`. Still uses a generic message for compound comparisons as a specific message starts to become confusing. For example, ```python if foo == True != False: ... ``` produces two recommendations, one of which would recommend `if True:`, which is confusing. Resolves [recommendation in a previous PR](https://github.com/astral-sh/ruff/pull/8613/files#r1514915070). ## Test Plan `cargo nextest run`
Author
Parents
Loading