| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
| |
(GH-112284) (#112285)
(cherry picked from commit d59feb5dbe5395615d06c30a95e6a6a9b7681d4d)
|
| |
|
|
|
|
|
|
| |
avoid false positives (GH-109121). (#109155)
(cherry picked from commit 5bda2f637e1cfbca45a83aa6e22db25498064b27)
Signed-off-by: Pablo Galindo <pablogsal@gmail.com>
|
| |
|
|
|
|
|
|
| |
(GH-107968) (#107970)
gh-107967: Fix infinite recursion on invalid escape sequence warning (GH-107968)
(cherry picked from commit d66bc9e8a7a8d6774d912a4b9d151885c4d8de1d)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
|
| |
|
|
|
|
|
| |
(GH-106401) (#106416)
(cherry picked from commit dfe4de203881e8d068e6fc5b8e31075841a86d25)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
|
| |
|
|
|
|
|
| |
test_fstring (GH-105943) (#105945)
(cherry picked from commit 6e40ee6e8456da04d6970a46863300c043c81208)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
|
| |
|
|
|
|
|
|
| |
(GH-105940) (#105942)
(cherry picked from commit 4b431d2e90bf5760a57aa40af2dd78e7bbf0b1ae)
Co-authored-by: @sunmy2019
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
|
| |
|
|
|
|
|
| |
(GH-105939) (#105941)
(cherry picked from commit 6586cee27f32f0354fe4e77c7b8c6e399329b5e2)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
|
| |
|
|
|
|
|
| |
tokenizer (GH-105828) (#105832)
(cherry picked from commit d382ad49157b3802fc5619f68d96810def517869)
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
|
| |
|
|
|
|
| |
sequences (GH-105801) (#105806)
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
|
| |
|
|
| |
(GH-105231) (#105234)
|
| | |
|
| |
|
|
| |
(#104660)
|
| |
|
| |
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
|
| | |
|
| |
|
|
|
|
| |
Co-authored-by: sunmy2019 <59365878+sunmy2019@users.noreply.github.com>
Co-authored-by: Ken Jin <kenjin@python.org>
Co-authored-by: Pablo Galindo <pablogsal@gmail.com>
|
| |
|
|
|
| |
(GH-103896)
Co-authored-by: Pablo Galindo <pablogsal@gmail.com>
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
| |
Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Co-authored-by: Batuhan Taskaya <isidentical@gmail.com>
Co-authored-by: Marta Gómez Macías <mgmacias@google.com>
Co-authored-by: sunmy2019 <59365878+sunmy2019@users.noreply.github.com>
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A backslash-character pair that is not a valid escape sequence now
generates a SyntaxWarning, instead of DeprecationWarning. For
example, re.compile("\d+\.\d+") now emits a SyntaxWarning ("\d" is an
invalid escape sequence), use raw strings for regular expression:
re.compile(r"\d+\.\d+"). In a future Python version, SyntaxError will
eventually be raised, instead of SyntaxWarning.
Octal escapes with value larger than 0o377 (ex: "\477"), deprecated
in Python 3.11, now produce a SyntaxWarning, instead of
DeprecationWarning. In a future Python version they will be
eventually a SyntaxError.
codecs.escape_decode() and codecs.unicode_escape_decode() are left
unchanged: they still emit DeprecationWarning.
* The parser only emits SyntaxWarning for Python 3.12 (feature
version), and still emits DeprecationWarning on older Python
versions.
* Fix SyntaxWarning by using raw strings in Tools/c-analyzer/ and
wasm_build.py.
|
| |
|
|
| |
nodes (#94895)
|
| |
|
|
| |
but no closing brace. (gh-93419)
|
| |
|
|
| |
character (GH-93349)
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
* Add more informative messages to f-string syntax errors
* 📜🤖 Added by blurb_it.
* Fix whitespaces
* Change error message
* Remove the 'else' statement (as sugested in review)
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
|
| |
|
|
| |
character if the f-string is missing a trailing right brace. (#31365)
|
| |
|
|
|
|
|
| |
sequences in f-strings. (GH-30865)
* bpo-46503: Prevent an assert from firing. Also fix one nearby tiny PEP-7 nit.
* Added blurb.
|
| |
|
|
| |
inside parentheses (GH-29757)
|
| |
|
|
| |
repeated expressions (GH-27729)
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
* bpo-43797: Improve syntax error for invalid comparisons
* Update Lib/test/test_fstring.py
Co-authored-by: Guido van Rossum <gvanrossum@gmail.com>
* Apply review comments
* can't -> cannot
Co-authored-by: Guido van Rossum <gvanrossum@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
| |
* Fix test_float
* Fix _osx_support
* Fix test_fstring
* Fix test_gc
* Fix test_gzip
* Fix test_hashlib
* Fix unrelated whitespace issue
Co-authored-by: Ned Deily <nad@python.org>
|
| |
|
|
| |
(GH-25006)
|
| |
|
|
| |
newlines (GH-24279)
|
| |
|
| |
Automerge-Triggered-By: GH:isidentical
|
| | |
|
| | |
|
| |
|
|
|
|
|
| |
in format specifier (GH-22036)
* Fixed `f-string/str.format` error description when using two `,` in format specifier.
Co-authored-by: millefalcon <hanish0019@hmail.com>
|
| | |
|
| |
|
|
|
| |
(GH-21084)
Prefix the error message with `fstring: `, when parsing an f-string expression throws a `SyntaxError`.
|
| |
|
|
| |
characters. (GH-21035)
|
| |
|
| |
This commit removes the old parser, the deprecated parser module, the old parser compatibility flags and environment variables and all associated support code and documentation.
|
| |
|
|
| |
statements with no value (GH-20701)
|
| |
|
|
|
|
|
|
| |
When a `SyntaxError` in the expression part of a fstring is found,
the filename attribute of the `SyntaxError` is always `<fstring>`.
With this commit, it gets changed to always have the name of the file
the fstring resides in.
Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
|
| |
|
|
| |
(GH-20033)
|
| |
|
|
| |
Due to backwards compatibility concerns regarding keywords immediately followed by a string without whitespace between them (like in `bg="#d00" if clear else"#fca"`) will fail to parse,
commit 41d5b94af44e34ac05d4cd57460ed104ccf96628 has to be reverted.
|
| | |
|
| |
|
| |
`JoinedStr`s and `FormattedValue also needs to be shifted, in order to correctly compute the location information of nested f-strings.
|
| |
|
|
|
|
|
|
|
|
|
| |
* Rename PyConfig.use_peg to _use_peg_parser
* Document PyConfig._use_peg_parser and mark it a deprecated
* Mark -X oldparser option and PYTHONOLDPARSER env var as deprecated
in the documentation.
* Add use_old_parser() and skip_if_new_parser() to test.support
* Remove sys.flags.use_peg: use_old_parser() uses
_testinternalcapi.get_configs() instead.
* Enhance test_embed tests
* subprocess._args_from_interpreter_flags() copies -X oldparser
|