Skip to content

Commit 235cfb7

Browse files
Bump version to v0.2.2 (#10018)
1 parent 91ae81b commit 235cfb7

File tree

9 files changed

+73
-12
lines changed

9 files changed

+73
-12
lines changed

CHANGELOG.md

+61
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,66 @@
11
# Changelog
22

3+
## 0.2.2
4+
5+
Highlights include:
6+
7+
- Initial support formatting f-strings (in `--preview`).
8+
- Support for overriding arbitrary configuration options via the CLI through an expanded `--config`
9+
argument (e.g., `--config "lint.isort.combine-as-imports=false"`).
10+
- Significant performance improvements in Ruff's lexer, parser, and lint rules.
11+
12+
### Preview features
13+
14+
- Implement minimal f-string formatting ([#9642](https://github.com/astral-sh/ruff/pull/9642))
15+
- \[`pycodestyle`\] Add blank line(s) rules (`E301`, `E302`, `E303`, `E304`, `E305`, `E306`) ([#9266](https://github.com/astral-sh/ruff/pull/9266))
16+
- \[`refurb`\] Implement `readlines_in_for` (`FURB129`) ([#9880](https://github.com/astral-sh/ruff/pull/9880))
17+
18+
### Rule changes
19+
20+
- \[`ruff`\] Ensure closing parentheses for multiline sequences are always on their own line (`RUF022`, `RUF023`) ([#9793](https://github.com/astral-sh/ruff/pull/9793))
21+
- \[`numpy`\] Add missing deprecation violations (`NPY002`) ([#9862](https://github.com/astral-sh/ruff/pull/9862))
22+
- \[`flake8-bandit`\] Detect `mark_safe` usages in decorators ([#9887](https://github.com/astral-sh/ruff/pull/9887))
23+
- \[`ruff`\] Expand `asyncio-dangling-task` (`RUF006`) to include `new_event_loop` ([#9976](https://github.com/astral-sh/ruff/pull/9976))
24+
- \[`flake8-pyi`\] Ignore 'unused' private type dicts in class scopes ([#9952](https://github.com/astral-sh/ruff/pull/9952))
25+
26+
### Formatter
27+
28+
- Docstring formatting: Preserve tab indentation when using `indent-style=tabs` ([#9915](https://github.com/astral-sh/ruff/pull/9915))
29+
- Disable top-level docstring formatting for notebooks ([#9957](https://github.com/astral-sh/ruff/pull/9957))
30+
- Stabilize quote-style's `preserve` mode ([#9922](https://github.com/astral-sh/ruff/pull/9922))
31+
32+
### CLI
33+
34+
- Allow arbitrary configuration options to be overridden via the CLI ([#9599](https://github.com/astral-sh/ruff/pull/9599))
35+
36+
### Bug fixes
37+
38+
- Make `show-settings` filters directory-agnostic ([#9866](https://github.com/astral-sh/ruff/pull/9866))
39+
- Respect duplicates when rewriting type aliases ([#9905](https://github.com/astral-sh/ruff/pull/9905))
40+
- Respect tuple assignments in typing analyzer ([#9969](https://github.com/astral-sh/ruff/pull/9969))
41+
- Use atomic write when persisting cache ([#9981](https://github.com/astral-sh/ruff/pull/9981))
42+
- Use non-parenthesized range for `DebugText` ([#9953](https://github.com/astral-sh/ruff/pull/9953))
43+
- \[`flake8-simplify`\] Avoid false positive with `async` for loops (`SIM113`) ([#9996](https://github.com/astral-sh/ruff/pull/9996))
44+
- \[`flake8-trio`\] Respect `async with` in `timeout-without-await` ([#9859](https://github.com/astral-sh/ruff/pull/9859))
45+
- \[`perflint`\] Catch a wider range of mutations in `PERF101` ([#9955](https://github.com/astral-sh/ruff/pull/9955))
46+
- \[`pycodestyle`\] Fix `E30X` panics on blank lines with trailing white spaces ([#9907](https://github.com/astral-sh/ruff/pull/9907))
47+
- \[`pydocstyle`\] Allow using `parameters` as a subsection header (`D405`) ([#9894](https://github.com/astral-sh/ruff/pull/9894))
48+
- \[`pydocstyle`\] Fix blank-line docstring rules for module-level docstrings ([#9878](https://github.com/astral-sh/ruff/pull/9878))
49+
- \[`pylint`\] Accept 0.0 and 1.0 as common magic values (`PLR2004`) ([#9964](https://github.com/astral-sh/ruff/pull/9964))
50+
- \[`pylint`\] Avoid suggesting set rewrites for non-hashable types ([#9956](https://github.com/astral-sh/ruff/pull/9956))
51+
- \[`ruff`\] Avoid false negatives with string literals inside of method calls (`RUF027`) ([#9865](https://github.com/astral-sh/ruff/pull/9865))
52+
- \[`ruff`\] Fix panic on with f-string detection (`RUF027`) ([#9990](https://github.com/astral-sh/ruff/pull/9990))
53+
- \[`ruff`\] Ignore builtins when detecting missing f-strings ([#9849](https://github.com/astral-sh/ruff/pull/9849))
54+
55+
### Performance
56+
57+
- Use `memchr` for string lexing ([#9888](https://github.com/astral-sh/ruff/pull/9888))
58+
- Use `memchr` for tab-indentation detection ([#9853](https://github.com/astral-sh/ruff/pull/9853))
59+
- Reduce `Result<Tok, LexicalError>` size by using `Box<str>` instead of `String` ([#9885](https://github.com/astral-sh/ruff/pull/9885))
60+
- Reduce size of `Expr` from 80 to 64 bytes ([#9900](https://github.com/astral-sh/ruff/pull/9900))
61+
- Improve trailing comma rule performance ([#9867](https://github.com/astral-sh/ruff/pull/9867))
62+
- Remove unnecessary string cloning from the parser ([#9884](https://github.com/astral-sh/ruff/pull/9884))
63+
364
## 0.2.1
465

566
This release includes support for range formatting (i.e., the ability to format specific lines

Cargo.lock

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ Ruff can also be used as a [pre-commit](https://pre-commit.com/) hook via [`ruff
150150
```yaml
151151
- repo: https://github.com/astral-sh/ruff-pre-commit
152152
# Ruff version.
153-
rev: v0.2.1
153+
rev: v0.2.2
154154
hooks:
155155
# Run the linter.
156156
- id: ruff

crates/ruff/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "ruff"
3-
version = "0.2.1"
3+
version = "0.2.2"
44
publish = false
55
authors = { workspace = true }
66
edition = { workspace = true }

crates/ruff_linter/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "ruff_linter"
3-
version = "0.2.1"
3+
version = "0.2.2"
44
publish = false
55
authors = { workspace = true }
66
edition = { workspace = true }

crates/ruff_shrinking/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "ruff_shrinking"
3-
version = "0.2.1"
3+
version = "0.2.2"
44
edition = "2021"
55

66
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

docs/integrations.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Ruff can be used as a [pre-commit](https://pre-commit.com) hook via [`ruff-pre-c
1414
```yaml
1515
- repo: https://github.com/astral-sh/ruff-pre-commit
1616
# Ruff version.
17-
rev: v0.2.1
17+
rev: v0.2.2
1818
hooks:
1919
# Run the linter.
2020
- id: ruff
@@ -27,7 +27,7 @@ To enable lint fixes, add the `--fix` argument to the lint hook:
2727
```yaml
2828
- repo: https://github.com/astral-sh/ruff-pre-commit
2929
# Ruff version.
30-
rev: v0.2.1
30+
rev: v0.2.2
3131
hooks:
3232
# Run the linter.
3333
- id: ruff
@@ -41,7 +41,7 @@ To run the hooks over Jupyter Notebooks too, add `jupyter` to the list of allowe
4141
```yaml
4242
- repo: https://github.com/astral-sh/ruff-pre-commit
4343
# Ruff version.
44-
rev: v0.2.1
44+
rev: v0.2.2
4545
hooks:
4646
# Run the linter.
4747
- id: ruff

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "maturin"
44

55
[project]
66
name = "ruff"
7-
version = "0.2.1"
7+
version = "0.2.2"
88
description = "An extremely fast Python linter and code formatter, written in Rust."
99
authors = [{ name = "Astral Software Inc.", email = "[email protected]" }]
1010
readme = "README.md"

scripts/benchmarks/pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "scripts"
3-
version = "0.2.1"
3+
version = "0.2.2"
44
description = ""
55
authors = ["Charles Marsh <[email protected]>"]
66

0 commit comments

Comments
 (0)