-
-
Notifications
You must be signed in to change notification settings - Fork 30.6k
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
[3.13.0b4] f-string with precision specifier has format_spec
of Constant
, not JoinedStr
#122300
Comments
format_spec
of Const
, not JoinedStr
format_spec
of Constant
, not JoinedStr
Bisected to c46d64e |
Thanks for the bisect. That PR updated the docs for |
Note that the docs are not prescriptive over what the shape of the AST will be, it's just an example. The actual shape of the AST can still change due to bug fixes and grammar extensions so I would not recommend looking at those docs as a prescription with any backwards compatibility guarantees. Being said that I can try to investigate how difficult it's to preserve this because I understand how annoying this can be downstream if you don't have anything you can match against and was like that for several versions. |
I think #122308 will do the trick |
… elements Signed-off-by: Pablo Galindo <pablogsal@gmail.com>
Will backport this soon |
… single elements (pythonGH-122308) (cherry picked from commit db2d8b6) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
… single elements (pythonGH-122308) (cherry picked from commit db2d8b6) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com> Signed-off-by: Pablo Galindo <pablogsal@gmail.com>
… single elements (pythonGH-122308) (cherry picked from commit db2d8b6) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
All done! |
Bug report
Bug description:
Docs say
FormattedValue.format_spec
is aJoinedStr
.Reported downstream in pylint-dev/astroid#2478
Not present in 3.13.0b3
CPython versions tested on:
3.13
Operating systems tested on:
Linux, macOS
Linked PRs
The text was updated successfully, but these errors were encountered: