Skip to content

[perflint] Add PERF403#6132

Merged
charliermarsh merged 18 commits intoastral-sh:mainfrom
qdegraaf:feature/PERF403
Sep 15, 2023
Merged

[perflint] Add PERF403#6132
charliermarsh merged 18 commits intoastral-sh:mainfrom
qdegraaf:feature/PERF403

Conversation

@qdegraaf
Copy link
Contributor

@qdegraaf qdegraaf commented Jul 27, 2023

Summary

Reopening of #5313

One open question as described in #5313 (comment)

FYI previous reviewers: @MichaReiser @dhruvmanila @charliermarsh

Old Description

Summary

Adds PERF403 mirroring W8403 from https://github.com/tonybaloney/perflint

Test Plan

Fixtures were added based on perflint tests

Issue Links

Refers: #4789

@github-actions
Copy link
Contributor

github-actions bot commented Jul 27, 2023

PR Check Results

Ecosystem

ℹ️ ecosystem check detected changes. (+22, -0, 0 error(s))

airflow (+5, -0)

+ airflow/providers/cncf/kubernetes/executors/kubernetes_executor_utils.py:163:17: PERF403 Use a dictionary comprehension instead of a for-loop
+ airflow/providers/exasol/hooks/exasol.py:68:17: PERF403 Use a dictionary comprehension instead of a for-loop
+ airflow/providers/mysql/hooks/mysql.py:170:17: PERF403 Use a dictionary comprehension instead of a for-loop
+ airflow/providers/postgres/hooks/postgres.py:153:17: PERF403 Use a dictionary comprehension instead of a for-loop
+ tests/providers/apache/spark/hooks/test_spark_submit.py:72:17: PERF403 Use a dictionary comprehension instead of a for-loop

rotki (+3, -0)

+ rotkehlchen/api/rest.py:506:13: PERF403 Use a dictionary comprehension instead of a for-loop
+ rotkehlchen/globaldb/handler.py:899:17: PERF403 Use a dictionary comprehension instead of a for-loop
+ rotkehlchen/tests/utils/database.py:104:13: PERF403 Use a dictionary comprehension instead of a for-loop

sphinx (+13, -0)

+ 
+    |
+    |             ^^^^^^^^^^^^ PERF403
+ 28 |     for info in reversed(list(request.node.iter_markers("apidoc"))):
+ 29 |         for i, a in enumerate(info.args):
+ 30 |             pargs[i] = a
+ 31 |         kwargs.update(info.kwargs)
+ 76 |     for info in reversed(list(request.node.iter_markers("sphinx"))):
+ 77 |         for i, a in enumerate(info.args):
+ 78 |             pargs[i] = a
+ 79 |         kwargs.update(info.kwargs)
+ sphinx/testing/fixtures.py:78:13: PERF403 Use a dictionary comprehension instead of a for-loop
+ tests/test_ext_apidoc.py:30:13: PERF403 Use a dictionary comprehension instead of a for-loop

zulip (+1, -0)

+ analytics/views/stats.py:456:9: PERF403 Use a dictionary comprehension instead of a for-loop

Rules changed: 1
Rule Changes Additions Removals
PERF403 11 11 0

@qdegraaf qdegraaf marked this pull request as draft July 27, 2023 17:25
@charliermarsh
Copy link
Member

We can probably implement this more confidently now by leveraging some of the basic type inference stuff added in the refurb module.

@qdegraaf
Copy link
Contributor Author

Awesome! I'll see if I can find some time next week to look at that and implement it in this PR

@charliermarsh
Copy link
Member

Sounds good! We'll need to pull the stuff out of refurb/helpers.rs into (probably) ruff_python_semantic::analyzers::typing.

@qdegraaf
Copy link
Contributor Author

qdegraaf commented Aug 29, 2023

Is that just a simple copy paste to ruff_python_semantic and reimport in the refurb module? If so I'll open a separate PR for that and then rebase this one. That will unblock other people from picking this up if they beat me to it and/or any other PRs where I'm sure basic type inference will be very useful.

charliermarsh pushed a commit that referenced this pull request Aug 29, 2023
…#6990)

## Summary

The utils added for `refurb` in its `helpers.rs` file could be useful
for many other plugins. (Such as the PERF4XX codes, see e.g.
#6132 ).

This PR moves them to `ruff_python_semantic::analyzers::typing` as
suggested in
#6132 (comment)

## Test Plan

Confirmed `refurb` and all other tests still work
@qdegraaf
Copy link
Contributor Author

qdegraaf commented Aug 29, 2023

I've added the dict check and also excluded if/elif/else comprehensions from the check. Upstream plugin does this as well (I misread the tests upon first implementation). Still need to find some time to implement the heuristic for checking if the dict is empty before the loop.

@charliermarsh For the if/elif/else check I misread upstream for PERF401 as well. Will open a small PR to fix that, can see if adding the type inference there (and PERF402 as well) has added value too.

EDIT: Someone beat me to it,. the fixtures were just still flagged wrong.

@charliermarsh charliermarsh added the rule Implementing or modifying a lint rule label Aug 30, 2023
@charliermarsh charliermarsh marked this pull request as ready for review August 30, 2023 04:20
@charliermarsh charliermarsh force-pushed the feature/PERF403 branch 2 times, most recently from 430ce0d to c62af56 Compare August 30, 2023 04:23
@charliermarsh charliermarsh enabled auto-merge (squash) September 15, 2023 01:15
@charliermarsh charliermarsh merged commit 067a4ac into astral-sh:main Sep 15, 2023
@qdegraaf qdegraaf deleted the feature/PERF403 branch September 15, 2023 15:32
renovate bot referenced this pull request in ixm-one/pytest-cmake-presets Sep 15, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [ruff](https://beta.ruff.rs/docs)
([source](https://togithub.com/astral-sh/ruff),
[changelog](https://togithub.com/astral-sh/ruff/releases)) | `^0.0.289`
-> `^0.0.290` |
[![age](https://developer.mend.io/api/mc/badges/age/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/ruff/0.0.289/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/ruff/0.0.289/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### ⚠ Dependency Lookup Warnings ⚠

Warnings were logged while processing this repo. Please check the logs
for more information.

---

### Release Notes

<details>
<summary>astral-sh/ruff (ruff)</summary>

###
[`v0.0.290`](https://togithub.com/astral-sh/ruff/releases/tag/v0.0.290)

[Compare
Source](https://togithub.com/astral-sh/ruff/compare/v0.0.289...v0.0.290)

<!-- Release notes generated using configuration in .github/release.yml
at v0.0.290 -->

#### What's Changed

##### Rules

- Update `deprecated-import` lists based on recent `typing-extensions`
release by [@&#8203;charliermarsh](https://togithub.com/charliermarsh)
in
[https://github.com/astral-sh/ruff/pull/7356](https://togithub.com/astral-sh/ruff/pull/7356)
- Add support for bounds, constraints, and explicit variance on generic
type variables to `UP040` by
[@&#8203;nathanwhit](https://togithub.com/nathanwhit) in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

##### Settings

- Show rule codes in shell tab completion by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7375](https://togithub.com/astral-sh/ruff/pull/7375)

##### Bug Fixes

- Parenthesize single-generator arguments when adding reverse keyword by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7365](https://togithub.com/astral-sh/ruff/pull/7365)
- Invert reverse argument regardless of whether it's a boolean by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7372](https://togithub.com/astral-sh/ruff/pull/7372)
- Extend `C416` to catch tuple unpacking by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7363](https://togithub.com/astral-sh/ruff/pull/7363)
- Allow `NURSERY` rule selctor in JSON Schema by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7374](https://togithub.com/astral-sh/ruff/pull/7374)
- Avoid flagging single-quoted docstrings with continuations for
multi-line rules by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7392](https://togithub.com/astral-sh/ruff/pull/7392)
- Treat whitespace-only line as blank for `D411` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7351](https://togithub.com/astral-sh/ruff/pull/7351)

##### Preview

[*What's this section?*](https://beta.ruff.rs/docs/preview/)

- \[`flake8-logging`] New rule `undocumented-warn` (`LOG009`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`flake8-logging`] New rule `direct-logger-instantiation` (`LOG001`)
by [@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7397](https://togithub.com/astral-sh/ruff/pull/7397)
- \[`flake8-logging`] New plugin `flake8_logging` (`LOG`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`perflint`] Add `manual-dict-comprehsion` (`PERF403`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/6132](https://togithub.com/astral-sh/ruff/pull/6132)
- \[`pylint`] New rule `too-many-public-methods` (`PLR0904`) by
[@&#8203;jelly](https://togithub.com/jelly) in
[https://github.com/astral-sh/ruff/pull/6179](https://togithub.com/astral-sh/ruff/pull/6179)
- \[`refurb`] New rule `no-slice-copy` (`FURB145`) by
[@&#8203;tjkuson](https://togithub.com/tjkuson) in
[https://github.com/astral-sh/ruff/pull/7007](https://togithub.com/astral-sh/ruff/pull/7007)
- Add warnings for nursery and preview rule selection by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7210](https://togithub.com/astral-sh/ruff/pull/7210)
- Remove the `PREVIEW` rule selector by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7389](https://togithub.com/astral-sh/ruff/pull/7389)
- [`pre-commit`
support](https://togithub.com/astral-sh/ruff-pre-commit#using-ruffs-formatter-unstable)
for the [alpha
formatter](https://togithub.com/astral-sh/ruff/discussions/7310) by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff-pre-commit/pull/50](https://togithub.com/astral-sh/ruff-pre-commit/pull/50)

#### New Contributors

- [@&#8203;nathanwhit](https://togithub.com/nathanwhit) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

**Full Changelog**:
astral-sh/ruff@v0.0.289...v0.0.290

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/ixm-one/pytest-cmake-presets).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi44My4wIiwidXBkYXRlZEluVmVyIjoiMzYuODMuMCIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
renovate bot referenced this pull request in spiraldb/ziggy-pydust Sep 16, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [ruff](https://beta.ruff.rs/docs)
([source](https://togithub.com/astral-sh/ruff),
[changelog](https://togithub.com/astral-sh/ruff/releases)) | `^0.0.289`
-> `^0.0.290` |
[![age](https://developer.mend.io/api/mc/badges/age/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/ruff/0.0.289/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/ruff/0.0.289/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>astral-sh/ruff (ruff)</summary>

###
[`v0.0.290`](https://togithub.com/astral-sh/ruff/releases/tag/v0.0.290)

[Compare
Source](https://togithub.com/astral-sh/ruff/compare/v0.0.289...v0.0.290)

<!-- Release notes generated using configuration in .github/release.yml
at v0.0.290 -->

#### What's Changed

##### Rules

- Update `deprecated-import` lists based on recent `typing-extensions`
release by [@&#8203;charliermarsh](https://togithub.com/charliermarsh)
in
[https://github.com/astral-sh/ruff/pull/7356](https://togithub.com/astral-sh/ruff/pull/7356)
- Add support for bounds, constraints, and explicit variance on generic
type variables to `UP040` by
[@&#8203;nathanwhit](https://togithub.com/nathanwhit) in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

##### Settings

- Show rule codes in shell tab completion by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7375](https://togithub.com/astral-sh/ruff/pull/7375)

##### Bug Fixes

- Parenthesize single-generator arguments when adding reverse keyword by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7365](https://togithub.com/astral-sh/ruff/pull/7365)
- Invert reverse argument regardless of whether it's a boolean by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7372](https://togithub.com/astral-sh/ruff/pull/7372)
- Extend `C416` to catch tuple unpacking by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7363](https://togithub.com/astral-sh/ruff/pull/7363)
- Allow `NURSERY` rule selctor in JSON Schema by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7374](https://togithub.com/astral-sh/ruff/pull/7374)
- Avoid flagging single-quoted docstrings with continuations for
multi-line rules by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7392](https://togithub.com/astral-sh/ruff/pull/7392)
- Treat whitespace-only line as blank for `D411` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7351](https://togithub.com/astral-sh/ruff/pull/7351)

##### Preview

[*What's this section?*](https://beta.ruff.rs/docs/preview/)

- \[`flake8-logging`] New rule `undocumented-warn` (`LOG009`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`flake8-logging`] New rule `direct-logger-instantiation` (`LOG001`)
by [@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7397](https://togithub.com/astral-sh/ruff/pull/7397)
- \[`flake8-logging`] New plugin `flake8_logging` (`LOG`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`perflint`] Add `manual-dict-comprehsion` (`PERF403`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/6132](https://togithub.com/astral-sh/ruff/pull/6132)
- \[`pylint`] New rule `too-many-public-methods` (`PLR0904`) by
[@&#8203;jelly](https://togithub.com/jelly) in
[https://github.com/astral-sh/ruff/pull/6179](https://togithub.com/astral-sh/ruff/pull/6179)
- \[`refurb`] New rule `no-slice-copy` (`FURB145`) by
[@&#8203;tjkuson](https://togithub.com/tjkuson) in
[https://github.com/astral-sh/ruff/pull/7007](https://togithub.com/astral-sh/ruff/pull/7007)
- Add warnings for nursery and preview rule selection by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7210](https://togithub.com/astral-sh/ruff/pull/7210)
- Remove the `PREVIEW` rule selector by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7389](https://togithub.com/astral-sh/ruff/pull/7389)
- [`pre-commit`
support](https://togithub.com/astral-sh/ruff-pre-commit#using-ruffs-formatter-unstable)
for the [alpha
formatter](https://togithub.com/astral-sh/ruff/discussions/7310) by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff-pre-commit/pull/50](https://togithub.com/astral-sh/ruff-pre-commit/pull/50)

#### New Contributors

- [@&#8203;nathanwhit](https://togithub.com/nathanwhit) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

**Full Changelog**:
astral-sh/ruff@v0.0.289...v0.0.290

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/fulcrum-so/ziggy-pydust).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi44My4wIiwidXBkYXRlZEluVmVyIjoiMzYuODMuMCIsInRhcmdldEJyYW5jaCI6ImRldmVsb3AifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
renovate bot referenced this pull request in allenporter/flux-local Sep 17, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [ruff](https://beta.ruff.rs/docs)
([source](https://togithub.com/astral-sh/ruff),
[changelog](https://togithub.com/astral-sh/ruff/releases)) | `==0.0.289`
-> `==0.0.290` |
[![age](https://developer.mend.io/api/mc/badges/age/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/ruff/0.0.289/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/ruff/0.0.289/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>astral-sh/ruff (ruff)</summary>

###
[`v0.0.290`](https://togithub.com/astral-sh/ruff/releases/tag/v0.0.290)

[Compare
Source](https://togithub.com/astral-sh/ruff/compare/v0.0.289...v0.0.290)

<!-- Release notes generated using configuration in .github/release.yml
at v0.0.290 -->

#### What's Changed

##### Rules

- Update `deprecated-import` lists based on recent `typing-extensions`
release by [@&#8203;charliermarsh](https://togithub.com/charliermarsh)
in
[https://github.com/astral-sh/ruff/pull/7356](https://togithub.com/astral-sh/ruff/pull/7356)
- Add support for bounds, constraints, and explicit variance on generic
type variables to `UP040` by
[@&#8203;nathanwhit](https://togithub.com/nathanwhit) in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

##### Settings

- Show rule codes in shell tab completion by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7375](https://togithub.com/astral-sh/ruff/pull/7375)

##### Bug Fixes

- Parenthesize single-generator arguments when adding reverse keyword by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7365](https://togithub.com/astral-sh/ruff/pull/7365)
- Invert reverse argument regardless of whether it's a boolean by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7372](https://togithub.com/astral-sh/ruff/pull/7372)
- Extend `C416` to catch tuple unpacking by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7363](https://togithub.com/astral-sh/ruff/pull/7363)
- Allow `NURSERY` rule selctor in JSON Schema by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7374](https://togithub.com/astral-sh/ruff/pull/7374)
- Avoid flagging single-quoted docstrings with continuations for
multi-line rules by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7392](https://togithub.com/astral-sh/ruff/pull/7392)
- Treat whitespace-only line as blank for `D411` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7351](https://togithub.com/astral-sh/ruff/pull/7351)

##### Preview

[*What's this section?*](https://beta.ruff.rs/docs/preview/)

- \[`flake8-logging`] New rule `undocumented-warn` (`LOG009`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`flake8-logging`] New rule `direct-logger-instantiation` (`LOG001`)
by [@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7397](https://togithub.com/astral-sh/ruff/pull/7397)
- \[`flake8-logging`] New plugin `flake8_logging` (`LOG`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`perflint`] Add `manual-dict-comprehsion` (`PERF403`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/6132](https://togithub.com/astral-sh/ruff/pull/6132)
- \[`pylint`] New rule `too-many-public-methods` (`PLR0904`) by
[@&#8203;jelly](https://togithub.com/jelly) in
[https://github.com/astral-sh/ruff/pull/6179](https://togithub.com/astral-sh/ruff/pull/6179)
- \[`refurb`] New rule `no-slice-copy` (`FURB145`) by
[@&#8203;tjkuson](https://togithub.com/tjkuson) in
[https://github.com/astral-sh/ruff/pull/7007](https://togithub.com/astral-sh/ruff/pull/7007)
- Add warnings for nursery and preview rule selection by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7210](https://togithub.com/astral-sh/ruff/pull/7210)
- Remove the `PREVIEW` rule selector by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7389](https://togithub.com/astral-sh/ruff/pull/7389)
- [`pre-commit`
support](https://togithub.com/astral-sh/ruff-pre-commit#using-ruffs-formatter-unstable)
for the [alpha
formatter](https://togithub.com/astral-sh/ruff/discussions/7310) by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff-pre-commit/pull/50](https://togithub.com/astral-sh/ruff-pre-commit/pull/50)

#### New Contributors

- [@&#8203;nathanwhit](https://togithub.com/nathanwhit) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

**Full Changelog**:
astral-sh/ruff@v0.0.289...v0.0.290

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/allenporter/flux-local).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi44My4wIiwidXBkYXRlZEluVmVyIjoiMzYuODMuMCIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
renovate bot referenced this pull request in allenporter/pyrainbird Sep 17, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [ruff](https://beta.ruff.rs/docs)
([source](https://togithub.com/astral-sh/ruff),
[changelog](https://togithub.com/astral-sh/ruff/releases)) | `==0.0.289`
-> `==0.0.290` |
[![age](https://developer.mend.io/api/mc/badges/age/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/ruff/0.0.289/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/ruff/0.0.289/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>astral-sh/ruff (ruff)</summary>

###
[`v0.0.290`](https://togithub.com/astral-sh/ruff/releases/tag/v0.0.290)

[Compare
Source](https://togithub.com/astral-sh/ruff/compare/v0.0.289...v0.0.290)

<!-- Release notes generated using configuration in .github/release.yml
at v0.0.290 -->

#### What's Changed

##### Rules

- Update `deprecated-import` lists based on recent `typing-extensions`
release by [@&#8203;charliermarsh](https://togithub.com/charliermarsh)
in
[https://github.com/astral-sh/ruff/pull/7356](https://togithub.com/astral-sh/ruff/pull/7356)
- Add support for bounds, constraints, and explicit variance on generic
type variables to `UP040` by
[@&#8203;nathanwhit](https://togithub.com/nathanwhit) in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

##### Settings

- Show rule codes in shell tab completion by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7375](https://togithub.com/astral-sh/ruff/pull/7375)

##### Bug Fixes

- Parenthesize single-generator arguments when adding reverse keyword by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7365](https://togithub.com/astral-sh/ruff/pull/7365)
- Invert reverse argument regardless of whether it's a boolean by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7372](https://togithub.com/astral-sh/ruff/pull/7372)
- Extend `C416` to catch tuple unpacking by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7363](https://togithub.com/astral-sh/ruff/pull/7363)
- Allow `NURSERY` rule selctor in JSON Schema by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7374](https://togithub.com/astral-sh/ruff/pull/7374)
- Avoid flagging single-quoted docstrings with continuations for
multi-line rules by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7392](https://togithub.com/astral-sh/ruff/pull/7392)
- Treat whitespace-only line as blank for `D411` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7351](https://togithub.com/astral-sh/ruff/pull/7351)

##### Preview

[*What's this section?*](https://beta.ruff.rs/docs/preview/)

- \[`flake8-logging`] New rule `undocumented-warn` (`LOG009`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`flake8-logging`] New rule `direct-logger-instantiation` (`LOG001`)
by [@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7397](https://togithub.com/astral-sh/ruff/pull/7397)
- \[`flake8-logging`] New plugin `flake8_logging` (`LOG`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`perflint`] Add `manual-dict-comprehsion` (`PERF403`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/6132](https://togithub.com/astral-sh/ruff/pull/6132)
- \[`pylint`] New rule `too-many-public-methods` (`PLR0904`) by
[@&#8203;jelly](https://togithub.com/jelly) in
[https://github.com/astral-sh/ruff/pull/6179](https://togithub.com/astral-sh/ruff/pull/6179)
- \[`refurb`] New rule `no-slice-copy` (`FURB145`) by
[@&#8203;tjkuson](https://togithub.com/tjkuson) in
[https://github.com/astral-sh/ruff/pull/7007](https://togithub.com/astral-sh/ruff/pull/7007)
- Add warnings for nursery and preview rule selection by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7210](https://togithub.com/astral-sh/ruff/pull/7210)
- Remove the `PREVIEW` rule selector by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7389](https://togithub.com/astral-sh/ruff/pull/7389)
- [`pre-commit`
support](https://togithub.com/astral-sh/ruff-pre-commit#using-ruffs-formatter-unstable)
for the [alpha
formatter](https://togithub.com/astral-sh/ruff/discussions/7310) by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff-pre-commit/pull/50](https://togithub.com/astral-sh/ruff-pre-commit/pull/50)

#### New Contributors

- [@&#8203;nathanwhit](https://togithub.com/nathanwhit) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

**Full Changelog**:
astral-sh/ruff@v0.0.289...v0.0.290

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/allenporter/pyrainbird).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi44My4wIiwidXBkYXRlZEluVmVyIjoiMzYuODMuMCIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
delta003 referenced this pull request in spiraldb/ziggy-pydust-template Sep 17, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [ruff](https://beta.ruff.rs/docs)
([source](https://togithub.com/astral-sh/ruff),
[changelog](https://togithub.com/astral-sh/ruff/releases)) | `^0.0.286`
-> `^0.0.290` |
[![age](https://developer.mend.io/api/mc/badges/age/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/ruff/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/ruff/0.0.286/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/ruff/0.0.286/0.0.290?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>astral-sh/ruff (ruff)</summary>

###
[`v0.0.290`](https://togithub.com/astral-sh/ruff/releases/tag/v0.0.290)

[Compare
Source](https://togithub.com/astral-sh/ruff/compare/v0.0.289...v0.0.290)

<!-- Release notes generated using configuration in .github/release.yml
at v0.0.290 -->

#### What's Changed

##### Rules

- Update `deprecated-import` lists based on recent `typing-extensions`
release by [@&#8203;charliermarsh](https://togithub.com/charliermarsh)
in
[https://github.com/astral-sh/ruff/pull/7356](https://togithub.com/astral-sh/ruff/pull/7356)
- Add support for bounds, constraints, and explicit variance on generic
type variables to `UP040` by
[@&#8203;nathanwhit](https://togithub.com/nathanwhit) in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

##### Settings

- Show rule codes in shell tab completion by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7375](https://togithub.com/astral-sh/ruff/pull/7375)

##### Bug Fixes

- Parenthesize single-generator arguments when adding reverse keyword by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7365](https://togithub.com/astral-sh/ruff/pull/7365)
- Invert reverse argument regardless of whether it's a boolean by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7372](https://togithub.com/astral-sh/ruff/pull/7372)
- Extend `C416` to catch tuple unpacking by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7363](https://togithub.com/astral-sh/ruff/pull/7363)
- Allow `NURSERY` rule selctor in JSON Schema by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7374](https://togithub.com/astral-sh/ruff/pull/7374)
- Avoid flagging single-quoted docstrings with continuations for
multi-line rules by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7392](https://togithub.com/astral-sh/ruff/pull/7392)
- Treat whitespace-only line as blank for `D411` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7351](https://togithub.com/astral-sh/ruff/pull/7351)

##### Preview

[*What's this section?*](https://beta.ruff.rs/docs/preview/)

- \[`flake8-logging`] New rule `undocumented-warn` (`LOG009`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`flake8-logging`] New rule `direct-logger-instantiation` (`LOG001`)
by [@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7397](https://togithub.com/astral-sh/ruff/pull/7397)
- \[`flake8-logging`] New plugin `flake8_logging` (`LOG`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/7249](https://togithub.com/astral-sh/ruff/pull/7249)
- \[`perflint`] Add `manual-dict-comprehsion` (`PERF403`) by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/6132](https://togithub.com/astral-sh/ruff/pull/6132)
- \[`pylint`] New rule `too-many-public-methods` (`PLR0904`) by
[@&#8203;jelly](https://togithub.com/jelly) in
[https://github.com/astral-sh/ruff/pull/6179](https://togithub.com/astral-sh/ruff/pull/6179)
- \[`refurb`] New rule `no-slice-copy` (`FURB145`) by
[@&#8203;tjkuson](https://togithub.com/tjkuson) in
[https://github.com/astral-sh/ruff/pull/7007](https://togithub.com/astral-sh/ruff/pull/7007)
- Add warnings for nursery and preview rule selection by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7210](https://togithub.com/astral-sh/ruff/pull/7210)
- Remove the `PREVIEW` rule selector by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7389](https://togithub.com/astral-sh/ruff/pull/7389)
- [`pre-commit`
support](https://togithub.com/astral-sh/ruff-pre-commit#using-ruffs-formatter-unstable)
for the [alpha
formatter](https://togithub.com/astral-sh/ruff/discussions/7310) by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff-pre-commit/pull/50](https://togithub.com/astral-sh/ruff-pre-commit/pull/50)

#### New Contributors

- [@&#8203;nathanwhit](https://togithub.com/nathanwhit) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/6749](https://togithub.com/astral-sh/ruff/pull/6749)

**Full Changelog**:
astral-sh/ruff@v0.0.289...v0.0.290

###
[`v0.0.289`](https://togithub.com/astral-sh/ruff/releases/tag/v0.0.289)

[Compare
Source](https://togithub.com/astral-sh/ruff/compare/v0.0.288...v0.0.289)

<!-- Release notes generated using configuration in .github/release.yml
at v0.0.289 -->

#### What's Changed

##### Bug Fixes

- Invert condition for < and <= in outdated version block by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7284](https://togithub.com/astral-sh/ruff/pull/7284)
- Ignore `@override` method when enforcing `bad-dunder-name` rule by
[@&#8203;brendonh8](https://togithub.com/brendonh8) in
[https://github.com/astral-sh/ruff/pull/7224](https://togithub.com/astral-sh/ruff/pull/7224)
- Add `NotebookIndex` to the cache by
[@&#8203;dhruvmanila](https://togithub.com/dhruvmanila) in
[https://github.com/astral-sh/ruff/pull/6863](https://togithub.com/astral-sh/ruff/pull/6863)

##### Preview

This release includes a new preview mode which can be used to opt-in to
unstable rules and features.

- Update rule selection to respect preview mode by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7195](https://togithub.com/astral-sh/ruff/pull/7195)
- Display the `--preview` option in the CLI help menu by
[@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7274](https://togithub.com/astral-sh/ruff/pull/7274)

See the [documentation](https://beta.ruff.rs/docs/preview/) and
[versioning
discussion](https://togithub.com/astral-sh/ruff/discussions/6998) for
more details.

#### New Contributors

- [@&#8203;brendonh8](https://togithub.com/brendonh8) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/7224](https://togithub.com/astral-sh/ruff/pull/7224)

**Full Changelog**:
astral-sh/ruff@v0.0.288...v0.0.289

###
[`v0.0.288`](https://togithub.com/astral-sh/ruff/releases/tag/v0.0.288)

[Compare
Source](https://togithub.com/astral-sh/ruff/compare/v0.0.287...v0.0.288)

#### What's Changed

##### Breaking Changes

- Remove emoji identifier support by
[@&#8203;MichaReiser](https://togithub.com/MichaReiser) in
[https://github.com/astral-sh/ruff/pull/7212](https://togithub.com/astral-sh/ruff/pull/7212)
- Location agnostic GitLab fingerprints by
[@&#8203;gregersn](https://togithub.com/gregersn) in
[https://github.com/astral-sh/ruff/pull/7203](https://togithub.com/astral-sh/ruff/pull/7203)

##### Rules

-   \[`ruff`]
- `RUF001`: Remove autofix for ambiguous unicode rule by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7168](https://togithub.com/astral-sh/ruff/pull/7168)

##### Settings

-   \[`flake8-self`]
- `SLF001`: Add `extend-ignore-names` option by
[@&#8203;jaap3](https://togithub.com/jaap3) in
[https://github.com/astral-sh/ruff/pull/7194](https://togithub.com/astral-sh/ruff/pull/7194)

##### Bug Fixes

-   \[`flake8-bugbear`]
- `B006`: Add newline if fix is at end-of-file by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7090](https://togithub.com/astral-sh/ruff/pull/7090)
- `B006`: Fix function docstring followed by whitespace but no newline
by [@&#8203;zanieb](https://togithub.com/zanieb) in
[https://github.com/astral-sh/ruff/pull/7160](https://togithub.com/astral-sh/ruff/pull/7160)
- `B009`: Parenthesize expressions when converting to attribute access
by [@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7091](https://togithub.com/astral-sh/ruff/pull/7091)
- `B009`, `B010`: Fix `getattr` calls on `int` literals by
[@&#8203;density](https://togithub.com/density) in
[https://github.com/astral-sh/ruff/pull/7057](https://togithub.com/astral-sh/ruff/pull/7057)
- `B013`: Supported starred exceptions in length-one tuple detection by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7080](https://togithub.com/astral-sh/ruff/pull/7080)
- `B013`: Insert required space when fixing by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7148](https://togithub.com/astral-sh/ruff/pull/7148)
-   \[`flake8-comprehensions`]
- `C402`: Add required space when fixing by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7152](https://togithub.com/astral-sh/ruff/pull/7152)
- `C404` Add required space when fixing by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7185](https://togithub.com/astral-sh/ruff/pull/7185)
- `C416` Add required space to fix by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7204](https://togithub.com/astral-sh/ruff/pull/7204)
- `C417`: Support length-2 lists in dictionary comprehension rewrites by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7081](https://togithub.com/astral-sh/ruff/pull/7081)
- `C417`: Parenthesize targets if necessary by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7189](https://togithub.com/astral-sh/ruff/pull/7189)
-   \[`flake8-return`]
- `RET504`: Add space after return when inlining number by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7116](https://togithub.com/astral-sh/ruff/pull/7116)
-   \[`flake8-simplify`]
- `SIM105`: Avoid attempting to fix violations with multi-statement
lines by [@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7191](https://togithub.com/astral-sh/ruff/pull/7191)
- `SIM105` Avoid inserting an extra newline for fixes by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7221](https://togithub.com/astral-sh/ruff/pull/7221)
- `SIM118`: Add required space when fixing by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7150](https://togithub.com/astral-sh/ruff/pull/7150)
- `SIM118`: delete `.keys()` rather than replace expression by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7223](https://togithub.com/astral-sh/ruff/pull/7223)
- `SIM210`: Retain parentheses when fixing by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7118](https://togithub.com/astral-sh/ruff/pull/7118)
- `SIM222`: Add parentheses when simplifying conditions by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7117](https://togithub.com/astral-sh/ruff/pull/7117)
- `SIM300`: Add required space when fixing by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7167](https://togithub.com/astral-sh/ruff/pull/7167)
-   \[`flake8-pytest-style`]
- `PT018`: Split within `not`, rather than outside of `not` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7151](https://togithub.com/astral-sh/ruff/pull/7151)
-   \[`flynt`]
- `FLY002`: Add required space for fixes by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7222](https://togithub.com/astral-sh/ruff/pull/7222)
-   \[`numpy`]
- `NPY001`: Avoid attempting to fix with overridden builtins by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7187](https://togithub.com/astral-sh/ruff/pull/7187)
- `NPY003`: Use symbol import for replacement by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7083](https://togithub.com/astral-sh/ruff/pull/7083)
-   \[`pandas-vet`]
- `PD002`: Handle parenthesized calls by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7111](https://togithub.com/astral-sh/ruff/pull/7111)
-   \[`pep8-naming`]
- `N806`: Avoid triggering on `TypeAlias` assignments by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7119](https://togithub.com/astral-sh/ruff/pull/7119)
-   \[`pydocstyle`]
- `D204`: Fix when there's a semicolon after a docstring by
[@&#8203;konstin](https://togithub.com/konstin) in
[https://github.com/astral-sh/ruff/pull/7174](https://togithub.com/astral-sh/ruff/pull/7174)
- `D213`, `D400`: Ignore single quote docstrings with newline escape by
[@&#8203;konstin](https://togithub.com/konstin) in
[https://github.com/astral-sh/ruff/pull/7173](https://togithub.com/astral-sh/ruff/pull/7173)
- `D417`: Fix error with function docstrings with dashed lines by
[@&#8203;eronnen](https://togithub.com/eronnen) in
[https://github.com/astral-sh/ruff/pull/7251](https://togithub.com/astral-sh/ruff/pull/7251)
-   \[`pyflakes`]
- `F401`: Avoid panic with noqa import name by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7260](https://togithub.com/astral-sh/ruff/pull/7260)
- `F841`: Expand fixes to handle parenthesized targets by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7110](https://togithub.com/astral-sh/ruff/pull/7110)
-   \[`pylint`]
- `PLW3301`: Copy the starred argument as is for autofix by
[@&#8203;dhruvmanila](https://togithub.com/dhruvmanila) in
[https://github.com/astral-sh/ruff/pull/7177](https://togithub.com/astral-sh/ruff/pull/7177)
-   \[`pyupgrade`]
- `UP006` and `UP007`: Add required space to fixes by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7202](https://togithub.com/astral-sh/ruff/pull/7202)
- `UP007`: Avoid attempting to fix invalid `Optional` annotations by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7079](https://togithub.com/astral-sh/ruff/pull/7079)
- `UP007`: Fix syntax error in autofix by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7137](https://togithub.com/astral-sh/ruff/pull/7137)
- `UP021`: Avoid adding duplicate `text` keyword to `subprocess.run` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7112](https://togithub.com/astral-sh/ruff/pull/7112)
- `UP022`: Avoid adding duplicate `capture_output` keyword to
`subprocess.run` by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7113](https://togithub.com/astral-sh/ruff/pull/7113)
- `UP028`: Support parenthesized expressions by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7114](https://togithub.com/astral-sh/ruff/pull/7114)
- `UP022`: Avoid fixing when `capture_output` is provided by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7149](https://togithub.com/astral-sh/ruff/pull/7149)
- `UP024`: Add required space when fixing by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7171](https://togithub.com/astral-sh/ruff/pull/7171)
-   \[`ruff`]
- `RUF017`: Avoid duplicate fixes for multi-import imports by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7063](https://togithub.com/astral-sh/ruff/pull/7063)
- Fix named expression precedence in generator by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7170](https://togithub.com/astral-sh/ruff/pull/7170)
- Fix precedence of annotated assignments in generator by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7115](https://togithub.com/astral-sh/ruff/pull/7115)
- Update identifier Unicode character validation to match Python spec by
[@&#8203;LaBatata101](https://togithub.com/LaBatata101) in
[https://github.com/astral-sh/ruff/pull/7209](https://togithub.com/astral-sh/ruff/pull/7209)

##### Other Changes

- Added argfile test and documentation by
[@&#8203;njgrisafi](https://togithub.com/njgrisafi) in
[https://github.com/astral-sh/ruff/pull/7138](https://togithub.com/astral-sh/ruff/pull/7138)

#### New Contributors

- [@&#8203;oliviacrain](https://togithub.com/oliviacrain) made their
first contribution in
[https://github.com/astral-sh/ruff/pull/7093](https://togithub.com/astral-sh/ruff/pull/7093)
- [@&#8203;dalgarno](https://togithub.com/dalgarno) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/7108](https://togithub.com/astral-sh/ruff/pull/7108)
- [@&#8203;manmartgarc](https://togithub.com/manmartgarc) made their
first contribution in
[https://github.com/astral-sh/ruff/pull/7179](https://togithub.com/astral-sh/ruff/pull/7179)
- [@&#8203;jaap3](https://togithub.com/jaap3) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/7194](https://togithub.com/astral-sh/ruff/pull/7194)
- [@&#8203;gregersn](https://togithub.com/gregersn) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/7203](https://togithub.com/astral-sh/ruff/pull/7203)
- [@&#8203;eronnen](https://togithub.com/eronnen) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/7251](https://togithub.com/astral-sh/ruff/pull/7251)

**Full Changelog**:
astral-sh/ruff@v0.0.287...v0.0.288

###
[`v0.0.287`](https://togithub.com/astral-sh/ruff/releases/tag/v0.0.287)

[Compare
Source](https://togithub.com/astral-sh/ruff/compare/v0.0.286...v0.0.287)

<!-- Release notes generated using configuration in .github/release.yml
at v0.0.287 -->

#### What's Changed

##### Rules

- \[refurb] Implement preview `repeated-append` rule (`FURB113`) by
[@&#8203;SavchenkoValeriy](https://togithub.com/SavchenkoValeriy) in
[https://github.com/astral-sh/ruff/pull/6702](https://togithub.com/astral-sh/ruff/pull/6702)
- \[refurb] Implement preview `delete-full-slice` rule (`FURB131`) by
[@&#8203;SavchenkoValeriy](https://togithub.com/SavchenkoValeriy) in
[https://github.com/astral-sh/ruff/pull/6897](https://togithub.com/astral-sh/ruff/pull/6897)
- \[refurb] Implement preview `check-and-remove-from-set` rule
(`FURB132`) by
[@&#8203;SavchenkoValeriy](https://togithub.com/SavchenkoValeriy) in
[https://github.com/astral-sh/ruff/pull/6904](https://togithub.com/astral-sh/ruff/pull/6904)

##### Bug Fixes

- Expand `PERF401` and `PERF402` with type checks by
[@&#8203;qdegraaf](https://togithub.com/qdegraaf) in
[https://github.com/astral-sh/ruff/pull/6994](https://togithub.com/astral-sh/ruff/pull/6994)
- Insert space to avoid syntax error in RSE fixes by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/6886](https://togithub.com/astral-sh/ruff/pull/6886)
- Avoid PEP 604 upgrades that lead to invalid syntax by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/6888](https://togithub.com/astral-sh/ruff/pull/6888)
- Fix ranges for global usages by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/6917](https://togithub.com/astral-sh/ruff/pull/6917)
- Avoid invalid fix for C417 with separate keys and values by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/6954](https://togithub.com/astral-sh/ruff/pull/6954)
- Avoid panic when `typename` is provided as a keyword argument by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/6955](https://togithub.com/astral-sh/ruff/pull/6955)
- Improve compatibility between multi-statement PYI rules by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/7024](https://togithub.com/astral-sh/ruff/pull/7024)
- Fixed panic in `missing_copyright_notice` by
[@&#8203;WindowGenerator](https://togithub.com/WindowGenerator) in
[https://github.com/astral-sh/ruff/pull/7029](https://togithub.com/astral-sh/ruff/pull/7029)
- Avoid lexer infinite loop on invalid input by
[@&#8203;dhruvmanila](https://togithub.com/dhruvmanila) in
[https://github.com/astral-sh/ruff/pull/6937](https://togithub.com/astral-sh/ruff/pull/6937)
- Fix `WithItem` ranges for parenthesized, non-`as` items by
[@&#8203;charliermarsh](https://togithub.com/charliermarsh) in
[https://github.com/astral-sh/ruff/pull/6782](https://togithub.com/astral-sh/ruff/pull/6782)

#### New Contributors

- [@&#8203;SavchenkoValeriy](https://togithub.com/SavchenkoValeriy) made
their first contribution in
[https://github.com/astral-sh/ruff/pull/6702](https://togithub.com/astral-sh/ruff/pull/6702)
- [@&#8203;Anselmoo](https://togithub.com/Anselmoo) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/6986](https://togithub.com/astral-sh/ruff/pull/6986)
- [@&#8203;njgrisafi](https://togithub.com/njgrisafi) made their first
contribution in
[https://github.com/astral-sh/ruff/pull/7032](https://togithub.com/astral-sh/ruff/pull/7032)
- [@&#8203;WindowGenerator](https://togithub.com/WindowGenerator) made
their first contribution in
[https://github.com/astral-sh/ruff/pull/7029](https://togithub.com/astral-sh/ruff/pull/7029)

**Full Changelog**:
astral-sh/ruff@v0.0.286...v0.0.287

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/fulcrum-so/ziggy-pydust-template).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi44My4wIiwidXBkYXRlZEluVmVyIjoiMzYuODMuMCIsInRhcmdldEJyYW5jaCI6ImRldmVsb3AifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rule Implementing or modifying a lint rule

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants