diff --git a/CHANGELOG.md b/CHANGELOG.md index 72e74a1d55131..6a621b0c6fa1e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,25 @@ # Changelog +## 0.3.2 + +### Preview features + +- Improve single-`with` item formatting for Python 3.8 or older ([#10276](https://github.com/astral-sh/ruff/pull/10276)) + +### Rule changes + +- \[`pyupgrade`\] Allow fixes for f-string rule regardless of line length (`UP032`) ([#10263](https://github.com/astral-sh/ruff/pull/10263)) +- \[`pycodestyle`\] Include actual conditions in E712 diagnostics ([#10254](https://github.com/astral-sh/ruff/pull/10254)) + +### Bug fixes + +- Fix trailing kwargs end of line comment after slash ([#10297](https://github.com/astral-sh/ruff/pull/10297)) +- Fix unstable `with` items formatting ([#10274](https://github.com/astral-sh/ruff/pull/10274)) +- Avoid repeating function calls in f-string conversions ([#10265](https://github.com/astral-sh/ruff/pull/10265)) +- Fix E203 false positive for slices in format strings ([#10280](https://github.com/astral-sh/ruff/pull/10280)) +- Fix incorrect `Parameter` range for `*args` and `**kwargs` ([#10283](https://github.com/astral-sh/ruff/pull/10283)) +- Treat `typing.Annotated` subscripts as type definitions ([#10285](https://github.com/astral-sh/ruff/pull/10285)) + ## 0.3.1 ### Preview features diff --git a/Cargo.lock b/Cargo.lock index 1da6f891534b9..371e39a029989 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1950,7 +1950,7 @@ dependencies = [ [[package]] name = "ruff" -version = "0.3.1" +version = "0.3.2" dependencies = [ "anyhow", "argfile", @@ -2111,7 +2111,7 @@ dependencies = [ [[package]] name = "ruff_linter" -version = "0.3.1" +version = "0.3.2" dependencies = [ "aho-corasick", "annotate-snippets 0.9.2", @@ -2362,7 +2362,7 @@ dependencies = [ [[package]] name = "ruff_shrinking" -version = "0.3.1" +version = "0.3.2" dependencies = [ "anyhow", "clap", diff --git a/README.md b/README.md index 41f06b5f7696f..ba2f07901d0ff 100644 --- a/README.md +++ b/README.md @@ -151,7 +151,7 @@ Ruff can also be used as a [pre-commit](https://pre-commit.com/) hook via [`ruff ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.3.1 + rev: v0.3.2 hooks: # Run the linter. - id: ruff diff --git a/crates/ruff/Cargo.toml b/crates/ruff/Cargo.toml index e1e13a49cae9c..45c3bc3c0f007 100644 --- a/crates/ruff/Cargo.toml +++ b/crates/ruff/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ruff" -version = "0.3.1" +version = "0.3.2" publish = false authors = { workspace = true } edition = { workspace = true } diff --git a/crates/ruff_linter/Cargo.toml b/crates/ruff_linter/Cargo.toml index 8a45fe4b9f6fd..1c3ad68091334 100644 --- a/crates/ruff_linter/Cargo.toml +++ b/crates/ruff_linter/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ruff_linter" -version = "0.3.1" +version = "0.3.2" publish = false authors = { workspace = true } edition = { workspace = true } diff --git a/crates/ruff_shrinking/Cargo.toml b/crates/ruff_shrinking/Cargo.toml index b3075f482c5b5..24b3223a17866 100644 --- a/crates/ruff_shrinking/Cargo.toml +++ b/crates/ruff_shrinking/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ruff_shrinking" -version = "0.3.1" +version = "0.3.2" edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/docs/integrations.md b/docs/integrations.md index 437109d355bb7..45f393763e0c8 100644 --- a/docs/integrations.md +++ b/docs/integrations.md @@ -14,7 +14,7 @@ Ruff can be used as a [pre-commit](https://pre-commit.com) hook via [`ruff-pre-c ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.3.1 + rev: v0.3.2 hooks: # Run the linter. - id: ruff @@ -27,7 +27,7 @@ To enable lint fixes, add the `--fix` argument to the lint hook: ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.3.1 + rev: v0.3.2 hooks: # Run the linter. - id: ruff @@ -41,7 +41,7 @@ To run the hooks over Jupyter Notebooks too, add `jupyter` to the list of allowe ```yaml - repo: https://github.com/astral-sh/ruff-pre-commit # Ruff version. - rev: v0.3.1 + rev: v0.3.2 hooks: # Run the linter. - id: ruff diff --git a/pyproject.toml b/pyproject.toml index 1a0b2cf3a8fa5..b67cf40362466 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "maturin" [project] name = "ruff" -version = "0.3.1" +version = "0.3.2" description = "An extremely fast Python linter and code formatter, written in Rust." authors = [{ name = "Astral Software Inc.", email = "hey@astral.sh" }] readme = "README.md" diff --git a/scripts/benchmarks/pyproject.toml b/scripts/benchmarks/pyproject.toml index 51505ecbcdd5a..1ec5344b536bc 100644 --- a/scripts/benchmarks/pyproject.toml +++ b/scripts/benchmarks/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "scripts" -version = "0.3.1" +version = "0.3.2" description = "" authors = ["Charles Marsh "]