vscode python gettext : Pylance reports undefined variable '_'
vscode python gettext : Pylance reports undefined variable '_' Question: In a localized program I use gettext.install() in the main modul src/testgettext.py. The documentation (python 3.10.7) says gettext.install(domain, localedir=None, codeset=None, names=None) This installs the function _() in Python’s builtins namespace… The code import gettext gettext.install("any") de = gettext.translation(‘testgettext’,localedir="src/locales", languages=[‘de’]) de.install() print(_("Selected Files:")) functions as awaited, …