v0.0.245
版本发布时间: 2023-02-11 12:04:00
astral-sh/ruff最新发布版本:0.5.3(2024-07-19 01:10:02)
What's Changed
Breaking Changes
- Remove public Rust API by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2709
Rules
- [
flake8-pyi
]Add flake8-pyi with one rule by @sbdchd in https://github.com/charliermarsh/ruff/pull/2682 - [
pylint
]: bad-string-format-type by @colin99d in https://github.com/charliermarsh/ruff/pull/2572 - [
pylint
]: yield-in-init by @tomecki in https://github.com/charliermarsh/ruff/pull/2716 - [
flake8-tidy-imports
] Implement autofix for relative imports (TID252) by @sbrugman in https://github.com/charliermarsh/ruff/pull/2739 - [
flake8-bandit
]: try-except-continue by @colin99d in https://github.com/charliermarsh/ruff/pull/2674 - [
flake8-bandit
] Implement bandit's 'hardcoded-sql-expressions' S608 by @mattoberle in https://github.com/charliermarsh/ruff/pull/2698 - [
pycodestyle
] Implement compound-statements (E701, E702, E703, E704) by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2680
Settings
- feat(isort): Implement known-local-folder by @spaceone in https://github.com/charliermarsh/ruff/pull/2657
- Suppress parse errors with explicit
# noqa: E999
directives by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2697
Bug Fixes
- Support callable decorators in classmethod_decorators et al by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2675
- Avoid flagging typed exceptions in tuples by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2728
- Mark flake8-simplify rules as unfixable in non-fixable cases by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2676
- Treat re-exported annotations as used-at-runtime by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2689
- Gate
Path.readlink()
behind Python 3.9+ guard by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2708 - Handle functions that never return in RET503 (#2602) by @ppentchev in https://github.com/charliermarsh/ruff/pull/2701
- Handle more functions that never return in RET503 by @ngnpope in https://github.com/charliermarsh/ruff/pull/2719
- Expand S110 and S112 ranges to include entire exception handler by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2729
- Relax conditions in bad-string-format-type by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2731
- Mark
__all__
members as used at end-of-scope by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2733 - Only validate
__all__
bindings for global scope by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2738 - Only trigger compound statements after select keywords by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2737
- Use
function_type::classify
foryield-in-init
by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2742 - Allow named unicodes in bidirectional escape check by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2710
- Respect NO_COLOR flags in --show-source by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2750
- Flag private member accesses on calls et al by @charliermarsh in https://github.com/charliermarsh/ruff/pull/2753
New Contributors
- @ngnpope made their first contribution in https://github.com/charliermarsh/ruff/pull/2692
- @ppentchev made their first contribution in https://github.com/charliermarsh/ruff/pull/2701
- @tomecki made their first contribution in https://github.com/charliermarsh/ruff/pull/2716
Full Changelog: https://github.com/charliermarsh/ruff/compare/v0.0.244...v0.0.245