[New-bugs-announce] [issue44885] Incorrect exception highlighting for fstring format
Pablo Galindo Salgado
report at bugs.python.org
Wed Aug 11 03:59:02 EDT 2021
New submission from Pablo Galindo Salgado <pablogsal at gmail.com>:
Given this code:
print(f"Here is that pesky {xxx/2:.3f} again")
The traceback prints:
Traceback (most recent call last):
File "/home/pablogsal/github/python/main/lel.py", line 1, in <module>
print(f"Here is that pesky {xxx/2:.3f} again")
^^^
NameError: name 'xxx' is not defined
Removing the formatting part ":.3f" makes it work as expected
----------
components: Interpreter Core
messages: 399372
nosy: BTaskaya, ammar2, pablogsal
priority: normal
severity: normal
status: open
title: Incorrect exception highlighting for fstring format
type: behavior
versions: Python 3.11
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue44885>
_______________________________________
More information about the New-bugs-announce
mailing list