This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Riccardo Polignieri
Recipients Riccardo Polignieri
Date 2018-03-30.20:25:16
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1522441516.38.0.467229070634.issue33189@psf.upfronthosting.co.za>
In-reply-to
Content
Tested (on windows) with python 3.6, but I guess it's the same in py3.7: 

# test.py
def hello(x):
  print(_(f'hello {x}'))



> py pygettext.py test.py
Traceback (most recent call last):
  File "C:\Program Files\Python36\Tools\i18n\pygettext.py", line 623, in <module>
    if __name__ == '__main__':
  File "C:\Program Files\Python36\Tools\i18n\pygettext.py", line 597, in main
    for _token in tokens:
  File "C:\Program Files\Python36\Tools\i18n\pygettext.py", line 328, in __call__
    ##              'tstring:', tstring
  File "C:\Program Files\Python36\Tools\i18n\pygettext.py", line 382, in __openseen
    elif ttype == tokenize.STRING:
  File "C:\Program Files\Python36\Tools\i18n\pygettext.py", line 236, in safe_eval
    # unwrap quotes, safely
  File "<string>", line 1, in <module>
NameError: name 'x' is not defined
History
Date User Action Args
2018-03-30 20:25:16Riccardo Polignierisetrecipients: + Riccardo Polignieri
2018-03-30 20:25:16Riccardo Polignierisetmessageid: <1522441516.38.0.467229070634.issue33189@psf.upfronthosting.co.za>
2018-03-30 20:25:16Riccardo Polignierilinkissue33189 messages
2018-03-30 20:25:16Riccardo Poligniericreate