Skip to content

[flake8-bugbear] Treat return as equivalent to break (B909)#12646

Merged
charliermarsh merged 1 commit intomainfrom
charlie/return
Aug 2, 2024
Merged

[flake8-bugbear] Treat return as equivalent to break (B909)#12646
charliermarsh merged 1 commit intomainfrom
charlie/return

Conversation

@charliermarsh
Copy link
Copy Markdown
Member

Closes #12640.

@charliermarsh charliermarsh added the bug Something isn't working label Aug 2, 2024
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Aug 2, 2024

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

ℹ️ ecosystem check detected linter changes. (+2 -1 violations, +0 -0 fixes in 2 projects; 52 projects unchanged)

rotki/rotki (+2 -0 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --ignore RUF9 --output-format concise --preview

+ rotkehlchen/api/rest.py:526:130: RUF100 [*] Unused `noqa` directive (unused: `B909`)
+ rotkehlchen/chain/evm/decoding/decoder.py:926:44: RUF100 [*] Unused `noqa` directive (unused: `B909`)

pytest-dev/pytest (+0 -1 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --ignore RUF9 --output-format concise --preview

- src/_pytest/pytester.py:310:17: B909 Mutation to loop iterable `self.calls` during iteration

Changes by rule (2 rules affected)

code total + violation - violation + fix - fix
RUF100 2 2 0 0 0
B909 1 0 1 0 0

@charliermarsh charliermarsh merged commit c858afe into main Aug 2, 2024
@charliermarsh charliermarsh deleted the charlie/return branch August 2, 2024 22:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

B909 False-positive: Detects immediate break but not return

1 participant