Skip to content

Commit ed7b98c

Browse files
authored
Bump version to 0.7.4 (#14358)
1 parent 6591775 commit ed7b98c

File tree

9 files changed

+64
-15
lines changed

9 files changed

+64
-15
lines changed

CHANGELOG.md

+49
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,54 @@
11
# Changelog
22

3+
## 0.7.4
4+
5+
### Preview features
6+
7+
- \[`flake8-datetimez`\] Detect usages of `datetime.max`/`datetime.min` (`DTZ901`) ([#14288](https://github.com/astral-sh/ruff/pull/14288))
8+
- \[`flake8-logging`\] Implement `root-logger-calls` (`LOG015`) ([#14302](https://github.com/astral-sh/ruff/pull/14302))
9+
- \[`flake8-no-pep420`\] Detect empty implicit namespace packages (`INP001`) ([#14236](https://github.com/astral-sh/ruff/pull/14236))
10+
- \[`flake8-pyi`\] Add "replace with `Self`" fix (`PYI019`) ([#14238](https://github.com/astral-sh/ruff/pull/14238))
11+
- \[`perflint`\] Implement quick-fix for `manual-list-comprehension` (`PERF401`) ([#13919](https://github.com/astral-sh/ruff/pull/13919))
12+
- \[`pylint`\] Implement `shallow-copy-environ` (`W1507`) ([#14241](https://github.com/astral-sh/ruff/pull/14241))
13+
- \[`ruff`\] Implement `none-not-at-end-of-union` (`RUF036`) ([#14314](https://github.com/astral-sh/ruff/pull/14314))
14+
- \[`ruff`\] Implementation `unsafe-markup-call` from `flake8-markupsafe` plugin (`RUF035`) ([#14224](https://github.com/astral-sh/ruff/pull/14224))
15+
- \[`ruff`\] Report problems for `attrs` dataclasses (`RUF008`, `RUF009`) ([#14327](https://github.com/astral-sh/ruff/pull/14327))
16+
17+
### Rule changes
18+
19+
- \[`flake8-boolean-trap`\] Exclude dunder methods that define operators (`FBT001`) ([#14203](https://github.com/astral-sh/ruff/pull/14203))
20+
- \[`flake8-pyi`\] Add "replace with `Self`" fix (`PYI034`) ([#14217](https://github.com/astral-sh/ruff/pull/14217))
21+
- \[`flake8-pyi`\] Always autofix `duplicate-union-members` (`PYI016`) ([#14270](https://github.com/astral-sh/ruff/pull/14270))
22+
- \[`flake8-pyi`\] Improve autofix for nested and mixed type unions for `unnecessary-type-union` (`PYI055`) ([#14272](https://github.com/astral-sh/ruff/pull/14272))
23+
- \[`flake8-pyi`\] Mark fix as unsafe when type annotation contains comments for `duplicate-literal-member` (`PYI062`) ([#14268](https://github.com/astral-sh/ruff/pull/14268))
24+
25+
### Server
26+
27+
- Use the current working directory to resolve settings from `ruff.configuration` ([#14352](https://github.com/astral-sh/ruff/pull/14352))
28+
29+
### Bug fixes
30+
31+
- Avoid conflicts between `PLC014` (`useless-import-alias`) and `I002` (`missing-required-import`) by considering `lint.isort.required-imports` for `PLC014` ([#14287](https://github.com/astral-sh/ruff/pull/14287))
32+
- \[`flake8-type-checking`\] Skip quoting annotation if it becomes invalid syntax (`TCH001`)
33+
- \[`flake8-pyi`\] Avoid using `typing.Self` in stub files pre-Python 3.11 (`PYI034`) ([#14230](https://github.com/astral-sh/ruff/pull/14230))
34+
- \[`flake8-pytest-style`\] Flag `pytest.raises` call with keyword argument `expected_exception` (`PT011`) ([#14298](https://github.com/astral-sh/ruff/pull/14298))
35+
- \[`flake8-simplify`\] Infer "unknown" truthiness for literal iterables whose items are all unpacks (`SIM222`) ([#14263](https://github.com/astral-sh/ruff/pull/14263))
36+
- \[`flake8-type-checking`\] Fix false positives for `typing.Annotated` (`TCH001`) ([#14311](https://github.com/astral-sh/ruff/pull/14311))
37+
- \[`pylint`\] Allow `await` at the top-level scope of a notebook (`PLE1142`) ([#14225](https://github.com/astral-sh/ruff/pull/14225))
38+
- \[`pylint`\] Fix miscellaneous issues in `await-outside-async` detection (`PLE1142`) ([#14218](https://github.com/astral-sh/ruff/pull/14218))
39+
- \[`pyupgrade`\] Avoid applying PEP 646 rewrites in invalid contexts (`UP044`) ([#14234](https://github.com/astral-sh/ruff/pull/14234))
40+
- \[`pyupgrade`\] Detect permutations in redundant open modes (`UP015`) ([#14255](https://github.com/astral-sh/ruff/pull/14255))
41+
- \[`refurb`\] Avoid triggering `hardcoded-string-charset` for reordered sets (`FURB156`) ([#14233](https://github.com/astral-sh/ruff/pull/14233))
42+
- \[`refurb`\] Further special cases added to `verbose-decimal-constructor` (`FURB157`) ([#14216](https://github.com/astral-sh/ruff/pull/14216))
43+
- \[`refurb`\] Use `UserString` instead of non-existent `UserStr` (`FURB189`) ([#14209](https://github.com/astral-sh/ruff/pull/14209))
44+
- \[`ruff`\] Avoid treating lowercase letters as `# noqa` codes (`RUF100`) ([#14229](https://github.com/astral-sh/ruff/pull/14229))
45+
- \[`ruff`\] Do not report when `Optional` has no type arguments (`RUF013`) ([#14181](https://github.com/astral-sh/ruff/pull/14181))
46+
47+
### Documentation
48+
49+
- Add "Notebook behavior" section for `F704`, `PLE1142` ([#14266](https://github.com/astral-sh/ruff/pull/14266))
50+
- Document comment policy around fix safety ([#14300](https://github.com/astral-sh/ruff/pull/14300))
51+
352
## 0.7.3
453

554
### Preview features

Cargo.lock

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

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,8 @@ curl -LsSf https://astral.sh/ruff/install.sh | sh
136136
powershell -c "irm https://astral.sh/ruff/install.ps1 | iex"
137137

138138
# For a specific version.
139-
curl -LsSf https://astral.sh/ruff/0.7.3/install.sh | sh
140-
powershell -c "irm https://astral.sh/ruff/0.7.3/install.ps1 | iex"
139+
curl -LsSf https://astral.sh/ruff/0.7.4/install.sh | sh
140+
powershell -c "irm https://astral.sh/ruff/0.7.4/install.ps1 | iex"
141141
```
142142

143143
You can also install Ruff via [Homebrew](https://formulae.brew.sh/formula/ruff), [Conda](https://anaconda.org/conda-forge/ruff),
@@ -170,7 +170,7 @@ Ruff can also be used as a [pre-commit](https://pre-commit.com/) hook via [`ruff
170170
```yaml
171171
- repo: https://github.com/astral-sh/ruff-pre-commit
172172
# Ruff version.
173-
rev: v0.7.3
173+
rev: v0.7.4
174174
hooks:
175175
# Run the linter.
176176
- 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.7.3"
3+
version = "0.7.4"
44
publish = true
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.7.3"
3+
version = "0.7.4"
44
publish = false
55
authors = { workspace = true }
66
edition = { workspace = true }

crates/ruff_wasm/Cargo.toml

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

docs/integrations.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ You can add the following configuration to `.gitlab-ci.yml` to run a `ruff forma
8080
stage: build
8181
interruptible: true
8282
image:
83-
name: ghcr.io/astral-sh/ruff:0.7.3-alpine
83+
name: ghcr.io/astral-sh/ruff:0.7.4-alpine
8484
before_script:
8585
- cd $CI_PROJECT_DIR
8686
- ruff --version
@@ -106,7 +106,7 @@ Ruff can be used as a [pre-commit](https://pre-commit.com) hook via [`ruff-pre-c
106106
```yaml
107107
- repo: https://github.com/astral-sh/ruff-pre-commit
108108
# Ruff version.
109-
rev: v0.7.3
109+
rev: v0.7.4
110110
hooks:
111111
# Run the linter.
112112
- id: ruff
@@ -119,7 +119,7 @@ To enable lint fixes, add the `--fix` argument to the lint hook:
119119
```yaml
120120
- repo: https://github.com/astral-sh/ruff-pre-commit
121121
# Ruff version.
122-
rev: v0.7.3
122+
rev: v0.7.4
123123
hooks:
124124
# Run the linter.
125125
- id: ruff
@@ -133,7 +133,7 @@ To run the hooks over Jupyter Notebooks too, add `jupyter` to the list of allowe
133133
```yaml
134134
- repo: https://github.com/astral-sh/ruff-pre-commit
135135
# Ruff version.
136-
rev: v0.7.3
136+
rev: v0.7.4
137137
hooks:
138138
# Run the linter.
139139
- 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.7.3"
7+
version = "0.7.4"
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.7.3"
3+
version = "0.7.4"
44
description = ""
55
authors = ["Charles Marsh <[email protected]>"]
66

0 commit comments

Comments
 (0)