-
Notifications
You must be signed in to change notification settings - Fork 1.5k
[flake8-return
] Stabilize only add return None
at the end when fixing implicit-return
(RET503
)
#18516
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
|
code | total | + violation | - violation | + fix | - fix |
---|---|---|---|---|---|
RET503 | 289 | 134 | 155 | 0 | 0 |
Linter (preview)
✅ ecosystem check detected no linter changes.
9252447
to
829acf4
Compare
4112464
to
ed85b61
Compare
ntBre
approved these changes
Jun 9, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, this looks right to me! Just one idea/question
...ules/flake8_return/snapshots/ruff_linter__rules__flake8_return__tests__RET503_RET503.py.snap
Show resolved
Hide resolved
aaf6c9b
to
96913d1
Compare
3ad0f1f
to
ff6fb14
Compare
ed85b61
to
6be65bb
Compare
351e674
to
4cfaa39
Compare
6be65bb
to
5977a58
Compare
ntBre
pushed a commit
that referenced
this pull request
Jun 16, 2025
…xing `implicit-return` (`RET503`) (#18516) This involved slightly more code changes than usual for a stabilization - so maybe worth double-checking the logic! I did verify by hand that the new stable behavior on the test fixture matches the old preview behavior, even after the internal refactor.
ntBre
pushed a commit
that referenced
this pull request
Jun 17, 2025
…xing `implicit-return` (`RET503`) (#18516) This involved slightly more code changes than usual for a stabilization - so maybe worth double-checking the logic! I did verify by hand that the new stable behavior on the test fixture matches the old preview behavior, even after the internal refactor.
ntBre
pushed a commit
that referenced
this pull request
Jun 17, 2025
…xing `implicit-return` (`RET503`) (#18516) This involved slightly more code changes than usual for a stabilization - so maybe worth double-checking the logic! I did verify by hand that the new stable behavior on the test fixture matches the old preview behavior, even after the internal refactor.
carljm
added a commit
to MatthewMckee4/ruff
that referenced
this pull request
Jun 17, 2025
…ence * main: (71 commits) Bump 0.12.0 (astral-sh#18724) Revert "[ty] Offer "Did you mean...?" suggestions for unresolved `from` imports and unresolved attributes (astral-sh#18705)" (astral-sh#18721) [`flake8-return`] Stabilize only add `return None` at the end when fixing `implicit-return` (`RET503`) (astral-sh#18516) [`pyupgrade`] Stabilize `non-pep695-generic-function` (`UP047`) (astral-sh#18524) [`pyupgrade`] Stabilize `non-pep695-generic-class` (`UP046`) (astral-sh#18519) [`pandas-vet`] Deprecate `pandas-df-variable-name` (`PD901`) (astral-sh#18618) [`flake8-bandit`] Remove `suspicious-xmle-tree-usage` (`S320`) (astral-sh#18617) Stabilize `dataclass-enum` (`RUF049`) (astral-sh#18570) Stabilize `unnecessary-dict-index-lookup` (`PLR1733`) (astral-sh#18571) Remove rust-toolchain.toml from sdist (astral-sh#17925) Stabilize `starmap-zip` (`RUF058`) (astral-sh#18525) [`flake8-logging`] Stabilize `exc-info-outside-except-handler` (`LOG014`) (astral-sh#18517) [`pyupgrade`] Stabilize `non-pep604-annotation-optional` (`UP045`) and preview behavior for `non-pep604-annotation-union` (`UP007`) (astral-sh#18505) Stabilize `pytest-warns-too-broad` (`PT030`) (astral-sh#18568) Stabilize `for-loop-writes` (`FURB122`) (astral-sh#18565) Stabilize `pytest-warns-with-multiple-statements` (`PT031`) (astral-sh#18569) Stabilize `pytest-parameter-with-default-argument` (`PT028`) (astral-sh#18566) Stabilize `nan-comparison` (`PLW0177`) (astral-sh#18559) Stabilize `check-and-remove-from-set` (`FURB132`) (astral-sh#18560) Stabilize `unnecessary-round` (`RUF057`) (astral-sh#18563) ...
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This involved slightly more code changes than usual for a stabilization - so maybe worth double-checking the logic!
I did verify by hand that the new stable behavior on the test fixture matches the old preview behavior, even after the internal refactor.