From: "Brian C. Lane" bcl@redhat.com
The base class should have a generic message, not one that is specific to the username entry.
Related: rhbz#1248421 --- pyanaconda/ui/tui/spokes/__init__.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/pyanaconda/ui/tui/spokes/__init__.py b/pyanaconda/ui/tui/spokes/__init__.py index 456b5c8..b6d6288 100644 --- a/pyanaconda/ui/tui/spokes/__init__.py +++ b/pyanaconda/ui/tui/spokes/__init__.py @@ -97,7 +97,11 @@ class NormalTUISpoke(TUISpoke, NormalSpoke): # Inherit abstract methods from NormalTUISpoke # pylint: disable=abstract-method class EditTUIDialog(NormalTUISpoke): - """Spoke/dialog used to read new value of textual or password data""" + """Spoke/dialog used to read new value of textual or password data + + To override the wrong input message set the wrong_input_message attribute + to a translated string. + """
title = N_("New value") PASSWORD = re.compile(".*") @@ -174,8 +178,7 @@ def input(self, entry, key): if self.wrong_input_message: print(self.wrong_input_message) else: - print(_("You have provided an invalid user name: %s\n" - "Tip: Keep your user name shorter than 32 characters and do not use spaces.\n") % key) + print(_("You have provided an invalid value\n")) return NormalTUISpoke.input(self, entry, key)
class OneShotEditTUIDialog(EditTUIDialog):