Proper detection of self-doc and PEP 701 f-strings - #360
Draft
netromdk wants to merge 10 commits into
Draft
Conversation
self-doc is 3.8+ PEP 701 f-string is 3.12+
netromdk
force-pushed
the
f-string-improvements
branch
from
September 4, 2026 06:45
154adf7 to
8e7f0eb
Compare
netromdk
force-pushed
the
f-string-improvements
branch
3 times, most recently
from
September 5, 2026 06:11
44bd571 to
4999538
Compare
netromdk
force-pushed
the
f-string-improvements
branch
2 times, most recently
from
September 6, 2026 06:27
68a457b to
2439080
Compare
It is gated behind `--feature fstring-pep701`. Detection requires Python 3.12+ to parse the syntax.
`visit_keyword()` only analyzed kwarg values when the callee matched a known kwarg rule, so user-defined callee values were never visited, and thus under-reporting the minimum version in certain cases.
They are now always-on but can be disabled by using `--no-feature`.
netromdk
force-pushed
the
f-string-improvements
branch
from
September 6, 2026 06:32
2439080 to
76f55da
Compare
netromdk
force-pushed
the
f-string-improvements
branch
from
September 6, 2026 06:34
76f55da to
581a133
Compare
Since 3.7, `await` may be used in expressions within f-strings.
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
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.
WIP