The Variety UI is displayed in English even when the session uses a locale
for which Variety ships a translation. I reproduced this with German.
Steps to reproduce:
$ env LANGUAGE=de LC_ALL=de_DE.UTF-8 /usr/bin/python3 \
-c 'from variety.Util import _; print(_("_Next"))'
_Next
Expected result:
_Nächstes
Cause:
Since upstream commit 3d2778d9ffbd302fb48603ed0be5fcde085645b2,
variety/Util.py unconditionally binds the "variety" gettext domain to the
package-local directory variety/locale:
gettext.bindtextdomain(
"variety", localedir=importlib.resources.files("variety") / "locale"
)
The Debian package does not install that directory. Its compiled catalogs
are instead installed in the standard system location, for example:
/usr/share/locale/de/LC_MESSAGES/variety.mo
Consequently gettext searches a nonexistent directory and silently returns
the untranslated msgids. The catalogs themselves are valid; rebinding the
domain to /usr/share/locale returns the expected German translation.
Possible fix:
Please patch Variety to use the system locale directory when the
package-local locale directory does not exist. Alternatively, install the
compiled catalogs under the package-local variety/locale directory expected
by the upstream code.
This affects the indicator menu as well as the rest of the gettext-based UI.
The issue appears to be specific to the new 0.9.1 packaging/layout.